提交 1136a5c1 编写于 作者: KK's avatar KK

日历事件调整

上级 b5935cc6
...@@ -425,21 +425,19 @@ import moment from 'moment'; ...@@ -425,21 +425,19 @@ import moment from 'moment';
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}
*/ */
protected async load(opt: any = {}): Promise<any> { protected async load(opt: any = {},isSetTileContent:boolean=true): Promise<any> {
const arg: any = { ...opt }; const arg: any = { ...opt };
const isloading: boolean = this.showBusyIndicator === true ? true : false; const isloading: boolean = this.showBusyIndicator === true ? true : false;
const response: any = await this.service.search(this.activeItem, { ...this.context }, { ...arg }, this.showBusyIndicator); const response: any = await this.service.search(this.activeItem, { ...this.context }, { ...arg }, this.showBusyIndicator);
if (response && response.status === 200) { if (response && response.status === 200) {
this.calendarItems = response.data; this.calendarItems = response.data;
this.setTileContent(); isSetTileContent?this.setTileContent():"";
} else { } else {
this.$notice.error('系统异常,请重试!'); this.$notice.error('系统异常,请重试!');
} }
this.show = true; this.show = true;
} }
/** /**
* 设置事件数组 * 设置事件数组
* *
...@@ -553,7 +551,7 @@ import moment from 'moment'; ...@@ -553,7 +551,7 @@ import moment from 'moment';
this.day = temptime.getDate(); this.day = temptime.getDate();
this.start = (moment as any)(temptime).startOf('day').format('YYYY-MM-DD HH:mm:ss'); this.start = (moment as any)(temptime).startOf('day').format('YYYY-MM-DD HH:mm:ss');
this.end = (moment as any)(temptime).endOf('day').format('YYYY-MM-DD HH:mm:ss'); this.end = (moment as any)(temptime).endOf('day').format('YYYY-MM-DD HH:mm:ss');
this.load(Object.assign(this.viewparams, { "start": this.start, "end": this.end })); this.load(Object.assign(this.viewparams, { "start": this.start, "end": this.end }),false);
} }
} }
...@@ -641,7 +639,7 @@ import moment from 'moment'; ...@@ -641,7 +639,7 @@ import moment from 'moment';
} }
if (response && Object.is(response.ret, 'OK')) { if (response && Object.is(response.ret, 'OK')) {
// 刷新日历 // 刷新日历
this.load(Object.assign(this.viewparams, { "start": this.start, "end": this.end })); this.load(Object.assign(this.viewparams, { "start": this.start, "end": this.end }),false);
} }
} }
} }
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册