Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
功
功能演示系统
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
示例
功能演示系统
提交
587e7a8a
提交
587e7a8a
编写于
11月 16, 2022
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
tony001 发布系统代码 [后台服务,演示应用]
上级
8efeaf2c
变更
31
隐藏空白字符变更
内嵌
并排
正在显示
31 个修改的文件
包含
3696 行增加
和
44 行删除
+3696
-44
app-todo-list.vue
app_Web/src/components/app-todo-list/app-todo-list.vue
+2
-2
ibizsample0021_BO_CN_base.ts
...nres/entities/ibizsample0021/ibizsample0021_BO_CN_base.ts
+21
-0
ibizsample0021_en_US_base.ts
...nres/entities/ibizsample0021/ibizsample0021_en_US_base.ts
+21
-0
ibizsample0021_zh_CN_base.ts
...nres/entities/ibizsample0021/ibizsample0021_zh_CN_base.ts
+21
-0
ibizsample0021-reassignwfdyna-action-view-base.vue
...n-view/ibizsample0021-reassignwfdyna-action-view-base.vue
+2
-0
ibizsample0021-reassignwfdyna-action-view.vue
...action-view/ibizsample0021-reassignwfdyna-action-view.vue
+2
-0
ibizsample0021-usr1114865995-wfdyna-edit-view3-base.vue
...3/ibizsample0021-usr1114865995-wfdyna-edit-view3-base.vue
+120
-16
default-searchform-base.vue
...s/ibizbook/default-searchform/default-searchform-base.vue
+2
-2
guide-view-form-form-base.vue
...izbook/guide-view-form-form/guide-view-form-form-base.vue
+5
-5
usr4-dataview-base.vue
...src/widgets/ibizbook/usr4-dataview/usr4-dataview-base.vue
+4
-4
usr4-dataview-model.ts
...src/widgets/ibizbook/usr4-dataview/usr4-dataview-model.ts
+5
-0
card-navigation-dataview-base.vue
...ard-navigation-dataview/card-navigation-dataview-base.vue
+4
-4
main-grid-base.vue
app_Web/src/widgets/ibizorder/main-grid/main-grid-base.vue
+21
-7
main-grid-model.ts
app_Web/src/widgets/ibizorder/main-grid/main-grid-model.ts
+15
-0
data-relation-drtab-model.ts
...mple0021/data-relation-drtab/data-relation-drtab-model.ts
+3
-0
start001-form-base.vue
...dgets/ibizsample0021/start001-form/start001-form-base.vue
+16
-0
start001-form-model.ts
...dgets/ibizsample0021/start001-form/start001-form-model.ts
+5
-0
transfer-form-base.vue
...dgets/ibizsample0021/transfer-form/transfer-form-base.vue
+2026
-0
transfer-form-model.ts
...dgets/ibizsample0021/transfer-form/transfer-form-model.ts
+82
-0
transfer-form-service.ts
...ets/ibizsample0021/transfer-form/transfer-form-service.ts
+473
-0
transfer-form.less
...c/widgets/ibizsample0021/transfer-form/transfer-form.less
+55
-0
transfer-form.vue
...rc/widgets/ibizsample0021/transfer-form/transfer-form.vue
+15
-0
IBIZSample0021.json
...model/PSMODULES/Sample/PSDATAENTITIES/IBIZSample0021.json
+89
-0
IBIZSample0021.json
...model/PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json
+18
-0
Start001.json
...eb/PSAPPDATAENTITIES/IBIZSample0021/PSFORMS/Start001.json
+37
-0
Transfer.json
...eb/PSAPPDATAENTITIES/IBIZSample0021/PSFORMS/Transfer.json
+219
-0
IBIZSample0021REASSIGNWFDynaActionView.json
.../PSAPPDEVIEWS/IBIZSample0021REASSIGNWFDynaActionView.json
+319
-0
IBIZSample0021Usr1116491232WFDynaStartView.json
...PPDEVIEWS/IBIZSample0021Usr1116491232WFDynaStartView.json
+74
-0
ACTv2.json
...tatic/remotemodel/PSWORKFLOWS/ACT/PSWFVERSIONS/ACTv2.json
+4
-2
ACTv2.json.bpmn
.../remotemodel/PSWORKFLOWS/ACT/PSWFVERSIONS/ACTv2.json.bpmn
+2
-2
DemoSys.json
demo-core/src/main/resources/sysmodel/DemoSys.json
+14
-0
未找到文件。
app_Web/src/components/app-todo-list/app-todo-list.vue
浏览文件 @
587e7a8a
...
...
@@ -54,7 +54,7 @@ export default class AppTodoList extends Vue {
/**
* 当前分页
*/
public
curPage
:
number
=
0
;
public
curPage
:
number
=
1
;
/**
* 总条数
...
...
@@ -79,7 +79,7 @@ export default class AppTodoList extends Vue {
public
getMyTasks
()
{
const
params
=
{
size
:
this
.
limit
,
page
:
this
.
curPage
page
:
this
.
curPage
-
1
};
let
url
:
any
=
'/wfcore/mytasks'
;
if
(
this
.
query
)
{
...
...
app_Web/src/locale/lanres/entities/ibizsample0021/ibizsample0021_BO_CN_base.ts
浏览文件 @
587e7a8a
...
...
@@ -16,6 +16,7 @@ function getLocaleResourceBase(){
curdeptid
:
commonLogic
.
appcommonhandle
(
"CURDEPTID"
,
null
),
amount
:
commonLogic
.
appcommonhandle
(
"总计"
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
},
views
:
{
wfdynaactionview
:
{
...
...
@@ -110,6 +111,7 @@ function getLocaleResourceBase(){
srfdeid
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfsourcekey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
ibizsample0021id
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
},
uiactions
:
{
...
...
@@ -307,6 +309,25 @@ function getLocaleResourceBase(){
uiactions
:
{
},
},
transfer_form
:
{
details
:
{
group1
:
commonLogic
.
appcommonhandle
(
"订单基本信息"
,
null
),
formpage1
:
commonLogic
.
appcommonhandle
(
"基本信息"
,
null
),
srfupdatedate
:
commonLogic
.
appcommonhandle
(
"更新时间"
,
null
),
srforikey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfkey
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
srfmajortext
:
commonLogic
.
appcommonhandle
(
"订单名称"
,
null
),
srftempmode
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfuf
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfdeid
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfsourcekey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
ibizsample0021id
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
},
uiactions
:
{
},
},
usr1116490270_form
:
{
details
:
{
group1
:
commonLogic
.
appcommonhandle
(
"订单基本信息"
,
null
),
...
...
app_Web/src/locale/lanres/entities/ibizsample0021/ibizsample0021_en_US_base.ts
浏览文件 @
587e7a8a
...
...
@@ -16,6 +16,7 @@ function getLocaleResourceBase(){
curdeptid
:
commonLogic
.
appcommonhandle
(
"CURDEPTID"
,
null
),
amount
:
commonLogic
.
appcommonhandle
(
"总计"
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
},
views
:
{
wfdynaactionview
:
{
...
...
@@ -110,6 +111,7 @@ function getLocaleResourceBase(){
srfdeid
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfsourcekey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
ibizsample0021id
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
},
uiactions
:
{
...
...
@@ -307,6 +309,25 @@ function getLocaleResourceBase(){
uiactions
:
{
},
},
transfer_form
:
{
details
:
{
group1
:
commonLogic
.
appcommonhandle
(
"订单基本信息"
,
null
),
formpage1
:
commonLogic
.
appcommonhandle
(
"基本信息"
,
null
),
srfupdatedate
:
commonLogic
.
appcommonhandle
(
"更新时间"
,
null
),
srforikey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfkey
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
srfmajortext
:
commonLogic
.
appcommonhandle
(
"订单名称"
,
null
),
srftempmode
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfuf
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfdeid
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfsourcekey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
ibizsample0021id
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
},
uiactions
:
{
},
},
usr1116490270_form
:
{
details
:
{
group1
:
commonLogic
.
appcommonhandle
(
"订单基本信息"
,
null
),
...
...
app_Web/src/locale/lanres/entities/ibizsample0021/ibizsample0021_zh_CN_base.ts
浏览文件 @
587e7a8a
...
...
@@ -16,6 +16,7 @@ function getLocaleResourceBase(){
curdeptid
:
commonLogic
.
appcommonhandle
(
"CURDEPTID"
,
null
),
amount
:
commonLogic
.
appcommonhandle
(
"总计"
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
},
views
:
{
wfdynaactionview
:
{
...
...
@@ -110,6 +111,7 @@ function getLocaleResourceBase(){
srfdeid
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfsourcekey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
ibizsample0021id
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
},
uiactions
:
{
...
...
@@ -307,6 +309,25 @@ function getLocaleResourceBase(){
uiactions
:
{
},
},
transfer_form
:
{
details
:
{
group1
:
commonLogic
.
appcommonhandle
(
"订单基本信息"
,
null
),
formpage1
:
commonLogic
.
appcommonhandle
(
"基本信息"
,
null
),
srfupdatedate
:
commonLogic
.
appcommonhandle
(
"更新时间"
,
null
),
srforikey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfkey
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
srfmajortext
:
commonLogic
.
appcommonhandle
(
"订单名称"
,
null
),
srftempmode
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfuf
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfdeid
:
commonLogic
.
appcommonhandle
(
""
,
null
),
srfsourcekey
:
commonLogic
.
appcommonhandle
(
""
,
null
),
deptheads
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
deptheadsid
:
commonLogic
.
appcommonhandle
(
"部门领导"
,
null
),
ibizsample0021id
:
commonLogic
.
appcommonhandle
(
"订单标识"
,
null
),
},
uiactions
:
{
},
},
usr1116490270_form
:
{
details
:
{
group1
:
commonLogic
.
appcommonhandle
(
"订单基本信息"
,
null
),
...
...
app_Web/src/pages/sample/ibizsample0021-reassignwfdyna-action-view/ibizsample0021-reassignwfdyna-action-view-base.vue
浏览文件 @
587e7a8a
...
...
@@ -215,6 +215,7 @@ export default class IBIZSample0021REASSIGNWFDynaActionViewBase extends Vue {
*/
public
containerModel
:
any
=
{
view_form
:
{
name
:
'form'
,
type
:
'FORM'
},
view_wfform_transfer
:
{
name
:
'wfform_transfer'
,
type
:
'FORM'
},
view_wfform_refuseform
:
{
name
:
'wfform_refuseform'
,
type
:
'FORM'
},
wflinks
:
[],
};
...
...
@@ -703,6 +704,7 @@ export default class IBIZSample0021REASSIGNWFDynaActionViewBase extends Vue {
*/
public
allForm
:
any
=
{
"form"
:{
name
:
"view_form"
,
autosave
:
"false"
,
showBusyIndicator
:
"true"
,
updateAction
:
"Update"
,
removeAction
:
"Remove"
,
loaddraftAction
:
"GetDraft"
,
loadAction
:
"Get"
,
createAction
:
"Create"
,
WFSubmitAction
:
""
,
WFStartAction
:
""
},
"wfform_transfer"
:{
name
:
"view_wfform_transfer"
,
autosave
:
"false"
,
showBusyIndicator
:
"true"
,
updateAction
:
"Update"
,
removeAction
:
"Remove"
,
loaddraftAction
:
"GetDraft"
,
loadAction
:
"Get"
,
createAction
:
"Create"
,
WFSubmitAction
:
""
,
WFStartAction
:
""
},
"wfform_refuseform"
:{
name
:
"view_wfform_refuseform"
,
autosave
:
"false"
,
showBusyIndicator
:
"true"
,
updateAction
:
"Update"
,
removeAction
:
"Remove"
,
loaddraftAction
:
"GetDraft"
,
loadAction
:
"Get"
,
createAction
:
"Create"
,
WFSubmitAction
:
""
,
WFStartAction
:
""
}
};
...
...
app_Web/src/pages/sample/ibizsample0021-reassignwfdyna-action-view/ibizsample0021-reassignwfdyna-action-view.vue
浏览文件 @
587e7a8a
...
...
@@ -3,11 +3,13 @@ import { Component } from 'vue-property-decorator';
import
IBIZSample0021REASSIGNWFDynaActionViewBase
from
'./ibizsample0021-reassignwfdyna-action-view-base.vue'
;
import
view_form
from
'@widgets/ibizsample0021/usr1116029485-form/usr1116029485-form.vue'
;
import
view_wfform_transfer
from
'@widgets/ibizsample0021/transfer-form/transfer-form.vue'
;
import
view_wfform_refuseform
from
'@widgets/ibizsample0021/refuse-form-form/refuse-form-form.vue'
;
// 基于 @VIEW/@MACRO/VIEW.vue.ftl 生成
@
Component
({
components
:
{
view_form
,
view_wfform_transfer
,
view_wfform_refuseform
,
},
beforeRouteEnter
:
(
to
:
any
,
from
:
any
,
next
:
any
)
=>
{
...
...
app_Web/src/pages/sample/ibizsample0021-usr1114865995-wfdyna-edit-view3/ibizsample0021-usr1114865995-wfdyna-edit-view3-base.vue
浏览文件 @
587e7a8a
...
...
@@ -728,6 +728,28 @@ export default class IBIZSample0021Usr1114865995WFDynaEditView3Base extends Vue
*/
public
activeForm
:
any
=
{};
/**
* 工作流附加功能类型映射关系对象
*
* @memberof IBIZSample0021Usr1114865995WFDynaEditView3Base
*/
public
wfAddiFeatureRef
:
any
=
{
// 转办
"reassign"
:
{
featureTag
:
"REASSIGN"
,
action
:
"TransFerTask"
},
// 前加签
"addstepbefore"
:
{
featureTag
:
"ADDSTEPBEFORE"
,
action
:
"BeforeSign"
},
// 后加签
"addstepafter"
:
{
featureTag
:
"ADDSTEPAFTER"
,
action
:
"AfterSign"
},
// 回退
"sendback"
:
{
featureTag
:
"SENDBACK"
,
action
:
"SendBack"
},
// 抄送
"sendcopy"
:
{
featureTag
:
"SENDCOPY"
,
action
:
"sendCopy"
},
// 补充信息
"supplyinfo"
:
{
featureTag
:
"SUPPLYINFO"
,
action
:
"supplyInfo"
},
// 征求意见
"takeadvice"
:
{
featureTag
:
"TAKEADVICE"
,
action
:
"takeAdvice"
}
};
/**
* 所有表单数据
*
...
...
@@ -884,27 +906,109 @@ export default class IBIZSample0021Usr1114865995WFDynaEditView3Base extends Vue
}
});
}
if
(
linkItem
&&
linkItem
.
sequenceflowview
&&
this
.
viewRefData
[
`WFACTION@
${
linkItem
.
sequenceflowview
}
`
])
{
let
tempContext
:
any
=
Util
.
deepCopy
(
this
.
context
);
Object
.
assign
(
tempContext
,{
ibizsample0021
:
datas
&&
datas
[
0
].
srfkey
});
let
tempViewParam
:
any
=
{
actionView
:
linkItem
.
sequenceflowview
,
actionForm
:
linkItem
.
sequenceflowform
};
let
targetView
:
any
=
this
.
viewRefData
[
`WFACTION@
${
linkItem
.
sequenceflowview
}
`
];
const
appmodal
=
this
.
$appmodal
.
openModal
({
viewname
:
targetView
.
viewname
,
title
:
(
this
.
$t
(
targetView
.
title
)
as
string
),
height
:
targetView
.
height
,
width
:
targetView
.
width
},
tempContext
,
tempViewParam
);
appmodal
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
let
tempSubmitData
:
any
=
Util
.
deepCopy
(
datas
);
tempSubmitData
.
forEach
((
element
:
any
)
=>
{
Object
.
assign
(
element
,
result
.
datas
&&
result
.
datas
[
0
]);
const
submitAction
:
Function
=
()
=>
{
if
(
linkItem
&&
linkItem
.
sequenceflowview
&&
this
.
viewRefData
[
`WFACTION@
${
linkItem
.
sequenceflowview
}
`
])
{
let
tempContext
:
any
=
Util
.
deepCopy
(
this
.
context
);
Object
.
assign
(
tempContext
,{
ibizsample0021
:
datas
&&
datas
[
0
].
srfkey
});
let
tempViewParam
:
any
=
{
actionView
:
linkItem
.
sequenceflowview
,
actionForm
:
linkItem
.
sequenceflowform
};
let
targetView
:
any
=
this
.
viewRefData
[
`WFACTION@
${
linkItem
.
sequenceflowview
}
`
];
const
appmodal
=
this
.
$appmodal
.
openModal
({
viewname
:
targetView
.
viewname
,
title
:
(
this
.
$t
(
targetView
.
title
)
as
string
),
height
:
targetView
.
height
,
width
:
targetView
.
width
},
tempContext
,
tempViewParam
);
appmodal
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
let
tempSubmitData
:
any
=
Util
.
deepCopy
(
datas
);
tempSubmitData
.
forEach
((
element
:
any
)
=>
{
Object
.
assign
(
element
,
result
.
datas
&&
result
.
datas
[
0
]);
});
submit
(
tempSubmitData
,
linkItem
);
});
submit
(
tempSubmitData
,
linkItem
);
});
}
else
{
submit
(
datas
,
linkItem
);
}
}
if
(
linkItem
&&
linkItem
.
type
)
{
if
(
Object
.
is
(
linkItem
.
type
,
"finish"
))
{
submitAction
();
}
else
{
this
.
handleWFAddiFeature
(
linkItem
,
datas
);
}
}
else
{
submit
(
datas
,
linkItem
);
submit
Action
(
);
}
}
/**
* 处理工作流辅助功能
*
* @memberof IBIZSample0021Usr1114865995WFDynaEditView3Base
*/
public
handleWFAddiFeature
(
linkItem
:
any
,
data
:
any
)
{
let
featureTag
:
string
=
this
.
wfAddiFeatureRef
[
linkItem
.
type
].
featureTag
;
if
(
!
featureTag
)
return
;
let
targetView
:
any
=
this
.
viewRefData
[
`WFUTILACTION@
${
featureTag
}
`
];
if
(
!
targetView
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
`未找到
${
featureTag
}
映射视图`
});
return
;
}
let
tempContext
:
any
=
Util
.
deepCopy
(
this
.
context
);
Object
.
assign
(
tempContext
,{
ibizsample0021
:
data
&&
data
[
0
].
srfkey
});
let
tempViewParam
:
any
=
{
actionForm
:
linkItem
.
sequenceflowform
};
const
appmodal
=
this
.
$appmodal
.
openModal
({
viewname
:
targetView
.
viewname
,
title
:
(
this
.
$t
(
targetView
.
title
)
as
string
),
height
:
targetView
.
height
,
width
:
targetView
.
width
},
tempContext
,
tempViewParam
);
appmodal
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
let
tempSubmitData
:
any
=
Util
.
deepCopy
(
data
[
0
]);
if
(
result
.
datas
&&
result
.
datas
[
0
])
{
const
resultData
:
any
=
result
.
datas
[
0
];
if
(
Object
.
keys
(
resultData
).
length
>
0
)
{
let
tempData
:
any
=
{};
Object
.
keys
(
resultData
).
forEach
((
key
:
any
)
=>
{
if
(
resultData
[
key
]
&&
(
key
!==
"srfuf"
))
tempData
[
key
]
=
resultData
[
key
];
})
Object
.
assign
(
tempSubmitData
,
tempData
);
}
this
.
submitWFAddiFeature
(
linkItem
,
tempSubmitData
);
}
});
}
/**
* 提交工作流辅助功能
*
* @memberof IBIZSample0021Usr1114865995WFDynaEditView3Base
*/
public
submitWFAddiFeature
(
linkItem
:
any
,
submitData
:
any
)
{
const
that
:
any
=
this
;
let
tempSubmitData
:
any
=
Object
.
assign
(
linkItem
,
{
"activedata"
:
submitData
});
let
action
:
string
=
this
.
wfAddiFeatureRef
[
linkItem
.
type
].
action
;
if
(
!
action
)
return
;
if
(
that
.
appEntityService
&&
that
.
appEntityService
[
action
]
&&
that
.
appEntityService
[
action
]
instanceof
Function
)
{
const
tempContext
=
Util
.
deepCopy
(
this
.
context
);
Object
.
assign
(
tempContext
,
{
taskId
:
linkItem
.
taskId
})
that
.
appEntityService
[
action
](
tempContext
,
tempSubmitData
).
then
((
response
:
any
)
=>
{
const
{
data
}
=
response
;
if
(
!
response
||
response
.
status
!==
200
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
data
.
message
?
data
.
message
:
this
.
$t
(
'app.commonWords.sysException'
)
as
string
});
return
;
}
if
(
this
.
viewdata
)
{
this
.
$emit
(
'viewdataschange'
,
[{
...
data
}]);
this
.
$emit
(
'close'
);
}
else
if
(
this
.
$tabPageExp
)
{
this
.
$tabPageExp
.
onClose
(
this
.
$route
.
fullPath
);
}
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.formpage.workflow.submitsuccess'
)
as
string
)
});
}).
catch
((
error
:
any
)
=>
{
const
{
data
}
=
error
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
data
.
message
?
data
.
message
:
this
.
$t
(
'app.commonWords.sysException'
)
as
string
});
})
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
`
${
action
}
暂未实现`
});
}
}
}
...
...
app_Web/src/widgets/ibizbook/default-searchform/default-searchform-base.vue
浏览文件 @
587e7a8a
...
...
@@ -712,7 +712,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Usr9Grid
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loadAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Calendar
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loadAction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
@@ -748,7 +748,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
public
async
loadDraft
(
opt
:
any
=
{},
mode
?:
string
):
Promise
<
any
>
{
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Usr9Grid
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loaddraftAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Calendar
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loaddraftAction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
}
;
...
...
app_Web/src/widgets/ibizbook/guide-view-form-form/guide-view-form-form-base.vue
浏览文件 @
587e7a8a
...
...
@@ -1447,7 +1447,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
*/
public
async
load
(
opt
:
any
=
{}):
Promise
<
any
>
{
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView'
+
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
@@ -1494,7 +1494,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
*/
public
async
loadDraft
(
opt
:
any
=
{}):
Promise
<
any
>
{
if
(
!
this
.
loaddraftAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView'
+
(
this
.
$t
(
'app.formpage.notconfig.loaddraftaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.loaddraftaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
}
;
...
...
@@ -1564,7 +1564,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
){
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
}
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
...
...
@@ -1672,7 +1672,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
){
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
}
Object
.
assign
(
arg
,
{
viewparams
:
this
.
viewparams
});
...
...
@@ -1764,7 +1764,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
public
remove
(
opt
:
Array
<
any
>
=
[],
showResultInfo
?:
boolean
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView'
+
(
this
.
$t
(
'app.formpage.notconfig.removeaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKWizardView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.removeaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
opt
[
0
];
...
...
app_Web/src/widgets/ibizbook/usr4-dataview/usr4-dataview-base.vue
浏览文件 @
587e7a8a
...
...
@@ -698,7 +698,7 @@ export default class Usr4Base extends Vue implements ControlInterface {
*/
public
async
load
(
opt
:
any
=
{},
isReset
:
boolean
=
false
):
Promise
<
any
>
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
TestCL
DataView'
+
(
this
.
$t
(
'app.list.notConfig.fetchAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Usr4
DataView'
+
(
this
.
$t
(
'app.list.notConfig.fetchAction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{...
opt
};
...
...
@@ -792,7 +792,7 @@ export default class Usr4Base extends Vue implements ControlInterface {
*/
public
async
remove
(
datas
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
TestCL
DataView'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Usr4
DataView'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
return
;
}
let
_datas
:
any
[]
=
[];
...
...
@@ -908,7 +908,7 @@ export default class Usr4Base extends Vue implements ControlInterface {
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
)){
if
(
!
this
.
createAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
TestCL
DataView'
+
(
this
.
$t
(
'app.list.notConfig.createAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Usr4
DataView'
+
(
this
.
$t
(
'app.list.notConfig.createAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
...
...
@@ -916,7 +916,7 @@ export default class Usr4Base extends Vue implements ControlInterface {
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
if
(
!
this
.
updateAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
TestCL
DataView'
+
(
this
.
$t
(
'app.list.notConfig.updateAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOK
Usr4
DataView'
+
(
this
.
$t
(
'app.list.notConfig.updateAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
if
(
item
.
ibizbook
){
...
...
app_Web/src/widgets/ibizbook/usr4-dataview/usr4-dataview-model.ts
浏览文件 @
587e7a8a
...
...
@@ -70,6 +70,11 @@ export default class Usr4Model {
prop
:
'n_ibizbookname_like'
,
dataType
:
'QUERYPARAM'
},
{
name
:
'n_price_gtandeq'
,
prop
:
'n_price_gtandeq'
,
dataType
:
'QUERYPARAM'
},
{
...
...
app_Web/src/widgets/ibizorder/card-navigation-dataview/card-navigation-dataview-base.vue
浏览文件 @
587e7a8a
...
...
@@ -736,7 +736,7 @@ export default class CardNavigationBase extends Vue implements ControlInterface
*/
public
async
load
(
opt
:
any
=
{},
isReset
:
boolean
=
false
):
Promise
<
any
>
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.fetchAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView'
+
(
this
.
$t
(
'app.list.notConfig.fetchAction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{...
opt
};
...
...
@@ -830,7 +830,7 @@ export default class CardNavigationBase extends Vue implements ControlInterface
*/
public
async
remove
(
datas
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView
_layout
'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
return
;
}
let
_datas
:
any
[]
=
[];
...
...
@@ -946,7 +946,7 @@ export default class CardNavigationBase extends Vue implements ControlInterface
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
)){
if
(
!
this
.
createAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.createAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView'
+
(
this
.
$t
(
'app.list.notConfig.createAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
...
...
@@ -954,7 +954,7 @@ export default class CardNavigationBase extends Vue implements ControlInterface
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
if
(
!
this
.
updateAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.updateAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderDataViewExpView'
+
(
this
.
$t
(
'app.list.notConfig.updateAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
if
(
item
.
ibizorder
){
...
...
app_Web/src/widgets/ibizorder/main-grid/main-grid-base.vue
浏览文件 @
587e7a8a
...
...
@@ -319,7 +319,7 @@ export default class MainBase extends Vue implements ControlInterface {
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof IBIZOrder
Pickup
GridViewBase
* @memberof IBIZOrder
SF1
GridViewBase
*/
public
Edit
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
if
(
args
.
length
===
0
)
{
...
...
@@ -462,6 +462,20 @@ export default class MainBase extends Vue implements ControlInterface {
return
this
.
selections
[
0
];
}
/**
* 打开新建数据视图
*
* @type {any}
* @memberof MainBase
*/
@
Prop
()
public
newdata
:
any
;
/**
* 打开编辑数据视图
*
* @type {any}
* @memberof MainBase
*/
@
Prop
()
public
opendata
:
any
;
/**
* 是否嵌入关系界面
...
...
@@ -996,7 +1010,7 @@ export default class MainBase extends Vue implements ControlInterface {
if
(
!
this
.
fetchAction
)
{
this
.
$Notice
.
error
({
title
:
this
.
$t
(
"app.commonWords.wrong"
)
as
string
,
desc
:
"IBIZOrder
Pickup
GridView"
+
(
this
.
$t
(
"app.gridpage.notConfig.fetchAction"
)
as
string
),
desc
:
"IBIZOrder
SF1
GridView"
+
(
this
.
$t
(
"app.gridpage.notConfig.fetchAction"
)
as
string
),
});
return
;
}
...
...
@@ -1125,7 +1139,7 @@ export default class MainBase extends Vue implements ControlInterface {
if
(
!
this
.
removeAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
Pickup
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
desc
:
'IBIZOrder
SF1
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
return
;
}
...
...
@@ -1239,7 +1253,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
addBatch
(
arg
:
any
=
{}):
void
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
Pickup
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.fetchAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
SF1
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.fetchAction'
)
as
string
)
});
return
;
}
if
(
!
arg
){
...
...
@@ -2170,7 +2184,7 @@ export default class MainBase extends Vue implements ControlInterface {
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
))
{
if
(
!
this
.
createAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
Pickup
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.createAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
SF1
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.createAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,
{
viewparams
:
this
.
viewparams
});
const
tempContext
=
Util
.
deepCopy
(
this
.
context
);
...
...
@@ -2179,7 +2193,7 @@ export default class MainBase extends Vue implements ControlInterface {
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
if
(
!
this
.
updateAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
Pickup
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.updateAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
SF1
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.updateAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,
{
viewparams
:
this
.
viewparams
});
const
tempContext
=
Util
.
deepCopy
(
this
.
context
);
...
...
@@ -2255,7 +2269,7 @@ export default class MainBase extends Vue implements ControlInterface {
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrder
Pickup
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.loaddraftAction'
)
as
string
)
desc
:
'IBIZOrder
SF1
GridView'
+
(
this
.
$t
(
'app.gridpage.notConfig.loaddraftAction'
)
as
string
)
});
return
;
}
...
...
app_Web/src/widgets/ibizorder/main-grid/main-grid-model.ts
浏览文件 @
587e7a8a
...
...
@@ -105,6 +105,21 @@ export default class MainModel {
prop
:
'n_ibizordername_like'
,
dataType
:
'QUERYPARAM'
},
{
name
:
'n_orderstate_eq'
,
prop
:
'n_orderstate_eq'
,
dataType
:
'QUERYPARAM'
},
{
name
:
'n_ordertime_gt'
,
prop
:
'n_ordertime_gt'
,
dataType
:
'QUERYPARAM'
},
{
name
:
'n_ordertime_lt'
,
prop
:
'n_ordertime_lt'
,
dataType
:
'QUERYPARAM'
},
{
name
:
'size'
,
...
...
app_Web/src/widgets/ibizsample0021/data-relation-drtab/data-relation-drtab-model.ts
浏览文件 @
587e7a8a
...
...
@@ -55,6 +55,9 @@ export default class DataRelationModel {
{
name
:
'deptheads'
,
},
{
name
:
'deptheadsid'
,
},
]
}
...
...
app_Web/src/widgets/ibizsample0021/start001-form/start001-form-base.vue
浏览文件 @
587e7a8a
...
...
@@ -470,6 +470,7 @@ export default class Start001Base extends Vue implements ControlInterface {
srfdeid
:
null
,
srfsourcekey
:
null
,
deptheads
:
null
,
deptheadsid
:
null
,
ibizsample0021id
:
null
,
ibizsample0021
:
null
,
};
...
...
@@ -654,6 +655,8 @@ export default class Start001Base extends Vue implements ControlInterface {
srfsourcekey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfsourcekey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
deptheads
:
new
FormItemModel
({
caption
:
'部门领导'
,
detailType
:
'FORMITEM'
,
name
:
'deptheads'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
deptheadsid
:
new
FormItemModel
({
caption
:
'部门领导'
,
detailType
:
'FORMITEM'
,
name
:
'deptheadsid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
ibizsample0021id
:
new
FormItemModel
({
caption
:
'订单标识'
,
detailType
:
'FORMITEM'
,
name
:
'ibizsample0021id'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
...
...
@@ -767,6 +770,18 @@ export default class Start001Base extends Vue implements ControlInterface {
this
.
formDataChange
({
name
:
'deptheads'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 deptheadsid 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof Start001Base
*/
@
Watch
(
'data.deptheadsid'
)
onDeptheadsidChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'deptheadsid'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 ibizsample0021id 值
*
...
...
@@ -845,6 +860,7 @@ export default class Start001Base extends Vue implements ControlInterface {
}
/**
...
...
app_Web/src/widgets/ibizsample0021/start001-form/start001-form-model.ts
浏览文件 @
587e7a8a
...
...
@@ -61,6 +61,11 @@ export default class Start001Model {
prop
:
'deptheads'
,
dataType
:
'TEXT'
,
},
{
name
:
'deptheadsid'
,
prop
:
'deptheadsid'
,
dataType
:
'TEXT'
,
},
{
name
:
'ibizsample0021id'
,
prop
:
'ibizsample0021id'
,
...
...
app_Web/src/widgets/ibizsample0021/transfer-form/transfer-form-base.vue
0 → 100644
浏览文件 @
587e7a8a
<
template
>
<i-form
:model=
"this.data"
class=
'app-form'
ref=
'wfform_transfer'
id=
'ibizsample0021_transfer'
style=
""
@
on-validate=
"formItemValidate"
>
<input
style=
"display:none;"
/>
<row
>
<i-col
v-show=
"detailsModel.group1.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-group
:uiService=
"appUIService"
:data=
"transformData(data)"
:manageContainerStatus=
"detailsModel.group1.manageContainerStatus"
:isManageContainer=
"detailsModel.group1.isManageContainer"
@
managecontainerclick=
"manageContainerClick('group1')"
layoutType=
"TABLE_24COL"
titleStyle=
""
class=
''
:uiActionGroup=
"detailsModel.group1.uiActionGroup"
@
groupuiactionclick=
"groupUIActionClick($event)"
:caption=
"$t('entities.ibizsample0021.transfer_form.details.group1')"
:isShowCaption=
"false"
uiStyle=
"DEFAULT"
:titleBarCloseMode=
"0"
:isInfoGroupMode=
"false"
>
<row>
<i-col
v-show=
"detailsModel.deptheads.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-item
name=
'deptheads'
:itemRules=
"this.rules().deptheads"
class=
''
:caption=
"$t('entities.ibizsample0021.transfer_form.details.deptheads')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.deptheads.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
</app-form-item>
</i-col>
</row>
</app-form-group>
</i-col>
</row>
</i-form>
</
template
>
// 基于 @CONTROL/表单/CONTROL-BASE.vue.ftl 生成
<
script
lang=
'tsx'
>
import
{
Vue
,
Component
,
Prop
,
Provide
,
Emit
,
Watch
,
Model
,
Inject
}
from
'vue-property-decorator'
;
import
{
CreateElement
}
from
'vue'
;
import
{
Subject
,
Subscription
}
from
'rxjs'
;
import
{
ControlInterface
}
from
'@/interface/control'
;
import
{
UIActionTool
,
Util
,
ViewTool
}
from
'@/utils'
;
import
NavDataService
from
'@/service/app/navdata-service'
;
import
AppCenterService
from
"@service/app/app-center-service"
;
import
IBIZSample0021EntityService
from
'@/service/ibizsample0021/ibizsample0021-service'
;
import
TransferService
from
'./transfer-form-service'
;
import
IBIZSample0021UIService
from
'@/uiservice/ibizsample0021/ibizsample0021-ui-service'
;
import
{
FormButtonModel
,
FormPageModel
,
FormItemModel
,
FormDRUIPartModel
,
FormPartModel
,
FormGroupPanelModel
,
FormIFrameModel
,
FormRowItemModel
,
FormTabPageModel
,
FormTabPanelModel
,
FormUserControlModel
}
from
'@/model/form-detail'
;
import
{
debounceTime
,
distinctUntilChanged
}
from
'rxjs/operators'
;
import
schema
from
'async-validator'
;
import
{
Environment
}
from
'@/environments/environment'
;
@
Component
({
components
:
{
}
})
export
default
class
TransferBase
extends
Vue
implements
ControlInterface
{
/**
* 名称
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
name
?:
string
;
/**
* 视图通讯对象
*
* @type {Subject<ViewState>}
* @memberof TransferBase
*/
@
Prop
()
public
viewState
!
:
Subject
<
ViewState
>
;
/**
* 应用上下文
*
* @type {*}
* @memberof TransferBase
*/
@
Prop
()
public
context
!
:
any
;
/**
* 视图参数
*
* @type {*}
* @memberof TransferBase
*/
@
Prop
()
public
viewparams
!
:
any
;
/**
* 视图操作参数(父级)
*
* @type {*}
* @memberof TransferBase
*/
@
Prop
()
public
pViewCtx
!
:
any
;
/**
* 视图操作参数
*
* @type {*}
* @memberof TransferBase
*/
public
viewCtx
:
any
=
{};
/**
* 监听视图操作参数变化
*
* @type {*}
* @memberof TransferBase
*/
@
Watch
(
'pViewCtx'
,
{
immediate
:
true
})
public
onViewCtxChange
(
newVal
:
any
,
oldVal
:
any
)
{
Object
.
assign
(
this
.
viewCtx
,
newVal
,
{
xData
:
this
,
ctrl
:
this
});
}
/**
* 视图状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof TransferBase
*/
public
viewStateEvent
:
Subscription
|
undefined
;
/**
* 获取部件类型
*
* @returns {string}
* @memberof TransferBase
*/
public
getControlType
():
string
{
return
'FORM'
}
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof TransferBase
*/
public
counterServiceArray
:
Array
<
any
>
=
[];
/**
* 建构部件服务对象
*
* @type {TransferService}
* @memberof TransferBase
*/
public
service
:
TransferService
=
new
TransferService
({
$store
:
this
.
$store
});
/**
* 实体服务对象
*
* @type {IBIZSample0021Service}
* @memberof TransferBase
*/
public
appEntityService
:
IBIZSample0021EntityService
=
new
IBIZSample0021EntityService
({
$store
:
this
.
$store
});
/**
* 转化数据
*
* @param {any} args
* @memberof TransferBase
*/
public
transformData
(
args
:
any
)
{
let
_this
:
any
=
this
;
if
(
_this
.
service
&&
_this
.
service
.
handleRequestData
instanceof
Function
&&
_this
.
service
.
handleRequestData
(
'transform'
,
_this
.
context
,
args
)){
return
_this
.
service
.
handleRequestData
(
'transform'
,
_this
.
context
,
args
)[
'data'
];
}
}
/**
* 关闭视图
*
* @param {any} args
* @memberof TransferBase
*/
public
closeView
(
args
:
any
):
void
{
let
_this
:
any
=
this
;
_this
.
$emit
(
'closeview'
,
[
args
]);
}
/**
* 计数器刷新
*
* @memberof TransferBase
*/
public
counterRefresh
(){
const
_this
:
any
=
this
;
if
(
_this
.
counterServiceArray
&&
_this
.
counterServiceArray
.
length
>
0
){
_this
.
counterServiceArray
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
refreshData
&&
item
.
refreshData
instanceof
Function
){
item
.
refreshData
();
}
})
}
}
/**
* 处理部件事件
*
* @memberof TransferBase
*/
public
async
handleCtrlEvents
(
eventName
:
string
,
args
:
any
=
{}):
Promise
<
boolean
>
{
const
actionData
=
{
data
:
this
.
getData
()
||
{},
context
:
Util
.
deepCopy
(
this
.
context
),
viewparams
:
Util
.
deepCopy
(
this
.
viewparams
),
xData
:
this
}
let
result
:
boolean
=
true
;
Object
.
assign
(
actionData
,
args
);
if
(
!
result
)
{
return
false
;
}
this
.
$emit
(
eventName
,
actionData
);
return
true
;
}
/**
* 视图默认使用
*
* @type {string}
* @memberof TransferBase
*/
@
Inject
({
from
:
'navModel'
,
default
:
'tab'
})
public
navModel
!
:
string
;
/**
* 主键表单项名称
*
* @protected
* @type {string}
* @memberof TransferBase
*/
public
formKeyItemName
:
string
=
''
;
/**
* 是否自动加载
*
* @type {boolean}
* @memberof TransferBase
*/
@
Prop
({
default
:
false
})
public
isautoload
?:
boolean
;
/**
* 界面UI服务对象
*
* @type {IBIZSample0021UIService}
* @memberof TransferBase
*/
public
appUIService
:
IBIZSample0021UIService
=
new
IBIZSample0021UIService
();
/**
* 工作流审批意见控件绑定值
*
* @memberof TransferBase
*/
public
srfwfmemo
:
string
=
""
;
/**
* 获取多项数据
*
* @returns {any[]}
* @memberof TransferBase
*/
public
getDatas
():
any
[]
{
return
[
this
.
data
];
}
/**
* 获取单项树
*
* @returns {*}
* @memberof TransferBase
*/
public
getData
():
any
{
return
this
.
data
;
}
/**
* 是否默认保存
*
* @type {boolean}
* @memberof TransferBase
*/
@
Prop
({
default
:
false
})
public
autosave
?:
boolean
;
/**
* 显示处理提示
*
* @type {boolean}
* @memberof TransferBase
*/
@
Prop
({
default
:
true
})
public
showBusyIndicator
?:
boolean
;
/**
* 部件行为--submit
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
WFSubmitAction
!
:
string
;
/**
* 部件行为--start
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
WFStartAction
!
:
string
;
/**
* 部件行为--update
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
updateAction
!
:
string
;
/**
* 部件行为--remove
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
removeAction
!
:
string
;
/**
* 部件行为--loaddraft
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
loaddraftAction
!
:
string
;
/**
* 部件行为--load
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
loadAction
!
:
string
;
/**
* 部件行为--create
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
createAction
!
:
string
;
/**
* 部件行为--create
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
searchAction
!
:
string
;
/**
* 视图标识
*
* @type {string}
* @memberof TransferBase
*/
@
Prop
()
public
viewtag
!
:
string
;
/**
* 表单状态
*
* @type {Subject<any>}
* @memberof TransferBase
*/
public
formState
:
Subject
<
any
>
=
new
Subject
();
/**
* 忽略表单项值变化
*
* @type {boolean}
* @memberof TransferBase
*/
public
ignorefieldvaluechange
:
boolean
=
false
;
/**
* 数据变化
*
* @public
* @type {Subject<any>}
* @memberof TransferBase
*/
public
dataChang
:
Subject
<
any
>
=
new
Subject
();
/**
* 视图状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof TransferBase
*/
public
dataChangEvent
:
Subscription
|
undefined
;
/**
* 原始数据
*
* @public
* @type {*}
* @memberof TransferBase
*/
public
oldData
:
any
=
{};
/**
* 混入表单数据对象
*
* @type {*}
* @memberof TransferBase
*/
public
mixinData
:
any
=
{};
/**
* 表单项校验错误提示信息
*
* @memberof TransferBase
*/
public
errorMessages
:
Array
<
any
>
=
[];
/**
* 应用状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof TransferBase
*/
public
appStateEvent
:
Subscription
|
undefined
;
/**
* 设置表单项错误提示信息
*
* @param {*} prop 表单项字段名
* @param {*} status 校验状态
* @param {*} error 错误信息
* @memberof TransferBase
*/
public
formItemValidate
(
prop
:
string
,
status
:
boolean
,
error
:
string
){
error
=
error
?
error
:
''
;
if
(
this
.
errorMessages
&&
this
.
errorMessages
.
length
>
0
){
const
index
=
this
.
errorMessages
.
findIndex
((
errorMessage
:
any
)
=>
Object
.
is
(
errorMessage
.
prop
,
prop
));
if
(
index
!=
-
1
){
this
.
errorMessages
[
index
].
error
=
error
;
}
else
{
this
.
errorMessages
.
push
({
prop
:
prop
,
error
:
error
});
}
}
else
{
this
.
errorMessages
.
push
({
prop
:
prop
,
error
:
error
});
}
}
/**
* 表单数据对象
*
* @type {*}
* @memberof TransferBase
*/
public
data
:
any
=
{
srfupdatedate
:
null
,
srforikey
:
null
,
srfkey
:
null
,
srfmajortext
:
null
,
srftempmode
:
null
,
srfuf
:
null
,
srfdeid
:
null
,
srfsourcekey
:
null
,
deptheads
:
null
,
deptheadsid
:
null
,
ibizsample0021id
:
null
,
ibizsample0021
:
null
,
};
/**
* 当前执行的行为逻辑
*
* @type {string}
* @memberof TransferBase
*/
public
currentAction
:
string
=
""
;
/**
* 关系界面计数器
*
* @type {number}
* @memberof TransferBase
*/
public
drcounter
:
number
=
0
;
/**
* 需要等待关系界面保存时,第一次调用save参数的备份
*
* @type {number}
* @memberof TransferBase
*/
public
drsaveopt
:
any
=
{};
/**
* 表单保存回调存储对象
*
* @type {any}
* @memberof TransferBase
*/
public
saveState
:
any
;
/**
* 主信息属性映射表单项名称
*
* @type {string}
* @memberof TransferBase
*/
public
majorMessageField
:
string
=
""
;
/**
* 值规则
*
* @type {*}
* @memberof TransferBase
*/
public
rules
()
:
any
{
return
{
deptheads
:
[
{
required
:
this
.
detailsModel
.
deptheads
.
required
,
type
:
'string'
,
message
:
'部门领导 值不能为空'
,
trigger
:
'change'
},
{
required
:
this
.
detailsModel
.
deptheads
.
required
,
type
:
'string'
,
message
:
'部门领导 值不能为空'
,
trigger
:
'blur'
},
],
}
}
/**
* 属性值规则
*
* @type {*}
* @memberof TransferBase
*/
public
deRules
(){
return
{
}
}
/**
* 校验属性值规则
*
* @public
* @param {{ name: string }} { name }
* @memberof TransferBase
*/
public
verifyDeRules
(
name
:
string
,
rule
:
any
=
this
.
deRules
(),
op
:
string
=
"AND"
)
:{
isPast
:
boolean
,
infoMessage
:
string
}{
let
falg
:
any
=
{
infoMessage
:
""
};
if
(
!
rule
[
name
]){
return
falg
;
}
let
opValue
=
op
==
'AND'
?
true
:
false
;
let
startOp
=
(
val
:
boolean
)
=>
{
if
(
falg
.
isPast
){
if
(
opValue
){
falg
.
isPast
=
falg
.
isPast
&&
val
;
}
else
{
falg
.
isPast
=
falg
.
isPast
||
val
;
}
}
else
{
falg
.
isPast
=
val
;
}
}
for
(
let
i
=
0
;
i
<
rule
[
name
].
length
;
i
++
){
let
item
:
any
=
rule
[
name
][
i
];
let
dataValue
=
item
.
deName
?
this
.
data
[
this
.
service
.
getItemNameByDeName
(
item
.
deName
)]:
""
;
item
.
ruleInfo
=
item
.
ruleInfo
?
item
.
ruleInfo
:
this
.
$t
(
'app.formpage.valuecheckex'
);
if
((
dataValue
===
null
||
dataValue
===
undefined
||
dataValue
===
""
)
&&
(
item
.
type
!=
'GROUP'
)){
startOp
(
true
);
return
falg
;
}
try
{
// 常规规则
if
(
item
.
type
==
'SIMPLE'
){
startOp
(
!
this
.
$verify
.
checkFieldSimpleRule
(
dataValue
,
item
.
condOP
,
item
.
paramValue
,
item
.
ruleInfo
,
item
.
paramType
,
this
.
data
,
item
.
isKeyCond
));
falg
.
infoMessage
=
item
.
ruleInfo
;
if
(
!
falg
.
isPast
)
return
falg
;
}
// 数值范围
if
(
item
.
type
==
'VALUERANGE2'
){
startOp
(
!
this
.
$verify
.
checkFieldValueRangeRule
(
dataValue
,
item
.
minValue
,
item
.
isIncludeMinValue
,
item
.
maxValue
,
item
.
isIncludeMaxValue
,
item
.
ruleInfo
,
item
.
isKeyCond
));
falg
.
infoMessage
=
item
.
ruleInfo
;
if
(
!
falg
.
isPast
)
return
falg
;
}
// 正则式
if
(
item
.
type
==
"REGEX"
)
{
startOp
(
!
this
.
$verify
.
checkFieldRegExRule
(
dataValue
,
item
.
regExCode
,
item
.
ruleInfo
,
item
.
isKeyCond
));
falg
.
infoMessage
=
item
.
ruleInfo
;
if
(
!
falg
.
isPast
)
return
falg
;
}
// 长度
if
(
item
.
type
==
"STRINGLENGTH"
)
{
startOp
(
!
this
.
$verify
.
checkFieldStringLengthRule
(
dataValue
,
item
.
minValue
,
item
.
isIncludeMinValue
,
item
.
maxValue
,
item
.
isIncludeMaxValue
,
item
.
ruleInfo
,
item
.
isKeyCond
));
falg
.
infoMessage
=
item
.
ruleInfo
;
if
(
!
falg
.
isPast
)
return
falg
;
}
// 系统值规则
if
(
item
.
type
==
"SYSVALUERULE"
)
{
startOp
(
!
this
.
$verify
.
checkFieldSysValueRule
(
dataValue
,
item
.
sysRule
.
regExCode
,
item
.
ruleInfo
,
item
.
isKeyCond
));
falg
.
infoMessage
=
item
.
ruleInfo
;
if
(
!
falg
.
isPast
)
return
falg
;
}
}
catch
(
error
)
{
falg
.
infoMessage
=
item
.
ruleInfo
;
startOp
(
false
);
if
(
!
falg
.
isPast
)
return
falg
;
}
// 分组
if
(
item
.
type
==
'GROUP'
){
falg
=
this
.
verifyDeRules
(
'group'
,
item
,
item
.
condOP
?
item
.
condOP
:
"AND"
);
if
(
item
.
isNotMode
){
falg
.
isPast
=
!
falg
.
isPast
;
}
if
(
!
falg
.
isPast
)
return
falg
;
}
}
if
(
!
falg
.
hasOwnProperty
(
"isPast"
)){
falg
.
isPast
=
true
;
}
if
(
!
this
.
data
[
name
]
&&
this
.
data
[
name
]
!=
0
){
falg
.
isPast
=
true
;
}
return
falg
;
}
/**
* 详情模型集合
*
* @type {*}
* @memberof TransferBase
*/
public
detailsModel
:
any
=
{
group1
:
new
FormGroupPanelModel
({
caption
:
'订单基本信息'
,
detailType
:
'GROUPPANEL'
,
name
:
'group1'
,
visible
:
true
,
isShowCaption
:
false
,
form
:
this
,
isControlledContent
:
false
,
uiActionGroup
:
{
caption
:
''
,
langbase
:
'entities.ibizsample0021.transfer_form'
,
extractMode
:
'ITEM'
,
details
:
[]
},
isManageContainer
:
false
,
showMoreModeItems
:
[]
})
,
formpage1
:
new
FormPageModel
({
caption
:
'基本信息'
,
detailType
:
'FORMPAGE'
,
name
:
'formpage1'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
})
,
srfupdatedate
:
new
FormItemModel
({
caption
:
'更新时间'
,
detailType
:
'FORMITEM'
,
name
:
'srfupdatedate'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srforikey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srforikey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srfkey
:
new
FormItemModel
({
caption
:
'订单标识'
,
detailType
:
'FORMITEM'
,
name
:
'srfkey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srfmajortext
:
new
FormItemModel
({
caption
:
'订单名称'
,
detailType
:
'FORMITEM'
,
name
:
'srfmajortext'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srftempmode
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srftempmode'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srfuf
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfuf'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srfdeid
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfdeid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
srfsourcekey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfsourcekey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
deptheads
:
new
FormItemModel
({
caption
:
'部门领导'
,
detailType
:
'FORMITEM'
,
name
:
'deptheads'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
deptheadsid
:
new
FormItemModel
({
caption
:
'部门领导'
,
detailType
:
'FORMITEM'
,
name
:
'deptheadsid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
ibizsample0021id
:
new
FormItemModel
({
caption
:
'订单标识'
,
detailType
:
'FORMITEM'
,
name
:
'ibizsample0021id'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
isControlledContent
:
false
,
required
:
false
,
disabled
:
false
,
enableCond
:
3
})
,
};
/**
* 监控表单属性 srfupdatedate 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srfupdatedate'
)
onSrfupdatedateChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfupdatedate'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srforikey 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srforikey'
)
onSrforikeyChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srforikey'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfkey 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srfkey'
)
onSrfkeyChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfkey'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfmajortext 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srfmajortext'
)
onSrfmajortextChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfmajortext'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srftempmode 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srftempmode'
)
onSrftempmodeChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srftempmode'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfuf 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srfuf'
)
onSrfufChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfuf'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfdeid 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srfdeid'
)
onSrfdeidChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfdeid'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfsourcekey 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.srfsourcekey'
)
onSrfsourcekeyChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfsourcekey'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 deptheads 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.deptheads'
)
onDeptheadsChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'deptheads'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 deptheadsid 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.deptheadsid'
)
onDeptheadsidChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'deptheadsid'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 ibizsample0021id 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof TransferBase
*/
@
Watch
(
'data.ibizsample0021id'
)
onIbizsample0021idChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'ibizsample0021id'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 显示更多模式切换操作
*
* @type {string}
* @memberof TransferBase
*/
public
manageContainerClick
(
name
:
string
){
let
model
=
this
.
detailsModel
[
name
];
if
(
model
.
isManageContainer
){
model
.
setManageContainerStatus
(
!
model
.
manageContainerStatus
);
model
.
showMoreModeItems
.
forEach
((
item
:
any
)
=>
{
if
(
this
.
detailsModel
[
item
].
isControlledContent
){
this
.
detailsModel
[
item
].
setVisible
(
model
.
manageContainerStatus
?
this
.
detailsModel
[
item
].
oldVisible
:
false
);
}
});
}
}
/**
* 重置表单项值
*
* @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof TransferBase
*/
public
resetFormData
({
name
,
newVal
,
oldVal
}:
{
name
:
string
,
newVal
:
any
,
oldVal
:
any
}):
void
{
}
/**
* 置空对象
*
* @param {any[]} args
* @memberof TransferBase
*/
public
ResetData
(
_datas
:
any
){
if
(
Object
.
keys
(
_datas
).
length
>
0
){
Object
.
keys
(
_datas
).
forEach
((
name
:
string
)
=>
{
if
(
this
.
data
.
hasOwnProperty
(
name
))
{
this
.
data
[
name
]
=
null
;
}
});
}
}
/**
* 表单逻辑
*
* @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof TransferBase
*/
public
async
formLogic
({
name
,
newVal
,
oldVal
}:
{
name
:
string
,
newVal
:
any
,
oldVal
:
any
}){
}
/**
* 表单项检查逻辑
*
* @public
* @param name 属性名
* @memberof TransferBase
*/
public
checkItem
(
name
:
string
):
Promise
<
any
>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
var
validator
=
new
schema
({[
name
]:
this
.
rules
()[
name
]});
validator
.
validate
({[
name
]:
this
.
data
[
name
]}).
then
(()
=>
{
resolve
(
true
);
})
.
catch
(()
=>
{
resolve
(
false
);
});;
})
}
/**
* 表单值变化
*
* @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @returns {void}
* @memberof TransferBase
*/
public
formDataChange
({
name
,
newVal
,
oldVal
}:
{
name
:
string
,
newVal
:
any
,
oldVal
:
any
}):
void
{
if
(
this
.
ignorefieldvaluechange
)
{
return
;
}
this
.
resetFormData
({
name
:
name
,
newVal
:
newVal
,
oldVal
:
oldVal
});
this
.
formLogic
({
name
:
name
,
newVal
:
newVal
,
oldVal
:
oldVal
});
this
.
dataChang
.
next
(
JSON
.
stringify
(
this
.
data
));
}
/**
* 表单加载完成
*
* @public
* @param {*} [data={}]
* @param {string} [action]
* @memberof TransferBase
*/
public
onFormLoad
(
data
:
any
=
{},
action
:
string
):
void
{
if
(
Object
.
is
(
action
,
"save"
)
||
Object
.
is
(
action
,
"autoSave"
)
||
Object
.
is
(
action
,
"submit"
))
// 更新context的实体主键
if
(
data
.
ibizsample0021
){
Object
.
assign
(
this
.
context
,{
ibizsample0021
:
data
.
ibizsample0021
})
}
this
.
setFormEnableCond
(
data
);
this
.
computeButtonState
(
data
);
this
.
fillForm
(
data
,
action
);
this
.
oldData
=
{};
Object
.
assign
(
this
.
oldData
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
data
)));
this
.
$store
.
commit
(
'viewaction/setViewDataChange'
,
{
viewtag
:
this
.
viewtag
,
viewdatachange
:
false
});
this
.
formLogic
({
name
:
''
,
newVal
:
null
,
oldVal
:
null
});
}
/**
* 值填充
*
* @param {*} [_datas={}]
* @param {string} [action]
* @memberof TransferBase
*/
public
fillForm
(
_datas
:
any
=
{},
action
:
string
):
void
{
this
.
mixinData
=
_datas
;
this
.
ignorefieldvaluechange
=
true
;
Object
.
keys
(
_datas
).
forEach
((
name
:
string
)
=>
{
if
(
this
.
data
.
hasOwnProperty
(
name
))
{
this
.
data
[
name
]
=
_datas
[
name
];
}
});
if
(
Object
.
is
(
action
,
'loadDraft'
)){
this
.
createDefault
();
}
if
(
Object
.
is
(
action
,
'load'
)){
this
.
updateDefault
();
}
this
.
$nextTick
(
function
()
{
this
.
ignorefieldvaluechange
=
false
;
})
}
/**
* 设置表单项是否启用
*
* @public
* @param {*} data
* @memberof TransferBase
*/
public
setFormEnableCond
(
data
:
any
):
void
{
Object
.
values
(
this
.
detailsModel
).
forEach
((
detail
:
any
)
=>
{
if
(
!
Object
.
is
(
detail
.
detailType
,
'FORMITEM'
))
{
return
;
}
const
formItem
:
FormItemModel
=
detail
;
formItem
.
setEnableCond
(
data
.
srfuf
);
});
}
/**
* 重置草稿表单状态
*
* @public
* @memberof TransferBase
*/
public
resetDraftFormStates
():
void
{
const
form
:
any
=
this
.
$refs
.
form
;
if
(
form
)
{
form
.
resetFields
();
}
}
/**
* 重置校验结果
*
* @memberof TransferBase
*/
public
resetValidates
():
void
{
Object
.
values
(
this
.
detailsModel
).
forEach
((
detail
:
any
)
=>
{
if
(
!
Object
.
is
(
detail
.
detailType
,
'FORMITEM'
))
{
return
;
}
const
formItem
:
FormItemModel
=
detail
;
formItem
.
setError
(
''
);
});
}
/**
* 填充校验结果 (后台)
*
* @param {any[]} fieldErrors
* @memberof TransferBase
*/
public
fillValidates
(
fieldErrors
:
any
[]):
void
{
fieldErrors
.
forEach
((
error
:
any
)
=>
{
const
formItem
:
FormItemModel
=
this
.
detailsModel
[
error
.
field
];
if
(
!
formItem
)
{
return
;
}
this
.
$nextTick
(()
=>
{
formItem
.
setError
(
error
.
message
);
});
});
}
/**
* 表单校验状态
*
* @returns {boolean}
* @memberof TransferBase
*/
public
formValidateStatus
():
boolean
{
const
form
:
any
=
this
.
$refs
.
wfform_transfer
;
let
validatestate
:
boolean
=
true
;
form
.
validate
((
valid
:
boolean
)
=>
{
validatestate
=
valid
?
true
:
false
;
});
return
validatestate
}
/**
* 获取全部值
*
* @returns {*}
* @memberof TransferBase
*/
public
getValues
():
any
{
return
this
.
data
;
}
/**
* 表单项值变更
*
* @param {{ name: string, value: any }} $event
* @returns {void}
* @memberof TransferBase
*/
public
onFormItemValueChange
(
$event
:
{
name
:
string
,
value
:
any
}):
void
{
if
(
!
$event
)
{
return
;
}
if
(
!
$event
.
name
||
Object
.
is
(
$event
.
name
,
''
)
||
!
this
.
data
.
hasOwnProperty
(
$event
.
name
))
{
return
;
}
this
.
data
[
$event
.
name
]
=
$event
.
value
;
}
/**
* 编辑器行为触发
*
* @param {*} arg
* @returns {void}
* @memberof TransferBase
*/
public
onFormItemActionClick
(
arg
:
any
){
if
(
arg
&&
(
arg
instanceof
Function
))
arg
();
}
/**
* 设置数据项值
*
* @param {string} name
* @param {*} value
* @returns {void}
* @memberof TransferBase
*/
public
setDataItemValue
(
name
:
string
,
value
:
any
):
void
{
if
(
!
name
||
Object
.
is
(
name
,
''
)
||
!
this
.
data
.
hasOwnProperty
(
name
))
{
return
;
}
if
(
Object
.
is
(
this
.
data
[
name
],
value
))
{
return
;
}
this
.
data
[
name
]
=
value
;
}
/**
* 计算表单按钮权限状态
*
* @param {*} [data] 传入数据
* @memberof TransferBase
*/
public
computeButtonState
(
data
:
any
){
let
targetData
:
any
=
this
.
transformData
(
data
);
if
(
this
.
detailsModel
&&
Object
.
keys
(
this
.
detailsModel
).
length
>
0
){
Object
.
keys
(
this
.
detailsModel
).
forEach
((
name
:
any
)
=>
{
if
(
this
.
detailsModel
[
name
]
&&
this
.
detailsModel
[
name
].
uiaction
&&
this
.
detailsModel
[
name
].
uiaction
.
dataaccaction
&&
Object
.
is
(
this
.
detailsModel
[
name
].
detailType
,
"BUTTON"
)){
this
.
detailsModel
[
name
].
isPower
=
true
;
let
tempUIAction
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
detailsModel
[
name
].
uiaction
));
let
result
:
any
[]
=
ViewTool
.
calcActionItemAuthState
(
targetData
,[
tempUIAction
],
this
.
appUIService
);
this
.
detailsModel
[
name
].
visible
=
tempUIAction
.
visabled
;
this
.
detailsModel
[
name
].
disabled
=
tempUIAction
.
disabled
;
this
.
detailsModel
[
name
].
isPower
=
result
[
0
]
===
1
?
true
:
false
;
}
})
}
}
/**
* 分组界面行为事件
*
* @param {*} $event
* @memberof TransferBase
*/
public
groupUIActionClick
(
$event
:
any
):
void
{
if
(
!
$event
)
{
return
;
}
const
item
:
any
=
$event
.
item
;
}
/**
* Vue声明周期(处理组件的输入属性)
*
* @memberof TransferBase
*/
public
created
():
void
{
this
.
afterCreated
();
}
/**
* 执行created后的逻辑
*
* @memberof TransferBase
*/
public
afterCreated
(){
if
(
this
.
isautoload
){
this
.
autoLoad
({
srfkey
:
this
.
context
.
ibizsample0021
});
}
if
(
this
.
viewState
)
{
this
.
viewStateEvent
=
this
.
viewState
.
subscribe
(({
tag
,
action
,
data
})
=>
{
if
(
!
Object
.
is
(
tag
,
this
.
name
))
{
return
;
}
if
(
Object
.
is
(
'autoload'
,
action
))
{
this
.
autoLoad
(
data
);
}
if
(
Object
.
is
(
'load'
,
action
))
{
this
.
load
(
data
);
}
if
(
Object
.
is
(
'loaddraft'
,
action
))
{
this
.
loadDraft
(
data
);
}
if
(
Object
.
is
(
'save'
,
action
))
{
this
.
save
(
data
,
data
.
showResultInfo
);
}
if
(
Object
.
is
(
'remove'
,
action
))
{
this
.
remove
(
data
);
}
if
(
Object
.
is
(
'saveandexit'
,
action
))
{
this
.
saveAndExit
(
data
);
}
if
(
Object
.
is
(
'saveandnew'
,
action
))
{
this
.
saveAndNew
(
data
);
}
if
(
Object
.
is
(
'removeandexit'
,
action
))
{
this
.
removeAndExit
(
data
);
}
if
(
Object
.
is
(
'refresh'
,
action
))
{
this
.
refresh
(
data
);
}
if
(
Object
.
is
(
'panelaction'
,
action
))
{
this
.
panelAction
(
data
.
action
,
data
.
emitAction
,
data
.
data
);
}
});
}
this
.
dataChangEvent
=
this
.
dataChang
.
pipe
(
debounceTime
(
300
),
distinctUntilChanged
()
).
subscribe
((
data
:
any
)
=>
{
if
(
this
.
autosave
)
{
this
.
autoSave
();
}
const
state
=
!
Object
.
is
(
JSON
.
stringify
(
this
.
oldData
),
JSON
.
stringify
(
this
.
data
))
?
true
:
false
;
this
.
$store
.
commit
(
'viewaction/setViewDataChange'
,
{
viewtag
:
this
.
viewtag
,
viewdatachange
:
state
});
});
}
/**
* vue 生命周期
*
* @memberof TransferBase
*/
public
destroyed
()
{
this
.
afterDestroy
();
}
/**
* 执行destroyed后的逻辑
*
* @memberof TransferBase
*/
public
afterDestroy
()
{
if
(
this
.
viewStateEvent
)
{
this
.
viewStateEvent
.
unsubscribe
();
}
if
(
this
.
dataChangEvent
)
{
this
.
dataChangEvent
.
unsubscribe
();
}
if
(
this
.
appStateEvent
){
this
.
appStateEvent
.
unsubscribe
();
}
}
/**
*打印
*@memberof @memberof TransferBase
*/
public
print
(){
let
_this
:
any
=
this
;
_this
.
$print
({
id
:
'ibizsample0021_transfer'
,
popTitle
:
'工作转移'
});
}
/**
* 部件刷新
*
* @param {any} args
* @memberof TransferBase
*/
public
refresh
(
args
?:
any
):
void
{
let
arg
:
any
=
{};
Object
.
assign
(
arg
,
args
?
args
[
0
]:{});
if
(
this
.
data
.
srfkey
&&
!
Object
.
is
(
this
.
data
.
srfkey
,
''
))
{
Object
.
assign
(
arg
,
{
srfkey
:
this
.
data
.
srfkey
});
this
.
load
(
arg
);
return
;
}
if
(
this
.
data
.
srfkeys
&&
!
Object
.
is
(
this
.
data
.
srfkeys
,
''
))
{
Object
.
assign
(
arg
,
{
srfkey
:
this
.
data
.
srfkeys
});
this
.
load
(
arg
);
return
;
}
}
/**
* 自动加载
*
* @param {*} [arg={}]
* @returns {void}
* @memberof TransferBase
*/
public
autoLoad
(
arg
:
any
=
{}):
void
{
if
(
arg
.
srfkey
&&
!
Object
.
is
(
arg
.
srfkey
,
''
))
{
Object
.
assign
(
arg
,
{
srfkey
:
arg
.
srfkey
});
this
.
load
(
arg
);
return
;
}
if
(
arg
.
srfkeys
&&
!
Object
.
is
(
arg
.
srfkeys
,
''
))
{
Object
.
assign
(
arg
,
{
srfkey
:
arg
.
srfkeys
});
this
.
load
(
arg
);
return
;
}
this
.
loadDraft
(
arg
);
}
/**
* 加载
*
* @public
* @param {*} [opt={}]
* @memberof TransferBase
*/
public
async
load
(
opt
:
any
=
{}):
Promise
<
any
>
{
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZSample0021REASSIGNWFDynaActionView'
+
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
};
let
viewparamResult
:
any
=
Object
.
assign
(
arg
,
this
.
viewparams
);
const
tempContext
=
Util
.
deepCopy
(
this
.
context
);
if
(
!
(
await
this
.
handleCtrlEvents
(
'onbeforeload'
,
{
context
:
tempContext
,
viewparams
:
viewparamResult
,
data
:
arg
})))
{
return
;
}
const
response
:
any
=
await
this
.
service
.
get
(
this
.
loadAction
,
tempContext
,
{
viewparams
:
viewparamResult
},
this
.
showBusyIndicator
);
try
{
if
(
response
&&
response
.
status
===
200
)
{
if
(
!
(
await
this
.
handleCtrlEvents
(
'onloadsuccess'
,
{
data
:
response
.
data
})))
{
return
;
}
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
'load'
);
this
.
$emit
(
'load'
,
data
);
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'load'
,
data
:
data
});
});
}
else
{
if
(
!
(
await
this
.
handleCtrlEvents
(
'onloaderror'
,
{
data
:
response
.
data
})))
{
return
;
}
}
return
response
;
}
catch
(
response
:
any
)
{
if
(
!
(
await
this
.
handleCtrlEvents
(
'onloaderror'
,
{
context
:
tempContext
,
viewparams
:
viewparamResult
,
data
:
response
&&
response
.
data
?
response
.
data
:
arg
})))
{
return
;
}
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
return
;
}
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
}
}
/**
* 加载草稿
*
* @param {*} [opt={}]
* @memberof TransferBase
*/
public
async
loadDraft
(
opt
:
any
=
{}):
Promise
<
any
>
{
if
(
!
this
.
loaddraftAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZSample0021REASSIGNWFDynaActionView'
+
(
this
.
$t
(
'app.formpage.notconfig.loaddraftaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
}
;
let
viewparamResult
:
any
=
Object
.
assign
(
arg
,
this
.
viewparams
);
try
{
if
(
!
(
await
this
.
handleCtrlEvents
(
'onbeforeloaddraft'
,
{
data
:
arg
})))
{
return
;
}
const
response
:
any
=
this
.
service
.
loadDraft
(
this
.
loaddraftAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),{
viewparams
:
viewparamResult
},
this
.
showBusyIndicator
);
if
(
!
response
.
status
||
response
.
status
!==
200
)
{
if
(
!
(
await
this
.
handleCtrlEvents
(
'onloaddrafterror'
,
{
data
:
response
.
data
?
response
.
data
:
arg
})))
{
return
;
}
if
(
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
}
return
;
}
if
(
!
(
await
this
.
handleCtrlEvents
(
'onloaddraftsuccess'
,
{
data
:
response
.
data
})))
{
return
;
}
const
data
=
response
.
data
;
this
.
resetDraftFormStates
();
this
.
onFormLoad
(
data
,
'loadDraft'
);
data
.
ibizsample0021
=
null
;
this
.
$emit
(
'load'
,
data
);
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'load'
,
data
:
data
});
});
setTimeout
(()
=>
{
const
form
:
any
=
this
.
$refs
.
form
;
if
(
form
)
{
form
.
fields
.
forEach
((
field
:
any
)
=>
{
field
.
validateMessage
=
""
;
field
.
validateState
=
""
;
field
.
validateStatus
=
false
;
});
}
});
return
response
;
}
catch
(
response
:
any
)
{
if
(
!
(
await
this
.
handleCtrlEvents
(
'onloaddrafterror'
,
{
data
:
response
.
data
?
response
.
data
:
arg
})))
{
return
;
}
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
return
response
;
}
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
}
}
/**
* 自动保存
*
* @param {*} [opt={}]
* @memberof TransferBase
*/
public
autoSave
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
formValidateStatus
())
{
return
;
}
const
arg
:
any
=
{
...
opt
};
const
data
=
this
.
getValues
();
Object
.
assign
(
arg
,
data
);
Object
.
assign
(
arg
,{
srfmajortext
:
data
[
this
.
majorMessageField
]});
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
){
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZSample0021REASSIGNWFDynaActionView'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
}
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
const
post
:
Promise
<
any
>
=
this
.
service
.
add
(
action
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
);
post
.
then
((
response
:
any
)
=>
{
if
(
!
response
.
status
||
response
.
status
!==
200
)
{
if
(
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
}
return
;
}
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
'autoSave'
);
this
.
$emit
(
'save'
,
data
);
AppCenterService
.
notifyMessage
({
name
:
"IBIZSample0021"
,
action
:
'appRefresh'
,
data
:
data
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
data
});
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
if
(
response
.
data
.
errorKey
)
{
if
(
Object
.
is
(
response
.
data
.
errorKey
,
"versionCheck"
))
{
this
.
$Modal
.
confirm
({
title
:
(
this
.
$t
(
'app.formpage.saveerror'
)
as
string
),
content
:
(
this
.
$t
(
'app.formpage.savecontent'
)
as
string
),
onOk
:
()
=>
{
this
.
refresh
([]);
},
onCancel
:
()
=>
{
}
});
}
else
if
(
Object
.
is
(
response
.
data
.
errorKey
,
'DupCheck'
))
{
let
errorProp
:
string
=
response
.
data
.
message
.
match
(
/
\[[
a-zA-Z
]
*
\]
/
)[
0
];
let
name
:
string
=
this
.
service
.
getNameByProp
(
errorProp
.
substr
(
1
,
errorProp
.
length
-
2
));
if
(
name
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.createFailed'
)
as
string
),
desc
:
this
.
detailsModel
[
name
].
caption
+
" : "
+
arg
[
name
]
+
(
this
.
$t
(
'app.commonWords.isExist'
)
as
string
)
+
'!'
,
});
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.createFailed'
)
as
string
),
desc
:
response
.
data
.
message
?
response
.
data
.
message
:(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
),
})
}
}
else
if
(
Object
.
is
(
response
.
data
.
errorKey
,
'DuplicateKeyException'
)){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.createFailed'
)
as
string
),
desc
:
this
.
detailsModel
[
this
.
formKeyItemName
].
caption
+
" : "
+
arg
[
this
.
formKeyItemName
]
+
(
this
.
$t
(
'app.commonWords.isExist'
)
as
string
)
+
'!'
,
});
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
?
response
.
data
.
message
:(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
}
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
?
response
.
data
.
message
:(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
}
return
;
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
}
});
}
/**
* 保存
*
* @param {*} [opt={}]
* @param {boolean} [showResultInfo]
* @param {boolean} [ifStateNext] formState是否下发通知
* @returns {Promise<any>}
* @memberof TransferBase
*/
public
save
(
opt
:
any
=
{},
showResultInfo
?:
boolean
,
ifStateNext
:
boolean
=
true
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
showResultInfo
=
showResultInfo
===
undefined
?
true
:
false
;
if
(
!
this
.
formValidateStatus
())
{
if
(
this
.
errorMessages
&&
this
.
errorMessages
.
length
>
0
)
{
let
descMessage
:
string
=
''
;
this
.
errorMessages
.
forEach
((
message
:
any
)
=>
{
descMessage
=
descMessage
+
'<p>'
+
message
.
error
+
'<p>'
;
})
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
descMessage
});
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.formpage.valuecheckex'
)
as
string
)
});
}
return
;
}
const
arg
:
any
=
{
...
opt
};
const
data
=
this
.
getValues
();
Object
.
assign
(
arg
,
this
.
context
);
Object
.
assign
(
arg
,
data
);
Object
.
assign
(
arg
,{
srfmajortext
:
data
[
this
.
majorMessageField
]});
if
(
ifStateNext
)
{
this
.
drcounter
=
0
;
if
(
this
.
drcounter
!==
0
){
this
.
drsaveopt
=
opt
;
this
.
formState
.
next
({
type
:
'beforesave'
,
data
:
arg
});
//先通知关系界面保存
this
.
saveState
=
resolve
;
return
;
}
}
if
(
this
.
viewparams
&&
this
.
viewparams
.
copymode
){
data
.
srfuf
=
'0'
;
}
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
){
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZSample0021REASSIGNWFDynaActionView'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
}
Object
.
assign
(
arg
,
{
viewparams
:
this
.
viewparams
});
this
.
handleCtrlEvents
(
'onbeforesave'
,
{
data
:
arg
}).
then
((
beforeSaveResult
:
boolean
)
=>
{
if
(
!
beforeSaveResult
)
{
return
;
}
const
post
:
Promise
<
any
>
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
service
.
update
(
action
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
):
this
.
service
.
add
(
action
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
);
post
.
then
((
response
:
any
)
=>
{
if
(
!
response
.
status
||
response
.
status
!==
200
)
{
this
.
handleCtrlEvents
(
'onsaverror'
,
{
data
:
response
&&
response
.
data
?
response
.
data
:
arg
}).
then
((
saveErrorResult
:
boolean
)
=>
{
// 保存失败处理
})
if
(
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
}
return
;
}
this
.
handleCtrlEvents
(
'onsavesuccess'
,
{
data
:
response
.
data
}).
then
((
saveSuccessResult
:
boolean
)
=>
{
if
(
!
saveSuccessResult
)
{
return
;
}
this
.
viewparams
.
copymode
=
false
;
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
'save'
);
this
.
$emit
(
'save'
,
data
);
AppCenterService
.
notifyMessage
({
name
:
"IBIZSample0021"
,
action
:
'appRefresh'
,
data
:
data
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
data
});
});
if
(
showResultInfo
)
{
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
data
.
srfmajortext
?
data
.
srfmajortext
:
''
)
+
' '
+
(
this
.
$t
(
'app.formpage.savesuccess'
)
as
string
)
});
}
resolve
(
response
);
})
}).
catch
((
response
:
any
)
=>
{
this
.
handleCtrlEvents
(
'onsaveerror'
,
{
data
:
response
&&
response
.
data
?
response
.
data
:
{}
}).
then
((
saveErrorResult
:
boolean
)
=>
{
if
(
!
saveErrorResult
)
{
return
;
}
if
(
response
&&
response
.
status
&&
response
.
data
)
{
if
(
response
.
data
.
errorKey
)
{
if
(
Object
.
is
(
response
.
data
.
errorKey
,
"versionCheck"
))
{
this
.
$Modal
.
confirm
({
title
:
(
this
.
$t
(
'app.formpage.saveerror'
)
as
string
),
content
:
(
this
.
$t
(
'app.formpage.savecontent'
)
as
string
),
onOk
:
()
=>
{
this
.
refresh
([]);
},
onCancel
:
()
=>
{
}
});
}
else
if
(
Object
.
is
(
response
.
data
.
errorKey
,
'DupCheck'
))
{
let
errorProp
:
string
=
response
.
data
.
message
.
match
(
/
\[[
a-zA-Z
]
*
\]
/
)[
0
];
let
name
:
string
=
this
.
service
.
getNameByProp
(
errorProp
.
substr
(
1
,
errorProp
.
length
-
2
));
if
(
name
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.createFailed'
)
as
string
),
desc
:
this
.
detailsModel
[
name
].
caption
+
" : "
+
arg
[
name
]
+
(
this
.
$t
(
'app.commonWords.isExist'
)
as
string
)
+
'!'
,
});
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.createFailed'
)
as
string
),
desc
:
response
.
data
.
message
,
})
}
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
}
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
reject
(
response
);
}
return
;
}
else
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
reject
(
response
);
}
reject
(
response
);
})
});
})
})
}
/**
* 删除
*
* @public
* @param {*} [opt={}]
* @memberof TransferBase
*/
public
remove
(
opt
:
Array
<
any
>
=
[],
showResultInfo
?:
boolean
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZSample0021REASSIGNWFDynaActionView'
+
(
this
.
$t
(
'app.formpage.notconfig.removeaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
opt
[
0
];
const
_this
:
any
=
this
;
Object
.
assign
(
arg
,
{
viewparams
:
this
.
viewparams
});
this
.
handleCtrlEvents
(
'onbeforeremove'
,
{
data
:
arg
}).
then
((
beforeRemoveResult
:
boolean
)
=>
{
if
(
!
beforeRemoveResult
)
{
return
;
}
this
.
service
.
delete
(
_this
.
removeAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
showResultInfo
).
then
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
===
200
)
{
this
.
handleCtrlEvents
(
'onremovesuccess'
,
{
data
:
response
.
data
}).
then
((
removeSuccessResult
:
boolean
)
=>
{
const
data
=
response
.
data
;
this
.
$emit
(
'remove'
,
data
);
this
.
formState
.
next
({
type
:
'remove'
,
data
:
data
});
this
.
data
.
ismodify
=
false
;
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
data
.
srfmajortext
?
data
.
srfmajortext
:
''
)
+
' '
+
(
this
.
$t
(
'app.formpage.deletesuccess'
)
as
string
)
});
AppCenterService
.
notifyMessage
({
name
:
"IBIZSample0021"
,
action
:
'appRefresh'
,
data
:
data
});
resolve
(
response
);
})
}
else
{
this
.
handleCtrlEvents
(
'onremoveerror'
,
{
data
:
response
&&
response
.
data
?
response
.
data
:
arg
});
}
}).
catch
((
error
:
any
)
=>
{
this
.
handleCtrlEvents
(
'onremoveerror'
,
{
data
:
error
&&
error
.
data
?
error
.
data
:
arg
}).
then
((
removeErrorResult
)
=>
{
if
(
!
removeErrorResult
)
{
const
{
data
:
_data
}
=
error
;
this
.
$Notice
.
error
({
title
:
_data
.
title
,
desc
:
_data
.
message
});
reject
(
error
);
}
})
});
})
});
}
/**
* 工作流启动
*
* @param {*} [data={}]
* @param {*} [localdata={}]
* @returns {Promise<any>}
* @memberof TransferBase
*/
public
async
wfstart
(
data
:
any
,
localdata
?:
any
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_this
:
any
=
this
;
const
formData
:
any
=
this
.
getData
();
const
copyData
:
any
=
Util
.
deepCopy
(
formData
);
const
post
:
Promise
<
any
>
=
Object
.
is
(
formData
.
srfuf
,
'1'
)?
this
.
service
.
update
(
this
.
updateAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
formData
,
this
.
showBusyIndicator
,
true
):
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
formData
,
this
.
showBusyIndicator
,
true
);
post
.
then
((
response
:
any
)
=>
{
const
responseData
:
any
=
response
.
data
;
let
tempResponseData
:
any
=
Util
.
deepCopy
(
response
);
this
.
service
.
handleResponse
(
'save'
,
tempResponseData
);
const
arg
:
any
=
tempResponseData
.
data
;
// 保存完成UI处理
this
.
onFormLoad
(
arg
,
'save'
);
this
.
$emit
(
'save'
,
arg
);
AppCenterService
.
notifyMessage
({
name
:
"IBIZSample0021"
,
action
:
'appRefresh'
,
data
:
data
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
arg
});
});
// 准备工作流数据,填充未存库数据
Object
.
assign
(
arg
,
copyData
);
// 准备提交参数
if
(
this
.
viewparams
){
let
copyViewParams
:
any
=
Util
.
deepCopy
(
this
.
viewparams
);
if
(
copyViewParams
.
w
){
delete
copyViewParams
.
w
;
}
Object
.
assign
(
responseData
,
copyViewParams
);
}
Object
.
assign
(
arg
,{
viewparams
:
responseData
});
// 强制补充srfwfmemo
if
(
this
.
srfwfmemo
){
Object
.
assign
(
arg
,{
srfwfmemo
:
this
.
srfwfmemo
});
}
const
result
:
Promise
<
any
>
=
this
.
service
.
wfstart
(
_this
.
WFStartAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
,
localdata
);
result
.
then
((
response
:
any
)
=>
{
if
(
!
response
||
response
.
status
!==
200
)
{
if
(
response
.
data
){
this
.
$Notice
.
error
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.formpage.workflow.starterror'
)
as
string
)
+
', '
+
response
.
data
.
message
});
}
return
;
}
this
.
$Notice
.
info
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.formpage.workflow.startsuccess'
)
as
string
)
});
resolve
(
response
);
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
reject
(
response
);
return
;
}
reject
(
response
);
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
reject
(
response
);
return
;
}
reject
(
response
);
})
});
}
/**
* 工作流提交
*
* @param {*} [data={}]
* @param {*} [localdata={}]
* @returns {Promise<any>}
* @memberof TransferBase
*/
public
async
wfsubmit
(
data
:
any
,
localdata
?:
any
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_this
:
any
=
this
;
const
arg
:
any
=
data
[
0
];
const
copyData
:
any
=
Util
.
deepCopy
(
arg
);
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
if
(
!
arg
.
ibizsample0021
||
Object
.
is
(
arg
.
ibizsample0021
,
''
))
{
return
;
}
const
post
:
Promise
<
any
>
=
Object
.
is
(
arg
.
srfuf
,
'1'
)?
this
.
service
.
update
(
this
.
updateAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
,
true
):
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
,
true
);
post
.
then
((
response
:
any
)
=>
{
const
responseData
:
any
=
response
.
data
;
let
tempResponseData
:
any
=
Util
.
deepCopy
(
response
);
this
.
service
.
handleResponse
(
'save'
,
tempResponseData
);
const
arg
:
any
=
tempResponseData
.
data
;
// 保存完成UI处理
this
.
onFormLoad
(
arg
,
'save'
);
this
.
$emit
(
'save'
,
arg
);
AppCenterService
.
notifyMessage
({
name
:
"IBIZSample0021"
,
action
:
'appRefresh'
,
data
:
data
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
arg
});
});
// 准备工作流数据,填充未存库数据
Object
.
assign
(
arg
,
copyData
);
// 准备提交参数
if
(
this
.
viewparams
){
Object
.
assign
(
responseData
,
this
.
viewparams
);
}
Object
.
assign
(
arg
,{
viewparams
:
responseData
});
// 强制补充srfwfmemo
if
(
this
.
srfwfmemo
){
Object
.
assign
(
arg
,{
srfwfmemo
:
this
.
srfwfmemo
});
}
const
result
:
Promise
<
any
>
=
this
.
service
.
wfsubmit
(
_this
.
WFSubmitAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
,
localdata
);
result
.
then
((
response
:
any
)
=>
{
if
(
!
response
||
response
.
status
!==
200
)
{
if
(
response
.
data
){
this
.
$Notice
.
error
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.formpage.workflow.submiterror'
)
as
string
)
+
', '
+
response
.
data
.
message
});
}
return
;
}
this
.
onFormLoad
(
arg
,
'submit'
);
this
.
$store
.
dispatch
(
'viewaction/datasaved'
,
{
viewtag
:
this
.
viewtag
});
this
.
$Notice
.
info
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.formpage.workflow.submitsuccess'
)
as
string
)
});
resolve
(
response
);
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
reject
(
response
);
return
;
}
reject
(
response
);
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
reject
(
response
);
return
;
}
reject
(
response
);
})
})
}
/**
* 面板行为
*
* @param {string} [action] 调用的实体行为
* @param {string} [emitAction] 抛出行为
* @param {*} [data={}] 传入数据
* @param {boolean} [showloading] 是否显示加载状态
*
* @memberof TransferBase
*/
public
panelAction
(
action
:
string
,
emitAction
:
string
,
data
:
any
=
{},
showloading
?:
boolean
):
void
{
if
(
!
action
||
(
action
&&
Object
.
is
(
action
,
''
)))
{
return
;
}
const
arg
:
any
=
{
...
data
};
const
formdata
=
this
.
getValues
();
Object
.
assign
(
arg
,
formdata
);
Object
.
assign
(
arg
,
this
.
viewparams
);
const
post
:
Promise
<
any
>
=
this
.
service
.
frontLogic
(
action
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
showloading
);
post
.
then
((
response
:
any
)
=>
{
if
(
!
response
.
status
||
response
.
status
!==
200
)
{
if
(
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
}
return
;
}
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
emitAction
);
this
.
$emit
(
emitAction
,
data
);
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
emitAction
,
data
:
data
});
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
return
;
}
});
}
/**
* 表单项更新
*
* @param {string} mode 界面行为名称
* @param {*} [data={}] 请求数据
* @param {string[]} updateDetails 更新项
* @param {boolean} [showloading] 是否显示加载状态
* @returns {void}
* @memberof TransferBase
*/
public
updateFormItems
(
mode
:
string
,
data
:
any
=
{},
updateDetails
:
string
[],
showloading
?:
boolean
):
void
{
if
(
!
mode
||
(
mode
&&
Object
.
is
(
mode
,
''
)))
{
return
;
}
const
arg
:
any
=
{
...
data
};
Object
.
assign
(
arg
,
this
.
viewparams
);
const
post
:
Promise
<
any
>
=
this
.
service
.
frontLogic
(
mode
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
showloading
);
post
.
then
((
response
:
any
)
=>
{
if
(
!
response
||
response
.
status
!==
200
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.formpage.updateerror'
)
as
string
)
});
return
;
}
const
data
=
response
.
data
;
const
_data
:
any
=
{};
updateDetails
.
forEach
((
name
:
string
)
=>
{
if
(
!
data
.
hasOwnProperty
(
name
))
{
return
;
}
Object
.
assign
(
_data
,
{
[
name
]:
data
[
name
]
});
});
this
.
setFormEnableCond
(
_data
);
this
.
fillForm
(
_data
,
'updateFormItem'
);
this
.
formLogic
({
name
:
''
,
newVal
:
null
,
oldVal
:
null
});
this
.
dataChang
.
next
(
JSON
.
stringify
(
this
.
data
));
AppCenterService
.
notifyMessage
({
name
:
"IBIZSample0021"
,
action
:
'appRefresh'
,
data
:
data
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'updateformitem'
,
ufimode
:
arg
.
srfufimode
,
data
:
_data
});
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
response
.
data
.
message
});
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
return
;
}
});
}
/**
* 回车事件
*
* @param {*} $event
* @memberof TransferBase
*/
public
onEnter
(
$event
:
any
):
void
{
}
/**
* 保存并退出
*
* @param {any[]} args
* @memberof TransferBase
*/
public
saveAndExit
(
data
:
any
[]):
Promise
<
any
>
{
let
_this
=
this
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
arg
:
any
=
{};
if
(
data
&&
data
.
length
>
0
){
Object
.
assign
(
arg
,
data
[
0
]);
}
_this
.
currentAction
=
"saveAndExit"
;
_this
.
save
([
arg
]).
then
((
res
)
=>
{
if
(
res
){
_this
.
closeView
(
res
.
data
);
}
resolve
(
res
);
}).
catch
((
error
)
=>
{
reject
(
error
);
})
})
}
/**
* 保存并新建
*
* @param {any[]} args
* @memberof TransferBase
*/
public
saveAndNew
(
data
:
any
[]):
Promise
<
any
>
{
let
_this
=
this
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
arg
:
any
=
{};
if
(
data
&&
data
.
length
>
0
){
Object
.
assign
(
arg
,
data
[
0
]);
}
_this
.
currentAction
=
"saveAndNew"
;
_this
.
save
([
arg
]).
then
((
res
)
=>
{
_this
.
ResetData
(
res
);
_this
.
loadDraft
({});
}).
catch
((
error
)
=>
{
reject
(
error
);
})
})
}
/**
* 删除并退出
*
* @param {any[]} args
* @memberof TransferBase
*/
public
removeAndExit
(
data
:
any
[]):
Promise
<
any
>
{
let
_this
=
this
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
arg
:
any
=
{};
if
(
data
&&
data
.
length
>
0
){
Object
.
assign
(
arg
,
data
[
0
]);
}
_this
.
remove
([
arg
]).
then
((
res
)
=>
{
if
(
res
){
_this
.
closeView
(
res
.
data
);
}
resolve
(
res
);
}).
catch
((
error
)
=>
{
reject
(
error
);
})
})
}
/**
* 关系界面数据保存完成
*
* @param {any} $event
* @memberof TransferBase
*/
public
drdatasaved
(
$event
:
any
){
let
_this
=
this
;
this
.
drcounter
--
;
if
(
this
.
drcounter
===
0
){
this
.
save
(
this
.
drsaveopt
,
undefined
,
false
).
then
((
res
)
=>
{
this
.
saveState
(
res
);
this
.
drsaveopt
=
{};
if
(
Object
.
is
(
_this
.
currentAction
,
"saveAndNew"
)){
_this
.
ResetData
(
res
);
_this
.
loadDraft
({});
}
else
if
(
Object
.
is
(
_this
.
currentAction
,
"saveAndExit"
)){
if
(
res
){
_this
.
closeView
(
res
.
data
);
}
}
});
}
}
/**
* 新建默认值
* @memberof TransferBase
*/
public
createDefault
(){
}
/**
* 更新默认值
* @memberof TransferBase
*/
public
updateDefault
(){
}
/**
* 面板数据变化处理事件
* @param {any} item 当前列数据
* @param {any} $event 面板事件数据
*
* @memberof TransferBase
*/
public
onPanelDataChange
(
item
:
any
,
$event
:
any
)
{
Object
.
assign
(
item
,
$event
,
{
rowDataState
:
'update'
});
}
}
</
script
>
<
style
lang=
'less'
>
@import './transfer-form.less';
</
style
>
\ No newline at end of file
app_Web/src/widgets/ibizsample0021/transfer-form/transfer-form-model.ts
0 → 100644
浏览文件 @
587e7a8a
// 基于 @CONTROL/表单/MODEL.ts.ftl 生成
/**
* Transfer 部件模型
*
* @export
* @class TransferModel
*/
export
default
class
TransferModel
{
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof TransferModel
*/
public
getDataItems
():
any
[]
{
return
[
{
name
:
'srfwfmemo'
,
prop
:
'srfwfmemo'
,
dataType
:
'TEXT'
,
},
// 前端新增修改标识,新增为"0",修改为"1"或未设值
{
name
:
'srffrontuf'
,
prop
:
'srffrontuf'
,
dataType
:
'TEXT'
,
},
{
name
:
'srfupdatedate'
,
prop
:
'updatedate'
,
dataType
:
'DATETIME'
,
},
{
name
:
'srforikey'
,
},
{
name
:
'srfkey'
,
prop
:
'ibizsample0021id'
,
dataType
:
'GUID'
,
},
{
name
:
'srfmajortext'
,
prop
:
'ibizsample0021name'
,
dataType
:
'TEXT'
,
},
{
name
:
'srftempmode'
,
},
{
name
:
'srfuf'
,
},
{
name
:
'srfdeid'
,
},
{
name
:
'srfsourcekey'
,
},
{
name
:
'deptheads'
,
prop
:
'deptheads'
,
dataType
:
'TEXT'
,
},
{
name
:
'deptheadsid'
,
prop
:
'deptheadsid'
,
dataType
:
'TEXT'
,
},
{
name
:
'ibizsample0021id'
,
prop
:
'ibizsample0021id'
,
dataType
:
'GUID'
,
},
{
name
:
'ibizsample0021'
,
prop
:
'ibizsample0021id'
,
dataType
:
'FONTKEY'
,
},
]
}
}
\ No newline at end of file
app_Web/src/widgets/ibizsample0021/transfer-form/transfer-form-service.ts
0 → 100644
浏览文件 @
587e7a8a
// 基于 @CONTROL/表单/SERVICE.ts.ftl 生成
import
{
Http
,
Util
,
Errorlog
}
from
'@/utils'
;
import
ControlService
from
'@/widgets/control-service'
;
import
IBIZSample0021Service
from
'@/service/ibizsample0021/ibizsample0021-service'
;
import
TransferModel
from
'./transfer-form-model'
;
/**
* Transfer 部件服务对象
*
* @export
* @class TransferService
*/
export
default
class
TransferService
extends
ControlService
{
/**
* 订单服务对象
*
* @type {IBIZSample0021Service}
* @memberof TransferService
*/
public
appEntityService
:
IBIZSample0021Service
=
new
IBIZSample0021Service
();
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof TransferService
*/
public
setTempMode
(){
this
.
isTempMode
=
false
;
}
/**
* Creates an instance of TransferService.
*
* @param {*} [opts={}]
* @memberof TransferService
*/
constructor
(
opts
:
any
=
{})
{
super
(
opts
);
this
.
model
=
new
TransferModel
();
}
/**
* 远端数据
*
* @type {*}
* @memberof TransferService
*/
private
remoteCopyData
:
any
=
{};
/**
* 处理数据
*
* @private
* @param {Promise<any>} promise
* @returns {Promise<any>}
* @memberof TransferService
*/
private
doItems
(
promise
:
Promise
<
any
>
,
deKeyField
:
string
,
deName
:
string
):
Promise
<
any
>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
promise
.
then
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
===
200
)
{
const
data
=
response
.
data
;
data
.
forEach
((
item
:
any
,
index
:
number
)
=>
{
item
[
deName
]
=
item
[
deKeyField
];
data
[
index
]
=
item
;
});
resolve
(
data
);
}
else
{
reject
([])
}
}).
catch
((
response
:
any
)
=>
{
reject
([])
});
});
}
/**
* 获取跨实体数据集合
*
* @param {string} serviceName 服务名称
* @param {string} interfaceName 接口名称
* @param {*} data
* @param {boolean} [isloading]
* @returns {Promise<any[]>}
* @memberof TransferService
*/
@
Errorlog
public
getItems
(
serviceName
:
string
,
interfaceName
:
string
,
context
:
any
=
{},
data
:
any
,
isloading
?:
boolean
):
Promise
<
any
[]
>
{
data
.
page
=
data
.
page
?
data
.
page
:
0
;
data
.
size
=
data
.
size
?
data
.
size
:
1000
;
return
Promise
.
reject
([])
}
/**
* 启动工作流
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {*} [localdata]
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
wfstart
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
localdata
?:
any
):
Promise
<
any
>
{
data
=
this
.
handleWFData
(
data
,
true
);
context
=
this
.
handleRequestData
(
action
,
context
,
data
).
context
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
context
,
data
,
isloading
,
localdata
);
}
else
{
result
=
this
.
appEntityService
.
WFStart
(
context
,
data
,
isloading
,
localdata
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 提交工作流
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {*} [localdata]
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
wfsubmit
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
localdata
?:
any
):
Promise
<
any
>
{
data
=
this
.
handleWFData
(
data
,
true
);
context
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
).
context
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
context
,
data
,
isloading
,
localdata
);
}
else
{
result
=
this
.
appEntityService
.
WFSubmit
(
context
,
data
,
isloading
,
localdata
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 添加数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {boolean} [isWorkflow] 是否在工作流中添加数据
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
add
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
isWorkflow
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
this
.
appEntityService
.
Create
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
if
(
isWorkflow
){
resolve
(
response
);
}
else
{
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 删除数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
delete
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
this
.
appEntityService
.
Remove
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 修改数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {boolean} [isWorkflow] 是否在工作流中修改数据
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
update
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
isWorkflow
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
this
.
appEntityService
.
Update
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
if
(
isWorkflow
){
resolve
(
response
);
}
else
{
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 查询数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
get
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
this
.
appEntityService
.
Get
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
this
.
setRemoteCopyData
(
response
);
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 加载草稿
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
loadDraft
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
);
//仿真主键数据
const
PrimaryKey
=
Util
.
createUUID
();
Data
.
ibizsample0021id
=
PrimaryKey
;
Data
.
ibizsample0021
=
PrimaryKey
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
this
.
appEntityService
.
GetDraft
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
this
.
setRemoteCopyData
(
response
);
response
.
data
.
ibizsample0021id
=
PrimaryKey
;
this
.
handleResponse
(
action
,
response
,
true
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 前台逻辑
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof TransferService
*/
@
Errorlog
public
frontLogic
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
return
Promise
.
reject
({
status
:
500
,
data
:
{
title
:
'失败'
,
message
:
'系统异常'
}
});
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
,
true
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
})
}
/**
* 处理请求数据
*
* @param action 行为
* @param data 数据
* @memberof TransferService
*/
public
handleRequestData
(
action
:
string
,
context
:
any
,
data
:
any
=
{},
isMerge
:
boolean
=
false
){
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
let
requestData
:
any
=
{};
if
(
isMerge
&&
(
data
&&
data
.
viewparams
)){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
&&
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
'FONTKEY'
)){
if
(
item
&&
item
.
prop
){
requestData
[
item
.
prop
]
=
context
[
item
.
name
];
}
}
else
{
if
(
item
&&
item
.
prop
){
requestData
[
item
.
prop
]
=
data
[
item
.
name
];
}
else
{
if
(
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
"FORMPART"
)){
Object
.
assign
(
requestData
,
data
[
item
.
name
]);
}
}
}
});
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
if
(
tempContext
&&
tempContext
.
srfsessionid
){
tempContext
.
srfsessionkey
=
tempContext
.
srfsessionid
;
delete
tempContext
.
srfsessionid
;
}
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof TransferService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
/**
* 重写处理返回数据
*
* @param {string} action
* @param {*} response
* @memberof TransferService
*/
public
handleResponseData
(
action
:
string
,
data
:
any
=
{},
isCreate
?:
boolean
,
codelistArray
?:
any
){
let
model
:
any
=
this
.
getMode
();
if
(
!
model
&&
model
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
item
:
any
=
{};
let
dataItems
:
any
[]
=
model
.
getDataItems
();
dataItems
.
forEach
(
dataitem
=>
{
let
val
=
data
.
hasOwnProperty
(
dataitem
.
prop
)
?
data
[
dataitem
.
prop
]
:
null
;
if
(
val
===
null
)
{
val
=
data
.
hasOwnProperty
(
dataitem
.
name
)
?
data
[
dataitem
.
name
]
:
null
;
}
if
((
isCreate
===
undefined
||
isCreate
===
null
)
&&
Object
.
is
(
dataitem
.
dataType
,
'GUID'
)
&&
Object
.
is
(
dataitem
.
name
,
'srfkey'
)
&&
(
val
&&
!
Object
.
is
(
val
,
''
))){
isCreate
=
true
;
}
item
[
dataitem
.
name
]
=
val
;
// 转化代码表
if
(
codelistArray
&&
dataitem
.
codelist
){
if
(
codelistArray
.
get
(
dataitem
.
codelist
.
tag
)
&&
codelistArray
.
get
(
dataitem
.
codelist
.
tag
).
get
(
val
)){
item
[
dataitem
.
name
]
=
codelistArray
.
get
(
dataitem
.
codelist
.
tag
).
get
(
val
);
}
}
});
item
.
srfuf
=
data
.
srfuf
?
data
.
srfuf
:
(
isCreate
?
"0"
:
"1"
);
item
=
Object
.
assign
(
data
,
item
);
return
item
;
}
/**
* 设置远端数据
*
* @param result 远端请求结果
* @memberof TransferService
*/
public
setRemoteCopyData
(
result
:
any
){
if
(
result
&&
result
.
status
===
200
)
{
this
.
remoteCopyData
=
Util
.
deepCopy
(
result
.
data
);
}
}
/**
* 获取远端数据
*
* @memberof TransferService
*/
public
getRemoteCopyData
(){
return
this
.
remoteCopyData
;
}
}
\ No newline at end of file
app_Web/src/widgets/ibizsample0021/transfer-form/transfer-form.less
0 → 100644
浏览文件 @
587e7a8a
// 基于 @CONTROL/表单/CONTROL.less.ftl 生成
.ivu-tabs-no-animation>.ivu-tabs-content{
padding: 0 16px;
}
.ivu-card-head{
padding: 14px 0;
}
.app-form {
overflow: auto;
padding: 6px;
> .ivu-row {
> .ivu-tabs {
height: 100%;
display: flex;
flex-direction: column;
> .ivu-tabs-content {
flex-grow: 1;
overflow: auto;
> .ivu-tabs-tabpane {
height: 100%;
}
}
}
}
}
.app-tabpanel-flex {
height: 100%;
> .ivu-tabs-content {
height: calc(100% - 52px);
> .ivu-tabs-tabpane {
height: 100%;
}
}
}
.app-form {
>.ivu-row:nth-child(2) {
>.ivu-col:nth-child(1) {
>.ivu-row.app-form-group.app-group-hiddden-caption:nth-child(1) {
margin-top: 12px;
}
}
}
}
.app-form{
// 表单行间距
.app-form-item{
margin-bottom: 20px;
}
// 表单按钮margin
.app-form-button{
margin:0 6px;
}
}
// this is less
app_Web/src/widgets/ibizsample0021/transfer-form/transfer-form.vue
0 → 100644
浏览文件 @
587e7a8a
<
script
lang=
'tsx'
>
import
{
Component
}
from
'vue-property-decorator'
;
import
TransferBase
from
'./transfer-form-base.vue'
;
// 基于 @CONTROL/@MACRO/CONTROL/CONTROL.vue.ftl 生成
@
Component
({
components
:
{
}
})
export
default
class
Transfer
extends
TransferBase
{
}
</
script
>
\ No newline at end of file
demo-boot/src/main/resources/static/remotemodel/PSMODULES/Sample/PSDATAENTITIES/IBIZSample0021.json
浏览文件 @
587e7a8a
...
...
@@ -1262,6 +1262,70 @@
"viewLevel"
:
0
,
"phisicalDEField"
:
false
,
"uIAssistDEField"
:
true
},
{
"getAllPSDEFUIModes"
:
[
{
"codeName"
:
"MobileDefault"
,
"name"
:
"[DEPTHEADSID][部门领导标识]移动端默认"
,
"getPSDEFFormItem"
:
{
"codeName"
:
"MobileDefault"
,
"editorType"
:
"MOBTEXT"
,
"name"
:
"[DEPTHEADSID][部门领导标识]移动端默认"
,
"stringLength"
:
100
,
"uIMode"
:
"MOBILEDEFAULT"
,
"mobileMode"
:
true
},
"type"
:
"MOBILEDEFAULT"
,
"mobileMode"
:
true
},
{
"codeName"
:
"Default"
,
"name"
:
"[DEPTHEADSID][部门领导标识]"
,
"getPSDEFFormItem"
:
{
"codeName"
:
"Default"
,
"editorType"
:
"TEXTBOX"
,
"name"
:
"[DEPTHEADSID][部门领导标识]"
,
"stringLength"
:
100
,
"uIMode"
:
"DEFAULT"
},
"type"
:
"DEFAULT"
}
],
"getAllPSDEFValueRules"
:
[
{
"codeName"
:
"Default"
,
"name"
:
"默认规则"
,
"getPSDEFVRGroupCondition"
:
{
"condOp"
:
"AND"
,
"condType"
:
"GROUP"
,
"name"
:
"默认组"
,
"getPSDEFVRConditions"
:
[
{
"condType"
:
"STRINGLENGTH"
,
"dEFName"
:
"DEPTHEADSID"
,
"maxValue"
:
100
,
"name"
:
"默认字符串长度"
,
"ruleInfo"
:
"内容长度必须小于等于[100]"
,
"includeMaxValue"
:
true
,
"includeMinValue"
:
false
,
"keyCond"
:
true
}
],
"ruleInfo"
:
"内容长度必须小于等于[100]"
},
"ruleInfo"
:
"内容长度必须小于等于[100]"
,
"checkDefault"
:
true
,
"defaultMode"
:
true
,
"enableBackend"
:
true
,
"enableFront"
:
true
}
],
"codeName"
:
"DeptHeadsId"
,
"dEFType"
:
5
,
"dataType"
:
"TEXT"
,
"importOrder"
:
1000
,
"length"
:
100
,
"logicName"
:
"部门领导"
,
"name"
:
"DEPTHEADSID"
,
"stdDataType"
:
25
,
"stringLength"
:
100
,
"valueFormat"
:
"%1$s"
,
"viewLevel"
:
0
,
"phisicalDEField"
:
false
,
"uIAssistDEField"
:
true
}
],
"getAllPSDEMethodDTOs"
:
[
{
"name"
:
"IBIZSample0021DTO"
,
...
...
@@ -1334,6 +1398,17 @@
"stdDataType"
:
25
,
"stringLength"
:
100
,
"type"
:
"SIMPLE"
},
{
"logicName"
:
"部门领导"
,
"name"
:
"DeptHeadsId"
,
"getPSDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"sourceType"
:
"DEFIELD"
,
"stdDataType"
:
25
,
"stringLength"
:
100
,
"type"
:
"SIMPLE"
},
{
"logicName"
:
"订单标识"
,
"name"
:
"IBIZSample0021Id"
,
...
...
@@ -1661,6 +1736,13 @@
"name"
:
"部门领导审批通过操作表单"
,
"realModelSubType"
:
"EDITFORM"
,
"realModelType"
:
"PSDEFORM"
},
{
"codeName"
:
"transfer"
,
"logicName"
:
"工作转移"
,
"modelTag2"
:
"0"
,
"name"
:
"工作转移"
,
"realModelSubType"
:
"EDITFORM"
,
"realModelType"
:
"PSDEFORM"
},
{
"codeName"
:
"operationForm"
,
"logicName"
:
"操作表单"
,
...
...
@@ -1689,6 +1771,13 @@
"name"
:
"Usr1116491232WFDynaStartView_表单"
,
"realModelSubType"
:
"EDITFORM"
,
"realModelType"
:
"PSDEFORM"
},
{
"codeName"
:
"beforeSign"
,
"logicName"
:
"加签"
,
"modelTag2"
:
"0"
,
"name"
:
"加签"
,
"realModelSubType"
:
"EDITFORM"
,
"realModelType"
:
"PSDEFORM"
},
{
"codeName"
:
"Usr1116490270"
,
"logicName"
:
" 实体工作流动态操作视图(前加签)_表单"
,
...
...
demo-boot/src/main/resources/static/remotemodel/PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json
浏览文件 @
587e7a8a
...
...
@@ -341,6 +341,12 @@
"name"
:
"DEPTHEADS"
,
"stdDataType"
:
25
,
"stringLength"
:
100
},
{
"codeName"
:
"DeptHeadsId"
,
"logicName"
:
"部门领导"
,
"name"
:
"DEPTHEADSID"
,
"stdDataType"
:
25
,
"stringLength"
:
100
}
],
"getAllPSAppDEMethodDTOs"
:
[
{
"codeName"
:
"IBIZSample0021DTO"
,
...
...
@@ -419,6 +425,18 @@
"sourceType"
:
"DEFIELD"
,
"stdDataType"
:
25
,
"type"
:
"SIMPLE"
},
{
"codeName"
:
"DeptHeadsId"
,
"logicName"
:
"部门领导"
,
"name"
:
"DeptHeadsId"
,
"orderValue"
:
1000
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"sourceType"
:
"DEFIELD"
,
"stdDataType"
:
25
,
"type"
:
"SIMPLE"
},
{
"codeName"
:
"IBIZSample0021Id"
,
"logicName"
:
"订单标识"
,
...
...
demo-boot/src/main/resources/static/remotemodel/PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021/PSFORMS/Start001.json
浏览文件 @
587e7a8a
...
...
@@ -74,6 +74,14 @@
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
}
},
{
"id"
:
"deptheadsid"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
}
},
{
"id"
:
"ibizsample0021id"
,
"hidden"
:
true
,
...
...
@@ -125,6 +133,7 @@
"editorType"
:
"PICKER"
,
"handlerType"
:
"PickupText"
,
"name"
:
"deptheads"
,
"valueItemName"
:
"deptheadsid"
,
"enableAC"
:
true
,
"enablePickupView"
:
true
,
"forceSelection"
:
true
,
...
...
@@ -135,7 +144,35 @@
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"valueItemName"
:
"deptheadsid"
,
"allowEmpty"
:
true
,
"showCaption"
:
true
},
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheadsid"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheadsid"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"getPSEditor"
:
{
"editorType"
:
"HIDDEN"
,
"name"
:
"deptheadsid"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"allowEmpty"
:
true
,
"hidden"
:
true
,
"showCaption"
:
true
}
],
"getPSLayout"
:
{
...
...
demo-boot/src/main/resources/static/remotemodel/PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021/PSFORMS/Transfer.json
0 → 100644
浏览文件 @
587e7a8a
{
"codeName"
:
"Transfer"
,
"controlType"
:
"FORM"
,
"getCreatePSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"create"
},
"dynaModelFilePath"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021/PSFORMS/Transfer.json"
,
"getGetDraftFromPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"loaddraftfrom"
},
"getGetDraftPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"loaddraft"
},
"getGetPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"load"
},
"logicName"
:
"工作转移"
,
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
},
"getPSDEFormItems"
:
[
{
"id"
:
"srfupdatedate"
,
"hidden"
:
true
,
"dataType"
:
5
,
"getPSAppDEField"
:
{
"name"
:
"UPDATEDATE"
,
"codeName"
:
"UpdateDate"
}
},
{
"id"
:
"srforikey"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfkey"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"IBIZSAMPLE0021ID"
,
"codeName"
:
"IBIZSample0021Id"
}
},
{
"id"
:
"srfmajortext"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"IBIZSAMPLE0021NAME"
,
"codeName"
:
"IBIZSample0021Name"
}
},
{
"id"
:
"srftempmode"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfuf"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfdeid"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfsourcekey"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"deptheads"
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
}
},
{
"id"
:
"deptheadsid"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
}
},
{
"id"
:
"ibizsample0021id"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"IBIZSAMPLE0021ID"
,
"codeName"
:
"IBIZSample0021Id"
}
}
],
"getPSDEFormPages"
:
[
{
"caption"
:
"基本信息"
,
"codeName"
:
"formpage1"
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMPAGE"
,
"name"
:
"formpage1"
,
"getPSDEFormDetails"
:
[
{
"actionGroupExtractMode"
:
"ITEM"
,
"caption"
:
"订单基本信息"
,
"codeName"
:
"group1"
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"GROUPPANEL"
,
"name"
:
"group1"
,
"getPSDEFormDetails"
:
[
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheads"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheads"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
},
"getPSEditor"
:
{
"editorParams"
:
{
"multiple"
:
"false"
,
"url"
:
"/wfcore/wfgroups/DepartmentHeads/wfmembers/fetchdefault?n_mdeptid_eq=${srforgsectorid}&sort=showorder,asc"
,
"AC"
:
"TRUE"
,
"fillMap"
:
"{id:'userid',label:'personname'}"
,
"PICKUPVIEW"
:
"TRUE"
,
"REALSTYLECODE"
:
"COMMONMICROCOM"
},
"editorStyle"
:
"COMMONMICROCOM"
,
"editorType"
:
"PICKER"
,
"handlerType"
:
"PickupText"
,
"name"
:
"deptheads"
,
"valueItemName"
:
"deptheadsid"
,
"enableAC"
:
true
,
"enablePickupView"
:
true
,
"forceSelection"
:
true
,
"showTrigger"
:
true
,
"singleSelect"
:
true
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"valueItemName"
:
"deptheadsid"
,
"allowEmpty"
:
true
,
"showCaption"
:
true
},
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheadsid"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheadsid"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"getPSEditor"
:
{
"editorType"
:
"HIDDEN"
,
"name"
:
"deptheadsid"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"allowEmpty"
:
true
,
"hidden"
:
true
,
"showCaption"
:
true
}
],
"getPSLayout"
:
{
"columnCount"
:
24
,
"layout"
:
"TABLE_24COL"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"infoGroupMode"
:
false
,
"showCaption"
:
false
}
],
"getPSLayout"
:
{
"columnCount"
:
24
,
"layout"
:
"TABLE_24COL"
},
"infoGroupMode"
:
false
}
],
"getPSLayout"
:
{
"columnCount"
:
24
,
"layout"
:
"TABLE_24COL"
},
"getRemovePSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"remove"
},
"tabHeaderPos"
:
"TOP"
,
"getUpdatePSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"update"
},
"getWFStartPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"WFSTART"
},
"getWFSubmitPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"WFSUBMIT"
},
"noTabHeader"
:
true
,
"modelid"
:
"0D397329-34E2-4381-B84C-108492D610BA"
,
"modeltype"
:
"PSDEFORM_EDITFORM"
}
\ No newline at end of file
demo-boot/src/main/resources/static/remotemodel/PSSYSAPPS/Web/PSAPPDEVIEWS/IBIZSample0021REASSIGNWFDynaActionView.json
浏览文件 @
587e7a8a
...
...
@@ -475,6 +475,325 @@
"name"
:
"form"
,
"modelid"
:
"D289CD12-0718-43A8-966E-12BB48B263B2"
,
"modeltype"
:
"PSDEFORM_EDITFORM"
},
{
"codeName"
:
"Transfer"
,
"controlType"
:
"FORM"
,
"getCreatePSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"create"
},
"dynaModelFilePath"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021/PSFORMS/Transfer.json"
,
"getGetDraftFromPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"loaddraftfrom"
},
"getGetDraftPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"loaddraft"
},
"getGetPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"load"
},
"logicName"
:
"工作转移"
,
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
},
"getPSControlHandler"
:
{
"getPSHandlerActions"
:
[
{
"actionName"
:
"GetDraft"
,
"actionType"
:
"DEACTION"
,
"dataAccessAction"
:
"CREATE"
,
"name"
:
"loaddraft"
,
"getPSAppDEMethod"
:
{
"modelref"
:
true
,
"id"
:
"GetDraft"
},
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"GETDRAFTFROM"
,
"actionType"
:
"DEACTION"
,
"dataAccessAction"
:
"CREATE"
,
"name"
:
"loaddraftfrom"
,
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"Get"
,
"actionType"
:
"DEACTION"
,
"dataAccessAction"
:
"READ"
,
"name"
:
"load"
,
"getPSAppDEMethod"
:
{
"modelref"
:
true
,
"id"
:
"Get"
},
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"Create"
,
"actionType"
:
"DEACTION"
,
"dataAccessAction"
:
"CREATE"
,
"name"
:
"create"
,
"getPSAppDEMethod"
:
{
"modelref"
:
true
,
"id"
:
"Create"
},
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"Update"
,
"actionType"
:
"DEACTION"
,
"dataAccessAction"
:
"UPDATE"
,
"name"
:
"update"
,
"getPSAppDEMethod"
:
{
"modelref"
:
true
,
"id"
:
"Update"
},
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"Remove"
,
"actionType"
:
"DEACTION"
,
"dataAccessAction"
:
"DELETE"
,
"name"
:
"remove"
,
"getPSAppDEMethod"
:
{
"modelref"
:
true
,
"id"
:
"Remove"
},
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"WFSTART"
,
"actionType"
:
"WFACTION"
,
"name"
:
"WFSTART"
,
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
},
{
"actionName"
:
"WFSUBMIT"
,
"actionType"
:
"WFACTION"
,
"name"
:
"WFSUBMIT"
,
"getPSAppDataEntity"
:
{
"modelref"
:
true
,
"path"
:
"PSSYSAPPS/Web/PSAPPDATAENTITIES/IBIZSample0021.json"
}
}
],
"enableDEFieldPrivilege"
:
false
,
"id"
:
"流程操作表单处理器"
},
"getPSControlParam"
:
{
"autoLoad"
:
true
,
"showBusyIndicator"
:
true
,
"id"
:
"wfform_transfer"
},
"getPSDEFormItems"
:
[
{
"id"
:
"srfupdatedate"
,
"hidden"
:
true
,
"dataType"
:
5
,
"getPSAppDEField"
:
{
"name"
:
"UPDATEDATE"
,
"codeName"
:
"UpdateDate"
}
},
{
"id"
:
"srforikey"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfkey"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"IBIZSAMPLE0021ID"
,
"codeName"
:
"IBIZSample0021Id"
}
},
{
"id"
:
"srfmajortext"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"IBIZSAMPLE0021NAME"
,
"codeName"
:
"IBIZSample0021Name"
}
},
{
"id"
:
"srftempmode"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfuf"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfdeid"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"srfsourcekey"
,
"hidden"
:
true
,
"dataType"
:
25
},
{
"id"
:
"deptheads"
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
}
},
{
"id"
:
"deptheadsid"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
}
},
{
"id"
:
"ibizsample0021id"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"IBIZSAMPLE0021ID"
,
"codeName"
:
"IBIZSample0021Id"
}
}
],
"getPSDEFormPages"
:
[
{
"caption"
:
"基本信息"
,
"codeName"
:
"formpage1"
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMPAGE"
,
"name"
:
"formpage1"
,
"getPSDEFormDetails"
:
[
{
"actionGroupExtractMode"
:
"ITEM"
,
"caption"
:
"订单基本信息"
,
"codeName"
:
"group1"
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"GROUPPANEL"
,
"name"
:
"group1"
,
"getPSDEFormDetails"
:
[
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheads"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheads"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
},
"getPSEditor"
:
{
"editorParams"
:
{
"multiple"
:
"false"
,
"url"
:
"/wfcore/wfgroups/DepartmentHeads/wfmembers/fetchdefault?n_mdeptid_eq=${srforgsectorid}&sort=showorder,asc"
,
"AC"
:
"TRUE"
,
"fillMap"
:
"{id:'userid',label:'personname'}"
,
"PICKUPVIEW"
:
"TRUE"
,
"REALSTYLECODE"
:
"COMMONMICROCOM"
},
"editorStyle"
:
"COMMONMICROCOM"
,
"editorType"
:
"PICKER"
,
"handlerType"
:
"PickupText"
,
"name"
:
"deptheads"
,
"valueItemName"
:
"deptheadsid"
,
"enableAC"
:
true
,
"enablePickupView"
:
true
,
"forceSelection"
:
true
,
"showTrigger"
:
true
,
"singleSelect"
:
true
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"valueItemName"
:
"deptheadsid"
,
"allowEmpty"
:
true
,
"showCaption"
:
true
},
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheadsid"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheadsid"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"getPSEditor"
:
{
"editorType"
:
"HIDDEN"
,
"name"
:
"deptheadsid"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"allowEmpty"
:
true
,
"hidden"
:
true
,
"showCaption"
:
true
}
],
"getPSLayout"
:
{
"columnCount"
:
24
,
"layout"
:
"TABLE_24COL"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"infoGroupMode"
:
false
,
"showCaption"
:
false
}
],
"getPSLayout"
:
{
"columnCount"
:
24
,
"layout"
:
"TABLE_24COL"
},
"infoGroupMode"
:
false
}
],
"getPSLayout"
:
{
"columnCount"
:
24
,
"layout"
:
"TABLE_24COL"
},
"getRemovePSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"remove"
},
"tabHeaderPos"
:
"TOP"
,
"getUpdatePSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"update"
},
"getWFStartPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"WFSTART"
},
"getWFSubmitPSControlAction"
:
{
"modelref"
:
true
,
"id"
:
"WFSUBMIT"
},
"noTabHeader"
:
true
,
"name"
:
"wfform_transfer"
,
"modelid"
:
"0D397329-34E2-4381-B84C-108492D610BA"
,
"modeltype"
:
"PSDEFORM_EDITFORM"
},
{
"codeName"
:
"RefuseForm"
,
"controlType"
:
"FORM"
,
...
...
demo-boot/src/main/resources/static/remotemodel/PSSYSAPPS/Web/PSAPPDEVIEWS/IBIZSample0021Usr1116491232WFDynaStartView.json
浏览文件 @
587e7a8a
...
...
@@ -188,6 +188,14 @@
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
}
},
{
"id"
:
"deptheadsid"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
}
},
{
"id"
:
"ibizsample0021id"
,
"hidden"
:
true
,
...
...
@@ -239,6 +247,7 @@
"editorType"
:
"PICKER"
,
"handlerType"
:
"PickupText"
,
"name"
:
"deptheads"
,
"valueItemName"
:
"deptheadsid"
,
"enableAC"
:
true
,
"enablePickupView"
:
true
,
"forceSelection"
:
true
,
...
...
@@ -249,7 +258,35 @@
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"valueItemName"
:
"deptheadsid"
,
"allowEmpty"
:
true
,
"showCaption"
:
true
},
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheadsid"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheadsid"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"getPSEditor"
:
{
"editorType"
:
"HIDDEN"
,
"name"
:
"deptheadsid"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"allowEmpty"
:
true
,
"hidden"
:
true
,
"showCaption"
:
true
}
],
"getPSLayout"
:
{
...
...
@@ -718,6 +755,14 @@
"name"
:
"DEPTHEADS"
,
"codeName"
:
"DeptHeads"
}
},
{
"id"
:
"deptheadsid"
,
"hidden"
:
true
,
"dataType"
:
25
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
}
},
{
"id"
:
"ibizsample0021id"
,
"hidden"
:
true
,
...
...
@@ -769,6 +814,7 @@
"editorType"
:
"PICKER"
,
"handlerType"
:
"PickupText"
,
"name"
:
"deptheads"
,
"valueItemName"
:
"deptheadsid"
,
"enableAC"
:
true
,
"enablePickupView"
:
true
,
"forceSelection"
:
true
,
...
...
@@ -779,7 +825,35 @@
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"valueItemName"
:
"deptheadsid"
,
"allowEmpty"
:
true
,
"showCaption"
:
true
},
{
"caption"
:
"部门领导"
,
"codeName"
:
"deptheadsid"
,
"dataType"
:
25
,
"detailStyle"
:
"DEFAULT"
,
"detailType"
:
"FORMITEM"
,
"enableCond"
:
3
,
"ignoreInput"
:
0
,
"labelPos"
:
"LEFT"
,
"labelWidth"
:
130
,
"name"
:
"deptheadsid"
,
"noPrivDisplayMode"
:
1
,
"getPSAppDEField"
:
{
"name"
:
"DEPTHEADSID"
,
"codeName"
:
"DeptHeadsId"
},
"getPSEditor"
:
{
"editorType"
:
"HIDDEN"
,
"name"
:
"deptheadsid"
},
"getPSLayoutPos"
:
{
"colMD"
:
24
,
"layout"
:
"TABLE_24COL"
},
"allowEmpty"
:
true
,
"hidden"
:
true
,
"showCaption"
:
true
}
],
"getPSLayout"
:
{
...
...
demo-boot/src/main/resources/static/remotemodel/PSWORKFLOWS/ACT/PSWFVERSIONS/ACTv2.json
浏览文件 @
587e7a8a
...
...
@@ -236,10 +236,12 @@
"uDField"
:
"DEPTHEADSID"
,
"wFProcessRoleType"
:
"UDACTOR"
}
],
"predefinedActions"
:
[
"
SENDBACK"
,
"
ADDSTEPBEFORE"
,
"REASSIGN"
],
"predefinedActions"
:
[
"ADDSTEPBEFORE"
,
"REASSIGN"
],
"timeout"
:
6
,
"timeoutType"
:
"MINUTE"
,
"topPos"
:
30
,
"util3FormCodeName"
:
"transfer"
,
"util3FormName"
:
"工作转移"
,
"wFProcessType"
:
"INTERACTIVE"
,
"wFStepValue"
:
"5"
,
"width"
:
100
,
...
...
@@ -361,7 +363,7 @@
"name"
:
"[当前操作者]"
,
"wFProcessRoleType"
:
"CURACTOR"
}
],
"predefinedActions"
:
[
"SENDBACK"
,
"REASSIGN"
],
"predefinedActions"
:
[
"SENDBACK"
],
"timeout"
:
-1
,
"topPos"
:
30
,
"wFProcessType"
:
"INTERACTIVE"
,
...
...
demo-boot/src/main/resources/static/remotemodel/PSWORKFLOWS/ACT/PSWFVERSIONS/ACTv2.json.bpmn
浏览文件 @
587e7a8a
...
...
@@ -40,7 +40,7 @@
<userTask
flowable:category=
"${businessKey}"
flowable:dueDate=
"PT6M"
flowable:candidateUsers=
"${activedata.deptheadsid},${activedata.srfwfpredefinedusers}"
flowable:exclusive=
"true"
id=
"tid-5-b43328c7712bd3739742121269b6c386"
name=
"部门经理审核"
>
<documentation>
${majortext}
</documentation>
<extensionElements>
<flowable:form
procfunc=
"
sendback;addstepbefore;reassign"
process-form=
"operationForm
"
/>
<flowable:form
procfunc=
"
addstepbefore;reassign"
process-form=
"operationForm"
process-util3form=
"transfer"
process-util3formname=
"工作转移
"
/>
</extensionElements>
</userTask>
<endEvent
id=
"sid-ebd510afdeda7eba09cf1a56679ca382"
name=
"结束"
>
...
...
@@ -56,7 +56,7 @@
<userTask
flowable:category=
"${businessKey}"
flowable:candidateUsers=
"${activedata.createman},${wfCoreService.getGroupUsers('FinancialManager|org|CURORGID',execution)},${activedata.srfwfpredefinedusers}"
flowable:exclusive=
"true"
id=
"tid-10-b2100e0a472c7e23cd936fbb272eaa67"
name=
"财务经理审核"
>
<documentation>
${majortext}
</documentation>
<extensionElements>
<flowable:form
procfunc=
"sendback
;reassign
"
/>
<flowable:form
procfunc=
"sendback"
/>
</extensionElements>
</userTask>
<userTask
flowable:category=
"${businessKey}"
flowable:candidateUsers=
"${wfCoreService.getGroupUsers('FinancialDirector|org|CURORGID',execution)},${activedata.srfwfpredefinedusers}"
flowable:exclusive=
"true"
id=
"tid-30-f33ca3120694e870ea7e1b5eed392750"
name=
"财务总监审批"
>
...
...
demo-core/src/main/resources/sysmodel/DemoSys.json
浏览文件 @
587e7a8a
...
...
@@ -8133,6 +8133,20 @@
"key_field"
:
0
,
"show_order"
:
1000
,
"major_field"
:
0
},
{
"fieldname"
:
"DEPTHEADSID"
,
"codename"
:
"DeptHeadsId"
,
"field_logic_name"
:
"部门领导"
,
"entity_name"
:
"IBIZSAMPLE0021"
,
"field_type"
:
"TEXT"
,
"nullable"
:
1
,
"physical_field"
:
0
,
"data_type"
:
"VARCHAR"
,
"data_length"
:
100
,
"key_field"
:
0
,
"show_order"
:
1000
,
"major_field"
:
0
}
],
"subEntitys"
:[
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录