|
@@ -3,7 +3,7 @@ export function timeFix () {
|
|
const hour = time.getHours()
|
|
const hour = time.getHours()
|
|
return hour < 9 ? '早上好' : hour <= 11 ? '上午好' : hour <= 13 ? '中午好' : hour < 20 ? '下午好' : '晚上好'
|
|
return hour < 9 ? '早上好' : hour <= 11 ? '上午好' : hour <= 13 ? '中午好' : hour < 20 ? '下午好' : '晚上好'
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
export function welcome () {
|
|
export function welcome () {
|
|
const arr = ['休息一会儿吧', '准备吃什么呢?', '要不要打一把 DOTA', '我猜你可能累了']
|
|
const arr = ['休息一会儿吧', '准备吃什么呢?', '要不要打一把 DOTA', '我猜你可能累了']
|
|
const index = Math.floor(Math.random() * arr.length)
|
|
const index = Math.floor(Math.random() * arr.length)
|
|
@@ -70,4 +70,13 @@ export function oneOf (value, validList) {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
return false
|
|
return false
|
|
-}
|
|
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+/*
|
|
|
|
+* 选择起止日期 + 固定时间
|
|
|
|
+* type:1 开始时间 2结束时间
|
|
|
|
+*/
|
|
|
|
+export function dealChooseDate (value, type) {
|
|
|
|
+ const newDate = type == 'start' ? value + ' 00:00:00' : value + ' 23:59:59'
|
|
|
|
+ return newDate
|
|
|
|
+}
|