提交 01384142 编写于 作者: WodahsOrez's avatar WodahsOrez

lxm--日历搜索表单,快速分组,快速搜索--fix1

上级 880e4239
...@@ -337,6 +337,9 @@ FullCalendar, ...@@ -337,6 +337,9 @@ FullCalendar,
Object.assign(arg,{query : fetchInfo.query}); Object.assign(arg,{query : fetchInfo.query});
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
const parentdata: any = {};
this.$emit('beforeload', parentdata);
Object.assign(arg, parentdata);
// 处理events数据 // 处理events数据
let _this = this; let _this = this;
let handleEvents = ()=>{ let handleEvents = ()=>{
......
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
<#if view.getViewType() == 'DECALENDAREXPVIEW'> <#if view.getViewType() == 'DECALENDAREXPVIEW'>
:isSelectFirstDefault="true" :isSelectFirstDefault="true"
</#if> </#if>
@beforeload="onBeforeLoad($event)"
</#assign> </#assign>
<#ibizinclude> <#ibizinclude>
../@MACRO/HTML/DEFAULT.html.ftl ../@MACRO/HTML/DEFAULT.html.ftl
......
...@@ -47,10 +47,37 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -47,10 +47,37 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
public onSearch($event: any): void { public onSearch($event: any): void {
const refs: any = this.$refs; const refs: any = this.$refs;
if (refs.calendar) { if (refs.calendar) {
refs.calendar.load({}); refs.calendar.refresh();
} }
} }
/**
* calendar 的 beforeload 事件
*
* @param {*} arg
* @memberof ${srfclassname('${view.name}')}
*/
public onBeforeLoad(arg: any){
if (this.viewparams && Object.keys(thisparams).length > 0) {
Object.assign(arg, this.viewparams);
}
if (this.getSearchForm() && this.isExpandSearchForm) {
Object.assign(arg, this.getSearchForm().getData());
}
if (this && !this.isExpandSearchForm) {
Object.assign(arg, { query: this.query });
}
// 快速分组和快速搜索栏
let otherQueryParam:any = {};
if(this && this.qucikGroupData){
Object.assign(otherQueryParam,this.qucikGroupData);
}
if(this && this.qucikFormData){
Object.assign(otherQueryParam,this.qucikFormData);
}
Object.assign(arg,{viewparams:otherQueryParam});
}
<#if view.getPSSysCounterRef() ?? && view.getPSSysCounterRef().getPSAppCounter()??> <#if view.getPSSysCounterRef() ?? && view.getPSSysCounterRef().getPSAppCounter()??>
<#assign appCounter = view.getPSSysCounterRef().getPSAppCounter() /> <#assign appCounter = view.getPSSysCounterRef().getPSAppCounter() />
/** /**
...@@ -134,8 +161,8 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -134,8 +161,8 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
const key = (value.substring(1, value.length - 1)).toLowerCase(); const key = (value.substring(1, value.length - 1)).toLowerCase();
if (this.context[key]) { if (this.context[key]) {
value = this.context[key]; value = this.context[key];
} else if(this.viewparams[key]){ } else if(thisparams[key]){
value = this.viewparams[key]; value = thisparams[key];
} }
} }
item.data[name] = value; item.data[name] = value;
......
...@@ -77,10 +77,37 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -77,10 +77,37 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
public onSearch($event: any): void { public onSearch($event: any): void {
const refs: any = this.$refs; const refs: any = this.$refs;
if (refs.calendar) { if (refs.calendar) {
refs.calendar.load({}); refs.calendar.refresh();
} }
} }
/**
* calendar 的 beforeload 事件
*
* @param {*} arg
* @memberof ${srfclassname('${view.name}')}
*/
public onBeforeLoad(arg: any){
if (this.viewparams && Object.keys(thisparams).length > 0) {
Object.assign(arg, this.viewparams);
}
if (this.getSearchForm() && this.isExpandSearchForm) {
Object.assign(arg, this.getSearchForm().getData());
}
if (this && !this.isExpandSearchForm) {
Object.assign(arg, { query: this.query });
}
// 快速分组和快速搜索栏
let otherQueryParam:any = {};
if(this && this.qucikGroupData){
Object.assign(otherQueryParam,this.qucikGroupData);
}
if(this && this.qucikFormData){
Object.assign(otherQueryParam,this.qucikFormData);
}
Object.assign(arg,{viewparams:otherQueryParam});
}
<#if view.getPSSysCounterRef() ?? && view.getPSSysCounterRef().getPSAppCounter()??> <#if view.getPSSysCounterRef() ?? && view.getPSSysCounterRef().getPSAppCounter()??>
<#assign appCounter = view.getPSSysCounterRef().getPSAppCounter() /> <#assign appCounter = view.getPSSysCounterRef().getPSAppCounter() />
/** /**
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册