diff --git a/src/utils/index.js b/src/utils/index.js index e97a8bea..819c4ba7 100644 --- a/src/utils/index.js +++ b/src/utils/index.js @@ -68,3 +68,29 @@ export function formatTime(time, option) { ) } } + +function zeroFill(i) { + if (i >= 0 && i <= 9) { + return '0' + i + } else { + return i + } +} + +export function getNowDAY() { // 默认显示今天 +// 获取当前时间 + const date = new Date() + const month = zeroFill(date.getMonth() + 1) + const day = zeroFill(date.getDate()) + const time = date.getFullYear() + '-' + month + '-' + day + return time +} + +export function get90DAY() { // 3个月显示今天 + var Data = new Date() + Data.setTime(Data.getTime() - 3600 * 1000 * 24 * 90) + const month = zeroFill(Data.getMonth() + 1) + const day = zeroFill(Data.getDate()) + const time = Data.getFullYear() + '-' + month + '-' + day + return time +} diff --git a/src/views/Inventory/CreatePickingList/index.vue b/src/views/Inventory/CreatePickingList/index.vue index 5fdb5a45..0ddd6c82 100644 --- a/src/views/Inventory/CreatePickingList/index.vue +++ b/src/views/Inventory/CreatePickingList/index.vue @@ -21,7 +21,7 @@ :value="item.value"/> - 查询 + 查询 - +