From 419e76f6256868851ed245940297f7f5bfd99e55 Mon Sep 17 00:00:00 2001
From: czt <czt18638530771@163.com>
Date: 星期四, 01 六月 2023 17:54:45 +0800
Subject: [PATCH] 化验页面优化1

---
 igds-web/src/main/resources/static/admin/inout/in-sample.js |   29 +----------------------------
 1 files changed, 1 insertions(+), 28 deletions(-)

diff --git a/igds-web/src/main/resources/static/admin/inout/in-sample.js b/igds-web/src/main/resources/static/admin/inout/in-sample.js
index 525ebf8..d51ee06 100644
--- a/igds-web/src/main/resources/static/admin/inout/in-sample.js
+++ b/igds-web/src/main/resources/static/admin/inout/in-sample.js
@@ -356,36 +356,9 @@
         return time;
 }
 
-function formatDateTime(date, format) {
-    const o = {
-        'M+': date.getMonth() + 1, // 鏈堜唤
-        'd+': date.getDate(), // 鏃�
-        'h+': date.getHours() % 12 === 0 ? 12 : date.getHours() % 12, // 灏忔椂
-        'H+': date.getHours(), // 灏忔椂
-        'm+': date.getMinutes(), // 鍒�
-        's+': date.getSeconds(), // 绉�
-        'q+': Math.floor((date.getMonth() + 3) / 3), // 瀛e害
-        S: date.getMilliseconds(), // 姣
-        a: date.getHours() < 12 ? '涓婂崍' : '涓嬪崍', // 涓婂崍/涓嬪崍
-        A: date.getHours() < 12 ? 'AM' : 'PM', // AM/PM
-    };
-    if (/(y+)/.test(format)) {
-        format = format.replace(RegExp.$1, (date.getFullYear() + '').substr(4 - RegExp.$1.length));
-    }
-    for (let k in o) {
-        if (new RegExp('(' + k + ')').test(format)) {
-            format = format.replace(
-                RegExp.$1,
-                RegExp.$1.length === 1 ? o[k] : ('00' + o[k]).substr(('' + o[k]).length)
-            );
-        }
-    }
-    return format;
-}
-
 function showDetail(obj) {
     curSampleData = null;
-    var nowTime = formatDateTime(new Date(), "yyyy-MM-dd HH:mm:ss");
+    var nowTime = dateFtt("yyyy-MM-dd HH:mm:ss", new Date());
     $("#printTime").html(nowTime);
 
     curSampleData = obj.data;

--
Gitblit v1.9.3