1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
<#list ctrl.getAllPSDEFormDetails() as formdetail>
<#if formdetail.getPSDEFDGroupLogic('ITEMBLANK')??>
<#assign ITEMBLANK = formdetail.getPSDEFDGroupLogic('ITEMBLANK')/>
if (Object.is(name, '')<#if ITEMBLANK.getRelatedDetailNames()??><#list ITEMBLANK.getRelatedDetailNames() as detailName> || Object.is(name, '${detailName}')</#list></#if>) {
let ret = true;
<#if ITEMBLANK.getRelatedDetailNames()??>
<#list ITEMBLANK.getRelatedDetailNames() as detailName>
const _${detailName} = this.data.${detailName};
</#list>
</#if>
if (${P.getPartCode(ITEMBLANK, 'DETAIL_LOGIC').code}) {
ret = false;
}
this.rules.${formdetail.name}.some((rule: any) => {
if (rule.hasOwnProperty('required')) {
rule.required = ret;
}
return false;
});
}
</#if>
<#if formdetail.getPSDEFDGroupLogic('ITEMENABLE')??>
<#assign ITEMENABLE = formdetail.getPSDEFDGroupLogic('ITEMENABLE')/>
if (Object.is(name, '')<#if ITEMENABLE.getRelatedDetailNames()??><#list ITEMENABLE.getRelatedDetailNames() as detailName> || Object.is(name, '${detailName}')</#list></#if>) {
let ret = false;
<#if ITEMENABLE.getRelatedDetailNames()??>
<#list ITEMENABLE.getRelatedDetailNames() as detailName>
const _${detailName} = this.data.${detailName};
</#list>
</#if>
if (${P.getPartCode(ITEMENABLE, 'DETAIL_LOGIC').code}) {
ret = true;
}
this.detailsModel.${formdetail.name}.setDisabled(!ret);
}
</#if>
<#if formdetail.getPSDEFDGroupLogic('PANELVISIBLE')??>
<#assign PANELVISIBLE = formdetail.getPSDEFDGroupLogic('PANELVISIBLE')/>
if (Object.is(name, '')<#if PANELVISIBLE.getRelatedDetailNames()??><#list PANELVISIBLE.getRelatedDetailNames() as detailName> || Object.is(name, '${detailName}')</#list></#if>) {
let ret = false;
<#if PANELVISIBLE.getRelatedDetailNames()??>
<#list PANELVISIBLE.getRelatedDetailNames() as detailName>
const _${detailName} = this.data.${detailName};
</#list>
</#if>
if (${P.getPartCode(PANELVISIBLE, 'DETAIL_LOGIC').code}) {
ret = true;
}
this.detailsModel.${formdetail.name}.setVisible(ret);
}
</#if>
</#list>