Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
iBiz企业中心
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
iBiz企业套件
iBiz企业中心
提交
7018448f
提交
7018448f
编写于
6月 18, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
chitanda 发布系统代码
上级
c5c0e890
变更
26
隐藏空白字符变更
内嵌
并排
正在显示
26 个修改的文件
包含
4533 行增加
和
327 行删除
+4533
-327
view-config.json
app_BusinessCentral/public/assets/json/view-config.json
+20
-20
list-lead_en_US.ts
...l/src/locale/lanres/entities/list-lead/list-lead_en_US.ts
+10
-28
list-lead_zh_CN.ts
...l/src/locale/lanres/entities/list-lead/list-lead_zh_CN.ts
+10
-28
viewconfig.ts
app_BusinessCentral/src/mock/viewconfig/viewconfig.ts
+16
-16
list-lead-by-list-base.vue
...es/marketing/list-lead-by-list/list-lead-by-list-base.vue
+1338
-0
list-lead-by-list.less
.../pages/marketing/list-lead-by-list/list-lead-by-list.less
+8
-0
list-lead-by-list.vue
...c/pages/marketing/list-lead-by-list/list-lead-by-list.vue
+21
-0
list-lead-quick-create-by-list-base.vue
...ck-create-by-list/list-lead-quick-create-by-list-base.vue
+554
-0
list-lead-quick-create-by-list.less
...-quick-create-by-list/list-lead-quick-create-by-list.less
+9
-0
list-lead-quick-create-by-list.vue
...d-quick-create-by-list/list-lead-quick-create-by-list.vue
+19
-0
page-register.ts
...usinessCentral/src/pages/ungroup/central/page-register.ts
+4
-2
router.ts
app_BusinessCentral/src/pages/ungroup/central/router.ts
+376
-178
state.ts
app_BusinessCentral/src/store/modules/view-action/state.ts
+35
-14
list-lead-ui-service-base.ts
...tral/src/uiservice/list-lead/list-lead-ui-service-base.ts
+2
-2
infotabviewpanel4-tabviewpanel-base.vue
...nel4-tabviewpanel/infotabviewpanel4-tabviewpanel-base.vue
+2
-2
default-searchform-base.vue
...dgets/lead/default-searchform/default-searchform-base.vue
+2
-2
main-grid-base.vue
...nessCentral/src/widgets/lead/main-grid/main-grid-base.vue
+5
-19
quick-create-by-list-form-base.vue
...ck-create-by-list-form/quick-create-by-list-form-base.vue
+15
-0
default-searchform-base.vue
.../list-lead/default-searchform/default-searchform-base.vue
+2
-2
main-grid-base.vue
...entral/src/widgets/list-lead/main-grid/main-grid-base.vue
+5
-5
quick-create-by-list-form-base.vue
...ck-create-by-list-form/quick-create-by-list-form-base.vue
+1589
-0
quick-create-by-list-form-model.ts
...ck-create-by-list-form/quick-create-by-list-form-model.ts
+81
-0
quick-create-by-list-form-service.ts
...-create-by-list-form/quick-create-by-list-form-service.ts
+383
-0
quick-create-by-list-form.less
.../quick-create-by-list-form/quick-create-by-list-form.less
+4
-0
quick-create-by-list-form.vue
...d/quick-create-by-list-form/quick-create-by-list-form.vue
+14
-0
h2_table.xml
...esscentral-core/src/main/resources/liquibase/h2_table.xml
+9
-9
未找到文件。
app_BusinessCentral/public/assets/json/view-config.json
浏览文件 @
7018448f
...
...
@@ -199,16 +199,6 @@
"viewtag"
:
"29bfcd628ab25e297248ff0524d12908"
,
"memo"
:
"系统自动添加"
},
"listleadeditview"
:
{
"title"
:
"营销列表-潜在客户编辑视图"
,
"caption"
:
"营销列表-潜在客户"
,
"viewtype"
:
"DEEDITVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadEditView"
,
"viewfilename"
:
"list-lead-edit-view"
,
"viewtag"
:
"29e6b575138e5652740ab94b21c40928"
,
"memo"
:
"系统自动添加"
},
"contactinfo_book"
:
{
"title"
:
"联系人编辑视图"
,
"caption"
:
"联系人"
,
...
...
@@ -219,6 +209,16 @@
"viewtag"
:
"2b787c59ba090b37b9a1ba8f8ba045b4"
,
"memo"
:
""
},
"listleadbylist"
:
{
"title"
:
"营销列表-潜在客户(根据营销列表)"
,
"caption"
:
"潜在客户"
,
"viewtype"
:
"DEGRIDVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadByList"
,
"viewfilename"
:
"list-lead-by-list"
,
"viewtag"
:
"2c6be792e84450585986e22f75dffa52"
,
"memo"
:
"系统自动添加"
},
"leadeditview"
:
{
"title"
:
"lead编辑视图"
,
"caption"
:
"潜在顾客"
,
...
...
@@ -579,16 +579,6 @@
"viewtag"
:
"7FCD2E75-E34A-493C-922E-8AE47BCE08CA"
,
"memo"
:
""
},
"listleadgridview"
:
{
"title"
:
"营销列表-潜在客户表格视图"
,
"caption"
:
"营销列表-潜在客户"
,
"viewtype"
:
"DEGRIDVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadGridView"
,
"viewfilename"
:
"list-lead-grid-view"
,
"viewtag"
:
"829c9b0c0bf0c3796537872b84f26935"
,
"memo"
:
"系统自动添加"
},
"ibizlistquickcreate"
:
{
"title"
:
"快速新建"
,
"caption"
:
"快速新建"
,
...
...
@@ -639,6 +629,16 @@
"viewtag"
:
"8b806fb12589b2fc17d1bb90f4b5422e"
,
"memo"
:
"系统自动添加"
},
"listleadquickcreatebylist"
:
{
"title"
:
"快速新建(根据营销列表)"
,
"caption"
:
"快速新建"
,
"viewtype"
:
"DEOPTVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadQuickCreateByList"
,
"viewfilename"
:
"list-lead-quick-create-by-list"
,
"viewtag"
:
"8d3e0363ae4532310000143fd6d61aae"
,
"memo"
:
""
},
"salesliteraturegridview"
:
{
"title"
:
"salesliterature表格视图"
,
"caption"
:
"销售宣传资料"
,
...
...
app_BusinessCentral/src/locale/lanres/entities/list-lead/list-lead_en_US.ts
浏览文件 @
7018448f
...
...
@@ -18,21 +18,19 @@ export default {
statuscode
:
'状态描述'
,
},
views
:
{
editview
:
{
caption
:
"
营销列表-
潜在客户"
,
title
:
'营销列表-潜在客户
编辑视图
'
,
bylist
:
{
caption
:
"潜在客户"
,
title
:
'营销列表-潜在客户
(根据营销列表)
'
,
},
gridview
:
{
caption
:
"
营销列表-潜在客户
"
,
title
:
'
营销列表-潜在客户表格视图
'
,
quickcreatebylist
:
{
caption
:
"
快速新建
"
,
title
:
'
快速新建(根据营销列表)
'
,
},
},
main
_form
:
{
quickcreatebylist
_form
:
{
details
:
{
group1
:
"营销列表-潜在客户基本信息"
,
formpage1
:
"基本信息"
,
group2
:
"操作信息"
,
formpage2
:
"其它"
,
srfupdatedate
:
"更新时间"
,
srforikey
:
""
,
srfkey
:
"关系标识"
,
...
...
@@ -41,6 +39,8 @@ export default {
srfuf
:
""
,
srfdeid
:
""
,
srfsourcekey
:
""
,
entity2name
:
"潜在顾客"
,
entity2id
:
"潜在顾客"
,
relationshipsid
:
"关系标识"
,
},
uiactions
:
{
...
...
@@ -64,7 +64,7 @@ export default {
uiactions
:
{
},
},
gridview
toolbar_toolbar
:
{
bylist
toolbar_toolbar
:
{
tbitem3
:
{
caption
:
"New"
,
tip
:
"New"
,
...
...
@@ -102,22 +102,4 @@ export default {
tip
:
"Filter"
,
},
},
editviewtoolbar_toolbar
:
{
tbitem3
:
{
caption
:
"Save"
,
tip
:
"Save"
,
},
tbitem5
:
{
caption
:
"Save And Close"
,
tip
:
"Save And Close Window"
,
},
tbitem6
:
{
caption
:
"-"
,
tip
:
""
,
},
tbitem12
:
{
caption
:
"关闭"
,
tip
:
"关闭"
,
},
},
};
\ No newline at end of file
app_BusinessCentral/src/locale/lanres/entities/list-lead/list-lead_zh_CN.ts
浏览文件 @
7018448f
...
...
@@ -17,21 +17,19 @@ export default {
statuscode
:
'状态描述'
,
},
views
:
{
editview
:
{
caption
:
'
营销列表-
潜在客户'
,
title
:
'营销列表-潜在客户
编辑视图
'
,
bylist
:
{
caption
:
'潜在客户'
,
title
:
'营销列表-潜在客户
(根据营销列表)
'
,
},
gridview
:
{
caption
:
'
营销列表-潜在客户
'
,
title
:
'
营销列表-潜在客户表格视图
'
,
quickcreatebylist
:
{
caption
:
'
快速新建
'
,
title
:
'
快速新建(根据营销列表)
'
,
},
},
main
_form
:
{
quickcreatebylist
_form
:
{
details
:
{
group1
:
'营销列表-潜在客户基本信息'
,
formpage1
:
'基本信息'
,
group2
:
'操作信息'
,
formpage2
:
'其它'
,
srfupdatedate
:
'更新时间'
,
srforikey
:
''
,
srfkey
:
'关系标识'
,
...
...
@@ -40,6 +38,8 @@ export default {
srfuf
:
''
,
srfdeid
:
''
,
srfsourcekey
:
''
,
entity2name
:
'潜在顾客'
,
entity2id
:
'潜在顾客'
,
relationshipsid
:
'关系标识'
,
},
uiactions
:
{
...
...
@@ -63,7 +63,7 @@ export default {
uiactions
:
{
},
},
gridview
toolbar_toolbar
:
{
bylist
toolbar_toolbar
:
{
tbitem3
:
{
caption
:
'新建'
,
tip
:
'新建'
,
...
...
@@ -101,22 +101,4 @@ export default {
tip
:
'过滤'
,
},
},
editviewtoolbar_toolbar
:
{
tbitem3
:
{
caption
:
'保存'
,
tip
:
'保存'
,
},
tbitem5
:
{
caption
:
'保存并关闭'
,
tip
:
'保存并关闭'
,
},
tbitem6
:
{
caption
:
'-'
,
tip
:
''
,
},
tbitem12
:
{
caption
:
'关闭'
,
tip
:
'关闭'
,
},
},
};
\ No newline at end of file
app_BusinessCentral/src/mock/viewconfig/viewconfig.ts
浏览文件 @
7018448f
...
...
@@ -167,14 +167,6 @@ mock.onGet('./assets/json/view-config.json').reply((config: any) => {
"viewname"
:
"AccountPickupView"
,
"viewtag"
:
"29bfcd628ab25e297248ff0524d12908"
},
"listleadeditview"
:
{
"title"
:
"营销列表-潜在客户编辑视图"
,
"caption"
:
"营销列表-潜在客户"
,
"viewtype"
:
"DEEDITVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadEditView"
,
"viewtag"
:
"29e6b575138e5652740ab94b21c40928"
},
"contactinfo_book"
:
{
"title"
:
"联系人编辑视图"
,
"caption"
:
"联系人"
,
...
...
@@ -183,6 +175,14 @@ mock.onGet('./assets/json/view-config.json').reply((config: any) => {
"viewname"
:
"ContactInfo_Book"
,
"viewtag"
:
"2b787c59ba090b37b9a1ba8f8ba045b4"
},
"listleadbylist"
:
{
"title"
:
"营销列表-潜在客户(根据营销列表)"
,
"caption"
:
"潜在客户"
,
"viewtype"
:
"DEGRIDVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadByList"
,
"viewtag"
:
"2c6be792e84450585986e22f75dffa52"
},
"leadeditview"
:
{
"title"
:
"lead编辑视图"
,
"caption"
:
"潜在顾客"
,
...
...
@@ -471,14 +471,6 @@ mock.onGet('./assets/json/view-config.json').reply((config: any) => {
"viewname"
:
"CenteralPortal"
,
"viewtag"
:
"7FCD2E75-E34A-493C-922E-8AE47BCE08CA"
},
"listleadgridview"
:
{
"title"
:
"营销列表-潜在客户表格视图"
,
"caption"
:
"营销列表-潜在客户"
,
"viewtype"
:
"DEGRIDVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadGridView"
,
"viewtag"
:
"829c9b0c0bf0c3796537872b84f26935"
},
"ibizlistquickcreate"
:
{
"title"
:
"快速新建"
,
"caption"
:
"快速新建"
,
...
...
@@ -519,6 +511,14 @@ mock.onGet('./assets/json/view-config.json').reply((config: any) => {
"viewname"
:
"PriceLevelPickupView"
,
"viewtag"
:
"8b806fb12589b2fc17d1bb90f4b5422e"
},
"listleadquickcreatebylist"
:
{
"title"
:
"快速新建(根据营销列表)"
,
"caption"
:
"快速新建"
,
"viewtype"
:
"DEOPTVIEW"
,
"viewmodule"
:
"Marketing"
,
"viewname"
:
"ListLeadQuickCreateByList"
,
"viewtag"
:
"8d3e0363ae4532310000143fd6d61aae"
},
"salesliteraturegridview"
:
{
"title"
:
"salesliterature表格视图"
,
"caption"
:
"销售宣传资料"
,
...
...
app_BusinessCentral/src/pages/marketing/list-lead-by-list/list-lead-by-list-base.vue
0 → 100644
浏览文件 @
7018448f
<
template
>
<studio-view
viewName=
"listleadbylist"
viewTitle=
"营销列表-潜在客户(根据营销列表)"
class=
'degridview list-lead-by-list'
>
<i-input
slot=
"quickSearch"
v-show=
"!isExpandSearchForm"
v-model=
"query"
search
@
on-search=
"onSearch($event)"
/>
<template
slot=
"toolbar"
>
<view-toolbar
:model=
"toolBarModels"
@
item-click=
"toolbar_click"
/>
</
template
>
<
template
slot=
"searchForm"
>
<view
_searchform
:viewState=
"viewState"
:viewparams=
"viewparams"
:context=
"context"
:showBusyIndicator=
"true"
v-show=
"isExpandSearchForm"
loaddraftAction=
"FilterGetDraft"
loadAction=
"FilterGet"
name=
"searchform"
ref=
'searchform'
@
save=
"searchform_save($event)"
@
search=
"searchform_search($event)"
@
load=
"searchform_load($event)"
@
closeview=
"closeView($event)"
>
</view
_searchform
>
</
template
>
<view
_grid
:viewState=
"viewState"
:viewparams=
"viewparams"
:context=
"context"
:isSingleSelect=
"isSingleSelect"
:showBusyIndicator=
"true"
:isOpenEdit=
"false"
:gridRowActiveMode=
"gridRowActiveMode"
@
save=
"onSave"
updateAction=
""
removeAction=
"Remove"
loaddraftAction=
""
loadAction=
""
createAction=
""
fetchAction=
"FetchDefault"
:newdata=
"newdata"
:opendata=
"opendata"
name=
"grid"
ref=
'grid'
@
selectionchange=
"grid_selectionchange($event)"
@
beforeload=
"grid_beforeload($event)"
@
rowdblclick=
"grid_rowdblclick($event)"
@
remove=
"grid_remove($event)"
@
load=
"grid_load($event)"
@
closeview=
"closeView($event)"
>
</view
_grid
>
</studio-view>
</template>
<
script
lang=
'tsx'
>
import
{
Vue
,
Component
,
Prop
,
Provide
,
Emit
,
Watch
}
from
'vue-property-decorator'
;
import
{
UIActionTool
,
Util
}
from
'@/utils'
;
import
{
Subject
}
from
'rxjs'
;
import
ListLeadService
from
'@/service/list-lead/list-lead-service'
;
import
GridViewEngine
from
'@engine/view/grid-view-engine'
;
import
CodeListService
from
"@service/app/codelist-service"
;
@
Component
({
components
:
{
},
})
export
default
class
ListLeadByListBase
extends
Vue
{
/**
* 实体服务对象
*
* @type {ListLeadService}
* @memberof ListLeadByListBase
*/
public
appEntityService
:
ListLeadService
=
new
ListLeadService
;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof ListLeadByListBase
*/
public
counterServiceArray
:
Array
<
any
>
=
[];
/**
* 数据变化
*
* @param {*} val
* @returns {*}
* @memberof ListLeadByListBase
*/
@
Emit
()
public
viewDatasChange
(
val
:
any
):
any
{
return
val
;
}
/**
* 传入视图上下文
*
* @type {string}
* @memberof ListLeadByListBase
*/
@
Prop
()
public
viewdata
!
:
string
;
/**
* 传入视图参数
*
* @type {string}
* @memberof ListLeadByListBase
*/
@
Prop
()
public
viewparam
!
:
string
;
/**
* 视图默认使用
*
* @type {boolean}
* @memberof ListLeadByListBase
*/
@
Prop
({
default
:
true
})
public
viewDefaultUsage
!
:
boolean
;
/**
* 视图标识
*
* @type {string}
* @memberof ListLeadByListBase
*/
public
viewtag
:
string
=
'2c6be792e84450585986e22f75dffa52'
;
/**
* 自定义视图导航上下文集合
*
* @type {*}
* @memberof ListLeadByListBase
*/
public
customViewNavContexts
:
any
=
{
};
/**
* 自定义视图导航参数集合
*
* @type {*}
* @memberof ListLeadByListBase
*/
public
customViewParams
:
any
=
{
};
/**
* 视图模型数据
*
* @type {*}
* @memberof ListLeadByListBase
*/
public
model
:
any
=
{
srfCaption
:
'entities.listlead.views.bylist.caption'
,
srfTitle
:
'entities.listlead.views.bylist.title'
,
srfSubTitle
:
'entities.listlead.views.bylist.subtitle'
,
dataInfo
:
''
}
/**
* 视图参数变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof ListLeadByListBase
*/
@
Watch
(
'viewparam'
,{
immediate
:
true
,
deep
:
true
})
onParamData
(
newVal
:
any
,
oldVal
:
any
)
{
if
(
newVal
){
for
(
let
key
in
this
.
viewparams
){
delete
this
.
viewparams
[
key
];
}
Object
.
assign
(
this
.
viewparams
,
JSON
.
parse
(
this
.
viewparam
));
}
}
/**
* 处理应用上下文变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof ListLeadByListBase
*/
@
Watch
(
'viewdata'
)
onViewData
(
newVal
:
any
,
oldVal
:
any
)
{
const
_this
:
any
=
this
;
if
(
!
Object
.
is
(
newVal
,
oldVal
)
&&
_this
.
engine
)
{
this
.
$nextTick
(()
=>
{
_this
.
parseViewParam
();
_this
.
engine
.
load
();
});
}
}
/**
* 容器模型
*
* @type {*}
* @memberof ListLeadByListBase
*/
public
containerModel
:
any
=
{
view_toolbar
:
{
name
:
'toolbar'
,
type
:
'TOOLBAR'
},
view_grid
:
{
name
:
'grid'
,
type
:
'GRID'
},
view_searchform
:
{
name
:
'searchform'
,
type
:
'SEARCHFORM'
},
};
/**
* 计数器刷新
*
* @memberof ListLeadByListBase
*/
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
();
}
})
}
}
/**
* 视图状态订阅对象
*
* @public
* @type {Subject<{action: string, data: any}>}
* @memberof ListLeadByListBase
*/
public
viewState
:
Subject
<
ViewState
>
=
new
Subject
();
/**
* 工具栏模型
*
* @type {*}
* @memberof ListLeadByList
*/
public
toolBarModels
:
any
=
{
tbitem3
:
{
name
:
'tbitem3'
,
caption
:
'新建'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'新建'
,
iconcls
:
'fa fa-file-text-o'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'New'
,
target
:
''
},
class
:
''
},
tbitem4
:
{
name
:
'tbitem4'
,
caption
:
'编辑'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'编辑'
,
iconcls
:
'fa fa-edit'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'Edit'
,
target
:
'SINGLEKEY'
},
class
:
''
},
tbitem6
:
{
name
:
'tbitem6'
,
caption
:
'拷贝'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'拷贝'
,
iconcls
:
'fa fa-copy'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'Copy'
,
target
:
'SINGLEKEY'
},
class
:
''
},
tbitem7
:
{
name
:
'tbitem7'
,
type
:
'SEPERATOR'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
}
},
tbitem8
:
{
name
:
'tbitem8'
,
caption
:
'删除'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'删除'
,
iconcls
:
'fa fa-remove'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'Remove'
,
target
:
'MULTIKEY'
},
class
:
''
},
tbitem9
:
{
name
:
'tbitem9'
,
type
:
'SEPERATOR'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
}
},
tbitem13
:
{
name
:
'tbitem13'
,
caption
:
'导出'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'导出'
,
iconcls
:
'fa fa-file-excel-o'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'ExportExcel'
,
target
:
''
},
MaxRowCount
:
1000
,
class
:
''
},
tbitem10
:
{
name
:
'tbitem10'
,
type
:
'SEPERATOR'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
}
},
tbitem19
:
{
name
:
'tbitem19'
,
caption
:
'过滤'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'过滤'
,
iconcls
:
'fa fa-filter'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'ToggleFilter'
,
target
:
''
},
class
:
''
},
};
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof ListLeadByListBase
*/
public
engine
:
GridViewEngine
=
new
GridViewEngine
();
/**
* 引擎初始化
*
* @public
* @memberof ListLeadByListBase
*/
public
engineInit
():
void
{
this
.
engine
.
init
({
view
:
this
,
opendata
:
(
args
:
any
[],
fullargs
?:
any
[],
params
?:
any
,
$event
?:
any
,
xData
?:
any
)
=>
{
this
.
opendata
(
args
,
fullargs
,
params
,
$event
,
xData
);
},
newdata
:
(
args
:
any
[],
fullargs
?:
any
[],
params
?:
any
,
$event
?:
any
,
xData
?:
any
)
=>
{
this
.
newdata
(
args
,
fullargs
,
params
,
$event
,
xData
);
},
grid
:
this
.
$refs
.
grid
,
searchform
:
this
.
$refs
.
searchform
,
keyPSDEField
:
'listlead'
,
majorPSDEField
:
'relationshipsname'
,
isLoadDefault
:
true
,
});
}
/**
* 应用上下文
*
* @type {*}
* @memberof ListLeadByListBase
*/
public
context
:
any
=
{};
/**
* 视图参数
*
* @type {*}
* @memberof ListLeadByListBase
*/
public
viewparams
:
any
=
{};
/**
* 解析视图参数
*
* @public
* @memberof ListLeadByListBase
*/
public
parseViewParam
():
void
{
for
(
let
key
in
this
.
context
){
delete
this
.
context
[
key
];
}
if
(
!
this
.
viewDefaultUsage
&&
this
.
viewdata
&&
!
Object
.
is
(
this
.
viewdata
,
''
))
{
Object
.
assign
(
this
.
context
,
JSON
.
parse
(
this
.
viewdata
));
if
(
this
.
context
&&
this
.
context
.
srfparentdename
){
Object
.
assign
(
this
.
viewparams
,{
srfparentdename
:
this
.
context
.
srfparentdename
});
}
if
(
this
.
context
&&
this
.
context
.
srfparentkey
){
Object
.
assign
(
this
.
viewparams
,{
srfparentkey
:
this
.
context
.
srfparentkey
});
}
if
(
this
.
$store
.
getters
.
getAppData
()
&&
this
.
$store
.
getters
.
getAppData
().
context
){
Object
.
assign
(
this
.
context
,
this
.
$store
.
getters
.
getAppData
().
context
);
}
this
.
handleCustomViewData
();
return
;
}
const
path
=
(
this
.
$route
.
matched
[
this
.
$route
.
matched
.
length
-
1
]).
path
;
const
keys
:
Array
<
any
>
=
[];
const
curReg
=
this
.
$pathToRegExp
.
pathToRegexp
(
path
,
keys
);
const
matchArray
=
curReg
.
exec
(
this
.
$route
.
path
);
let
tempValue
:
Object
=
{};
keys
.
forEach
((
item
:
any
,
index
:
number
)
=>
{
Object
.
defineProperty
(
tempValue
,
item
.
name
,
{
enumerable
:
true
,
value
:
matchArray
[
index
+
1
]
});
});
this
.
$viewTool
.
formatRouteParams
(
tempValue
,
this
.
$route
,
this
.
context
,
this
.
viewparams
);
if
(
this
.
$store
.
getters
.
getAppData
()
&&
this
.
$store
.
getters
.
getAppData
().
context
){
Object
.
assign
(
this
.
context
,
this
.
$store
.
getters
.
getAppData
().
context
);
}
//初始化视图唯一标识
Object
.
assign
(
this
.
context
,{
srfsessionid
:
this
.
$util
.
createUUID
()});
this
.
handleCustomViewData
();
}
/**
* 处理自定义视图数据
*
* @memberof ListLeadByListBase
*/
public
handleCustomViewData
(){
if
(
Object
.
keys
(
this
.
customViewNavContexts
).
length
>
0
){
Object
.
keys
(
this
.
customViewNavContexts
).
forEach
((
item
:
any
)
=>
{
let
tempContext
:
any
=
{};
let
curNavContext
:
any
=
this
.
customViewNavContexts
[
item
];
this
.
handleCustomDataLogic
(
curNavContext
,
tempContext
,
item
);
Object
.
assign
(
this
.
context
,
tempContext
);
})
}
if
(
Object
.
keys
(
this
.
customViewParams
).
length
>
0
){
Object
.
keys
(
this
.
customViewParams
).
forEach
((
item
:
any
)
=>
{
let
tempParam
:
any
=
{};
let
curNavParam
:
any
=
this
.
customViewParams
[
item
];
this
.
handleCustomDataLogic
(
curNavParam
,
tempParam
,
item
);
Object
.
assign
(
this
.
viewparams
,
tempParam
);
})
}
}
/**
* 处理自定义视图数据逻辑
*
* @memberof ListLeadByListBase
*/
public
handleCustomDataLogic
(
curNavData
:
any
,
tempData
:
any
,
item
:
string
){
// 直接值直接赋值
if
(
curNavData
.
isRawValue
){
if
(
Object
.
is
(
curNavData
.
value
,
"null"
)
||
Object
.
is
(
curNavData
.
value
,
""
)){
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
null
,
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
else
{
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
curNavData
.
value
,
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
}
else
{
// 先从导航上下文取数,没有再从导航参数(URL)取数,如果导航上下文和导航参数都没有则为null
if
(
this
.
context
[(
curNavData
.
value
).
toLowerCase
()]){
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
this
.
context
[(
curNavData
.
value
).
toLowerCase
()],
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
else
{
if
(
this
.
viewparams
[(
curNavData
.
value
).
toLowerCase
()]){
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
this
.
viewparams
[(
curNavData
.
value
).
toLowerCase
()],
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
else
{
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
null
,
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
}
}
}
/**
* Vue声明周期
*
* @memberof ListLeadByListBase
*/
public
created
()
{
this
.
afterCreated
();
}
/**
* 执行created后的逻辑
*
* @memberof ListLeadByListBase
*/
public
afterCreated
(){
const
secondtag
=
this
.
$util
.
createUUID
();
this
.
$store
.
commit
(
'viewaction/createdView'
,
{
viewtag
:
this
.
viewtag
,
secondtag
:
secondtag
});
this
.
viewtag
=
secondtag
;
this
.
parseViewParam
();
if
(
this
.
formDruipart
){
this
.
formDruipart
.
subscribe
((
res
:
any
)
=>
{
if
(
Object
.
is
(
res
.
action
,
'save'
)){
this
.
viewState
.
next
({
tag
:
'grid'
,
action
:
'save'
,
data
:
this
.
viewparams
});
}
if
(
Object
.
is
(
res
.
action
,
'load'
)){
const
_this
:
any
=
this
;
_this
.
engine
.
load
(
res
.
data
,
true
);
}
});
}
}
/**
* 销毁之前
*
* @memberof ListLeadByListBase
*/
public
beforeDestroy
()
{
this
.
$store
.
commit
(
'viewaction/removeView'
,
this
.
viewtag
);
}
/**
* Vue声明周期(组件初始化完毕)
*
* @memberof ListLeadByListBase
*/
public
mounted
()
{
this
.
afterMounted
();
}
/**
* 执行mounted后的逻辑
*
* @memberof ListLeadByListBase
*/
public
afterMounted
(){
const
_this
:
any
=
this
;
_this
.
engineInit
();
if
(
_this
.
loadModel
&&
_this
.
loadModel
instanceof
Function
)
{
_this
.
loadModel
();
}
}
/**
* toolbar 部件 click 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
toolbar_click
(
$event
:
any
,
$event2
?:
any
)
{
if
(
Object
.
is
(
$event
.
tag
,
'tbitem3'
))
{
this
.
toolbar_tbitem3_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem4'
))
{
this
.
toolbar_tbitem4_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem6'
))
{
this
.
toolbar_tbitem6_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem24'
))
{
this
.
toolbar_tbitem24_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem25'
))
{
this
.
toolbar_tbitem25_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem8'
))
{
this
.
toolbar_tbitem8_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem13'
))
{
this
.
toolbar_tbitem13_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem11'
))
{
this
.
toolbar_tbitem11_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem19'
))
{
this
.
toolbar_tbitem19_click
(
null
,
''
,
$event2
);
}
}
/**
* grid 部件 selectionchange 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
grid_selectionchange
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'grid'
,
'selectionchange'
,
$event
);
}
/**
* grid 部件 beforeload 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
grid_beforeload
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'grid'
,
'beforeload'
,
$event
);
}
/**
* grid 部件 rowdblclick 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
grid_rowdblclick
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'grid'
,
'rowdblclick'
,
$event
);
}
/**
* grid 部件 remove 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
grid_remove
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'grid'
,
'remove'
,
$event
);
}
/**
* grid 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
grid_load
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'grid'
,
'load'
,
$event
);
}
/**
* searchform 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
searchform_save
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'searchform'
,
'save'
,
$event
);
}
/**
* searchform 部件 search 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
searchform_search
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'searchform'
,
'search'
,
$event
);
}
/**
* searchform 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
searchform_load
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'searchform'
,
'load'
,
$event
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem3_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
New
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem4_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
Edit
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem6_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
Copy
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem24_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
ToggleRowEdit
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem25_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
NewRow
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem8_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
Remove
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem13_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
ExportExcel
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem11_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
Print
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem19_click
(
params
:
any
=
{},
tag
?:
any
,
$event
?:
any
)
{
// 参数
// 取数
let
datas
:
any
[]
=
[];
let
xData
:
any
=
null
;
// _this 指向容器对象
const
_this
:
any
=
this
;
let
paramJO
:
any
=
{};
let
contextJO
:
any
=
{};
xData
=
this
.
$refs
.
grid
;
if
(
xData
.
getDatas
&&
xData
.
getDatas
instanceof
Function
)
{
datas
=
[...
xData
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
ToggleFilter
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"ListLead"
);
}
/**
* 打开新建数据视图
*
* @param {any[]} args
* @param {*} [params]
* @param {*} [fullargs]
* @param {*} [$event]
* @param {*} [xData]
* @memberof ListLeadByList
*/
public
newdata
(
args
:
any
[],
fullargs
?:
any
[],
params
?:
any
,
$event
?:
any
,
xData
?:
any
)
{
let
localContext
:
any
=
null
;
let
localViewParam
:
any
=
null
;
const
data
:
any
=
{};
if
(
args
[
0
].
srfsourcekey
){
data
.
srfsourcekey
=
args
[
0
].
srfsourcekey
;
}
let
tempContext
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
));
delete
tempContext
.
listlead
;
if
(
args
.
length
>
0
){
Object
.
assign
(
tempContext
,
args
[
0
]);
}
let
deResParameters
:
any
[]
=
[];
if
(
tempContext
.
lead
&&
true
){
deResParameters
=
[
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
]
}
const
parameters
:
any
[]
=
[
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
];
const
_this
:
any
=
this
;
const
openDrawer
=
(
view
:
any
,
data
:
any
)
=>
{
let
container
:
Subject
<
any
>
=
this
.
$appdrawer
.
openDrawer
(
view
,
tempContext
,
data
);
container
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
if
(
!
xData
||
!
(
xData
.
refresh
instanceof
Function
))
{
return
;
}
xData
.
refresh
(
result
.
datas
);
});
}
const
view
:
any
=
{
viewname
:
'list-lead-quick-create-by-list'
,
height
:
0
,
width
:
450
,
title
:
this
.
$t
(
'entities.listlead.views.quickcreatebylist.title'
),
placement
:
'DRAWER_RIGHT'
,
};
openDrawer
(
view
,
data
);
}
/**
* 打开编辑数据视图
*
* @param {any[]} args
* @param {*} [params]
* @param {*} [fullargs]
* @param {*} [$event]
* @param {*} [xData]
* @memberof ListLeadByList
*/
public
opendata
(
args
:
any
[],
fullargs
?:
any
[],
params
?:
any
,
$event
?:
any
,
xData
?:
any
)
{
let
localContext
:
any
=
null
;
let
localViewParam
:
any
=
null
;
const
data
:
any
=
{};
let
tempContext
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
));
if
(
args
.
length
>
0
){
Object
.
assign
(
tempContext
,
args
[
0
]);
}
let
deResParameters
:
any
[]
=
[];
if
(
tempContext
.
lead
&&
true
){
deResParameters
=
[
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
]
}
const
parameters
:
any
[]
=
[
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
];
const
_this
:
any
=
this
;
const
openDrawer
=
(
view
:
any
,
data
:
any
)
=>
{
let
container
:
Subject
<
any
>
=
this
.
$appdrawer
.
openDrawer
(
view
,
tempContext
,
data
);
container
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
if
(
!
xData
||
!
(
xData
.
refresh
instanceof
Function
))
{
return
;
}
xData
.
refresh
(
result
.
datas
);
});
}
const
view
:
any
=
{
viewname
:
'list-lead-quick-create-by-list'
,
height
:
0
,
width
:
450
,
title
:
this
.
$t
(
'entities.listlead.views.quickcreatebylist.title'
),
placement
:
'DRAWER_RIGHT'
,
};
openDrawer
(
view
,
data
);
}
/**
* 新建
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
New
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
const
_this
:
any
=
this
;
if
(
_this
.
newdata
&&
_this
.
newdata
instanceof
Function
)
{
const
data
:
any
=
{};
_this
.
newdata
([{
...
data
}],[{
...
data
}],
params
,
$event
,
xData
);
}
else
{
_this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'newdata 视图处理逻辑不存在,请添加!'
});
}
}
/**
* 编辑
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
Edit
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
if
(
args
.
length
===
0
)
{
return
;
}
const
_this
:
any
=
this
;
if
(
_this
.
opendata
&&
_this
.
opendata
instanceof
Function
)
{
const
data
:
any
=
{
};
if
(
args
.
length
>
0
)
{
Object
.
assign
(
data
,
{
listlead
:
args
[
0
].
listlead
})
}
_this
.
opendata
([{
...
data
}],
params
,
$event
,
xData
);
}
else
{
_this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'opendata 视图处理逻辑不存在,请添加!'
});
}
}
/**
* 拷贝
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
Copy
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
if
(
args
.
length
===
0
)
{
return
;
}
const
_this
:
any
=
this
;
if
(
_this
.
newdata
&&
_this
.
newdata
instanceof
Function
)
{
const
data
:
any
=
{};
if
(
args
.
length
>
0
)
{
Object
.
assign
(
data
,
{
srfsourcekey
:
args
[
0
].
srfkey
})
actionContext
.
$store
.
commit
(
'addCopyData'
,
{
srfkey
:
args
[
0
].
srfkey
,
copyData
:
args
[
0
]
});
}
_this
.
newdata
([{
...
data
}],[{
...
data
}],
params
,
$event
,
xData
);
}
else
if
(
xData
&&
xData
.
copy
instanceof
Function
)
{
if
(
args
.
length
>
0
)
{
actionContext
.
$store
.
commit
(
'addCopyData'
,
{
srfkey
:
args
[
0
].
srfkey
,
copyData
:
args
[
0
]
});
}
xData
.
copy
(
args
[
0
].
srfkey
);
}
else
{
_this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'opendata 视图处理逻辑不存在,请添加!'
});
}
}
/**
* 行编辑
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
ToggleRowEdit
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
xData
.
actualIsOpenEdit
=
!
xData
.
actualIsOpenEdit
;
}
/**
* 新建行
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
NewRow
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
const
_this
:
any
=
this
;
const
data
:
any
=
{};
if
(
_this
.
newRow
&&
_this
.
newRow
instanceof
Function
)
{
_this
.
newRow
([{
...
data
}],
params
,
$event
,
xData
);
}
else
if
(
xData
.
newRow
&&
xData
.
newRow
instanceof
Function
)
{
xData
.
newRow
([{
...
data
}],
params
,
$event
,
xData
);
}
else
{
_this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'newRow 视图处理逻辑不存在,请添加!'
});
}
}
/**
* 删除
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
Remove
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
const
_this
:
any
=
this
;
if
(
!
xData
||
!
(
xData
.
remove
instanceof
Function
))
{
return
;
}
xData
.
remove
(
args
);
}
/**
* 导出
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
ExportExcel
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
const
_this
:
any
=
this
;
if
(
!
xData
||
!
(
xData
.
exportExcel
instanceof
Function
)
||
!
$event
)
{
return
;
}
xData
.
exportExcel
(
$event
.
exportparms
);
}
/**
* 打印
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
Print
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
let
_this
:
any
=
this
;
if
(
!
xData
||
!
(
xData
.
print
instanceof
Function
)
||
!
$event
)
{
return
;
}
xData
.
print
();
}
/**
* 过滤
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof ListLeadByListBase
*/
public
ToggleFilter
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
const
_this
:
any
=
this
;
if
(
_this
.
hasOwnProperty
(
'isExpandSearchForm'
))
{
_this
.
isExpandSearchForm
=
!
_this
.
isExpandSearchForm
;
}
}
/**
* 关闭视图
*
* @param {any[]} args
* @memberof ListLeadByListBase
*/
public
closeView
(
args
:
any
[]):
void
{
let
_view
:
any
=
this
;
if
(
_view
.
viewdata
)
{
_view
.
$emit
(
'viewdataschange'
,
[
args
]);
_view
.
$emit
(
'close'
,
[
args
]);
}
else
if
(
_view
.
$tabPageExp
)
{
_view
.
$tabPageExp
.
onClose
(
_view
.
$route
.
fullPath
);
}
}
/**
* 销毁视图回调
*
* @memberof ListLeadByListBase
*/
public
destroyed
(){
this
.
afterDestroyed
();
}
/**
* 执行destroyed后的逻辑
*
* @memberof ListLeadByListBase
*/
public
afterDestroyed
(){
if
(
this
.
viewDefaultUsage
){
let
localStoreLength
=
Object
.
keys
(
localStorage
);
if
(
localStoreLength
.
length
>
0
){
localStoreLength
.
forEach
((
item
:
string
)
=>
{
if
(
item
.
startsWith
(
this
.
context
.
srfsessionid
)){
localStorage
.
removeItem
(
item
);
}
})
}
}
}
/**
* 是否单选
*
* @type {boolean}
* @memberof ListLeadByListBase
*/
public
isSingleSelect
:
boolean
=
false
;
/**
* 是否嵌入关系界面
*
* @type {boolean}
* @memberof ListLeadByListBase
*/
@
Prop
({
default
:
false
})
public
isformDruipart
?:
boolean
;
/**
* 界面关系通讯对象
*
* @type {Subject<ViewState>}
* @memberof ListLeadByListBase
*/
@
Prop
()
public
formDruipart
?:
Subject
<
ViewState
>
;
/**
* 搜索值
*
* @type {string}
* @memberof ListLeadByListBase
*/
public
query
:
string
=
''
;
/**
* 是否展开搜索表单
*
* @type {boolean}
* @memberof ListLeadByListBase
*/
public
isExpandSearchForm
:
boolean
=
false
;
/**
* 表格行数据默认激活模式
* 0 不激活
* 1 单击激活
* 2 双击激活
*
* @type {(number | 0 | 1 | 2)}
* @memberof ListLeadByListBase
*/
public
gridRowActiveMode
:
number
|
0
|
1
|
2
=
2
;
/**
* 快速搜索
*
* @param {*} $event
* @memberof ListLeadByListBase
*/
public
onSearch
(
$event
:
any
):
void
{
const
grid
:
any
=
this
.
$refs
.
grid
;
if
(
grid
)
{
grid
.
load
(
this
.
context
,
true
);
}
}
/**
* grid 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ENTITYTEST1Usr2GridViewBase
*/
public
onSave
(
$event
:
any
)
{
this
.
$emit
(
'drdatasaved'
,
$event
);
}
/**
* 刷新数据
*
* @readonly
* @type {(number | null)}
* @memberof ListLeadByListBase
*/
get
refreshdata
():
number
|
null
{
return
this
.
$store
.
getters
[
'viewaction/getRefreshData'
](
this
.
viewtag
);
}
/**
* 监控数据变化
*
* @param {*} newVal
* @param {*} oldVal
* @returns
* @memberof ListLeadByListBase
*/
@
Watch
(
'refreshdata'
)
onRefreshData
(
newVal
:
any
,
oldVal
:
any
)
{
if
(
newVal
===
null
||
newVal
===
undefined
)
{
return
;
}
if
(
newVal
===
0
)
{
return
;
}
const
grid
:
any
=
this
.
$refs
.
grid
;
if
(
grid
)
{
grid
.
load
({});
}
}
}
</
script
>
<
style
lang=
'less'
>
@import './list-lead-by-list.less';
</
style
>
\ No newline at end of file
app_BusinessCentral/src/pages/marketing/list-lead-by-list/list-lead-by-list.less
0 → 100644
浏览文件 @
7018448f
// 避免空文件,后台不让空文件过
.list-lead-by-list {
--list-lead-by-list: 0;
}
// 视图样式
// this is less
app_BusinessCentral/src/pages/marketing/list-lead-by-list/list-lead-by-list.vue
0 → 100644
浏览文件 @
7018448f
<
script
lang=
'tsx'
>
import
{
Component
}
from
'vue-property-decorator'
;
import
ListLeadByListBase
from
'./list-lead-by-list-base.vue'
;
import
view_grid
from
'@widgets/list-lead/main-grid/main-grid.vue'
;
import
view_searchform
from
'@widgets/list-lead/default-searchform/default-searchform.vue'
;
@
Component
({
components
:
{
view_grid
,
view_searchform
,
},
beforeRouteEnter
:
(
to
:
any
,
from
:
any
,
next
:
any
)
=>
{
next
((
vm
:
any
)
=>
{
vm
.
$store
.
commit
(
'addCurPageViewtag'
,
{
route
:
to
,
viewtag
:
vm
.
viewtag
});
});
},
})
export
default
class
ListLeadByList
extends
ListLeadByListBase
{
}
</
script
>
\ No newline at end of file
app_BusinessCentral/src/pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list-base.vue
0 → 100644
浏览文件 @
7018448f
<
template
>
<studio-view
viewName=
"listleadquickcreatebylist"
viewTitle=
"快速新建(根据营销列表)"
class=
'deoptview list-lead-quick-create-by-list'
>
<template
slot=
'title'
>
<span
class=
'caption-info'
>
{{
$t
(
model
.
srfTitle
)
}}
</span>
</
template
>
<view
_form
:viewState=
"viewState"
:viewparams=
"viewparams"
:context=
"context"
:autosave=
"false"
:viewtag=
"viewtag"
:showBusyIndicator=
"true"
updateAction=
"Update"
removeAction=
"Remove"
loaddraftAction=
"GetDraft"
loadAction=
"Get"
createAction=
"Create"
WFSubmitAction=
""
WFStartAction=
""
style=
''
name=
"form"
ref=
'form'
@
save=
"form_save($event)"
@
remove=
"form_remove($event)"
@
load=
"form_load($event)"
@
closeview=
"closeView($event)"
>
</view
_form
>
<
template
slot=
"footer"
>
<div
class=
"option-view-footer-actions"
>
<i-button
type=
'primary'
@
click=
"onClickOk"
>
{{
containerModel
.
view_okbtn
.
text
}}
</i-button>
<i-button
@
click=
"onClickCancel"
>
{{
containerModel
.
view_cancelbtn
.
text
}}
</i-button>
</div>
</
template
>
</studio-view>
</template>
<
script
lang=
'tsx'
>
import
{
Vue
,
Component
,
Prop
,
Provide
,
Emit
,
Watch
}
from
'vue-property-decorator'
;
import
{
UIActionTool
,
Util
}
from
'@/utils'
;
import
{
Subject
}
from
'rxjs'
;
import
ListLeadService
from
'@/service/list-lead/list-lead-service'
;
import
OptionViewEngine
from
'@engine/view/option-view-engine'
;
@
Component
({
components
:
{
},
})
export
default
class
ListLeadQuickCreateByListBase
extends
Vue
{
/**
* 实体服务对象
*
* @type {ListLeadService}
* @memberof ListLeadQuickCreateByListBase
*/
public
appEntityService
:
ListLeadService
=
new
ListLeadService
;
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof ListLeadQuickCreateByListBase
*/
public
counterServiceArray
:
Array
<
any
>
=
[];
/**
* 数据变化
*
* @param {*} val
* @returns {*}
* @memberof ListLeadQuickCreateByListBase
*/
@
Emit
()
public
viewDatasChange
(
val
:
any
):
any
{
return
val
;
}
/**
* 传入视图上下文
*
* @type {string}
* @memberof ListLeadQuickCreateByListBase
*/
@
Prop
()
public
viewdata
!
:
string
;
/**
* 传入视图参数
*
* @type {string}
* @memberof ListLeadQuickCreateByListBase
*/
@
Prop
()
public
viewparam
!
:
string
;
/**
* 视图默认使用
*
* @type {boolean}
* @memberof ListLeadQuickCreateByListBase
*/
@
Prop
({
default
:
true
})
public
viewDefaultUsage
!
:
boolean
;
/**
* 视图标识
*
* @type {string}
* @memberof ListLeadQuickCreateByListBase
*/
public
viewtag
:
string
=
'8d3e0363ae4532310000143fd6d61aae'
;
/**
* 自定义视图导航上下文集合
*
* @type {*}
* @memberof ListLeadQuickCreateByListBase
*/
public
customViewNavContexts
:
any
=
{
};
/**
* 自定义视图导航参数集合
*
* @type {*}
* @memberof ListLeadQuickCreateByListBase
*/
public
customViewParams
:
any
=
{
};
/**
* 视图模型数据
*
* @type {*}
* @memberof ListLeadQuickCreateByListBase
*/
public
model
:
any
=
{
srfCaption
:
'entities.listlead.views.quickcreatebylist.caption'
,
srfTitle
:
'entities.listlead.views.quickcreatebylist.title'
,
srfSubTitle
:
'entities.listlead.views.quickcreatebylist.subtitle'
,
dataInfo
:
''
}
/**
* 视图参数变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof ListLeadQuickCreateByListBase
*/
@
Watch
(
'viewparam'
,{
immediate
:
true
,
deep
:
true
})
onParamData
(
newVal
:
any
,
oldVal
:
any
)
{
if
(
newVal
){
for
(
let
key
in
this
.
viewparams
){
delete
this
.
viewparams
[
key
];
}
Object
.
assign
(
this
.
viewparams
,
JSON
.
parse
(
this
.
viewparam
));
}
}
/**
* 处理应用上下文变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof ListLeadQuickCreateByListBase
*/
@
Watch
(
'viewdata'
)
onViewData
(
newVal
:
any
,
oldVal
:
any
)
{
const
_this
:
any
=
this
;
if
(
!
Object
.
is
(
newVal
,
oldVal
)
&&
_this
.
engine
)
{
this
.
$nextTick
(()
=>
{
_this
.
parseViewParam
();
_this
.
engine
.
load
();
});
}
}
/**
* 容器模型
*
* @type {*}
* @memberof ListLeadQuickCreateByListBase
*/
public
containerModel
:
any
=
{
view_form
:
{
name
:
'form'
,
type
:
'FORM'
},
view_okbtn
:
{
name
:
'okbtn'
,
type
:
'button'
,
text
:
'确定'
,
disabled
:
true
},
view_cancelbtn
:
{
name
:
'cancelbtn'
,
type
:
'button'
,
text
:
'取消'
,
disabled
:
false
},
view_leftbtn
:
{
name
:
'leftbtn'
,
type
:
'button'
,
text
:
'左移'
,
disabled
:
true
},
view_rightbtn
:
{
name
:
'rightbtn'
,
type
:
'button'
,
text
:
'右移'
,
disabled
:
true
},
view_allleftbtn
:
{
name
:
'allleftbtn'
,
type
:
'button'
,
text
:
'全部左移'
,
disabled
:
true
},
view_allrightbtn
:
{
name
:
'allrightbtn'
,
type
:
'button'
,
text
:
'全部右移'
,
disabled
:
true
},
};
/**
* 计数器刷新
*
* @memberof ListLeadQuickCreateByListBase
*/
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
();
}
})
}
}
/**
* 视图状态订阅对象
*
* @public
* @type {Subject<{action: string, data: any}>}
* @memberof ListLeadQuickCreateByListBase
*/
public
viewState
:
Subject
<
ViewState
>
=
new
Subject
();
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof ListLeadQuickCreateByListBase
*/
public
engine
:
OptionViewEngine
=
new
OptionViewEngine
();
/**
* 引擎初始化
*
* @public
* @memberof ListLeadQuickCreateByListBase
*/
public
engineInit
():
void
{
this
.
engine
.
init
({
view
:
this
,
form
:
this
.
$refs
.
form
,
p2k
:
'0'
,
keyPSDEField
:
'listlead'
,
majorPSDEField
:
'relationshipsname'
,
isLoadDefault
:
true
,
});
}
/**
* 应用上下文
*
* @type {*}
* @memberof ListLeadQuickCreateByListBase
*/
public
context
:
any
=
{};
/**
* 视图参数
*
* @type {*}
* @memberof ListLeadQuickCreateByListBase
*/
public
viewparams
:
any
=
{};
/**
* 解析视图参数
*
* @public
* @memberof ListLeadQuickCreateByListBase
*/
public
parseViewParam
():
void
{
for
(
let
key
in
this
.
context
){
delete
this
.
context
[
key
];
}
if
(
!
this
.
viewDefaultUsage
&&
this
.
viewdata
&&
!
Object
.
is
(
this
.
viewdata
,
''
))
{
Object
.
assign
(
this
.
context
,
JSON
.
parse
(
this
.
viewdata
));
if
(
this
.
context
&&
this
.
context
.
srfparentdename
){
Object
.
assign
(
this
.
viewparams
,{
srfparentdename
:
this
.
context
.
srfparentdename
});
}
if
(
this
.
context
&&
this
.
context
.
srfparentkey
){
Object
.
assign
(
this
.
viewparams
,{
srfparentkey
:
this
.
context
.
srfparentkey
});
}
if
(
this
.
$store
.
getters
.
getAppData
()
&&
this
.
$store
.
getters
.
getAppData
().
context
){
Object
.
assign
(
this
.
context
,
this
.
$store
.
getters
.
getAppData
().
context
);
}
this
.
handleCustomViewData
();
return
;
}
const
path
=
(
this
.
$route
.
matched
[
this
.
$route
.
matched
.
length
-
1
]).
path
;
const
keys
:
Array
<
any
>
=
[];
const
curReg
=
this
.
$pathToRegExp
.
pathToRegexp
(
path
,
keys
);
const
matchArray
=
curReg
.
exec
(
this
.
$route
.
path
);
let
tempValue
:
Object
=
{};
keys
.
forEach
((
item
:
any
,
index
:
number
)
=>
{
Object
.
defineProperty
(
tempValue
,
item
.
name
,
{
enumerable
:
true
,
value
:
matchArray
[
index
+
1
]
});
});
this
.
$viewTool
.
formatRouteParams
(
tempValue
,
this
.
$route
,
this
.
context
,
this
.
viewparams
);
if
(
this
.
$store
.
getters
.
getAppData
()
&&
this
.
$store
.
getters
.
getAppData
().
context
){
Object
.
assign
(
this
.
context
,
this
.
$store
.
getters
.
getAppData
().
context
);
}
//初始化视图唯一标识
Object
.
assign
(
this
.
context
,{
srfsessionid
:
this
.
$util
.
createUUID
()});
this
.
handleCustomViewData
();
}
/**
* 处理自定义视图数据
*
* @memberof ListLeadQuickCreateByListBase
*/
public
handleCustomViewData
(){
if
(
Object
.
keys
(
this
.
customViewNavContexts
).
length
>
0
){
Object
.
keys
(
this
.
customViewNavContexts
).
forEach
((
item
:
any
)
=>
{
let
tempContext
:
any
=
{};
let
curNavContext
:
any
=
this
.
customViewNavContexts
[
item
];
this
.
handleCustomDataLogic
(
curNavContext
,
tempContext
,
item
);
Object
.
assign
(
this
.
context
,
tempContext
);
})
}
if
(
Object
.
keys
(
this
.
customViewParams
).
length
>
0
){
Object
.
keys
(
this
.
customViewParams
).
forEach
((
item
:
any
)
=>
{
let
tempParam
:
any
=
{};
let
curNavParam
:
any
=
this
.
customViewParams
[
item
];
this
.
handleCustomDataLogic
(
curNavParam
,
tempParam
,
item
);
Object
.
assign
(
this
.
viewparams
,
tempParam
);
})
}
}
/**
* 处理自定义视图数据逻辑
*
* @memberof ListLeadQuickCreateByListBase
*/
public
handleCustomDataLogic
(
curNavData
:
any
,
tempData
:
any
,
item
:
string
){
// 直接值直接赋值
if
(
curNavData
.
isRawValue
){
if
(
Object
.
is
(
curNavData
.
value
,
"null"
)
||
Object
.
is
(
curNavData
.
value
,
""
)){
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
null
,
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
else
{
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
curNavData
.
value
,
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
}
else
{
// 先从导航上下文取数,没有再从导航参数(URL)取数,如果导航上下文和导航参数都没有则为null
if
(
this
.
context
[(
curNavData
.
value
).
toLowerCase
()]){
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
this
.
context
[(
curNavData
.
value
).
toLowerCase
()],
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
else
{
if
(
this
.
viewparams
[(
curNavData
.
value
).
toLowerCase
()]){
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
this
.
viewparams
[(
curNavData
.
value
).
toLowerCase
()],
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
else
{
Object
.
defineProperty
(
tempData
,
item
.
toLowerCase
(),
{
value
:
null
,
writable
:
true
,
enumerable
:
true
,
configurable
:
true
});
}
}
}
}
/**
* Vue声明周期
*
* @memberof ListLeadQuickCreateByListBase
*/
public
created
()
{
this
.
afterCreated
();
}
/**
* 执行created后的逻辑
*
* @memberof ListLeadQuickCreateByListBase
*/
public
afterCreated
(){
const
secondtag
=
this
.
$util
.
createUUID
();
this
.
$store
.
commit
(
'viewaction/createdView'
,
{
viewtag
:
this
.
viewtag
,
secondtag
:
secondtag
});
this
.
viewtag
=
secondtag
;
this
.
parseViewParam
();
}
/**
* 销毁之前
*
* @memberof ListLeadQuickCreateByListBase
*/
public
beforeDestroy
()
{
this
.
$store
.
commit
(
'viewaction/removeView'
,
this
.
viewtag
);
}
/**
* Vue声明周期(组件初始化完毕)
*
* @memberof ListLeadQuickCreateByListBase
*/
public
mounted
()
{
this
.
afterMounted
();
}
/**
* 执行mounted后的逻辑
*
* @memberof ListLeadQuickCreateByListBase
*/
public
afterMounted
(){
const
_this
:
any
=
this
;
_this
.
engineInit
();
if
(
_this
.
loadModel
&&
_this
.
loadModel
instanceof
Function
)
{
_this
.
loadModel
();
}
}
/**
* form 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadQuickCreateByListBase
*/
public
form_save
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'form'
,
'save'
,
$event
);
}
/**
* form 部件 remove 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadQuickCreateByListBase
*/
public
form_remove
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'form'
,
'remove'
,
$event
);
}
/**
* form 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ListLeadQuickCreateByListBase
*/
public
form_load
(
$event
:
any
,
$event2
?:
any
)
{
this
.
engine
.
onCtrlEvent
(
'form'
,
'load'
,
$event
);
}
/**
* 关闭视图
*
* @param {any[]} args
* @memberof ListLeadQuickCreateByListBase
*/
public
closeView
(
args
:
any
[]):
void
{
let
_view
:
any
=
this
;
if
(
_view
.
viewdata
)
{
_view
.
$emit
(
'viewdataschange'
,
[
args
]);
_view
.
$emit
(
'close'
,
[
args
]);
}
else
if
(
_view
.
$tabPageExp
)
{
_view
.
$tabPageExp
.
onClose
(
_view
.
$route
.
fullPath
);
}
}
/**
* 销毁视图回调
*
* @memberof ListLeadQuickCreateByListBase
*/
public
destroyed
(){
this
.
afterDestroyed
();
}
/**
* 执行destroyed后的逻辑
*
* @memberof ListLeadQuickCreateByListBase
*/
public
afterDestroyed
(){
if
(
this
.
viewDefaultUsage
){
let
localStoreLength
=
Object
.
keys
(
localStorage
);
if
(
localStoreLength
.
length
>
0
){
localStoreLength
.
forEach
((
item
:
string
)
=>
{
if
(
item
.
startsWith
(
this
.
context
.
srfsessionid
)){
localStorage
.
removeItem
(
item
);
}
})
}
}
}
/**
* 确定
*
* @memberof ListLeadQuickCreateByListBase
*/
public
onClickOk
():
void
{
const
form
:
any
=
this
.
$refs
.
form
;
if
(
!
form
)
return
;
form
.
save
().
then
((
res
:
any
)
=>
{
if
(
res
.
status
==
200
){
this
.
$emit
(
'close'
,[
res
.
data
]);
}
});
}
/**
* 取消
*
* @memberof ListLeadQuickCreateByListBase
*/
public
onClickCancel
():
void
{
this
.
$emit
(
'close'
,
null
);
}
}
</
script
>
<
style
lang=
'less'
>
@import './list-lead-quick-create-by-list.less';
</
style
>
\ No newline at end of file
app_BusinessCentral/src/pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.less
0 → 100644
浏览文件 @
7018448f
.option-view {
--option-view: 0;
}
// 避免空文件,后台不让空文件过
.list-lead-quick-create-by-list {
--list-lead-quick-create-by-list: 0;
}
app_BusinessCentral/src/pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue
0 → 100644
浏览文件 @
7018448f
<
script
lang=
'tsx'
>
import
{
Component
}
from
'vue-property-decorator'
;
import
ListLeadQuickCreateByListBase
from
'./list-lead-quick-create-by-list-base.vue'
;
import
view_form
from
'@widgets/list-lead/quick-create-by-list-form/quick-create-by-list-form.vue'
;
@
Component
({
components
:
{
view_form
,
},
beforeRouteEnter
:
(
to
:
any
,
from
:
any
,
next
:
any
)
=>
{
next
((
vm
:
any
)
=>
{
vm
.
$store
.
commit
(
'addCurPageViewtag'
,
{
route
:
to
,
viewtag
:
vm
.
viewtag
});
});
},
})
export
default
class
ListLeadQuickCreateByList
extends
ListLeadQuickCreateByListBase
{
}
</
script
>
\ No newline at end of file
app_BusinessCentral/src/pages/ungroup/central/page-register.ts
浏览文件 @
7018448f
...
...
@@ -12,6 +12,7 @@ export const PageComponents = {
Vue
.
component
(
'account-edit-view'
,
()
=>
import
(
'@pages/base/account-edit-view/account-edit-view.vue'
));
Vue
.
component
(
'list-contact-grid-view'
,
()
=>
import
(
'@pages/marketing/list-contact-grid-view/list-contact-grid-view.vue'
));
Vue
.
component
(
'fax-edit-view'
,
()
=>
import
(
'@pages/base/fax-edit-view/fax-edit-view.vue'
));
Vue
.
component
(
'lead-pickup-view'
,
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
));
Vue
.
component
(
'incident-edit-view'
,
()
=>
import
(
'@pages/service/incident-edit-view/incident-edit-view.vue'
));
Vue
.
component
(
'campaign-list-grid-view'
,
()
=>
import
(
'@pages/marketing/campaign-list-grid-view/campaign-list-grid-view.vue'
));
Vue
.
component
(
'activity-pointer-edit-view'
,
()
=>
import
(
'@pages/base/activity-pointer-edit-view/activity-pointer-edit-view.vue'
));
...
...
@@ -55,21 +56,22 @@ export const PageComponents = {
Vue
.
component
(
'sales-literature-edit-view'
,
()
=>
import
(
'@pages/sales/sales-literature-edit-view/sales-literature-edit-view.vue'
));
Vue
.
component
(
'ibiz-list-info'
,
()
=>
import
(
'@pages/marketing/ibiz-list-info/ibiz-list-info.vue'
));
Vue
.
component
(
'ibiz-list-summary'
,
()
=>
import
(
'@pages/marketing/ibiz-list-summary/ibiz-list-summary.vue'
));
Vue
.
component
(
'lead-pickup-grid-view'
,
()
=>
import
(
'@pages/sales/lead-pickup-grid-view/lead-pickup-grid-view.vue'
));
Vue
.
component
(
'list-account-quick-create-by-list'
,
()
=>
import
(
'@pages/marketing/list-account-quick-create-by-list/list-account-quick-create-by-list.vue'
));
Vue
.
component
(
'list-lead-edit-view'
,
()
=>
import
(
'@pages/marketing/list-lead-edit-view/list-lead-edit-view.vue'
));
Vue
.
component
(
'campaign-list-edit-view'
,
()
=>
import
(
'@pages/marketing/campaign-list-edit-view/campaign-list-edit-view.vue'
));
Vue
.
component
(
'account-pickup-grid-view'
,
()
=>
import
(
'@pages/base/account-pickup-grid-view/account-pickup-grid-view.vue'
));
Vue
.
component
(
'product-edit-quick-create'
,
()
=>
import
(
'@pages/product/product-edit-quick-create/product-edit-quick-create.vue'
));
Vue
.
component
(
'list-lead-quick-create-by-list'
,
()
=>
import
(
'@pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue'
));
Vue
.
component
(
'account-info'
,
()
=>
import
(
'@pages/base/account-info/account-info.vue'
));
Vue
.
component
(
'campaign-info-manager'
,
()
=>
import
(
'@pages/marketing/campaign-info-manager/campaign-info-manager.vue'
));
Vue
.
component
(
'contact-info-abstract'
,
()
=>
import
(
'@pages/base/contact-info-abstract/contact-info-abstract.vue'
));
Vue
.
component
(
'list-contact-edit-view'
,
()
=>
import
(
'@pages/marketing/list-contact-edit-view/list-contact-edit-view.vue'
));
Vue
.
component
(
'campaign-grid-view'
,
()
=>
import
(
'@pages/marketing/campaign-grid-view/campaign-grid-view.vue'
));
Vue
.
component
(
'list-lead-by-list'
,
()
=>
import
(
'@pages/marketing/list-lead-by-list/list-lead-by-list.vue'
));
Vue
.
component
(
'account-info-major-contact'
,
()
=>
import
(
'@pages/base/account-info-major-contact/account-info-major-contact.vue'
));
Vue
.
component
(
'sales-order-grid-view'
,
()
=>
import
(
'@pages/sales/sales-order-grid-view/sales-order-grid-view.vue'
));
Vue
.
component
(
'contact-option-view'
,
()
=>
import
(
'@pages/base/contact-option-view/contact-option-view.vue'
));
Vue
.
component
(
'activity-pointer-by-parent-key'
,
()
=>
import
(
'@pages/base/activity-pointer-by-parent-key/activity-pointer-by-parent-key.vue'
));
Vue
.
component
(
'list-lead-grid-view'
,
()
=>
import
(
'@pages/marketing/list-lead-grid-view/list-lead-grid-view.vue'
));
Vue
.
component
(
'lead-edit-view'
,
()
=>
import
(
'@pages/sales/lead-edit-view/lead-edit-view.vue'
));
Vue
.
component
(
'phone-call-edit-view'
,
()
=>
import
(
'@pages/base/phone-call-edit-view/phone-call-edit-view.vue'
));
Vue
.
component
(
'contact-dashboard-view'
,
()
=>
import
(
'@pages/base/contact-dashboard-view/contact-dashboard-view.vue'
));
...
...
app_BusinessCentral/src/pages/ungroup/central/router.ts
浏览文件 @
7018448f
...
...
@@ -263,6 +263,50 @@ const router = new Router({
},
component
:
()
=>
import
(
'@pages/base/fax-edit-view/fax-edit-view.vue'
),
},
{
path
:
'contacts/:contact?/leads/:lead?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
),
},
{
path
:
'campaigns/:campaign?/leads/:lead?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
),
},
{
path
:
'leads/:lead?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
),
},
{
path
:
'incidents/:incident?/editview/:editview?'
,
meta
:
{
...
...
@@ -967,6 +1011,50 @@ const router = new Router({
},
component
:
()
=>
import
(
'@pages/marketing/campaign-response-quick-create/campaign-response-quick-create.vue'
),
},
{
path
:
'contacts/:contact?/leads/:lead?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupgridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-grid-view/lead-pickup-grid-view.vue'
),
},
{
path
:
'campaigns/:campaign?/leads/:lead?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupgridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-grid-view/lead-pickup-grid-view.vue'
),
},
{
path
:
'leads/:lead?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupgridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-grid-view/lead-pickup-grid-view.vue'
),
},
{
path
:
'ibizlists/:ibizlist?/listaccounts/:listaccount?/quickcreatebylist/:quickcreatebylist?'
,
meta
:
{
...
...
@@ -1012,152 +1100,152 @@ const router = new Router({
component
:
()
=>
import
(
'@pages/marketing/list-account-quick-create-by-list/list-account-quick-create-by-list.vue'
),
},
{
path
:
'
contacts/:contact?/leads/:lead?/listleads/:listlead
?/editview/:editview?'
,
path
:
'
ibizlists/:ibizlist?/campaignlists/:campaignlist
?/editview/:editview?'
,
meta
:
{
caption
:
'entities.
listlead
.views.editview.title'
,
caption
:
'entities.
campaignlist
.views.editview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'campaignlists'
,
parameterName
:
'campaignlist'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/
list-lead-edit-view/list-lead
-edit-view.vue'
),
component
:
()
=>
import
(
'@pages/marketing/
campaign-list-edit-view/campaign-list
-edit-view.vue'
),
},
{
path
:
'campaigns/:campaign?/
leads/:lead?/listleads/:listlead
?/editview/:editview?'
,
path
:
'campaigns/:campaign?/
campaignlists/:campaignlist
?/editview/:editview?'
,
meta
:
{
caption
:
'entities.
listlead
.views.editview.title'
,
caption
:
'entities.
campaignlist
.views.editview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'campaignlists'
,
parameterName
:
'campaignlist'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/
list-lead-edit-view/list-lead
-edit-view.vue'
),
component
:
()
=>
import
(
'@pages/marketing/
campaign-list-edit-view/campaign-list
-edit-view.vue'
),
},
{
path
:
'
ibizlists/:ibizlist?/listleads/:listlead
?/editview/:editview?'
,
path
:
'
campaignlists/:campaignlist
?/editview/:editview?'
,
meta
:
{
caption
:
'entities.
listlead
.views.editview.title'
,
caption
:
'entities.
campaignlist
.views.editview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'campaignlists'
,
parameterName
:
'campaignlist'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/
list-lead-edit-view/list-lead
-edit-view.vue'
),
component
:
()
=>
import
(
'@pages/marketing/
campaign-list-edit-view/campaign-list
-edit-view.vue'
),
},
{
path
:
'
leads/:lead?/listleads/:listlead?/editview/:edit
view?'
,
path
:
'
accounts/:account?/pickupgridview/:pickupgrid
view?'
,
meta
:
{
caption
:
'entities.
listlead.views.edit
view.title'
,
caption
:
'entities.
account.views.pickupgrid
view.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
{
pathName
:
'accounts'
,
parameterName
:
'account'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-edit-view/list-lead-edit
-view.vue'
),
component
:
()
=>
import
(
'@pages/
base/account-pickup-grid-view/account-pickup-grid
-view.vue'
),
},
{
path
:
'
listleads/:listlead?/editview/:editview
?'
,
path
:
'
products/:product?/edit_quickcreate/:edit_quickcreate
?'
,
meta
:
{
caption
:
'entities.
listlead.views.editview
.title'
,
caption
:
'entities.
product.views.edit_quickcreate
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'
listleads'
,
parameterName
:
'listlead
'
},
{
pathName
:
'edit
view'
,
parameterName
:
'editview
'
},
{
pathName
:
'
products'
,
parameterName
:
'product
'
},
{
pathName
:
'edit
_quickcreate'
,
parameterName
:
'edit_quickcreate
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-edit-view/list-lead-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/
product/product-edit-quick-create/product-edit-quick-create
.vue'
),
},
{
path
:
'
ibizlists/:ibizlist?/campaignlists/:campaignlist?/editview/:editview
?'
,
path
:
'
contacts/:contact?/leads/:lead?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist
?'
,
meta
:
{
caption
:
'entities.
campaignlist.views.editview
.title'
,
caption
:
'entities.
listlead.views.quickcreatebylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'campaignlists'
,
parameterName
:
'campaignlist'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/
campaign-list-edit-view/campaign-list-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/
list-lead-quick-create-by-list/list-lead-quick-create-by-list
.vue'
),
},
{
path
:
'campaigns/:campaign?/
campaignlists/:campaignlist?/editview/:editview
?'
,
path
:
'campaigns/:campaign?/
leads/:lead?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist
?'
,
meta
:
{
caption
:
'entities.
campaignlist.views.editview
.title'
,
caption
:
'entities.
listlead.views.quickcreatebylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'campaignlists'
,
parameterName
:
'campaignlist'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/
campaign-list-edit-view/campaign-list-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/
list-lead-quick-create-by-list/list-lead-quick-create-by-list
.vue'
),
},
{
path
:
'
campaignlists/:campaignlist?/editview/:editview
?'
,
path
:
'
ibizlists/:ibizlist?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist
?'
,
meta
:
{
caption
:
'entities.
campaignlist.views.editview
.title'
,
caption
:
'entities.
listlead.views.quickcreatebylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'campaignlists'
,
parameterName
:
'campaignlist'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/
campaign-list-edit-view/campaign-list-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/
list-lead-quick-create-by-list/list-lead-quick-create-by-list
.vue'
),
},
{
path
:
'
accounts/:account?/pickupgridview/:pickupgridview
?'
,
path
:
'
leads/:lead?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist
?'
,
meta
:
{
caption
:
'entities.
account.views.pickupgridview
.title'
,
caption
:
'entities.
listlead.views.quickcreatebylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'accounts'
,
parameterName
:
'account'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
base/account-pickup-grid-view/account-pickup-grid-view
.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list
.vue'
),
},
{
path
:
'
products/:product?/edit_quickcreate/:edit_quickcreate
?'
,
path
:
'
listleads/:listlead?/quickcreatebylist/:quickcreatebylist
?'
,
meta
:
{
caption
:
'entities.
product.views.edit_quickcreate
.title'
,
caption
:
'entities.
listlead.views.quickcreatebylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'
products'
,
parameterName
:
'product
'
},
{
pathName
:
'
edit_quickcreate'
,
parameterName
:
'edit_quickcreate
'
},
{
pathName
:
'
listleads'
,
parameterName
:
'listlead
'
},
{
pathName
:
'
quickcreatebylist'
,
parameterName
:
'quickcreatebylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
product/product-edit-quick-create/product-edit-quick-create
.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list
.vue'
),
},
{
path
:
'accounts/:account?/info/:info?'
,
...
...
@@ -1274,136 +1362,150 @@ const router = new Router({
component
:
()
=>
import
(
'@pages/marketing/campaign-grid-view/campaign-grid-view.vue'
),
},
{
path
:
'
accounts/:account?/info_majorcontact/:info_majorcontac
t?'
,
path
:
'
contacts/:contact?/leads/:lead?/listleads/:listlead?/bylist/:bylis
t?'
,
meta
:
{
caption
:
'entities.
account.views.info_majorcontac
t.title'
,
caption
:
'entities.
listlead.views.bylis
t.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'accounts'
,
parameterName
:
'account'
},
{
pathName
:
'info_majorcontact'
,
parameterName
:
'info_majorcontact'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'bylist'
,
parameterName
:
'bylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
base/account-info-major-contact/account-info-major-contac
t.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-by-list/list-lead-by-lis
t.vue'
),
},
{
path
:
'
salesorders/:salesorder?/gridview/:gridview
?'
,
path
:
'
campaigns/:campaign?/leads/:lead?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.
salesorder.views.gridview
.title'
,
caption
:
'entities.
listlead.views.bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'salesorders'
,
parameterName
:
'salesorder'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'bylist'
,
parameterName
:
'bylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
sales/sales-order-grid-view/sales-order-grid-view
.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-by-list/list-lead-by-list
.vue'
),
},
{
path
:
'
contacts/:contact?/optionview/:optionview
?'
,
path
:
'
ibizlists/:ibizlist?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.
contact.views.optionview
.title'
,
caption
:
'entities.
listlead.views.bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'optionview'
,
parameterName
:
'optionview'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'bylist'
,
parameterName
:
'bylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
base/contact-option-view/contact-option-view
.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-by-list/list-lead-by-list
.vue'
),
},
{
path
:
'
activitypointers/:activitypointer?/byparentkey/:byparentkey
?'
,
path
:
'
leads/:lead?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.
activitypointer.views.byparentkey
.title'
,
caption
:
'entities.
listlead.views.bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'activitypointers'
,
parameterName
:
'activitypointer'
},
{
pathName
:
'byparentkey'
,
parameterName
:
'byparentkey'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'bylist'
,
parameterName
:
'bylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
base/activity-pointer-by-parent-key/activity-pointer-by-parent-key
.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-by-list/list-lead-by-list
.vue'
),
},
{
path
:
'
contacts/:contact?/leads/:lead?/listleads/:listlead?/gridview/:gridview
?'
,
path
:
'
listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.listlead.views.
gridview
.title'
,
caption
:
'entities.listlead.views.
bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'
gridview'
,
parameterName
:
'gridview
'
},
{
pathName
:
'
bylist'
,
parameterName
:
'bylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-
grid-view/list-lead-grid-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/list-lead-
by-list/list-lead-by-list
.vue'
),
},
{
path
:
'
campaigns/:campaign?/leads/:lead?/listleads/:listlead?/gridview/:gridview
?'
,
path
:
'
accounts/:account?/info_majorcontact/:info_majorcontact
?'
,
meta
:
{
caption
:
'entities.
listlead.views.gridview
.title'
,
caption
:
'entities.
account.views.info_majorcontact
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'accounts'
,
parameterName
:
'account'
},
{
pathName
:
'info_majorcontact'
,
parameterName
:
'info_majorcontact'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead-grid-view
.vue'
),
component
:
()
=>
import
(
'@pages/
base/account-info-major-contact/account-info-major-contact
.vue'
),
},
{
path
:
'
ibizlists/:ibizlist?/listleads/:listlead
?/gridview/:gridview?'
,
path
:
'
salesorders/:salesorder
?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.
listlead
.views.gridview.title'
,
caption
:
'entities.
salesorder
.views.gridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'salesorders'
,
parameterName
:
'salesorder'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead
-grid-view.vue'
),
component
:
()
=>
import
(
'@pages/
sales/sales-order-grid-view/sales-order
-grid-view.vue'
),
},
{
path
:
'
leads/:lead?/listleads/:listlead?/gridview/:grid
view?'
,
path
:
'
contacts/:contact?/optionview/:option
view?'
,
meta
:
{
caption
:
'entities.
listlead.views.grid
view.title'
,
caption
:
'entities.
contact.views.option
view.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'optionview'
,
parameterName
:
'optionview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead-grid
-view.vue'
),
component
:
()
=>
import
(
'@pages/
base/contact-option-view/contact-option
-view.vue'
),
},
{
path
:
'
listleads/:listlead?/gridview/:gridview
?'
,
path
:
'
activitypointers/:activitypointer?/byparentkey/:byparentkey
?'
,
meta
:
{
caption
:
'entities.
listlead.views.gridview
.title'
,
caption
:
'entities.
activitypointer.views.byparentkey
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'
listleads'
,
parameterName
:
'listlead
'
},
{
pathName
:
'
gridview'
,
parameterName
:
'gridview
'
},
{
pathName
:
'
activitypointers'
,
parameterName
:
'activitypointer
'
},
{
pathName
:
'
byparentkey'
,
parameterName
:
'byparentkey
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-grid-view/list-lead-grid-view.vue'
),
component
:
()
=>
import
(
'@pages/base/activity-pointer-by-parent-key/activity-pointer-by-parent-key.vue'
),
},
{
path
:
'accounts/:account?/innerpickupgridview/:innerpickupgridview?'
,
meta
:
{
caption
:
'entities.account.views.innerpickupgridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'accounts'
,
parameterName
:
'account'
},
{
pathName
:
'innerpickupgridview'
,
parameterName
:
'innerpickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/base/account-inner-pickup-grid-view/account-inner-pickup-grid-view.vue'
),
},
{
path
:
'contacts/:contact?/leads/:lead?/editview/:editview?'
,
...
...
@@ -1676,6 +1778,20 @@ const router = new Router({
},
component
:
()
=>
import
(
'@pages/service/incident-grid-view/incident-grid-view.vue'
),
},
{
path
:
'accounts/:account?/innerpickupview/:innerpickupview?'
,
meta
:
{
caption
:
'entities.account.views.innerpickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'accounts'
,
parameterName
:
'account'
},
{
pathName
:
'innerpickupview'
,
parameterName
:
'innerpickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/base/account-inner-pickup-view/account-inner-pickup-view.vue'
),
},
{
path
:
'ibizlists/:ibizlist?/quickcreate/:quickcreate?'
,
meta
:
{
...
...
@@ -1877,6 +1993,47 @@ const router = new Router({
},
component
:
()
=>
import
(
'@pages/sales/lead-grid-view/lead-grid-view.vue'
),
},
{
path
:
'/contacts/:contact?/leads/:lead?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
),
},
{
path
:
'/campaigns/:campaign?/leads/:lead?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
),
},
{
path
:
'/leads/:lead?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.lead.views.pickupview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/sales/lead-pickup-view/lead-pickup-view.vue'
),
},
{
path
:
'/accounts/:account?/info_account/:info_account?'
,
meta
:
{
...
...
@@ -1956,88 +2113,88 @@ const router = new Router({
component
:
()
=>
import
(
'@pages/base/account-pickup-view/account-pickup-view.vue'
),
},
{
path
:
'/contacts/:contact?/
leads/:lead?/listleads/:listlead?/editview/:editview
?'
,
path
:
'/contacts/:contact?/
info_book/:info_book
?'
,
meta
:
{
caption
:
'entities.
listlead.views.editview
.title'
,
caption
:
'entities.
contact.views.info_book
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
{
pathName
:
'info_book'
,
parameterName
:
'info_book'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-edit-view/list-lead-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/
base/contact-info-book/contact-info-book
.vue'
),
},
{
path
:
'/c
ampaigns/:campaign?/leads/:lead?/listleads/:listlead?/editview/:editview
?'
,
path
:
'/c
ontacts/:contact?/leads/:lead?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.listlead.views.
editview
.title'
,
caption
:
'entities.listlead.views.
bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'c
ampaigns'
,
parameterName
:
'campaign
'
},
{
pathName
:
'c
ontacts'
,
parameterName
:
'contact
'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'
editview'
,
parameterName
:
'editview
'
},
{
pathName
:
'
bylist'
,
parameterName
:
'bylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-
edit-view/list-lead-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/list-lead-
by-list/list-lead-by-list
.vue'
),
},
{
path
:
'/
ibizlists/:ibizlist?/listleads/:listlead?/editview/:editview
?'
,
path
:
'/
campaigns/:campaign?/leads/:lead?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.listlead.views.
editview
.title'
,
caption
:
'entities.listlead.views.
bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'
editview'
,
parameterName
:
'editview
'
},
{
pathName
:
'
bylist'
,
parameterName
:
'bylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-
edit-view/list-lead-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/list-lead-
by-list/list-lead-by-list
.vue'
),
},
{
path
:
'/
leads/:lead?/listleads/:listlead?/editview/:editview
?'
,
path
:
'/
ibizlists/:ibizlist?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.listlead.views.
editview
.title'
,
caption
:
'entities.listlead.views.
bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'
leads'
,
parameterName
:
'lead
'
},
{
pathName
:
'
ibizlists'
,
parameterName
:
'ibizlist
'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'
editview'
,
parameterName
:
'editview
'
},
{
pathName
:
'
bylist'
,
parameterName
:
'bylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-
edit-view/list-lead-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/list-lead-
by-list/list-lead-by-list
.vue'
),
},
{
path
:
'/l
istleads/:listlead?/editview/:editview
?'
,
path
:
'/l
eads/:lead?/listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.listlead.views.
editview
.title'
,
caption
:
'entities.listlead.views.
bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'
editview'
,
parameterName
:
'editview
'
},
{
pathName
:
'
bylist'
,
parameterName
:
'bylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-
edit-view/list-lead-edit-view
.vue'
),
component
:
()
=>
import
(
'@pages/marketing/list-lead-
by-list/list-lead-by-list
.vue'
),
},
{
path
:
'/
contacts/:contact?/info_book/:info_book
?'
,
path
:
'/
listleads/:listlead?/bylist/:bylist
?'
,
meta
:
{
caption
:
'entities.
contact.views.info_book
.title'
,
caption
:
'entities.
listlead.views.bylist
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'
contacts'
,
parameterName
:
'contact
'
},
{
pathName
:
'
info_book'
,
parameterName
:
'info_book
'
},
{
pathName
:
'
listleads'
,
parameterName
:
'listlead
'
},
{
pathName
:
'
bylist'
,
parameterName
:
'bylist
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
base/contact-info-book/contact-info-book
.vue'
),
component
:
()
=>
import
(
'@pages/
marketing/list-lead-by-list/list-lead-by-list
.vue'
),
},
{
path
:
'/contacts/:contact?/leads/:lead?/editview/:editview?'
,
...
...
@@ -2611,87 +2768,57 @@ const router = new Router({
component
:
()
=>
import
(
'@pages/sales/opportunity-edit-view/opportunity-edit-view.vue'
),
},
{
path
:
'/c
enteralportal/:centeralportal
?'
,
path
:
'/c
ontacts/:contact?/leads/:lead?/pickupgridview/:pickupgridview
?'
,
meta
:
{
caption
:
'app.views.centeralportal.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'centeralportal'
,
parameterName
:
'centeralportal'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ungroup/centeral-portal/centeral-portal.vue'
),
},
{
path
:
'/contacts/:contact?/leads/:lead?/listleads/:listlead?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.listlead.views.gridview.title'
,
caption
:
'entities.lead.views.pickupgridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead
-grid-view.vue'
),
component
:
()
=>
import
(
'@pages/
sales/lead-pickup-grid-view/lead-pickup
-grid-view.vue'
),
},
{
path
:
'/campaigns/:campaign?/leads/:lead?/
listleads/:listlead?/gridview/:
gridview?'
,
path
:
'/campaigns/:campaign?/leads/:lead?/
pickupgridview/:pickup
gridview?'
,
meta
:
{
caption
:
'entities.l
istlead.views.
gridview.title'
,
caption
:
'entities.l
ead.views.pickup
gridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-grid-view/list-lead-grid-view.vue'
),
},
{
path
:
'/ibizlists/:ibizlist?/listleads/:listlead?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.listlead.views.gridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead
-grid-view.vue'
),
component
:
()
=>
import
(
'@pages/
sales/lead-pickup-grid-view/lead-pickup
-grid-view.vue'
),
},
{
path
:
'/leads/:lead?/
listleads/:listlead?/gridview/:
gridview?'
,
path
:
'/leads/:lead?/
pickupgridview/:pickup
gridview?'
,
meta
:
{
caption
:
'entities.l
istlead.views.
gridview.title'
,
caption
:
'entities.l
ead.views.pickup
gridview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead
-grid-view.vue'
),
component
:
()
=>
import
(
'@pages/
sales/lead-pickup-grid-view/lead-pickup
-grid-view.vue'
),
},
{
path
:
'/
listleads/:listlead?/gridview/:gridview
?'
,
path
:
'/
centeralportal/:centeralportal
?'
,
meta
:
{
caption
:
'
entities.listlead.views.gridview
.title'
,
caption
:
'
app.views.centeralportal
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
{
pathName
:
'centeralportal'
,
parameterName
:
'centeralportal'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
marketing/list-lead-grid-view/list-lead-grid-view
.vue'
),
component
:
()
=>
import
(
'@pages/
ungroup/centeral-portal/centeral-portal
.vue'
),
},
{
path
:
'/ibizlists/:ibizlist?/quickcreate/:quickcreate?'
,
...
...
@@ -2745,6 +2872,77 @@ const router = new Router({
},
component
:
()
=>
import
(
'@pages/product/price-level-pickup-view/price-level-pickup-view.vue'
),
},
{
path
:
'/contacts/:contact?/leads/:lead?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist?'
,
meta
:
{
caption
:
'entities.listlead.views.quickcreatebylist.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'contacts'
,
parameterName
:
'contact'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue'
),
},
{
path
:
'/campaigns/:campaign?/leads/:lead?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist?'
,
meta
:
{
caption
:
'entities.listlead.views.quickcreatebylist.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'campaigns'
,
parameterName
:
'campaign'
},
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue'
),
},
{
path
:
'/ibizlists/:ibizlist?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist?'
,
meta
:
{
caption
:
'entities.listlead.views.quickcreatebylist.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue'
),
},
{
path
:
'/leads/:lead?/listleads/:listlead?/quickcreatebylist/:quickcreatebylist?'
,
meta
:
{
caption
:
'entities.listlead.views.quickcreatebylist.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'leads'
,
parameterName
:
'lead'
},
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue'
),
},
{
path
:
'/listleads/:listlead?/quickcreatebylist/:quickcreatebylist?'
,
meta
:
{
caption
:
'entities.listlead.views.quickcreatebylist.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'listleads'
,
parameterName
:
'listlead'
},
{
pathName
:
'quickcreatebylist'
,
parameterName
:
'quickcreatebylist'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/list-lead-quick-create-by-list/list-lead-quick-create-by-list.vue'
),
},
{
path
:
'/salesliteratures/:salesliterature?/gridview/:gridview?'
,
meta
:
{
...
...
app_BusinessCentral/src/store/modules/view-action/state.ts
浏览文件 @
7018448f
...
...
@@ -132,6 +132,16 @@ export const viewstate: any = {
'4745ca10fe4421ea043cb9ace1840224'
,
],
},
{
viewtag
:
'1bc48b15dbe69c5f30dafe489f58aacb'
,
viewmodule
:
'Sales'
,
viewname
:
'LeadPickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'7d00f63c306adf3537efeabb3326095d'
,
],
},
{
viewtag
:
'1d3b94223a5d3f8ab1d2fe334c8c4afd'
,
viewmodule
:
'Base'
,
...
...
@@ -190,21 +200,22 @@ export const viewstate: any = {
],
},
{
viewtag
:
'2
9e6b575138e5652740ab94b21c40928
'
,
viewmodule
:
'
Marketing
'
,
viewname
:
'
ListLeadEditView
'
,
viewtag
:
'2
b787c59ba090b37b9a1ba8f8ba045b4
'
,
viewmodule
:
'
Base
'
,
viewname
:
'
ContactInfo_Book
'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'2
b787c59ba090b37b9a1ba8f8ba045b4
'
,
viewmodule
:
'
Base
'
,
viewname
:
'
ContactInfo_Book
'
,
viewtag
:
'2
c6be792e84450585986e22f75dffa52
'
,
viewmodule
:
'
Marketing
'
,
viewname
:
'
ListLeadByList
'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'8d3e0363ae4532310000143fd6d61aae'
,
],
},
{
...
...
@@ -521,22 +532,21 @@ export const viewstate: any = {
],
},
{
viewtag
:
'7
FCD2E75-E34A-493C-922E-8AE47BCE08CA
'
,
viewmodule
:
'
Ungroup
'
,
viewname
:
'
CenteralPortal
'
,
viewtag
:
'7
d00f63c306adf3537efeabb3326095d
'
,
viewmodule
:
'
Sales
'
,
viewname
:
'
LeadPickupGridView
'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'
829c9b0c0bf0c3796537872b84f26935
'
,
viewmodule
:
'
Marketing
'
,
viewname
:
'
ListLeadGridView
'
,
viewtag
:
'
7FCD2E75-E34A-493C-922E-8AE47BCE08CA
'
,
viewmodule
:
'
Ungroup
'
,
viewname
:
'
CenteralPortal
'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'29e6b575138e5652740ab94b21c40928'
,
],
},
{
...
...
@@ -602,6 +612,16 @@ export const viewstate: any = {
'dd10cba0f2ded085120f7dc8eccc7c10'
,
],
},
{
viewtag
:
'8d3e0363ae4532310000143fd6d61aae'
,
viewmodule
:
'Marketing'
,
viewname
:
'ListLeadQuickCreateByList'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'1bc48b15dbe69c5f30dafe489f58aacb'
,
],
},
{
viewtag
:
'90b48a107932f432e0dde42791a51887'
,
viewmodule
:
'Sales'
,
...
...
@@ -675,6 +695,7 @@ export const viewstate: any = {
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'054fb10ed157549dc619f06af1c21a31'
,
],
},
{
...
...
@@ -750,9 +771,9 @@ export const viewstate: any = {
viewdatachange
:
false
,
refviews
:
[
'661e0045037121d27f78b71049dc0d8a'
,
'2c6be792e84450585986e22f75dffa52'
,
'4799b0e7139b537ebe9313a004daa0ac'
,
'a0baf844a4d48914ee2623448b1a73fb'
,
'829c9b0c0bf0c3796537872b84f26935'
,
'3124753ba4abff3aaf49355a5197c4ab'
,
],
},
...
...
app_BusinessCentral/src/uiservice/list-lead/list-lead-ui-service-base.ts
浏览文件 @
7018448f
...
...
@@ -79,8 +79,8 @@ export default class ListLeadUIServiceBase extends UIService {
* @memberof ListLeadUIServiceBase
*/
public
initViewMap
(){
this
.
allViewMap
.
set
(
'
EDITVIEW:'
,{
viewname
:
'editview
'
,
srfappde
:
'listleads'
});
this
.
allViewMap
.
set
(
'
MDATAVIEW:'
,{
viewname
:
'gridview
'
,
srfappde
:
'listleads'
});
this
.
allViewMap
.
set
(
'
:'
,{
viewname
:
'bylist
'
,
srfappde
:
'listleads'
});
this
.
allViewMap
.
set
(
'
:'
,{
viewname
:
'quickcreatebylist
'
,
srfappde
:
'listleads'
});
}
/**
...
...
app_BusinessCentral/src/widgets/ibiz-list/infotabviewpanel4-tabviewpanel/infotabviewpanel4-tabviewpanel-base.vue
浏览文件 @
7018448f
<
template
>
<div
class=
'tabviewpanel'
style=
"height:100%;"
v-if =
'isActivied'
>
<list-lead-
grid-view
<list-lead-
by-list
class=
'viewcontainer2'
:viewdata=
"viewdata"
:viewparam=
"viewparam"
@
viewload=
"viewDatasChange($event)"
:viewDefaultUsage=
"false"
>
</list-lead-
grid-view
>
</list-lead-
by-list
>
</div>
</
template
>
<
script
lang=
'tsx'
>
...
...
app_BusinessCentral/src/widgets/lead/default-searchform/default-searchform-base.vue
浏览文件 @
7018448f
...
...
@@ -669,7 +669,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图搜索表单loadAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图搜索表单loadAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
@@ -706,7 +706,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
public
loadDraft
(
opt
:
any
=
{},
mode
?:
string
):
void
{
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图搜索表单loaddraftAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图搜索表单loaddraftAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
}
;
...
...
app_BusinessCentral/src/widgets/lead/main-grid/main-grid-base.vue
浏览文件 @
7018448f
...
...
@@ -258,20 +258,6 @@ export default class MainBase extends Vue implements ControlInterface {
return
this
.
selections
[
0
];
}
/**
* 打开新建数据视图
*
* @type {any}
* @memberof Main
*/
@
Prop
()
public
newdata
:
any
;
/**
* 打开编辑数据视图
*
* @type {any}
* @memberof Main
*/
@
Prop
()
public
opendata
:
any
;
/**
* 显示处理提示
...
...
@@ -646,7 +632,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
load
(
opt
:
any
=
{},
pageReset
:
boolean
=
false
):
void
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图表格fetchAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图表格fetchAction参数未配置'
});
return
;
}
if
(
pageReset
){
...
...
@@ -723,7 +709,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
async
remove
(
datas
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图表格removeAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图表格removeAction参数未配置'
});
return
;
}
let
_datas
:
any
[]
=
[];
...
...
@@ -829,7 +815,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
addBatch
(
arg
:
any
=
{}):
void
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图表格fetchAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图表格fetchAction参数未配置'
});
return
;
}
if
(
!
arg
){
...
...
@@ -1375,7 +1361,7 @@ export default class MainBase extends Vue implements ControlInterface {
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
)){
if
(
!
this
.
createAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图表格createAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图表格createAction参数未配置'
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
...
...
@@ -1383,7 +1369,7 @@ export default class MainBase extends Vue implements ControlInterface {
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
if
(
!
this
.
updateAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'LeadGridView视图表格updateAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'Lead
Pickup
GridView视图表格updateAction参数未配置'
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
if
(
item
.
lead
){
...
...
app_BusinessCentral/src/widgets/list-account/quick-create-by-list-form/quick-create-by-list-form-base.vue
浏览文件 @
7018448f
...
...
@@ -9,6 +9,21 @@
<i-col
v-show=
"detailsModel.entity2name.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-item
name=
'entity2name'
:itemRules=
"this.rules.entity2name"
class=
''
:caption=
"$t('entities.listaccount.quickcreatebylist_form.details.entity2name')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.entity2name.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<app-embed-picker
:formState=
"formState"
:data=
"JSON.stringify(this.data)"
:context=
"context"
:viewparams=
"viewparams"
:ignorefieldvaluechange=
"ignorefieldvaluechange"
:value=
"data.entity2name"
name=
"entity2name"
:localContext =
'
{ }'
:localParam ='{ }'
valueItem=''
refviewname="account-inner-pickup-view"
@formitemvaluechange="onFormItemValueChange"
style="">
</app-embed-picker>
</app-form-item>
...
...
app_BusinessCentral/src/widgets/list-lead/default-searchform/default-searchform-base.vue
浏览文件 @
7018448f
...
...
@@ -589,7 +589,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图搜索表单loadAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图搜索表单loadAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
@@ -626,7 +626,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
public
loadDraft
(
opt
:
any
=
{},
mode
?:
string
):
void
{
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图搜索表单loaddraftAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图搜索表单loaddraftAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
}
;
...
...
app_BusinessCentral/src/widgets/list-lead/main-grid/main-grid-base.vue
浏览文件 @
7018448f
...
...
@@ -665,7 +665,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
load
(
opt
:
any
=
{},
pageReset
:
boolean
=
false
):
void
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图表格fetchAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图表格fetchAction参数未配置'
});
return
;
}
if
(
pageReset
){
...
...
@@ -742,7 +742,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
async
remove
(
datas
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图表格removeAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图表格removeAction参数未配置'
});
return
;
}
let
_datas
:
any
[]
=
[];
...
...
@@ -848,7 +848,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
addBatch
(
arg
:
any
=
{}):
void
{
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图表格fetchAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图表格fetchAction参数未配置'
});
return
;
}
if
(
!
arg
){
...
...
@@ -1394,7 +1394,7 @@ export default class MainBase extends Vue implements ControlInterface {
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
)){
if
(
!
this
.
createAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图表格createAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图表格createAction参数未配置'
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
...
...
@@ -1402,7 +1402,7 @@ export default class MainBase extends Vue implements ControlInterface {
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
if
(
!
this
.
updateAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
GridView
视图表格updateAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLead
ByList
视图表格updateAction参数未配置'
});
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
if
(
item
.
listlead
){
...
...
app_BusinessCentral/src/widgets/list-lead/quick-create-by-list-form/quick-create-by-list-form-base.vue
0 → 100644
浏览文件 @
7018448f
<
template
>
<i-form
:model=
"this.data"
class=
'app-form'
ref=
'form'
id=
'listlead_quickcreatebylist'
style=
""
>
<input
style=
"display:none;"
/>
<row
>
<i-col
v-show=
"detailsModel.group1.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-group
layoutType=
"TABLE_24COL"
titleStyle=
""
class=
''
:uiActionGroup=
"detailsModel.group1.uiActionGroup"
@
groupuiactionclick=
"groupUIActionClick($event)"
:caption=
"$t('entities.listlead.quickcreatebylist_form.details.group1')"
:isShowCaption=
"false"
uiStyle=
"DEFAULT"
:titleBarCloseMode=
"0"
:isInfoGroupMode=
"false"
>
<row>
<i-col
v-show=
"detailsModel.entity2name.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-item
name=
'entity2name'
:itemRules=
"this.rules.entity2name"
class=
''
:caption=
"$t('entities.listlead.quickcreatebylist_form.details.entity2name')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.entity2name.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<app-picker
:formState=
"formState"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
:localContext =
'
{ }'
:localParam ='{ }'
:disabled="detailsModel.entity2name.disabled"
name='entity2name'
deMajorField='fullname'
deKeyField='lead'
:service="service"
:acParams="{ serviceName: 'LeadService', interfaceName: 'FetchDefault'}"
valueitem='entity2id'
:value="data.entity2name"
editortype=""
:pickupView="{ viewname: 'lead-pickup-view', title: $t('entities.lead.views.pickupview.title'), deResParameters: [{ pathName: 'campaigns', parameterName: 'campaign' }, ], parameters: [{ pathName: 'leads', parameterName: 'lead' }, { pathName: 'pickupview', parameterName: 'pickupview' } ], placement:'' }"
style=""
@formitemvaluechange="onFormItemValueChange">
</app-picker>
</app-form-item>
</i-col>
</row>
</app-form-group>
</i-col>
</row>
</i-form>
</
template
>
<
script
lang=
'tsx'
>
import
{
Vue
,
Component
,
Prop
,
Provide
,
Emit
,
Watch
,
Model
}
from
'vue-property-decorator'
;
import
{
CreateElement
}
from
'vue'
;
import
{
Subject
,
Subscription
}
from
'rxjs'
;
import
{
ControlInterface
}
from
'@/interface/control'
;
import
{
UIActionTool
,
Util
}
from
'@/utils'
;
import
ListLeadService
from
'@/service/list-lead/list-lead-service'
;
import
QuickCreateByListService
from
'./quick-create-by-list-form-service'
;
import
{
FormButtonModel
,
FormPageModel
,
FormItemModel
,
FormDRUIPartModel
,
FormPartModel
,
FormGroupPanelModel
,
FormIFrameModel
,
FormRowItemModel
,
FormTabPageModel
,
FormTabPanelModel
,
FormUserControlModel
}
from
'@/model/form-detail'
;
import
{
debounceTime
,
distinctUntilChanged
}
from
'rxjs/operators'
;
@
Component
({
components
:
{
}
})
export
default
class
QuickCreateByListBase
extends
Vue
implements
ControlInterface
{
/**
* 名称
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
name
?:
string
;
/**
* 视图通讯对象
*
* @type {Subject<ViewState>}
* @memberof QuickCreateByList
*/
@
Prop
()
public
viewState
!
:
Subject
<
ViewState
>
;
/**
* 应用上下文
*
* @type {*}
* @memberof QuickCreateByList
*/
@
Prop
()
public
context
:
any
;
/**
* 视图参数
*
* @type {*}
* @memberof QuickCreateByList
*/
@
Prop
()
public
viewparams
:
any
;
/**
* 视图状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof QuickCreateByList
*/
public
viewStateEvent
:
Subscription
|
undefined
;
/**
* 获取部件类型
*
* @returns {string}
* @memberof QuickCreateByList
*/
public
getControlType
():
string
{
return
'FORM'
}
/**
* 计数器服务对象集合
*
* @type {Array<*>}
* @memberof QuickCreateByList
*/
public
counterServiceArray
:
Array
<
any
>
=
[];
/**
* 建构部件服务对象
*
* @type {QuickCreateByListService}
* @memberof QuickCreateByList
*/
public
service
:
QuickCreateByListService
=
new
QuickCreateByListService
({
$store
:
this
.
$store
});
/**
* 实体服务对象
*
* @type {ListLeadService}
* @memberof QuickCreateByList
*/
public
appEntityService
:
ListLeadService
=
new
ListLeadService
({
$store
:
this
.
$store
});
/**
* 关闭视图
*
* @param {any} args
* @memberof QuickCreateByList
*/
public
closeView
(
args
:
any
):
void
{
let
_this
:
any
=
this
;
_this
.
$emit
(
'closeview'
,
[
args
]);
}
/**
* 计数器刷新
*
* @memberof QuickCreateByList
*/
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 QuickCreateByList
*/
public
srfwfmemo
:
string
=
""
;
/**
* 获取多项数据
*
* @returns {any[]}
* @memberof QuickCreateByList
*/
public
getDatas
():
any
[]
{
return
[
this
.
data
];
}
/**
* 获取单项树
*
* @returns {*}
* @memberof QuickCreateByList
*/
public
getData
():
any
{
return
this
.
data
;
}
/**
* 是否默认保存
*
* @type {boolean}
* @memberof QuickCreateByList
*/
@
Prop
({
default
:
false
})
public
autosave
?:
boolean
;
/**
* 显示处理提示
*
* @type {boolean}
* @memberof QuickCreateByList
*/
@
Prop
({
default
:
true
})
public
showBusyIndicator
?:
boolean
;
/**
* 部件行为--submit
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
WFSubmitAction
!
:
string
;
/**
* 部件行为--start
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
WFStartAction
!
:
string
;
/**
* 部件行为--update
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
updateAction
!
:
string
;
/**
* 部件行为--remove
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
removeAction
!
:
string
;
/**
* 部件行为--loaddraft
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
loaddraftAction
!
:
string
;
/**
* 部件行为--load
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
loadAction
!
:
string
;
/**
* 部件行为--create
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
createAction
!
:
string
;
/**
* 部件行为--create
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
searchAction
!
:
string
;
/**
* 视图标识
*
* @type {string}
* @memberof QuickCreateByList
*/
@
Prop
()
public
viewtag
!
:
string
;
/**
* 表单状态
*
* @type {Subject<any>}
* @memberof QuickCreateByList
*/
public
formState
:
Subject
<
any
>
=
new
Subject
();
/**
* 忽略表单项值变化
*
* @type {boolean}
* @memberof QuickCreateByList
*/
public
ignorefieldvaluechange
:
boolean
=
false
;
/**
* 数据变化
*
* @public
* @type {Subject<any>}
* @memberof QuickCreateByList
*/
public
dataChang
:
Subject
<
any
>
=
new
Subject
();
/**
* 视图状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof QuickCreateByList
*/
public
dataChangEvent
:
Subscription
|
undefined
;
/**
* 原始数据
*
* @public
* @type {*}
* @memberof QuickCreateByList
*/
public
oldData
:
any
=
{};
/**
* 表单数据对象
*
* @type {*}
* @memberof QuickCreateByList
*/
public
data
:
any
=
{
srfupdatedate
:
null
,
srforikey
:
null
,
srfkey
:
null
,
srfmajortext
:
null
,
srftempmode
:
null
,
srfuf
:
null
,
srfdeid
:
null
,
srfsourcekey
:
null
,
entity2name
:
null
,
entity2id
:
null
,
relationshipsid
:
null
,
listlead
:
null
,
};
/**
* 当前执行的行为逻辑
*
* @type {string}
* @memberof QuickCreateByList
*/
public
currentAction
:
string
=
""
;
/**
* 关系界面计数器
*
* @type {number}
* @memberof QuickCreateByList
*/
public
drcounter
:
number
=
0
;
/**
* 需要等待关系界面保存时,第一次调用save参数的备份
*
* @type {number}
* @memberof QuickCreateByList
*/
public
drsaveopt
:
any
=
{};
/**
* 表单保存回调存储对象
*
* @type {any}
* @memberof QuickCreateByList
*/
public
saveState
:
any
;
/**
* 属性值规则
*
* @type {*}
* @memberof QuickCreateByList
*/
public
rules
:
any
=
{
srfupdatedate
:
[
{
type
:
'string'
,
message
:
'更新时间 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
'更新时间 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
'更新时间 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
'更新时间 值不能为空'
,
trigger
:
'blur'
},
],
srforikey
:
[
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'blur'
},
],
srfkey
:
[
{
type
:
'string'
,
message
:
'关系标识 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
'关系标识 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
'关系标识 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
'关系标识 值不能为空'
,
trigger
:
'blur'
},
],
srfmajortext
:
[
{
type
:
'string'
,
message
:
'关系名称 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
'关系名称 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
'关系名称 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
'关系名称 值不能为空'
,
trigger
:
'blur'
},
],
srftempmode
:
[
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'blur'
},
],
srfuf
:
[
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'blur'
},
],
srfdeid
:
[
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'blur'
},
],
srfsourcekey
:
[
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
' 值不能为空'
,
trigger
:
'blur'
},
],
entity2name
:
[
{
type
:
'string'
,
message
:
'潜在顾客 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
'潜在顾客 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
'潜在顾客 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
'潜在顾客 值不能为空'
,
trigger
:
'blur'
},
],
entity2id
:
[
{
type
:
'string'
,
message
:
'潜在顾客 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
'潜在顾客 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
'潜在顾客 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
'潜在顾客 值不能为空'
,
trigger
:
'blur'
},
],
relationshipsid
:
[
{
type
:
'string'
,
message
:
'关系标识 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
'关系标识 值必须为字符串类型'
,
trigger
:
'blur'
},
{
required
:
false
,
type
:
'string'
,
message
:
'关系标识 值不能为空'
,
trigger
:
'change'
},
{
required
:
false
,
type
:
'string'
,
message
:
'关系标识 值不能为空'
,
trigger
:
'blur'
},
],
}
/**
* 详情模型集合
*
* @type {*}
* @memberof QuickCreateByList
*/
public
detailsModel
:
any
=
{
group1
:
new
FormGroupPanelModel
({
caption
:
'营销列表-潜在客户基本信息'
,
detailType
:
'GROUPPANEL'
,
name
:
'group1'
,
visible
:
true
,
isShowCaption
:
false
,
form
:
this
,
uiActionGroup
:
{
caption
:
''
,
langbase
:
'entities.listlead.quickcreatebylist_form'
,
extractMode
:
'ITEM'
,
details
:
[]
}
})
,
formpage1
:
new
FormPageModel
({
caption
:
'基本信息'
,
detailType
:
'FORMPAGE'
,
name
:
'formpage1'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
})
,
srfupdatedate
:
new
FormItemModel
({
caption
:
'更新时间'
,
detailType
:
'FORMITEM'
,
name
:
'srfupdatedate'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srforikey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srforikey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srfkey
:
new
FormItemModel
({
caption
:
'关系标识'
,
detailType
:
'FORMITEM'
,
name
:
'srfkey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srfmajortext
:
new
FormItemModel
({
caption
:
'关系名称'
,
detailType
:
'FORMITEM'
,
name
:
'srfmajortext'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srftempmode
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srftempmode'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srfuf
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfuf'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srfdeid
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfdeid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
srfsourcekey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfsourcekey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
entity2name
:
new
FormItemModel
({
caption
:
'潜在顾客'
,
detailType
:
'FORMITEM'
,
name
:
'entity2name'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
entity2id
:
new
FormItemModel
({
caption
:
'潜在顾客'
,
detailType
:
'FORMITEM'
,
name
:
'entity2id'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
relationshipsid
:
new
FormItemModel
({
caption
:
'关系标识'
,
detailType
:
'FORMITEM'
,
name
:
'relationshipsid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
disabled
:
false
,
enableCond
:
3
})
,
};
/**
* 监控表单属性 srfupdatedate 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srfupdatedate'
)
onSrfupdatedateChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfupdatedate'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srforikey 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srforikey'
)
onSrforikeyChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srforikey'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfkey 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srfkey'
)
onSrfkeyChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfkey'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfmajortext 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srfmajortext'
)
onSrfmajortextChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfmajortext'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srftempmode 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srftempmode'
)
onSrftempmodeChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srftempmode'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfuf 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srfuf'
)
onSrfufChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfuf'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfdeid 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srfdeid'
)
onSrfdeidChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfdeid'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 srfsourcekey 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.srfsourcekey'
)
onSrfsourcekeyChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'srfsourcekey'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 entity2name 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.entity2name'
)
onEntity2nameChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'entity2name'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 entity2id 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.entity2id'
)
onEntity2idChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'entity2id'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 监控表单属性 relationshipsid 值
*
* @param {*} newVal
* @param {*} oldVal
* @memberof QuickCreateByList
*/
@
Watch
(
'data.relationshipsid'
)
onRelationshipsidChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
formDataChange
({
name
:
'relationshipsid'
,
newVal
:
newVal
,
oldVal
:
oldVal
});
}
/**
* 重置表单项值
*
* @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof QuickCreateByList
*/
public
resetFormData
({
name
,
newVal
,
oldVal
}:
{
name
:
string
,
newVal
:
any
,
oldVal
:
any
}):
void
{
}
/**
* 置空对象
*
* @param {any[]} args
* @memberof EditForm
*/
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 QuickCreateByList
*/
public
formLogic
({
name
,
newVal
,
oldVal
}:
{
name
:
string
,
newVal
:
any
,
oldVal
:
any
}):
void
{
}
/**
* 表单值变化
*
* @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @returns {void}
* @memberof QuickCreateByList
*/
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 QuickCreateByList
*/
public
onFormLoad
(
data
:
any
=
{},
action
:
string
):
void
{
if
(
Object
.
is
(
action
,
"save"
)
||
Object
.
is
(
action
,
"autoSave"
)
||
Object
.
is
(
action
,
"submit"
))
// 更新context的实体主键
if
(
data
.
listlead
){
Object
.
assign
(
this
.
context
,{
listlead
:
data
.
listlead
})
}
this
.
setFormEnableCond
(
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 QuickCreateByList
*/
public
fillForm
(
_datas
:
any
=
{},
action
:
string
):
void
{
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 QuickCreateByList
*/
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 QuickCreateByList
*/
public
resetDraftFormStates
():
void
{
const
form
:
any
=
this
.
$refs
.
form
;
if
(
form
)
{
form
.
resetFields
();
}
}
/**
* 重置校验结果
*
* @memberof QuickCreateByList
*/
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 QuickCreateByList
*/
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 QuickCreateByList
*/
public
formValidateStatus
():
boolean
{
const
form
:
any
=
this
.
$refs
.
form
;
let
validatestate
:
boolean
=
true
;
form
.
validate
((
valid
:
boolean
)
=>
{
validatestate
=
valid
?
true
:
false
;
});
return
validatestate
}
/**
* 获取全部值
*
* @returns {*}
* @memberof QuickCreateByList
*/
public
getValues
():
any
{
return
this
.
data
;
}
/**
* 表单项值变更
*
* @param {{ name: string, value: any }} $event
* @returns {void}
* @memberof QuickCreateByList
*/
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 {string} name
* @param {*} value
* @returns {void}
* @memberof QuickCreateByList
*/
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 {*} $event
* @memberof QuickCreateByList
*/
public
groupUIActionClick
(
$event
:
any
):
void
{
if
(
!
$event
)
{
return
;
}
const
item
:
any
=
$event
.
item
;
}
/**
* Vue声明周期(处理组件的输入属性)
*
* @memberof QuickCreateByList
*/
public
created
():
void
{
this
.
afterCreated
();
}
/**
* 执行created后的逻辑
*
* @memberof QuickCreateByList
*/
public
afterCreated
(){
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
))
{
if
(
this
.
context
.
srfsourcekey
){
this
.
copy
(
this
.
context
.
srfsourcekey
);
}
else
{
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
);
}
});
}
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 QuickCreateByList
*/
public
destroyed
()
{
this
.
afterDestroy
();
}
/**
* 执行destroyed后的逻辑
*
* @memberof QuickCreateByList
*/
public
afterDestroy
()
{
if
(
this
.
viewStateEvent
)
{
this
.
viewStateEvent
.
unsubscribe
();
}
if
(
this
.
dataChangEvent
)
{
this
.
dataChangEvent
.
unsubscribe
();
}
}
/**
* 拷贝内容
*
* @param {*} [arg={}]
* @memberof @memberof QuickCreateByList
*/
public
copy
(
srfkey
:
string
):
void
{
let
copyData
=
this
.
$store
.
getters
.
getCopyData
(
srfkey
);
copyData
.
srfkey
=
Util
.
createUUID
();
copyData
.
listlead
=
copyData
.
srfkey
;
copyData
.
relationshipsid
=
copyData
.
srfkey
;
Object
.
assign
(
this
.
context
,{
listlead
:
copyData
.
listlead
})
this
.
data
=
copyData
;
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'load'
,
data
:
copyData
});
this
.
data
.
srfuf
=
'0'
;
this
.
setFormEnableCond
(
this
.
data
);
});
}
/**
*打印
*@memberof @memberof QuickCreateByList
*/
public
print
(){
let
_this
:
any
=
this
;
_this
.
$print
({
id
:
'listlead_quickcreatebylist'
,
popTitle
:
'快速新建(根据营销列表)'
});
}
/**
* 部件刷新
*
* @param {any[]} args
* @memberof QuickCreateByList
*/
public
refresh
(
args
:
any
[]):
void
{
let
arg
:
any
=
{};
Object
.
assign
(
arg
,
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 QuickCreateByList
*/
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 QuickCreateByList
*/
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLeadQuickCreateByList视图表单loadAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
};
let
viewparamResult
:
any
=
Object
.
assign
(
arg
,
this
.
viewparams
);
const
get
:
Promise
<
any
>
=
this
.
service
.
get
(
this
.
loadAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),{
viewparams
:
viewparamResult
},
this
.
showBusyIndicator
);
get
.
then
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
===
200
)
{
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
'load'
);
this
.
$emit
(
'load'
,
data
);
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'load'
,
data
:
data
});
});
}
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
return
;
}
});
}
/**
* 加载草稿
*
* @param {*} [opt={}]
* @memberof QuickCreateByList
*/
public
loadDraft
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLeadQuickCreateByList视图表单loaddraftAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
}
;
let
viewparamResult
:
any
=
Object
.
assign
(
arg
,
this
.
viewparams
);
let
post
:
Promise
<
any
>
=
this
.
service
.
loadDraft
(
this
.
loaddraftAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),{
viewparams
:
viewparamResult
},
this
.
showBusyIndicator
);
post
.
then
((
response
:
any
)
=>
{
if
(
!
response
.
status
||
response
.
status
!==
200
)
{
if
(
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
}
return
;
}
const
data
=
response
.
data
;
if
(
data
.
listlead
){
Object
.
assign
(
this
.
context
,{
listlead
:
data
.
listlead
})
}
this
.
resetDraftFormStates
();
this
.
onFormLoad
(
data
,
'loadDraft'
);
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
;
});
}
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
return
;
}
});
}
/**
* 自动保存
*
* @param {*} [opt={}]
* @memberof QuickCreateByList
*/
public
autoSave
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
formValidateStatus
())
{
return
;
}
const
arg
:
any
=
{
...
opt
};
const
data
=
this
.
getValues
();
Object
.
assign
(
arg
,
data
);
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
:
'错误'
,
desc
:
'ListLeadQuickCreateByList视图表单'
+
actionName
+
'参数未配置'
});
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
:
'错误'
,
desc
:
response
.
data
.
message
});
}
return
;
}
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
'autoSave'
);
this
.
$emit
(
'save'
,
data
);
this
.
$store
.
dispatch
(
'viewaction/datasaved'
,
{
viewtag
:
this
.
viewtag
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
data
});
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
return
;
}
});
}
/**
* 保存
*
* @param {*} [opt={}]
* @param {boolean} [showResultInfo]
* @param {boolean} [ifStateNext] formState是否下发通知
* @returns {Promise<any>}
* @memberof QuickCreateByList
*/
public
async
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
())
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'值规则校验异常'
});
return
;
}
const
arg
:
any
=
{
...
opt
};
const
data
=
this
.
getValues
();
Object
.
assign
(
arg
,
data
);
Object
.
assign
(
arg
,
this
.
context
);
if
(
ifStateNext
)
{
this
.
drcounter
=
0
;
if
(
this
.
drcounter
!==
0
){
this
.
drsaveopt
=
opt
;
this
.
formState
.
next
({
type
:
'beforesave'
,
data
:
arg
});
//先通知关系界面保存
this
.
saveState
=
resolve
;
return
;
}
}
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
:
'错误'
,
desc
:
'ListLeadQuickCreateByList视图表单'
+
actionName
+
'参数未配置'
});
return
;
}
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
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
)
{
if
(
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
}
return
;
}
const
data
=
response
.
data
;
this
.
onFormLoad
(
data
,
'save'
);
this
.
$emit
(
'save'
,
data
);
this
.
$store
.
dispatch
(
'viewaction/datasaved'
,
{
viewtag
:
this
.
viewtag
});
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
data
});
});
if
(
showResultInfo
)
{
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
data
.
srfmajortext
?
data
.
srfmajortext
:
''
)
+
' 保存成功!'
});
}
resolve
(
response
);
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
reject
(
response
);
return
;
}
reject
(
response
);
});
})
}
/**
* 删除
*
* @public
* @param {*} [opt={}]
* @memberof EditForm
*/
public
remove
(
opt
:
Array
<
any
>
=
[],
showResultInfo
?:
boolean
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'ListLeadQuickCreateByList视图表单removeAction参数未配置'
});
return
;
}
const
arg
:
any
=
opt
[
0
];
const
_this
:
any
=
this
;
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
this
.
service
.
delete
(
_this
.
removeAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
showResultInfo
).
then
((
response
:
any
)
=>
{
if
(
response
)
{
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
:
''
)
+
' 删除成功!'
});
resolve
(
response
);
}
}).
catch
((
error
:
any
)
=>
{
const
{
data
:
_data
}
=
error
;
this
.
$Notice
.
error
({
title
:
_data
.
title
,
desc
:
_data
.
message
});
reject
(
error
);
});
});
}
/**
* 工作流启动
*
* @param {*} [data={}]
* @param {*} [localdata={}]
* @returns {Promise<any>}
* @memberof QuickCreateByList
*/
public
async
wfstart
(
data
:
any
,
localdata
?:
any
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_this
:
any
=
this
;
const
post
:
Promise
<
any
>
=
_this
.
save
({},
false
);
post
.
then
((
response
:
any
)
=>
{
const
arg
:
any
=
response
.
data
;
if
(
this
.
viewparams
){
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
}
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
:
'工作流启动失败, '
+
response
.
data
.
message
});
}
return
;
}
this
.
$Notice
.
info
({
title
:
''
,
desc
:
'工作流启动成功'
});
resolve
(
response
);
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
reject
(
response
);
return
;
}
reject
(
response
);
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
reject
(
response
);
return
;
}
reject
(
response
);
})
});
}
/**
* 工作流提交
*
* @param {*} [data={}]
* @param {*} [localdata={}]
* @returns {Promise<any>}
* @memberof QuickCreateByList
*/
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
];
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
if
(
!
arg
.
listlead
||
Object
.
is
(
arg
.
listlead
,
''
))
{
return
;
}
const
post
:
Promise
<
any
>
=
Object
.
is
(
arg
.
srfuf
,
'1'
)?
this
.
service
.
update
(
this
.
updateAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
):
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
arg
,
this
.
showBusyIndicator
);
post
.
then
((
response
:
any
)
=>
{
const
arg
:
any
=
response
.
data
;
// 保存完成UI处理
this
.
onFormLoad
(
arg
,
'save'
);
this
.
$emit
(
'save'
,
arg
);
this
.
$nextTick
(()
=>
{
this
.
formState
.
next
({
type
:
'save'
,
data
:
arg
});
});
// 准备提交参数
if
(
this
.
viewparams
){
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
}
// 强制补充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
:
'工作流提交失败, '
+
response
.
data
.
message
});
}
return
;
}
this
.
onFormLoad
(
arg
,
'submit'
);
this
.
$store
.
dispatch
(
'viewaction/datasaved'
,
{
viewtag
:
this
.
viewtag
});
this
.
$Notice
.
info
({
title
:
''
,
desc
:
'工作流提交成功'
});
resolve
(
response
);
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
reject
(
response
);
return
;
}
reject
(
response
);
});
}).
catch
((
response
:
any
)
=>
{
if
(
response
&&
response
.
status
&&
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
response
.
data
.
message
});
reject
(
response
);
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
reject
(
response
);
return
;
}
reject
(
response
);
})
})
}
/**
* 表单项更新
*
* @param {string} mode 界面行为名称
* @param {*} [data={}] 请求数据
* @param {string[]} updateDetails 更新项
* @param {boolean} [showloading] 是否显示加载状态
* @returns {void}
* @memberof QuickCreateByList
*/
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
:
'错误'
,
desc
:
'表单项更新失败'
});
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
));
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
:
'错误'
,
desc
:
response
.
data
.
message
});
return
;
}
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'系统异常'
});
return
;
}
});
}
/**
* 回车事件
*
* @param {*} $event
* @memberof QuickCreateByList
*/
public
onEnter
(
$event
:
any
):
void
{
}
/**
* 保存并退出
*
* @param {any[]} args
* @memberof QuickCreateByList
*/
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 QuickCreateByList
*/
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 QuickCreateByList
*/
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 QuickCreateByList
*/
public
drdatasaved
(
$event
:
any
){
let
_this
=
this
;
this
.
drcounter
--
;
if
(
this
.
drcounter
>
0
){
return
;
}
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 QuickCreateByList
*/
public
createDefault
(){
}
/**
* 更新默认值
* @memberof QuickCreateByList
*/
public
updateDefault
(){
}
}
</
script
>
<
style
lang=
'less'
>
@import './quick-create-by-list-form.less';
</
style
>
\ No newline at end of file
app_BusinessCentral/src/widgets/list-lead/quick-create-by-list-form/quick-create-by-list-form-model.ts
0 → 100644
浏览文件 @
7018448f
/**
* QuickCreateByList 部件模型
*
* @export
* @class QuickCreateByListModel
*/
export
default
class
QuickCreateByListModel
{
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof QuickCreateByListModel
*/
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
:
'relationshipsid'
,
dataType
:
'GUID'
,
},
{
name
:
'srfmajortext'
,
prop
:
'relationshipsname'
,
dataType
:
'TEXT'
,
},
{
name
:
'srftempmode'
,
},
{
name
:
'srfuf'
,
},
{
name
:
'srfdeid'
,
},
{
name
:
'srfsourcekey'
,
},
{
name
:
'entity2name'
,
prop
:
'entity2name'
,
dataType
:
'PICKUPTEXT'
,
},
{
name
:
'entity2id'
,
prop
:
'entity2id'
,
dataType
:
'PICKUP'
,
},
{
name
:
'relationshipsid'
,
prop
:
'relationshipsid'
,
dataType
:
'GUID'
,
},
{
name
:
'listlead'
,
prop
:
'relationshipsid'
,
dataType
:
'FONTKEY'
,
},
]
}
}
\ No newline at end of file
app_BusinessCentral/src/widgets/list-lead/quick-create-by-list-form/quick-create-by-list-form-service.ts
0 → 100644
浏览文件 @
7018448f
import
{
Http
,
Util
,
Errorlog
}
from
'@/utils'
;
import
ControlService
from
'@/widgets/control-service'
;
import
ListLeadService
from
'@/service/list-lead/list-lead-service'
;
import
QuickCreateByListModel
from
'./quick-create-by-list-form-model'
;
import
LeadService
from
'@/service/lead/lead-service'
;
/**
* QuickCreateByList 部件服务对象
*
* @export
* @class QuickCreateByListService
*/
export
default
class
QuickCreateByListService
extends
ControlService
{
/**
* 营销列表-潜在客户服务对象
*
* @type {ListLeadService}
* @memberof QuickCreateByListService
*/
public
appEntityService
:
ListLeadService
=
new
ListLeadService
({
$store
:
this
.
getStore
()
});
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof QuickCreateByListService
*/
public
setTempMode
(){
this
.
isTempMode
=
false
;
}
/**
* Creates an instance of QuickCreateByListService.
*
* @param {*} [opts={}]
* @memberof QuickCreateByListService
*/
constructor
(
opts
:
any
=
{})
{
super
(
opts
);
this
.
model
=
new
QuickCreateByListModel
();
}
/**
* 潜在顾客服务对象
*
* @type {LeadService}
* @memberof QuickCreateByListService
*/
public
leadService
:
LeadService
=
new
LeadService
();
/**
* 处理数据
*
* @private
* @param {Promise<any>} promise
* @returns {Promise<any>}
* @memberof QuickCreateByListService
*/
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 QuickCreateByListService
*/
@
Errorlog
public
getItems
(
serviceName
:
string
,
interfaceName
:
string
,
context
:
any
=
{},
data
:
any
,
isloading
?:
boolean
):
Promise
<
any
[]
>
{
if
(
Object
.
is
(
serviceName
,
'LeadService'
)
&&
Object
.
is
(
interfaceName
,
'FetchDefault'
))
{
return
this
.
doItems
(
this
.
leadService
.
FetchDefault
(
JSON
.
parse
(
JSON
.
stringify
(
context
)),
data
,
isloading
),
'leadid'
,
'lead'
);
}
return
Promise
.
reject
([])
}
/**
* 启动工作流
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {*} [localdata]
* @returns {Promise<any>}
* @memberof QuickCreateByListService
*/
@
Errorlog
public
wfstart
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
localdata
?:
any
):
Promise
<
any
>
{
data
=
this
.
handleWFData
(
data
);
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 QuickCreateByListService
*/
@
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
).
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]
* @returns {Promise<any>}
* @memberof QuickCreateByListService
*/
@
Errorlog
public
add
(
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
.
Create
(
Context
,
Data
,
isloading
);
}
result
.
then
((
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 QuickCreateByListService
*/
@
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]
* @returns {Promise<any>}
* @memberof QuickCreateByListService
*/
@
Errorlog
public
update
(
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
.
Update
(
Context
,
Data
,
isloading
);
}
result
.
then
((
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 QuickCreateByListService
*/
@
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
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 加载草稿
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof QuickCreateByListService
*/
@
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
.
relationshipsid
=
PrimaryKey
;
Data
.
listlead
=
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
)
=>
{
response
.
data
.
relationshipsid
=
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 QuickCreateByListService
*/
@
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 QuickCreateByListService
*/
public
handleRequestData
(
action
:
string
,
context
:
any
,
data
:
any
=
{}){
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
let
requestData
:
any
=
{};
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
];
}
}
});
if
(
data
&&
data
.
viewparams
){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
if
(
tempContext
&&
tempContext
.
srfsessionid
){
tempContext
.
srfsessionkey
=
tempContext
.
srfsessionid
;
delete
tempContext
.
srfsessionid
;
}
return
{
context
:
tempContext
,
data
:
requestData
};
}
}
\ No newline at end of file
app_BusinessCentral/src/widgets/list-lead/quick-create-by-list-form/quick-create-by-list-form.less
0 → 100644
浏览文件 @
7018448f
.form {
--form: 0px;
}
// this is less
app_BusinessCentral/src/widgets/list-lead/quick-create-by-list-form/quick-create-by-list-form.vue
0 → 100644
浏览文件 @
7018448f
<
script
lang=
'tsx'
>
import
{
Component
}
from
'vue-property-decorator'
;
import
QuickCreateByListBase
from
'./quick-create-by-list-form-base.vue'
;
@
Component
({
components
:
{
}
})
export
default
class
QuickCreateByList
extends
QuickCreateByListBase
{
}
</
script
>
\ No newline at end of file
businesscentral-core/src/main/resources/liquibase/h2_table.xml
浏览文件 @
7018448f
...
...
@@ -3182,7 +3182,7 @@
<!--输出实体[CONTACT]数据结构 -->
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"tab-contact-1
34
-43"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"tab-contact-1
40
-43"
>
<createTable
tableName=
"CONTACT"
>
<column
name=
"ADDRESS1_FREIGHTTERMSCODE"
remarks=
""
type=
"VARCHAR(30)"
>
</column>
...
...
@@ -9836,7 +9836,7 @@
<!--输出实体[LIST]数据结构 -->
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"tab-list-3
0
-110"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"tab-list-3
6
-110"
>
<createTable
tableName=
"LIST"
>
<column
name=
"OWNERIDTYPE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
...
...
@@ -11021,22 +11021,22 @@
<addForeignKeyConstraint
baseColumnNames=
"TRANSACTIONCURRENCYID"
baseTableName=
"MONTHLYFISCALCALENDAR"
constraintName=
"DER1N_MONTHLYFISCALCALENDAR__T"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"TRANSACTIONCURRENCYID"
referencedTableName=
"TRANSACTIONCURRENCY"
validate=
"true"
/>
</changeSet>
<!--输出实体[CONTACT]外键关系 -->
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
34
-212"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
40
-212"
>
<addForeignKeyConstraint
baseColumnNames=
"PREFERREDEQUIPMENTID"
baseTableName=
"CONTACT"
constraintName=
"DER1N_CONTACT__EQUIPMENT__PREF"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"EQUIPMENTID"
referencedTableName=
"EQUIPMENT"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
34
-213"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
40
-213"
>
<addForeignKeyConstraint
baseColumnNames=
"ORIGINATINGLEADID"
baseTableName=
"CONTACT"
constraintName=
"DER1N_CONTACT__LEAD__ORIGINATI"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"LEADID"
referencedTableName=
"LEAD"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
34
-214"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
40
-214"
>
<addForeignKeyConstraint
baseColumnNames=
"DEFAULTPRICELEVELID"
baseTableName=
"CONTACT"
constraintName=
"DER1N_CONTACT__PRICELEVEL__DEF"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"PRICELEVELID"
referencedTableName=
"PRICELEVEL"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
34
-215"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
40
-215"
>
<addForeignKeyConstraint
baseColumnNames=
"PREFERREDSERVICEID"
baseTableName=
"CONTACT"
constraintName=
"DER1N_CONTACT__SERVICE__PREFER"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"SERVICEID"
referencedTableName=
"SERVICE"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
34
-216"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
40
-216"
>
<addForeignKeyConstraint
baseColumnNames=
"SLAID"
baseTableName=
"CONTACT"
constraintName=
"DER1N_CONTACT__SLA__SLAID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"SLAID"
referencedTableName=
"SLA"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
34
-217"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-contact-1
40
-217"
>
<addForeignKeyConstraint
baseColumnNames=
"TRANSACTIONCURRENCYID"
baseTableName=
"CONTACT"
constraintName=
"DER1N_CONTACT__TRANSACTIONCURR"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"TRANSACTIONCURRENCYID"
referencedTableName=
"TRANSACTIONCURRENCY"
validate=
"true"
/>
</changeSet>
<!--输出实体[TEAM]外键关系 -->
...
...
@@ -11565,7 +11565,7 @@
<!--输出实体[POST]外键关系 -->
<!--输出实体[CONTRACTTEMPLATE]外键关系 -->
<!--输出实体[LIST]外键关系 -->
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-list-3
0
-393"
>
<changeSet
author=
"a_LAB01_e85d8801c"
id=
"fk-list-3
6
-393"
>
<addForeignKeyConstraint
baseColumnNames=
"TRANSACTIONCURRENCYID"
baseTableName=
"LIST"
constraintName=
"DER1N_LIST__TRANSACTIONCURRENC"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"TRANSACTIONCURRENCYID"
referencedTableName=
"TRANSACTIONCURRENCY"
validate=
"true"
/>
</changeSet>
<!--输出实体[KNOWLEDGEBASERECORD]外键关系 -->
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录