|
@@ -60,20 +60,7 @@ function renderView() {
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
- // const str = `<img src="static/img/undraw_male_avatar_323b.svg" alt="">
|
|
|
- // <p class="card-profile-txt">User Profile</p>
|
|
|
- // <p class="card-profile-cnt">${userInfo.user_info.userName}</p>
|
|
|
- // <p class="card-profile-cnt">${userInfo.user_info.email}</p>
|
|
|
- // <div class="d-flex justify-content-around">
|
|
|
- // <div>
|
|
|
- // <p set-lan="html:used">已使用</p>
|
|
|
- // <p><strong>${userInfo.user_info.total_sec}</strong><span set-lan="html:sec">秒</span></p>
|
|
|
- // </div>
|
|
|
- // <div>
|
|
|
- // <p set-lan="html:left">未使用</p>
|
|
|
- // <p><strong>${userInfo.user_info.left_sec}</strong><span set-lan="html:sec">秒</span></p>
|
|
|
- // </div>
|
|
|
- // </div>`;
|
|
|
+
|
|
|
const str = `<img src="static/img/undraw_male_avatar_323b.svg" alt="">
|
|
|
<p class="card-profile-txt">User Profile</p>
|
|
|
<p class="card-profile-cnt">${userInfo.user_info.userName}</p>
|
|
@@ -117,11 +104,21 @@ function renderView() {
|
|
|
}
|
|
|
// 歷史紀錄
|
|
|
// const historicalrecord
|
|
|
- var historicalrecord=''
|
|
|
+ var historicalrecord='';
|
|
|
for (var i = 0; i < userInfo.video_info.length; i++) {
|
|
|
+ let formatted = userInfo.video_info[i].time_stamp;
|
|
|
+ if (lan == 'zh') {
|
|
|
+ const timeStamp = userInfo.video_info[i].time_stamp;
|
|
|
+ const year = timeStamp.split(',')[0].split('/')[2];
|
|
|
+ const arr = timeStamp.split(',')[0].split('/');
|
|
|
+ arr.pop();
|
|
|
+ arr.unshift(year);
|
|
|
+ const fomatDate = [arr.join('/')];
|
|
|
+ formatted = fomatDate.concat(timeStamp.split(',')[1]).join('');
|
|
|
+ }
|
|
|
historicalrecord+='\
|
|
|
<tr>\
|
|
|
- <td class="px-0">'+userInfo.video_info[i].time_stamp+'</td>\
|
|
|
+ <td class="px-0">'+formatted+'</td>\
|
|
|
<td class="px-0">'+userInfo.video_info[i].title+'</td>\
|
|
|
<td class="px-0 w-25">'+userInfo.video_info[i].duration+'</td>\
|
|
|
</tr>`\
|