Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
iBiz企业中心
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
iBiz企业套件
iBiz企业中心
提交
2082a1ad
提交
2082a1ad
编写于
7月 12, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
lab_gzf 发布系统代码
上级
ab507142
变更
23
显示空白字符变更
内嵌
并排
正在显示
23 个修改的文件
包含
1982 行增加
和
11 行删除
+1982
-11
ibiz-list_en_US.ts
...M/src/locale/lanres/entities/ibiz-list/ibiz-list_en_US.ts
+45
-0
ibiz-list_zh_CN.ts
...M/src/locale/lanres/entities/ibiz-list/ibiz-list_zh_CN.ts
+45
-0
page-register.ts
app_CRM/src/pages/base/central/page-register.ts
+2
-1
router.ts
app_CRM/src/pages/base/central/router.ts
+24
-10
ibiz-list-edit-data-panel-view-base.tsx
...t-data-panel-view/ibiz-list-edit-data-panel-view-base.tsx
+165
-0
ibiz-list-edit-data-panel-view.html
...-edit-data-panel-view/ibiz-list-edit-data-panel-view.html
+24
-0
ibiz-list-edit-data-panel-view.vue
...t-edit-data-panel-view/ibiz-list-edit-data-panel-view.vue
+22
-0
ibiz-list-info-base.tsx
...rc/pages/marketing/ibiz-list-info/ibiz-list-info-base.tsx
+157
-0
ibiz-list-info.html
...RM/src/pages/marketing/ibiz-list-info/ibiz-list-info.html
+23
-0
ibiz-list-info.vue
...CRM/src/pages/marketing/ibiz-list-info/ibiz-list-info.vue
+2
-0
state.ts
app_CRM/src/store/modules/view-action/state.ts
+10
-0
ibiz-list-ui-service-base.ts
app_CRM/src/uiservice/ibiz-list/ibiz-list-ui-service-base.ts
+63
-0
data-panel-form-base.tsx
...idgets/ibiz-list/data-panel-form/data-panel-form-base.tsx
+171
-0
data-panel-form-model.ts
...idgets/ibiz-list/data-panel-form/data-panel-form-model.ts
+86
-0
data-panel-form-service.ts
...gets/ibiz-list/data-panel-form/data-panel-form-service.ts
+371
-0
data-panel-form.html
...rc/widgets/ibiz-list/data-panel-form/data-panel-form.html
+55
-0
data-panel-form.less
...rc/widgets/ibiz-list/data-panel-form/data-panel-form.less
+32
-0
data-panel-form.vue
...src/widgets/ibiz-list/data-panel-form/data-panel-form.vue
+25
-0
edit-data-panel-form-base.tsx
...z-list/edit-data-panel-form/edit-data-panel-form-base.tsx
+133
-0
edit-data-panel-form-model.ts
...z-list/edit-data-panel-form/edit-data-panel-form-model.ts
+86
-0
edit-data-panel-form-service.ts
...list/edit-data-panel-form/edit-data-panel-form-service.ts
+371
-0
edit-data-panel-form.html
.../ibiz-list/edit-data-panel-form/edit-data-panel-form.html
+48
-0
edit-data-panel-form.vue
...s/ibiz-list/edit-data-panel-form/edit-data-panel-form.vue
+22
-0
未找到文件。
app_CRM/src/locale/lanres/entities/ibiz-list/ibiz-list_en_US.ts
浏览文件 @
2082a1ad
...
...
@@ -194,6 +194,29 @@ export default {
uiactions
:
{
},
},
datapanel_form
:
{
details
:
{
button1
:
"头信息编辑"
,
grouppanel1
:
"分组面板"
,
group1
:
"市场营销列表基本信息"
,
formpage1
:
"基本信息"
,
srfupdatedate
:
"更新时间"
,
srforikey
:
""
,
srfkey
:
"列表"
,
srfmajortext
:
"名称"
,
srftempmode
:
""
,
srfuf
:
""
,
srfdeid
:
""
,
srfsourcekey
:
""
,
lockstatus
:
"已锁定"
,
lastusedon
:
"上次使用时间"
,
ownername
:
"负责人"
,
listid
:
"列表"
,
},
uiactions
:
{
ibizlist_openedit_datapanel
:
"头信息编辑"
,
},
},
main_form
:
{
details
:
{
group1
:
"list基本信息"
,
...
...
@@ -236,6 +259,28 @@ export default {
uiactions
:
{
},
},
infotoolbar_toolbar
:
{
tbitem17_active
:
{
caption
:
"激活"
,
tip
:
"激活"
,
},
tbitem17_stop_sep
:
{
caption
:
""
,
tip
:
""
,
},
tbitem17_stop
:
{
caption
:
"停用"
,
tip
:
"停用"
,
},
tbitem2
:
{
caption
:
"-"
,
tip
:
""
,
},
tbitem12
:
{
caption
:
"关闭"
,
tip
:
"关闭"
,
},
},
gridviewtoolbar_toolbar
:
{
tbitem1_quickcreate
:
{
caption
:
"新建"
,
...
...
app_CRM/src/locale/lanres/entities/ibiz-list/ibiz-list_zh_CN.ts
浏览文件 @
2082a1ad
...
...
@@ -193,6 +193,29 @@ export default {
uiactions
:
{
},
},
datapanel_form
:
{
details
:
{
button1
:
"头信息编辑"
,
grouppanel1
:
"分组面板"
,
group1
:
"市场营销列表基本信息"
,
formpage1
:
"基本信息"
,
srfupdatedate
:
"更新时间"
,
srforikey
:
""
,
srfkey
:
"列表"
,
srfmajortext
:
"名称"
,
srftempmode
:
""
,
srfuf
:
""
,
srfdeid
:
""
,
srfsourcekey
:
""
,
lockstatus
:
"已锁定"
,
lastusedon
:
"上次使用时间"
,
ownername
:
"负责人"
,
listid
:
"列表"
,
},
uiactions
:
{
ibizlist_openedit_datapanel
:
"头信息编辑"
,
},
},
main_form
:
{
details
:
{
group1
:
"list基本信息"
,
...
...
@@ -235,6 +258,28 @@ export default {
uiactions
:
{
},
},
infotoolbar_toolbar
:
{
tbitem17_active
:
{
caption
:
"激活"
,
tip
:
"激活"
,
},
tbitem17_stop_sep
:
{
caption
:
""
,
tip
:
""
,
},
tbitem17_stop
:
{
caption
:
"停用"
,
tip
:
"停用"
,
},
tbitem2
:
{
caption
:
"-"
,
tip
:
""
,
},
tbitem12
:
{
caption
:
"关闭"
,
tip
:
"关闭"
,
},
},
gridviewtoolbar_toolbar
:
{
tbitem1_quickcreate
:
{
caption
:
"新建"
,
...
...
app_CRM/src/pages/base/central/page-register.ts
浏览文件 @
2082a1ad
...
...
@@ -5,6 +5,7 @@ export const PageComponents = {
Vue
.
component
(
'goal-child-goal-grid-view'
,
()
=>
import
(
'@pages/sales/goal-child-goal-grid-view/goal-child-goal-grid-view.vue'
));
Vue
.
component
(
'invoice-info-invoice-view'
,
()
=>
import
(
'@pages/finance/invoice-info-invoice-view/invoice-info-invoice-view.vue'
));
Vue
.
component
(
'competitor-option-view'
,
()
=>
import
(
'@pages/sales/competitor-option-view/competitor-option-view.vue'
));
Vue
.
component
(
'ibiz-list-edit-data-panel-view'
,
()
=>
import
(
'@pages/marketing/ibiz-list-edit-data-panel-view/ibiz-list-edit-data-panel-view.vue'
));
Vue
.
component
(
'account-edit-view'
,
()
=>
import
(
'@pages/base/account-edit-view/account-edit-view.vue'
));
Vue
.
component
(
'product-sales-literature-sal-lit-pro-grid-view'
,
()
=>
import
(
'@pages/sales/product-sales-literature-sal-lit-pro-grid-view/product-sales-literature-sal-lit-pro-grid-view.vue'
));
Vue
.
component
(
'incident-child-incident-grid-view'
,
()
=>
import
(
'@pages/service/incident-child-incident-grid-view/incident-child-incident-grid-view.vue'
));
...
...
@@ -183,8 +184,8 @@ export const PageComponents = {
Vue
.
component
(
'product-association-grid-view'
,
()
=>
import
(
'@pages/product/product-association-grid-view/product-association-grid-view.vue'
));
Vue
.
component
(
'transaction-currency-grid-view'
,
()
=>
import
(
'@pages/base/transaction-currency-grid-view/transaction-currency-grid-view.vue'
));
Vue
.
component
(
'appointment-quick-create'
,
()
=>
import
(
'@pages/base/appointment-quick-create/appointment-quick-create.vue'
));
Vue
.
component
(
'account-by-parent-key'
,
()
=>
import
(
'@pages/base/account-by-parent-key/account-by-parent-key.vue'
));
Vue
.
component
(
'incident-customer-pickup-grid-view'
,
()
=>
import
(
'@pages/service/incident-customer-pickup-grid-view/incident-customer-pickup-grid-view.vue'
));
Vue
.
component
(
'account-by-parent-key'
,
()
=>
import
(
'@pages/base/account-by-parent-key/account-by-parent-key.vue'
));
Vue
.
component
(
'campaign-response-edit-view'
,
()
=>
import
(
'@pages/marketing/campaign-response-edit-view/campaign-response-edit-view.vue'
));
Vue
.
component
(
'campaign-info'
,
()
=>
import
(
'@pages/marketing/campaign-info/campaign-info.vue'
));
Vue
.
component
(
'product-summary-view'
,
()
=>
import
(
'@pages/product/product-summary-view/product-summary-view.vue'
));
...
...
app_CRM/src/pages/base/central/router.ts
浏览文件 @
2082a1ad
...
...
@@ -284,6 +284,20 @@ const router = new Router({
},
component
:
()
=>
import
(
'@pages/sales/competitor-option-view/competitor-option-view.vue'
),
},
{
path
:
'ibizlists/:ibizlist?/edit_datapanelview/:edit_datapanelview?'
,
meta
:
{
caption
:
'entities.ibizlist.views.edit_datapanelview.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
{
pathName
:
'edit_datapanelview'
,
parameterName
:
'edit_datapanelview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/marketing/ibiz-list-edit-data-panel-view/ibiz-list-edit-data-panel-view.vue'
),
},
{
path
:
'accounts/:account?/editview/:editview?'
,
meta
:
{
...
...
@@ -7816,32 +7830,32 @@ const router = new Router({
component
:
()
=>
import
(
'@pages/base/appointment-quick-create/appointment-quick-create.vue'
),
},
{
path
:
'
accounts/:account?/byparentkey/:byparentkey
?'
,
path
:
'
incidentcustomers/:incidentcustomer?/pickupgridview/:pickupgridview
?'
,
meta
:
{
caption
:
'entities.
account.views.byparentkey
.title'
,
caption
:
'entities.
incidentcustomer.views.pickupgridview
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'
accounts'
,
parameterName
:
'account
'
},
{
pathName
:
'
byparentkey'
,
parameterName
:
'byparentkey
'
},
{
pathName
:
'
incidentcustomers'
,
parameterName
:
'incidentcustomer
'
},
{
pathName
:
'
pickupgridview'
,
parameterName
:
'pickupgridview
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
base/account-by-parent-key/account-by-parent-key
.vue'
),
component
:
()
=>
import
(
'@pages/
service/incident-customer-pickup-grid-view/incident-customer-pickup-grid-view
.vue'
),
},
{
path
:
'
incidentcustomers/:incidentcustomer?/pickupgridview/:pickupgridview
?'
,
path
:
'
accounts/:account?/byparentkey/:byparentkey
?'
,
meta
:
{
caption
:
'entities.
incidentcustomer.views.pickupgridview
.title'
,
caption
:
'entities.
account.views.byparentkey
.title'
,
info
:
''
,
parameters
:
[
{
pathName
:
'central'
,
parameterName
:
'central'
},
{
pathName
:
'
incidentcustomers'
,
parameterName
:
'incidentcustomer
'
},
{
pathName
:
'
pickupgridview'
,
parameterName
:
'pickupgridview
'
},
{
pathName
:
'
accounts'
,
parameterName
:
'account
'
},
{
pathName
:
'
byparentkey'
,
parameterName
:
'byparentkey
'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/
service/incident-customer-pickup-grid-view/incident-customer-pickup-grid-view
.vue'
),
component
:
()
=>
import
(
'@pages/
base/account-by-parent-key/account-by-parent-key
.vue'
),
},
{
path
:
'campaignresponses/:campaignresponse?/editview/:editview?'
,
...
...
app_CRM/src/pages/marketing/ibiz-list-edit-data-panel-view/ibiz-list-edit-data-panel-view-base.tsx
0 → 100644
浏览文件 @
2082a1ad
import
{
Subject
}
from
'rxjs'
;
import
{
EditViewBase
}
from
'@/studio-core'
;
import
IBizListService
from
'@/service/ibiz-list/ibiz-list-service'
;
import
IBizListAuthService
from
'@/authservice/ibiz-list/ibiz-list-auth-service'
;
import
EditViewEngine
from
'@engine/view/edit-view-engine'
;
import
IBizListUIService
from
'@/uiservice/ibiz-list/ibiz-list-ui-service'
;
/**
* 头部信息编辑视图基类
*
* @export
* @class IBizListEdit_DataPanelViewBase
* @extends {EditViewBase}
*/
export
class
IBizListEdit_DataPanelViewBase
extends
EditViewBase
{
/**
* 视图对应应用实体名称
*
* @protected
* @type {string}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
appDeName
:
string
=
'ibizlist'
;
/**
* 应用实体主键
*
* @protected
* @type {string}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
appDeKey
:
string
=
'listid'
;
/**
* 应用实体主信息
*
* @protected
* @type {string}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
appDeMajor
:
string
=
'listname'
;
/**
* 实体服务对象
*
* @type {IBizListService}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
appEntityService
:
IBizListService
=
new
IBizListService
;
/**
* 实体权限服务对象
*
* @type IBizListUIService
* @memberof IBizListEdit_DataPanelViewBase
*/
public
appUIService
:
IBizListUIService
=
new
IBizListUIService
(
this
.
$store
);
/**
* 计数器服务对象集合
*
* @protected
* @type {Array<*>}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
counterServiceArray
:
Array
<
any
>
=
[];
/**
* 视图模型数据
*
* @protected
* @type {*}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
model
:
any
=
{
srfCaption
:
'entities.ibizlist.views.edit_datapanelview.caption'
,
srfTitle
:
'entities.ibizlist.views.edit_datapanelview.title'
,
srfSubTitle
:
'entities.ibizlist.views.edit_datapanelview.subtitle'
,
dataInfo
:
''
}
/**
* 容器模型
*
* @protected
* @type {*}
* @memberof IBizListEdit_DataPanelViewBase
*/
protected
containerModel
:
any
=
{
view_form
:
{
name
:
'form'
,
type
:
'FORM'
},
};
/**
* 视图唯一标识
*
* @protected
* @type {string}
* @memberof ViewBase
*/
protected
viewtag
:
string
=
'0ab0bd0aaadd588905a82de62c80ff07'
;
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof IBizListEdit_DataPanelViewBase
*/
public
engine
:
EditViewEngine
=
new
EditViewEngine
();
/**
* 引擎初始化
*
* @public
* @memberof IBizListEdit_DataPanelViewBase
*/
public
engineInit
():
void
{
this
.
engine
.
init
({
view
:
this
,
form
:
this
.
$refs
.
form
,
p2k
:
'0'
,
keyPSDEField
:
'ibizlist'
,
majorPSDEField
:
'listname'
,
isLoadDefault
:
true
,
});
}
/**
* form 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBizListEdit_DataPanelViewBase
*/
public
form_save
(
$event
:
any
,
$event2
?:
any
):
void
{
this
.
engine
.
onCtrlEvent
(
'form'
,
'save'
,
$event
);
}
/**
* form 部件 remove 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBizListEdit_DataPanelViewBase
*/
public
form_remove
(
$event
:
any
,
$event2
?:
any
):
void
{
this
.
engine
.
onCtrlEvent
(
'form'
,
'remove'
,
$event
);
}
/**
* form 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBizListEdit_DataPanelViewBase
*/
public
form_load
(
$event
:
any
,
$event2
?:
any
):
void
{
this
.
engine
.
onCtrlEvent
(
'form'
,
'load'
,
$event
);
}
}
\ No newline at end of file
app_CRM/src/pages/marketing/ibiz-list-edit-data-panel-view/ibiz-list-edit-data-panel-view.html
0 → 100644
浏览文件 @
2082a1ad
<studio-view-style2
viewName=
"ibizlistedit_datapanelview"
viewTitle=
"头部信息编辑"
class=
'deeditview ibiz-list-edit-data-panel-view'
>
<view
_form
:viewState=
"viewState"
:viewparams=
"viewparams"
:context=
"context"
:autosave=
"true"
: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
>
</studio-view-style2>
\ No newline at end of file
app_CRM/src/pages/marketing/ibiz-list-edit-data-panel-view/ibiz-list-edit-data-panel-view.vue
0 → 100644
浏览文件 @
2082a1ad
<
template
src=
"./ibiz-list-edit-data-panel-view.html"
/>
<script
lang=
'tsx'
>
import
{ Component } from 'vue-property-decorator';
import { VueLifeCycleProcessing } from '@/studio-core';
import { IBizListEdit_DataPanelViewBase } from './ibiz-list-edit-data-panel-view-base';
import view_form from '@widgets/ibiz-list/edit-data-panel-form/edit-data-panel-form.vue';
/**
* 头部信息编辑视图
*
* @export
* @class IBizListEdit_DataPanelView
* @extends {IBizListEdit_DataPanelViewBase}
*/
@Component({
components: {
view_form,
}
})
@VueLifeCycleProcessing()
export default class IBizListEdit_DataPanelView extends IBizListEdit_DataPanelViewBase { }
</script>
app_CRM/src/pages/marketing/ibiz-list-info/ibiz-list-info-base.tsx
浏览文件 @
2082a1ad
...
...
@@ -3,6 +3,7 @@ import { TabExpViewBase } from '@/studio-core';
import
IBizListService
from
'@/service/ibiz-list/ibiz-list-service'
;
import
IBizListAuthService
from
'@/authservice/ibiz-list/ibiz-list-auth-service'
;
import
TabExpViewEngine
from
'@engine/view/tab-exp-view-engine'
;
import
DataPanelEngine
from
'@engine/ctrl/data-panel-engine'
;
import
IBizListUIService
from
'@/uiservice/ibiz-list/ibiz-list-ui-service'
;
/**
...
...
@@ -88,9 +89,29 @@ export class IBizListInfoBase extends TabExpViewBase {
* @memberof IBizListInfoBase
*/
protected
containerModel
:
any
=
{
view_toolbar
:
{
name
:
'toolbar'
,
type
:
'TOOLBAR'
},
view_datapanel
:
{
name
:
'datapanel'
,
type
:
'FORM'
},
view_tabexppanel
:
{
name
:
'tabexppanel'
,
type
:
'TABEXPPANEL'
},
};
/**
* 工具栏模型
*
* @type {*}
* @memberof IBizListInfo
*/
public
toolBarModels
:
any
=
{
tbitem17_active
:
{
name
:
'tbitem17_active'
,
caption
:
'激活'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'激活'
,
iconcls
:
'fa fa-play-circle-o'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
noprivdisplaymode
:
2
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'Active'
,
target
:
'SINGLEKEY'
,
class
:
''
}
},
tbitem17_stop_sep
:
{
name
:
'tbitem17_stop_sep'
,
type
:
'SEPERATOR'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
}
},
tbitem17_stop
:
{
name
:
'tbitem17_stop'
,
caption
:
'停用'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'停用'
,
iconcls
:
'fa fa-minus-circle'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
noprivdisplaymode
:
2
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'Stop'
,
target
:
'SINGLEKEY'
,
class
:
''
}
},
tbitem2
:
{
name
:
'tbitem2'
,
type
:
'SEPERATOR'
,
visabled
:
true
,
dataaccaction
:
''
,
uiaction
:
{
}
},
tbitem12
:
{
name
:
'tbitem12'
,
caption
:
'关闭'
,
'isShowCaption'
:
true
,
'isShowIcon'
:
true
,
tooltip
:
'关闭'
,
iconcls
:
'fa fa-sign-out'
,
icon
:
''
,
disabled
:
false
,
type
:
'DEUIACTION'
,
visabled
:
true
,
noprivdisplaymode
:
2
,
dataaccaction
:
''
,
uiaction
:
{
tag
:
'Exit'
,
target
:
''
,
class
:
''
}
},
};
/**
* 视图唯一标识
...
...
@@ -111,6 +132,15 @@ export class IBizListInfoBase extends TabExpViewBase {
*/
public
engine
:
TabExpViewEngine
=
new
TabExpViewEngine
();
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof IBizListInfoBase
*/
public
datapanel
:
DataPanelEngine
=
new
DataPanelEngine
();
/**
* 引擎初始化
*
...
...
@@ -124,6 +154,133 @@ export class IBizListInfoBase extends TabExpViewBase {
majorPSDEField
:
'listname'
,
isLoadDefault
:
true
,
});
this
.
datapanel
.
init
({
view
:
this
,
datapanel
:
this
.
$refs
.
datapanel
,
keyPSDEField
:
'ibizlist'
,
majorPSDEField
:
'listname'
,
isLoadDefault
:
true
,
});
}
/**
* toolbar 部件 click 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof IBizListInfoBase
*/
public
toolbar_click
(
$event
:
any
,
$event2
?:
any
):
void
{
if
(
Object
.
is
(
$event
.
tag
,
'tbitem17_active'
))
{
this
.
toolbar_tbitem17_active_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem17_stop'
))
{
this
.
toolbar_tbitem17_stop_click
(
null
,
''
,
$event2
);
}
if
(
Object
.
is
(
$event
.
tag
,
'tbitem12'
))
{
this
.
toolbar_tbitem12_click
(
null
,
''
,
$event2
);
}
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem17_active_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
=
{};
if
(
_this
.
getDatas
&&
_this
.
getDatas
instanceof
Function
)
{
datas
=
[...
_this
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
const
curUIService
:
IBizListUIService
=
new
IBizListUIService
();
curUIService
.
IBizList_Active
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"IBizList"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem17_stop_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
=
{};
if
(
_this
.
getDatas
&&
_this
.
getDatas
instanceof
Function
)
{
datas
=
[...
_this
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
const
curUIService
:
IBizListUIService
=
new
IBizListUIService
();
curUIService
.
IBizList_Stop
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"IBizList"
);
}
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
toolbar_tbitem12_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
=
{};
if
(
_this
.
getDatas
&&
_this
.
getDatas
instanceof
Function
)
{
datas
=
[...
_this
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
this
.
Exit
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"IBizList"
);
}
/**
* 关闭
*
* @param {any[]} args 当前数据
* @param {any} contextJO 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @memberof IBizListInfoBase
*/
public
Exit
(
args
:
any
[],
contextJO
?:
any
,
params
?:
any
,
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
this
.
closeView
(
args
);
if
(
window
.
parent
){
window
.
parent
.
postMessage
([{
...
args
}],
'*'
);
}
}
...
...
app_CRM/src/pages/marketing/ibiz-list-info/ibiz-list-info.html
浏览文件 @
2082a1ad
...
...
@@ -2,6 +2,29 @@
<template
slot=
'title'
>
<span
class=
'caption-info'
>
{{$t(model.srfTitle)}}
</span>
</template>
<template
slot=
"dataPanel"
>
<view
_datapanel
: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=
"datapanel"
ref=
'datapanel'
@
closeview=
"closeView($event)"
>
</view
_datapanel
>
</template>
<template
slot=
"toolbar"
>
<view-toolbar
mode=
"STYLE2"
:model=
"toolBarModels"
@
item-click=
"toolbar_click($event)"
/>
</template>
<view
_tabexppanel
:viewState=
"viewState"
:viewparams=
"viewparams"
...
...
app_CRM/src/pages/marketing/ibiz-list-info/ibiz-list-info.vue
浏览文件 @
2082a1ad
...
...
@@ -3,6 +3,7 @@
import
{ Component } from 'vue-property-decorator';
import { VueLifeCycleProcessing } from '@/studio-core';
import { IBizListInfoBase } from './ibiz-list-info-base';
import view_datapanel from '@widgets/ibiz-list/data-panel-form/data-panel-form.vue';
import view_tabexppanel from '@widgets/ibiz-list/infotabexppanel-tabexppanel/infotabexppanel-tabexppanel.vue';
/**
...
...
@@ -14,6 +15,7 @@ import view_tabexppanel from '@widgets/ibiz-list/infotabexppanel-tabexppanel/inf
*/
@Component({
components: {
view_datapanel,
view_tabexppanel,
}
})
...
...
app_CRM/src/store/modules/view-action/state.ts
浏览文件 @
2082a1ad
...
...
@@ -178,6 +178,15 @@ export const viewstate: any = {
'6e18ac74e5685439110f9b4e534ee005'
,
],
},
{
viewtag
:
'0ab0bd0aaadd588905a82de62c80ff07'
,
viewmodule
:
'Marketing'
,
viewname
:
'IBizListEdit_DataPanelView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'0dff48c04927315f77dd70a9a2767b59'
,
viewmodule
:
'Service'
,
...
...
@@ -2142,6 +2151,7 @@ export const viewstate: any = {
'2c6be792e84450585986e22f75dffa52'
,
'4799b0e7139b537ebe9313a004daa0ac'
,
'a0baf844a4d48914ee2623448b1a73fb'
,
'0ab0bd0aaadd588905a82de62c80ff07'
,
'3124753ba4abff3aaf49355a5197c4ab'
,
],
},
...
...
app_CRM/src/uiservice/ibiz-list/ibiz-list-ui-service-base.ts
浏览文件 @
2082a1ad
...
...
@@ -181,6 +181,69 @@ export default class IBizListUIServiceBase extends UIService {
openDrawer
(
view
,
data
);
}
/**
* 头信息编辑
*
* @param {any[]} args 当前数据
* @param {any} context 行为附加上下文
* @param {*} [params] 附加参数
* @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文
* @param {*} [srfParentDeName] 父实体名称
* @returns {Promise<any>}
*/
public
async
IBizList_OpenEdit_DataPanel
(
args
:
any
[],
context
:
any
=
{}
,
params
:
any
=
{},
$event
?:
any
,
xData
?:
any
,
actionContext
?:
any
,
srfParentDeName
?:
string
)
{
let
data
:
any
=
{};
let
parentContext
:
any
=
{};
let
parentViewParam
:
any
=
{};
const
_this
:
any
=
actionContext
;
const
_args
:
any
[]
=
Util
.
deepCopy
(
args
);
const
actionTarget
:
string
|
null
=
'SINGLEKEY'
;
Object
.
assign
(
context
,
{
ibizlist
:
'%ibizlist%'
});
Object
.
assign
(
params
,
{
listid
:
'%ibizlist%'
});
Object
.
assign
(
params
,
{
listname
:
'%listname%'
});
if
(
_this
.
context
){
parentContext
=
_this
.
context
;
}
if
(
_this
.
viewparams
){
parentViewParam
=
_this
.
viewparams
;
}
context
=
UIActionTool
.
handleContextParam
(
actionTarget
,
_args
,
parentContext
,
parentViewParam
,
context
);
data
=
UIActionTool
.
handleActionParam
(
actionTarget
,
_args
,
parentContext
,
parentViewParam
,
params
);
context
=
Object
.
assign
({},
actionContext
.
context
,
context
);
let
parentObj
:
any
=
{
srfparentdename
:
srfParentDeName
?
srfParentDeName
:
null
,
srfparentkey
:
srfParentDeName
?
context
[
srfParentDeName
.
toLowerCase
()]:
null
};
Object
.
assign
(
data
,
parentObj
);
Object
.
assign
(
context
,
parentObj
);
let
deResParameters
:
any
[]
=
[];
const
parameters
:
any
[]
=
[
{
pathName
:
'ibizlists'
,
parameterName
:
'ibizlist'
},
];
const
openPopOver
=
(
view
:
any
,
data
:
any
)
=>
{
let
container
:
Subject
<
any
>
=
actionContext
.
$apppopover
.
openPop
(
$event
,
view
,
context
,
data
);
container
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
const
_this
:
any
=
actionContext
;
if
(
window
.
opener
){
window
.
opener
.
postMessage
({
status
:
'OK'
,
identification
:
'WF'
},
Environment
.
uniteAddress
);
window
.
close
();
}
return
result
.
datas
;
});
}
const
view
:
any
=
{
viewname
:
'ibiz-list-edit-data-panel-view'
,
height
:
300
,
width
:
300
,
title
:
actionContext
.
$t
(
'entities.ibizlist.views.edit_datapanelview.title'
),
placement
:
'POPOVER'
,
};
openPopOver
(
view
,
data
);
}
/**
* 激活
*
...
...
app_CRM/src/widgets/ibiz-list/data-panel-form/data-panel-form-base.tsx
0 → 100644
浏览文件 @
2082a1ad
import
{
Prop
,
Provide
,
Emit
,
Model
}
from
'vue-property-decorator'
;
import
{
Subject
,
Subscription
}
from
'rxjs'
;
import
{
Watch
,
EditFormControlBase
}
from
'@/studio-core'
;
import
IBizListService
from
'@/service/ibiz-list/ibiz-list-service'
;
import
DataPanelService
from
'./data-panel-form-service'
;
import
IBizListUIService
from
'@/uiservice/ibiz-list/ibiz-list-ui-service'
;
import
{
FormButtonModel
,
FormPageModel
,
FormItemModel
,
FormDRUIPartModel
,
FormPartModel
,
FormGroupPanelModel
,
FormIFrameModel
,
FormRowItemModel
,
FormTabPageModel
,
FormTabPanelModel
,
FormUserControlModel
}
from
'@/model/form-detail'
;
/**
* datapanel部件基类
*
* @export
* @class EditFormControlBase
* @extends {DataPanelEditFormBase}
*/
export
class
DataPanelEditFormBase
extends
EditFormControlBase
{
/**
* 获取部件类型
*
* @protected
* @type {string}
* @memberof DataPanelEditFormBase
*/
protected
controlType
:
string
=
'FORM'
;
/**
* 建构部件服务对象
*
* @type {DataPanelService}
* @memberof DataPanelEditFormBase
*/
public
service
:
DataPanelService
=
new
DataPanelService
({
$store
:
this
.
$store
});
/**
* 实体服务对象
*
* @type {IBizListService}
* @memberof DataPanelEditFormBase
*/
public
appEntityService
:
IBizListService
=
new
IBizListService
({
$store
:
this
.
$store
});
/**
* 应用实体名称
*
* @protected
* @type {string}
* @memberof DataPanelEditFormBase
*/
protected
appDeName
:
string
=
'ibizlist'
;
/**
* 逻辑事件
*
* @param {*} [params={}]
* @param {*} [tag]
* @param {*} [$event]
* @memberof
*/
public
datapanel_button1_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
;
if
(
_this
.
getDatas
&&
_this
.
getDatas
instanceof
Function
)
{
datas
=
[...
_this
.
getDatas
()];
}
if
(
params
){
datas
=
[
params
];
}
// 界面行为
const
curUIService
:
IBizListUIService
=
new
IBizListUIService
();
curUIService
.
IBizList_OpenEdit_DataPanel
(
datas
,
contextJO
,
paramJO
,
$event
,
xData
,
this
,
"IBizList"
);
}
/**
* 界面UI服务对象
*
* @type {IBizListUIService}
* @memberof DataPanelEditFormBase
*/
public
appUIService
:
IBizListUIService
=
new
IBizListUIService
(
this
.
$store
);
/**
* 表单数据对象
*
* @type {*}
* @memberof DataPanelEditFormBase
*/
public
data
:
any
=
{
srfupdatedate
:
null
,
srforikey
:
null
,
srfkey
:
null
,
srfmajortext
:
null
,
srftempmode
:
null
,
srfuf
:
null
,
srfdeid
:
null
,
srfsourcekey
:
null
,
lockstatus
:
null
,
lastusedon
:
null
,
ownername
:
null
,
listid
:
null
,
ibizlist
:
null
,
};
/**
* 属性值规则
*
* @type {*}
* @memberof DataPanelEditFormBase
*/
public
rules
:
any
=
{
}
/**
* 详情模型集合
*
* @type {*}
* @memberof DataPanelEditFormBase
*/
public
detailsModel
:
any
=
{
button1
:
new
FormButtonModel
({
caption
:
'头信息编辑'
,
detailType
:
'BUTTON'
,
name
:
'button1'
,
visible
:
true
,
isShowCaption
:
false
,
form
:
this
,
showMoreMode
:
0
,
uiaction
:
{
type
:
'DEUIACTION'
,
tag
:
'OpenEdit_DataPanel'
,
actiontarget
:
'SINGLEKEY'
}
}),
grouppanel1
:
new
FormGroupPanelModel
({
caption
:
'分组面板'
,
detailType
:
'GROUPPANEL'
,
name
:
'grouppanel1'
,
visible
:
true
,
isShowCaption
:
false
,
form
:
this
,
showMoreMode
:
0
,
uiActionGroup
:
{
caption
:
''
,
langbase
:
'entities.ibizlist.datapanel_form'
,
extractMode
:
'ITEM'
,
details
:
[]
}
}),
group1
:
new
FormGroupPanelModel
({
caption
:
'市场营销列表基本信息'
,
detailType
:
'GROUPPANEL'
,
name
:
'group1'
,
visible
:
true
,
isShowCaption
:
false
,
form
:
this
,
showMoreMode
:
0
,
uiActionGroup
:
{
caption
:
''
,
langbase
:
'entities.ibizlist.datapanel_form'
,
extractMode
:
'ITEM'
,
details
:
[]
}
}),
formpage1
:
new
FormPageModel
({
caption
:
'基本信息'
,
detailType
:
'FORMPAGE'
,
name
:
'formpage1'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
}),
srfupdatedate
:
new
FormItemModel
({
caption
:
'更新时间'
,
detailType
:
'FORMITEM'
,
name
:
'srfupdatedate'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
0
}),
srforikey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srforikey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfkey
:
new
FormItemModel
({
caption
:
'列表'
,
detailType
:
'FORMITEM'
,
name
:
'srfkey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfmajortext
:
new
FormItemModel
({
caption
:
'名称'
,
detailType
:
'FORMITEM'
,
name
:
'srfmajortext'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srftempmode
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srftempmode'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfuf
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfuf'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfdeid
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfdeid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfsourcekey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfsourcekey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
lockstatus
:
new
FormItemModel
({
caption
:
'已锁定'
,
detailType
:
'FORMITEM'
,
name
:
'lockstatus'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
lastusedon
:
new
FormItemModel
({
caption
:
'上次使用时间'
,
detailType
:
'FORMITEM'
,
name
:
'lastusedon'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
ownername
:
new
FormItemModel
({
caption
:
'负责人'
,
detailType
:
'FORMITEM'
,
name
:
'ownername'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
listid
:
new
FormItemModel
({
caption
:
'列表'
,
detailType
:
'FORMITEM'
,
name
:
'listid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
};
/**
* 表单 头信息编辑 事件
*
* @memberof @memberof DataPanelEditFormBase
*/
public
button1_click
(
$event
:
any
):
void
{
this
.
datapanel_button1_click
(
null
,
null
,
$event
);
}
}
\ No newline at end of file
app_CRM/src/widgets/ibiz-list/data-panel-form/data-panel-form-model.ts
0 → 100644
浏览文件 @
2082a1ad
/**
* DataPanel 部件模型
*
* @export
* @class DataPanelModel
*/
export
default
class
DataPanelModel
{
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof DataPanelModel
*/
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
:
'listid'
,
dataType
:
'GUID'
,
},
{
name
:
'srfmajortext'
,
prop
:
'listname'
,
dataType
:
'TEXT'
,
},
{
name
:
'srftempmode'
,
},
{
name
:
'srfuf'
,
},
{
name
:
'srfdeid'
,
},
{
name
:
'srfsourcekey'
,
},
{
name
:
'lockstatus'
,
prop
:
'lockstatus'
,
dataType
:
'YESNO'
,
},
{
name
:
'lastusedon'
,
prop
:
'lastusedon'
,
dataType
:
'DATETIME'
,
},
{
name
:
'ownername'
,
prop
:
'ownername'
,
dataType
:
'TEXT'
,
},
{
name
:
'listid'
,
prop
:
'listid'
,
dataType
:
'GUID'
,
},
{
name
:
'ibizlist'
,
prop
:
'listid'
,
dataType
:
'FONTKEY'
,
},
]
}
}
\ No newline at end of file
app_CRM/src/widgets/ibiz-list/data-panel-form/data-panel-form-service.ts
0 → 100644
浏览文件 @
2082a1ad
import
{
Http
,
Util
,
Errorlog
}
from
'@/utils'
;
import
ControlService
from
'@/widgets/control-service'
;
import
IBizListService
from
'@/service/ibiz-list/ibiz-list-service'
;
import
DataPanelModel
from
'./data-panel-form-model'
;
/**
* DataPanel 部件服务对象
*
* @export
* @class DataPanelService
*/
export
default
class
DataPanelService
extends
ControlService
{
/**
* 市场营销列表服务对象
*
* @type {IBizListService}
* @memberof DataPanelService
*/
public
appEntityService
:
IBizListService
=
new
IBizListService
({
$store
:
this
.
getStore
()
});
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof DataPanelService
*/
public
setTempMode
(){
this
.
isTempMode
=
false
;
}
/**
* Creates an instance of DataPanelService.
*
* @param {*} [opts={}]
* @memberof DataPanelService
*/
constructor
(
opts
:
any
=
{})
{
super
(
opts
);
this
.
model
=
new
DataPanelModel
();
}
/**
* 处理数据
*
* @private
* @param {Promise<any>} promise
* @returns {Promise<any>}
* @memberof DataPanelService
*/
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 DataPanelService
*/
@
Errorlog
public
getItems
(
serviceName
:
string
,
interfaceName
:
string
,
context
:
any
=
{},
data
:
any
,
isloading
?:
boolean
):
Promise
<
any
[]
>
{
return
Promise
.
reject
([])
}
/**
* 启动工作流
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {*} [localdata]
* @returns {Promise<any>}
* @memberof DataPanelService
*/
@
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 DataPanelService
*/
@
Errorlog
public
wfsubmit
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
localdata
?:
any
):
Promise
<
any
>
{
data
=
this
.
handleWFData
(
data
,
true
);
context
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
).
context
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
context
,
data
,
isloading
,
localdata
);
}
else
{
result
=
this
.
appEntityService
.
WFSubmit
(
context
,
data
,
isloading
,
localdata
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 添加数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof DataPanelService
*/
@
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 DataPanelService
*/
@
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 DataPanelService
*/
@
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 DataPanelService
*/
@
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 DataPanelService
*/
@
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
.
listid
=
PrimaryKey
;
Data
.
ibizlist
=
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
.
listid
=
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 DataPanelService
*/
@
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 DataPanelService
*/
public
handleRequestData
(
action
:
string
,
context
:
any
,
data
:
any
=
{},
isMerge
:
boolean
=
false
){
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
let
requestData
:
any
=
{};
if
(
isMerge
&&
(
data
&&
data
.
viewparams
)){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
&&
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
'FONTKEY'
)){
if
(
item
&&
item
.
prop
){
requestData
[
item
.
prop
]
=
context
[
item
.
name
];
}
}
else
{
if
(
item
&&
item
.
prop
){
requestData
[
item
.
prop
]
=
data
[
item
.
name
];
}
}
});
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_CRM/src/widgets/ibiz-list/data-panel-form/data-panel-form.html
0 → 100644
浏览文件 @
2082a1ad
<i-form
:model=
"this.data"
class=
'app-form info-form-mode'
ref=
'datapanel'
id=
'ibizlist_datapanel'
style=
""
>
<input
style=
"display:none;"
/>
<row
>
<i-col
v-show=
"detailsModel.group1.visible"
:style=
"{}"
:lg=
"{ span: 24, offset: 0 }"
>
<app-form-group
:model=
"detailsModel.group1"
layoutType=
"FLEX"
titleStyle=
""
class=
''
:uiActionGroup=
"detailsModel.group1.uiActionGroup"
@
groupuiactionclick=
"groupUIActionClick($event)"
:caption=
"$t('entities.ibizlist.datapanel_form.details.group1')"
:isShowCaption=
"false"
uiStyle=
"DEFAULT"
:titleBarCloseMode=
"0"
:isInfoGroupMode=
"true"
>
<app-radio-group-data-panel
slot=
"dataInfoPanel"
:model=
"detailsModel.group1"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
/>
<div
style=
"height: 100%;display: flex;"
>
<div
v-show=
"detailsModel.lockstatus.visible"
:style=
"{}"
>
<app-form-item
name=
'lockstatus'
:itemRules=
"this.rules.lockstatus"
class=
'datapanel-style'
:caption=
"$t('entities.ibizlist.datapanel_form.details.lockstatus')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.lockstatus.error"
:isEmptyCaption=
"false"
labelPos=
"BOTTOM"
>
<app-span
name=
'lockstatus'
:value=
"data.lockstatus"
tag=
'YesNo'
codelistType=
'STATIC'
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
:localContext =
'{ }'
:localParam =
'{ }'
style=
""
></app-span>
</app-form-item>
</div>
<div
v-show=
"detailsModel.lastusedon.visible"
:style=
"{}"
>
<app-form-item
name=
'lastusedon'
:itemRules=
"this.rules.lastusedon"
class=
'datapanel-style'
:caption=
"$t('entities.ibizlist.datapanel_form.details.lastusedon')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.lastusedon.error"
:isEmptyCaption=
"false"
labelPos=
"BOTTOM"
>
<app-span
name=
'lastusedon'
:value=
"data.lastusedon"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
:localContext =
'{ }'
:localParam =
'{ }'
style=
""
></app-span>
</app-form-item>
</div>
<div
v-show=
"detailsModel.ownername.visible"
:style=
"{}"
>
<app-form-item
name=
'ownername'
:itemRules=
"this.rules.ownername"
class=
'datapanel-style'
:caption=
"$t('entities.ibizlist.datapanel_form.details.ownername')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.ownername.error"
:isEmptyCaption=
"false"
labelPos=
"BOTTOM"
>
<app-span
name=
'ownername'
:value=
"data.ownername"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
:localContext =
'{ }'
:localParam =
'{ }'
style=
""
></app-span>
</app-form-item>
</div>
<div
v-show=
"detailsModel.grouppanel1.visible"
:style=
"{}"
>
<app-form-group
:model=
"detailsModel.grouppanel1"
layoutType=
"FLEX"
titleStyle=
""
class=
''
:uiActionGroup=
"detailsModel.grouppanel1.uiActionGroup"
@
groupuiactionclick=
"groupUIActionClick($event)"
:caption=
"$t('entities.ibizlist.datapanel_form.details.grouppanel1')"
:isShowCaption=
"false"
uiStyle=
"DEFAULT"
:titleBarCloseMode=
"0"
:isInfoGroupMode=
"true"
>
<app-radio-group-data-panel
slot=
"dataInfoPanel"
:model=
"detailsModel.grouppanel1"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
/>
<div
style=
"height: 100%;display: flex;"
>
<div
v-show=
"detailsModel.button1.visible"
:style=
"{}"
>
<i-button
type=
"primary"
@
click=
"button1_click($event)"
class=
"form-btn-noborder-transparent"
style=
""
>
<i
class=
"fa fa-angle-down"
style=
"margin-right: 2px;"
></i>
</i-button>
</div>
</div>
</app-form-group>
</div>
</div>
</app-form-group>
</i-col>
</row>
</i-form>
\ No newline at end of file
app_CRM/src/widgets/ibiz-list/data-panel-form/data-panel-form.less
0 → 100644
浏览文件 @
2082a1ad
.datapanel-style {
font-size:20px;font-weight:bold;text-align:left
}
.datapanel-style {
height: 48px;
margin-top: 2px;
margin-bottom: 0px!important;
margin-right: 5px;
padding-right: 5px;
border-right: 2px solid var(--app-dividing-line-color-bright) ;
}
.label-bottom {
.editor-wrapper {
height: 24px!important;
}
.app-form-item-label {
font-size: 12px;
font-weight: bold;
height: 24px!important;
line-height: 24px!important;
}
}
.form-btn-noborder-transparent {
background-color:rgba(255, 0, 0, 0);border-style:none;margin:0px 10px 0px 0px
}
.form-btn-noborder-transparent {
background-color:transparent!important;
border-style:none;
margin:0px 5px 0px 5px
}
app_CRM/src/widgets/ibiz-list/data-panel-form/data-panel-form.vue
0 → 100644
浏览文件 @
2082a1ad
<
template
src=
"./data-panel-form.html"
/>
<script
lang=
'tsx'
>
import
{ Component } from 'vue-property-decorator';
import { VueLifeCycleProcessing } from '@/studio-core';
import { DataPanelEditFormBase } from './data-panel-form-base';
/**
* datapanel部件
*
* @export
* @class DataPanelEditForm
* @extends {DataPanelEditFormBase}
*/
@Component({
components: {
}
})
@VueLifeCycleProcessing()
export default class DataPanelEditForm extends DataPanelEditFormBase { }
</script>
<style
lang=
'less'
>
@import
'./data-panel-form.less'
;
</style>
app_CRM/src/widgets/ibiz-list/edit-data-panel-form/edit-data-panel-form-base.tsx
0 → 100644
浏览文件 @
2082a1ad
import
{
Prop
,
Provide
,
Emit
,
Model
}
from
'vue-property-decorator'
;
import
{
Subject
,
Subscription
}
from
'rxjs'
;
import
{
Watch
,
EditFormControlBase
}
from
'@/studio-core'
;
import
IBizListService
from
'@/service/ibiz-list/ibiz-list-service'
;
import
Edit_DataPanelService
from
'./edit-data-panel-form-service'
;
import
IBizListUIService
from
'@/uiservice/ibiz-list/ibiz-list-ui-service'
;
import
{
FormButtonModel
,
FormPageModel
,
FormItemModel
,
FormDRUIPartModel
,
FormPartModel
,
FormGroupPanelModel
,
FormIFrameModel
,
FormRowItemModel
,
FormTabPageModel
,
FormTabPanelModel
,
FormUserControlModel
}
from
'@/model/form-detail'
;
/**
* form部件基类
*
* @export
* @class EditFormControlBase
* @extends {Edit_DataPanelEditFormBase}
*/
export
class
Edit_DataPanelEditFormBase
extends
EditFormControlBase
{
/**
* 获取部件类型
*
* @protected
* @type {string}
* @memberof Edit_DataPanelEditFormBase
*/
protected
controlType
:
string
=
'FORM'
;
/**
* 建构部件服务对象
*
* @type {Edit_DataPanelService}
* @memberof Edit_DataPanelEditFormBase
*/
public
service
:
Edit_DataPanelService
=
new
Edit_DataPanelService
({
$store
:
this
.
$store
});
/**
* 实体服务对象
*
* @type {IBizListService}
* @memberof Edit_DataPanelEditFormBase
*/
public
appEntityService
:
IBizListService
=
new
IBizListService
({
$store
:
this
.
$store
});
/**
* 应用实体名称
*
* @protected
* @type {string}
* @memberof Edit_DataPanelEditFormBase
*/
protected
appDeName
:
string
=
'ibizlist'
;
/**
* 界面UI服务对象
*
* @type {IBizListUIService}
* @memberof Edit_DataPanelEditFormBase
*/
public
appUIService
:
IBizListUIService
=
new
IBizListUIService
(
this
.
$store
);
/**
* 表单数据对象
*
* @type {*}
* @memberof Edit_DataPanelEditFormBase
*/
public
data
:
any
=
{
srfupdatedate
:
null
,
srforikey
:
null
,
srfkey
:
null
,
srfmajortext
:
null
,
srftempmode
:
null
,
srfuf
:
null
,
srfdeid
:
null
,
srfsourcekey
:
null
,
lockstatus
:
null
,
lastusedon
:
null
,
ownername
:
null
,
listid
:
null
,
ibizlist
:
null
,
};
/**
* 属性值规则
*
* @type {*}
* @memberof Edit_DataPanelEditFormBase
*/
public
rules
:
any
=
{
ownername
:
[
{
required
:
true
,
type
:
'string'
,
message
:
'负责人 值不能为空'
,
trigger
:
'change'
},
{
required
:
true
,
type
:
'string'
,
message
:
'负责人 值不能为空'
,
trigger
:
'blur'
},
],
}
/**
* 详情模型集合
*
* @type {*}
* @memberof Edit_DataPanelEditFormBase
*/
public
detailsModel
:
any
=
{
group1
:
new
FormGroupPanelModel
({
caption
:
'市场营销列表基本信息'
,
detailType
:
'GROUPPANEL'
,
name
:
'group1'
,
visible
:
true
,
isShowCaption
:
false
,
form
:
this
,
showMoreMode
:
0
,
uiActionGroup
:
{
caption
:
''
,
langbase
:
'entities.ibizlist.edit_datapanel_form'
,
extractMode
:
'ITEM'
,
details
:
[]
}
}),
formpage1
:
new
FormPageModel
({
caption
:
'基本信息'
,
detailType
:
'FORMPAGE'
,
name
:
'formpage1'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
}),
srfupdatedate
:
new
FormItemModel
({
caption
:
'更新时间'
,
detailType
:
'FORMITEM'
,
name
:
'srfupdatedate'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
0
}),
srforikey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srforikey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfkey
:
new
FormItemModel
({
caption
:
'列表'
,
detailType
:
'FORMITEM'
,
name
:
'srfkey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfmajortext
:
new
FormItemModel
({
caption
:
'名称'
,
detailType
:
'FORMITEM'
,
name
:
'srfmajortext'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srftempmode
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srftempmode'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfuf
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfuf'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfdeid
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfdeid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
srfsourcekey
:
new
FormItemModel
({
caption
:
''
,
detailType
:
'FORMITEM'
,
name
:
'srfsourcekey'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
lockstatus
:
new
FormItemModel
({
caption
:
'已锁定'
,
detailType
:
'FORMITEM'
,
name
:
'lockstatus'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
lastusedon
:
new
FormItemModel
({
caption
:
'上次使用时间'
,
detailType
:
'FORMITEM'
,
name
:
'lastusedon'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
ownername
:
new
FormItemModel
({
caption
:
'负责人'
,
detailType
:
'FORMITEM'
,
name
:
'ownername'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
listid
:
new
FormItemModel
({
caption
:
'列表'
,
detailType
:
'FORMITEM'
,
name
:
'listid'
,
visible
:
true
,
isShowCaption
:
true
,
form
:
this
,
showMoreMode
:
0
,
disabled
:
false
,
enableCond
:
3
}),
};
}
\ No newline at end of file
app_CRM/src/widgets/ibiz-list/edit-data-panel-form/edit-data-panel-form-model.ts
0 → 100644
浏览文件 @
2082a1ad
/**
* Edit_DataPanel 部件模型
*
* @export
* @class Edit_DataPanelModel
*/
export
default
class
Edit_DataPanelModel
{
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof Edit_DataPanelModel
*/
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
:
'listid'
,
dataType
:
'GUID'
,
},
{
name
:
'srfmajortext'
,
prop
:
'listname'
,
dataType
:
'TEXT'
,
},
{
name
:
'srftempmode'
,
},
{
name
:
'srfuf'
,
},
{
name
:
'srfdeid'
,
},
{
name
:
'srfsourcekey'
,
},
{
name
:
'lockstatus'
,
prop
:
'lockstatus'
,
dataType
:
'YESNO'
,
},
{
name
:
'lastusedon'
,
prop
:
'lastusedon'
,
dataType
:
'DATETIME'
,
},
{
name
:
'ownername'
,
prop
:
'ownername'
,
dataType
:
'TEXT'
,
},
{
name
:
'listid'
,
prop
:
'listid'
,
dataType
:
'GUID'
,
},
{
name
:
'ibizlist'
,
prop
:
'listid'
,
dataType
:
'FONTKEY'
,
},
]
}
}
\ No newline at end of file
app_CRM/src/widgets/ibiz-list/edit-data-panel-form/edit-data-panel-form-service.ts
0 → 100644
浏览文件 @
2082a1ad
import
{
Http
,
Util
,
Errorlog
}
from
'@/utils'
;
import
ControlService
from
'@/widgets/control-service'
;
import
IBizListService
from
'@/service/ibiz-list/ibiz-list-service'
;
import
Edit_DataPanelModel
from
'./edit-data-panel-form-model'
;
/**
* Edit_DataPanel 部件服务对象
*
* @export
* @class Edit_DataPanelService
*/
export
default
class
Edit_DataPanelService
extends
ControlService
{
/**
* 市场营销列表服务对象
*
* @type {IBizListService}
* @memberof Edit_DataPanelService
*/
public
appEntityService
:
IBizListService
=
new
IBizListService
({
$store
:
this
.
getStore
()
});
/**
* 设置从数据模式
*
* @type {boolean}
* @memberof Edit_DataPanelService
*/
public
setTempMode
(){
this
.
isTempMode
=
false
;
}
/**
* Creates an instance of Edit_DataPanelService.
*
* @param {*} [opts={}]
* @memberof Edit_DataPanelService
*/
constructor
(
opts
:
any
=
{})
{
super
(
opts
);
this
.
model
=
new
Edit_DataPanelModel
();
}
/**
* 处理数据
*
* @private
* @param {Promise<any>} promise
* @returns {Promise<any>}
* @memberof Edit_DataPanelService
*/
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 Edit_DataPanelService
*/
@
Errorlog
public
getItems
(
serviceName
:
string
,
interfaceName
:
string
,
context
:
any
=
{},
data
:
any
,
isloading
?:
boolean
):
Promise
<
any
[]
>
{
return
Promise
.
reject
([])
}
/**
* 启动工作流
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @param {*} [localdata]
* @returns {Promise<any>}
* @memberof Edit_DataPanelService
*/
@
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 Edit_DataPanelService
*/
@
Errorlog
public
wfsubmit
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
,
localdata
?:
any
):
Promise
<
any
>
{
data
=
this
.
handleWFData
(
data
,
true
);
context
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
).
context
;
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
let
result
:
Promise
<
any
>
;
const
_appEntityService
:
any
=
this
.
appEntityService
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
context
,
data
,
isloading
,
localdata
);
}
else
{
result
=
this
.
appEntityService
.
WFSubmit
(
context
,
data
,
isloading
,
localdata
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
resolve
(
response
);
}).
catch
(
response
=>
{
reject
(
response
);
});
});
}
/**
* 添加数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof Edit_DataPanelService
*/
@
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 Edit_DataPanelService
*/
@
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 Edit_DataPanelService
*/
@
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 Edit_DataPanelService
*/
@
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 Edit_DataPanelService
*/
@
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
.
listid
=
PrimaryKey
;
Data
.
ibizlist
=
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
.
listid
=
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 Edit_DataPanelService
*/
@
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 Edit_DataPanelService
*/
public
handleRequestData
(
action
:
string
,
context
:
any
,
data
:
any
=
{},
isMerge
:
boolean
=
false
){
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
let
requestData
:
any
=
{};
if
(
isMerge
&&
(
data
&&
data
.
viewparams
)){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
&&
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
'FONTKEY'
)){
if
(
item
&&
item
.
prop
){
requestData
[
item
.
prop
]
=
context
[
item
.
name
];
}
}
else
{
if
(
item
&&
item
.
prop
){
requestData
[
item
.
prop
]
=
data
[
item
.
name
];
}
}
});
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_CRM/src/widgets/ibiz-list/edit-data-panel-form/edit-data-panel-form.html
0 → 100644
浏览文件 @
2082a1ad
<i-form
:model=
"this.data"
class=
'app-form'
ref=
'form'
id=
'ibizlist_edit_datapanel'
style=
""
>
<input
style=
"display:none;"
/>
<row
>
<i-col
v-show=
"detailsModel.group1.visible"
:style=
"{}"
:lg=
"{ span: 24, offset: 0 }"
>
<app-form-group
:model=
"detailsModel.group1"
layoutType=
"TABLE_24COL"
titleStyle=
""
class=
''
:uiActionGroup=
"detailsModel.group1.uiActionGroup"
@
groupuiactionclick=
"groupUIActionClick($event)"
:caption=
"$t('entities.ibizlist.edit_datapanel_form.details.group1')"
:isShowCaption=
"false"
uiStyle=
"DEFAULT"
:titleBarCloseMode=
"0"
:isInfoGroupMode=
"false"
>
<app-radio-group-data-panel
slot=
"dataInfoPanel"
:model=
"detailsModel.group1"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
/>
<row>
<i-col
v-show=
"detailsModel.lockstatus.visible"
:style=
"{}"
:lg=
"{ span: 24, offset: 0 }"
>
<app-form-item
name=
'lockstatus'
:itemRules=
"this.rules.lockstatus"
class=
''
:caption=
"$t('entities.ibizlist.edit_datapanel_form.details.lockstatus')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.lockstatus.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<dropdown-list
v-model=
"data.lockstatus"
:data=
"data"
:context=
"context"
:viewparams=
"viewparams"
:localContext =
'{ }'
:localParam =
'{ }'
:disabled=
"detailsModel.lockstatus.disabled"
style=
"width:100px;width: 100px;"
tag=
'YesNo'
codelistType=
'STATIC'
placeholder=
'请选择...'
>
</dropdown-list>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.lastusedon.visible"
:style=
"{}"
:lg=
"{ span: 24, offset: 0 }"
>
<app-form-item
name=
'lastusedon'
:itemRules=
"this.rules.lastusedon"
class=
''
:caption=
"$t('entities.ibizlist.edit_datapanel_form.details.lastusedon')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.lastusedon.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<date-picker
type=
"datetime"
:transfer=
"true"
format=
"yyyy-MM-dd HH:mm:ss"
placeholder=
"请选择时间..."
:value=
"data.lastusedon"
:disabled=
"detailsModel.lastusedon.disabled"
style=
"min-width: 150px; width:160px;"
@
on-change=
"(val1, val2) => { this.data.lastusedon = val1 }"
></date-picker>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.ownername.visible"
:style=
"{}"
:lg=
"{ span: 24, offset: 0 }"
>
<app-form-item
name=
'ownername'
:itemRules=
"this.rules.ownername"
class=
''
:caption=
"$t('entities.ibizlist.edit_datapanel_form.details.ownername')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.ownername.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.ownername"
@
enter=
"onEnter($event)"
unit=
""
:disabled=
"detailsModel.ownername.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
</row>
</app-form-group>
</i-col>
</row>
</i-form>
\ No newline at end of file
app_CRM/src/widgets/ibiz-list/edit-data-panel-form/edit-data-panel-form.vue
0 → 100644
浏览文件 @
2082a1ad
<
template
src=
"./edit-data-panel-form.html"
/>
<script
lang=
'tsx'
>
import
{ Component } from 'vue-property-decorator';
import { VueLifeCycleProcessing } from '@/studio-core';
import { Edit_DataPanelEditFormBase } from './edit-data-panel-form-base';
/**
* form部件
*
* @export
* @class Edit_DataPanelEditForm
* @extends {Edit_DataPanelEditFormBase}
*/
@Component({
components: {
}
})
@VueLifeCycleProcessing()
export default class Edit_DataPanelEditForm extends Edit_DataPanelEditFormBase { }
</script>
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录