update 2/2/2026
This commit is contained in:
@@ -32,7 +32,8 @@ export function resolveProductPage(slug: string): ProductResult | null {
|
||||
const data = {
|
||||
...product,
|
||||
productDescription : productDetail.productDescription,
|
||||
productSpec : productDetail.productSpec
|
||||
productSpec : productDetail.productSpec,
|
||||
related : productDetail.related
|
||||
}
|
||||
|
||||
return {
|
||||
|
||||
@@ -71,6 +71,18 @@ export function formatArticleTime(article_time: string) {
|
||||
return `${day}/${month}/${year}`;
|
||||
}
|
||||
|
||||
export function formatDate(a:any){
|
||||
let dateObj = new Date(parseInt(a)*1000);
|
||||
|
||||
let year = dateObj.getFullYear();
|
||||
let month = ((dateObj.getMonth()+1) <= 9) ? '0' + (dateObj.getMonth()+1) : dateObj.getMonth()+1;
|
||||
let date = (dateObj.getDate() < 10) ? '0' + dateObj.getDate() : dateObj.getDate();
|
||||
let hour = (dateObj.getHours() < 10) ? '0' + dateObj.getHours() : dateObj.getHours();
|
||||
let min = (dateObj.getMinutes() < 10) ? '0' + dateObj.getMinutes() : dateObj.getMinutes();
|
||||
let time = `${date}/${month}/${year}, ${hour}:${min}`;
|
||||
return time;
|
||||
}
|
||||
|
||||
//
|
||||
export function normalizeKey(str: string) {
|
||||
return str
|
||||
|
||||
Reference in New Issue
Block a user