Commit f4947fdf30877617272c7dc1dc30098b86787bc1

Authored by vking
1 parent aa6fcd9d

使用默认时间

... ... @@ -146,8 +146,14 @@ Page({
let timeObj = await comm.getTimeSpaceIndexData(d);
//form.time=await comm.getTimeSpaceIndex(d);
form.time = timeObj.timeIndex;
//如果小于默认时间,使用默认时间
let mmii = util.unixtoTime(d,'HH:II')
if (mmii < this.data.defDtime[timeObj.timeIndex]) {
let str=util.unixtoTime(d, 'YYYY-MM-DD '+this.data.defDtime[timeObj.timeIndex]+':00')
timeObj = await comm.getTimeSpaceIndexData(util.timetouUnix(str));
}
form.time = timeObj.timeIndex;
let ind = dateStr._indexOf(nowStr);
if (ind > -1) {
form.date = ind
... ... @@ -163,6 +169,7 @@ Page({
timePickerIndex: timePickerIndex,
timeOpt: timeObj.timeOpt,
};
this.setData(obj)
return obj;
... ...