提交 bf11f757 编写于 作者: Shine-zwj's avatar Shine-zwj

列表和分组方法

上级 9c2b15e0
......@@ -175,6 +175,19 @@ import CodeListService from "@service/app/codelist-service";
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public groupData: Array<any> = [];
/**
* 分组方法
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public group(){
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'AUTO'>
this.drawGroup();
<#elseif ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
this.drawCodelistGroup();
</#if>
}
</#if>
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
......@@ -540,10 +553,8 @@ import CodeListService from "@service/app/codelist-service";
if(this.isSelectFirstDefault){
this.handleClick(this.items[0]);
}
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'AUTO'>
this.drawGroup();
<#elseif ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
this.drawCodelistGroup();
<#if ctrl.isEnableGroup?? && ctrl.isEnableGroup()>
this.group();
</#if>
}, (response: any) => {
if (response && response.status === 401) {
......@@ -608,10 +619,8 @@ import CodeListService from "@service/app/codelist-service";
this.items.some((item:any,index:number)=>{
if(Object.is(item.srfkey,data.srfkey)){
this.items.splice(index,1);
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'AUTO'>
this.drawGroup();
<#elseif ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
this.drawCodelistGroup();
<#if ctrl.isEnableGroup?? && ctrl.isEnableGroup()>
this.group();
</#if>
return true;
}
......
......@@ -217,6 +217,19 @@ import CodeListService from "@service/app/codelist-service";
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public groupData: Array<any> = [];
/**
* 分组方法
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public group(){
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'AUTO'>
this.drawGroup();
<#elseif ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
this.drawCodelistGroup();
</#if>
}
</#if>
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
......@@ -619,10 +632,8 @@ import CodeListService from "@service/app/codelist-service";
if(this.isSelectFirstDefault){
this.handleClick(this.items[0]);
}
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'AUTO'>
this.drawGroup();
<#elseif ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
this.drawCodelistGroup();
<#if ctrl.isEnableGroup?? && ctrl.isEnableGroup()>
this.group();
</#if>
}, (response: any) => {
if (response && response.status === 401) {
......@@ -650,10 +661,8 @@ import CodeListService from "@service/app/codelist-service";
this.items.some((val: any, num: number) =>{
if(JSON.stringify(val) == JSON.stringify(record)){
this.items.splice(num,1);
<#if ctrl.getGroupMode?? && ctrl.getGroupMode() == 'AUTO'>
this.drawGroup();
<#elseif ctrl.getGroupMode?? && ctrl.getGroupMode() == 'CODELIST'>
this.drawCodelistGroup();
<#if ctrl.isEnableGroup?? && ctrl.isEnableGroup()>
this.group();
</#if>
return true;
}
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册