Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
功
功能演示系统
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
示例
功能演示系统
提交
185531d2
提交
185531d2
编写于
11月 04, 2022
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Mosher 发布系统代码 [后台服务,演示应用]
上级
f8c5c2d2
变更
40
隐藏空白字符变更
内嵌
并排
正在显示
40 个修改的文件
包含
2397 行增加
和
73 行删除
+2397
-73
app-field-image-dynamic.vue
...media/app-field-image-dynamic/app-field-image-dynamic.vue
+23
-19
app-rawitem-carousel.vue
...ement/media/app-rawitem-carousel/app-rawitem-carousel.vue
+19
-13
app-rawitem-image.vue
...out-element/media/app-rawitem-image/app-rawitem-image.vue
+22
-15
app-rawitem-video.vue
...out-element/media/app-rawitem-video/app-rawitem-video.vue
+29
-6
index.ts
app_Web/src/interface/logic/index.ts
+2
-0
logic-link.ts
app_Web/src/interface/logic/logic-link.ts
+31
-0
logic-node.ts
app_Web/src/interface/logic/logic-node.ts
+128
-0
logic-param-type.ts
app_Web/src/logic/const/logic-param-type.ts
+48
-0
logic-param-value-type.ts
app_Web/src/logic/const/logic-param-value-type.ts
+37
-0
logic-return-type.ts
app_Web/src/logic/const/logic-return-type.ts
+26
-0
action-context.ts
app_Web/src/logic/de-logic/action-context.ts
+149
-0
index.ts
app_Web/src/logic/ui-logic/index.ts
+2
-0
appendparam-node.ts
app_Web/src/logic/ui-logic/logic-node/appendparam-node.ts
+54
-0
begin-node.ts
app_Web/src/logic/ui-logic/logic-node/begin-node.ts
+19
-0
bindparam-node.ts
app_Web/src/logic/ui-logic/logic-node/bindparam-node.ts
+50
-0
copyparam-node.ts
app_Web/src/logic/ui-logic/logic-node/copyparam-node.ts
+53
-0
deaction-node.ts
app_Web/src/logic/ui-logic/logic-node/deaction-node.ts
+106
-0
debugparam-node.ts
app_Web/src/logic/ui-logic/logic-node/debugparam-node.ts
+47
-0
dedataset-node.ts
app_Web/src/logic/ui-logic/logic-node/dedataset-node.ts
+75
-0
delogic-node.ts
app_Web/src/logic/ui-logic/logic-node/delogic-node.ts
+65
-0
deuiaction-node.ts
app_Web/src/logic/ui-logic/logic-node/deuiaction-node.ts
+73
-0
end-node.ts
app_Web/src/logic/ui-logic/logic-node/end-node.ts
+63
-0
index.ts
app_Web/src/logic/ui-logic/logic-node/index.ts
+21
-0
logic-node-base.ts
app_Web/src/logic/ui-logic/logic-node/logic-node-base.ts
+90
-0
msgbox-node.ts
app_Web/src/logic/ui-logic/logic-node/msgbox-node.ts
+71
-0
plugin-node.ts
app_Web/src/logic/ui-logic/logic-node/plugin-node.ts
+26
-0
prepareparam-node.ts
app_Web/src/logic/ui-logic/logic-node/prepareparam-node.ts
+362
-0
rawcode-node.ts
app_Web/src/logic/ui-logic/logic-node/rawcode-node.ts
+50
-0
renewparam-node.ts
app_Web/src/logic/ui-logic/logic-node/renewparam-node.ts
+52
-0
resetparam-node.ts
app_Web/src/logic/ui-logic/logic-node/resetparam-node.ts
+52
-0
sortparam-node.ts
app_Web/src/logic/ui-logic/logic-node/sortparam-node.ts
+50
-0
throw-exception-node.ts
...Web/src/logic/ui-logic/logic-node/throw-exception-node.ts
+33
-0
viewctrl-fire-event.ts
app_Web/src/logic/ui-logic/logic-node/viewctrl-fire-event.ts
+77
-0
viewctrl-invoke-node.ts
...Web/src/logic/ui-logic/logic-node/viewctrl-invoke-node.ts
+62
-0
uiaction-context.ts
app_Web/src/logic/ui-logic/uiaction-context.ts
+230
-0
grid-view-load-ui-logic-base.ts
...b/src/uiservice/ibizorder/grid-view-load-ui-logic-base.ts
+44
-4
open-yu-que-ui-logic-base.ts
app_Web/src/uiservice/ibizorder/open-yu-que-ui-logic-base.ts
+45
-5
default-searchform-base.vue
...s/ibizbook/default-searchform/default-searchform-base.vue
+2
-2
main-form-base.vue
app_Web/src/widgets/ibizbook/main-form/main-form-base.vue
+5
-5
list-exp-list-base.vue
...rc/widgets/ibizorder/list-exp-list/list-exp-list-base.vue
+4
-4
未找到文件。
app_Web/src/components/layout-element/media/app-field-image-dynamic/app-field-image-dynamic.vue
浏览文件 @
185531d2
<
template
>
<
template
>
<div
:class=
"
{'app-field-image-dynamic':true,[`${cssClass}`]:cssClass?true:false}
">
<div
:class=
"
['app-field-image-dynamic', model.sysCss]"
:style=
"containerStyle
"
>
<img
:style=
"
cssStyle
"
:src=
"imgUrl"
/>
<img
:style=
"
model.sysCss
"
:src=
"imgUrl"
/>
</div>
</div>
</
template
>
</
template
>
<
script
lang =
'ts'
>
<
script
lang =
'ts'
>
import
{
Vue
,
Component
,
Prop
,
Watch
,
Provide
}
from
'vue-property-decorator'
;
import
{
Vue
,
Component
,
Prop
,
Watch
,
Provide
}
from
'vue-property-decorator'
;
import
{
ImgurlBase64
}
from
'@/utils'
;
import
{
ImgurlBase64
}
from
'@/utils'
;
import
{
Environment
}
from
"@/environments/environment"
;
import
{
Environment
}
from
"@/environments/environment"
;
import
{
PanelFieldModel
}
from
'@/model/panel-detail'
;
@
Component
({})
@
Component
({})
export
default
class
AppFieldImageDynamic
extends
Vue
{
export
default
class
AppFieldImageDynamic
extends
Vue
{
...
@@ -14,57 +15,60 @@ export default class AppFieldImageDynamic extends Vue {
...
@@ -14,57 +15,60 @@ export default class AppFieldImageDynamic extends Vue {
* 输入值
* 输入值
*
*
* @type {string}
* @type {string}
* @memberof App
RawItemImage
* @memberof App
FieldImageDynamic
*/
*/
@
Prop
()
public
value
:
any
;
@
Prop
()
public
value
:
any
;
/**
/**
*
样式
*
模型
*
*
* @type {string}
* @type {*}
* @memberof AppRawItemImage
* @memberof AppFieldImageDynamic
*/
@
Prop
()
public
cssStyle
?:
string
;
/**
* 样式表类名
*
* @type {string}
* @memberof AppRawItemImage
*/
*/
@
Prop
({
default
:
''
})
public
cssClass
?:
string
;
@
Prop
()
public
model
!
:
PanelFieldModel
;
/**
/**
* 动态图片路径
* 动态图片路径
*
*
* @memberof App
PresetRawitem
* @memberof App
FieldImageDynamic
*/
*/
protected
dynaImgUrl
:
string
=
''
;
protected
dynaImgUrl
:
string
=
''
;
/**
/**
* 下载文件路径
* 下载文件路径
*
*
* @memberof App
PresetRawitem
* @memberof App
FieldImageDynamic
*/
*/
public
downloadUrl
=
Environment
.
ExportFile
;
public
downloadUrl
=
Environment
.
ExportFile
;
/**
* 容器样式
*
* @type {any}
* @memberof AppFieldImageDynamic
*/
public
containerStyle
:
any
=
null
;
/**
/**
* 图片路径
* 图片路径
*
*
* @memberof App
PresetRawitem
* @memberof App
FieldImageDynamic
*/
*/
get
imgUrl
():
string
{
get
imgUrl
():
string
{
return
this
.
dynaImgUrl
;
return
this
.
dynaImgUrl
;
}
}
created
()
{
created
()
{
if
(
this
.
model
)
{
this
.
containerStyle
=
this
.
model
.
getElementStyle
();
}
this
.
handleDynaImg
();
this
.
handleDynaImg
();
}
}
/**
/**
* 处理动态图片
* 处理动态图片
*
*
* @memberof App
PresetRawitem
* @memberof App
FieldImageDynamic
*/
*/
protected
handleDynaImg
()
{
protected
handleDynaImg
()
{
if
(
this
.
value
&&
typeof
this
.
value
==
"string"
)
{
if
(
this
.
value
&&
typeof
this
.
value
==
"string"
)
{
...
...
app_Web/src/components/layout-element/media/app-rawitem-carousel/app-rawitem-carousel.vue
浏览文件 @
185531d2
<
template
>
<
template
>
<div
class=
"app-rawitem-carousel"
>
<div
:class=
"['app-rawitem-carousel',model.sysCss]"
:style=
"containerStyle"
>
<el-carousel
class=
"carsouel-container"
<el-carousel
class=
"carsouel-container"
height=
"150px"
height=
"150px"
indicator-position=
"outside"
indicator-position=
"outside"
...
@@ -16,6 +16,7 @@
...
@@ -16,6 +16,7 @@
</div>
</div>
</
template
>
</
template
>
<
script
lang=
'ts'
>
<
script
lang=
'ts'
>
import
{
PanelFieldModel
}
from
'@/model/panel-detail'
;
import
{
Component
,
Vue
,
Prop
,
Watch
}
from
'vue-property-decorator'
;
import
{
Component
,
Vue
,
Prop
,
Watch
}
from
'vue-property-decorator'
;
@
Component
({})
@
Component
({})
export
default
class
AppCarousel
extends
Vue
{
export
default
class
AppCarousel
extends
Vue
{
...
@@ -23,7 +24,7 @@ export default class AppCarousel extends Vue {
...
@@ -23,7 +24,7 @@ export default class AppCarousel extends Vue {
* 父项所有数据
* 父项所有数据
*
*
* @type {*}
* @type {*}
* @memberof App
Preset
Carousel
* @memberof AppCarousel
*/
*/
@
Prop
()
public
data
?:
any
;
@
Prop
()
public
data
?:
any
;
...
@@ -35,18 +36,12 @@ export default class AppCarousel extends Vue {
...
@@ -35,18 +36,12 @@ export default class AppCarousel extends Vue {
@
Prop
()
public
value
?:
any
;
@
Prop
()
public
value
?:
any
;
/**
/**
* @description 轮播图样式
* 模型
* @param {*}
*
* @type {*}
* @memberof AppCarousel
* @memberof AppCarousel
*/
*/
@
Prop
()
public
cssStyle
?:
any
;
@
Prop
()
public
model
!
:
PanelFieldModel
;
/**
* @description 样式表
* @param {*}
* @memberof AppCarousel
*/
@
Prop
()
public
cssClass
?:
any
;
/**
/**
* 名称
* 名称
...
@@ -77,6 +72,14 @@ export default class AppCarousel extends Vue {
...
@@ -77,6 +72,14 @@ export default class AppCarousel extends Vue {
*/
*/
public
swipeConfig
:
any
=
{};
public
swipeConfig
:
any
=
{};
/**
* 容器样式
*
* @type {any}
* @memberof AppCarousel
*/
public
containerStyle
:
any
=
null
;
/**
/**
* data值变化
* data值变化
*
*
...
@@ -87,7 +90,7 @@ export default class AppCarousel extends Vue {
...
@@ -87,7 +90,7 @@ export default class AppCarousel extends Vue {
@
Watch
(
'value'
,
{
immediate
:
true
,
deep
:
true
})
@
Watch
(
'value'
,
{
immediate
:
true
,
deep
:
true
})
public
onDataChange
(
newVal
:
any
,
oldVal
:
any
)
{
public
onDataChange
(
newVal
:
any
,
oldVal
:
any
)
{
if
(
newVal
)
{
if
(
newVal
)
{
//
this.handleSwipData(newVal);
this
.
handleSwipData
(
newVal
);
}
}
}
}
...
@@ -96,6 +99,9 @@ export default class AppCarousel extends Vue {
...
@@ -96,6 +99,9 @@ export default class AppCarousel extends Vue {
* @memberof AppCarousel
* @memberof AppCarousel
*/
*/
created
()
{
created
()
{
if
(
this
.
model
)
{
this
.
containerStyle
=
this
.
model
.
getElementStyle
();
}
//处理轮播图-动态数据
//处理轮播图-动态数据
if
(
this
.
type
===
"FIELD_CAROUSEL"
)
{
if
(
this
.
type
===
"FIELD_CAROUSEL"
)
{
if
(
this
.
value
&&
typeof
this
.
value
===
'string'
)
{
if
(
this
.
value
&&
typeof
this
.
value
===
'string'
)
{
...
...
app_Web/src/components/layout-element/media/app-rawitem-image/app-rawitem-image.vue
浏览文件 @
185531d2
<
template
>
<
template
>
<div
class=
'app-rawitem-image'
>
<div
:class=
"['app-rawitem-image', model.sysCss]"
:style=
"containerStyle"
>
<img
:style=
"cssStyle"
v-if=
"imgUrl"
:src=
"imgUrl"
/>
<img
v-if=
"imgUrl"
:src=
"imgUrl"
/>
<i
:style=
"cssStyle"
v-else
:class=
"imageClass ? imageClass : ''"
></i>
<i
v-else
:class=
"imageClass ? imageClass : ''"
></i>
</div>
</div>
</
template
>
</
template
>
<
script
lang =
'ts'
>
<
script
lang =
'ts'
>
import
{
PanelFieldModel
}
from
'@/model/panel-detail'
;
import
{
Vue
,
Component
,
Prop
,
Watch
,
Provide
}
from
'vue-property-decorator'
;
import
{
Vue
,
Component
,
Prop
,
Watch
,
Provide
}
from
'vue-property-decorator'
;
@
Component
({})
@
Component
({})
export
default
class
AppRawItemImage
extends
Vue
{
export
default
class
AppRawItemImage
extends
Vue
{
/**
/**
*
样式
*
模型
*
*
* @type {
string
}
* @type {
*
}
* @memberof AppRawItemImage
* @memberof AppRawItemImage
*/
*/
@
Prop
()
public
cssStyle
:
any
;
@
Prop
()
public
model
!
:
PanelFieldModel
;
/**
/**
*
样式表
*
图片地址
*
*
* @type {string}
* @type {string}
* @memberof AppRawItemImage
* @memberof AppRawItemImage
*/
*/
@
Prop
()
public
cssClass
:
any
;
@
Prop
()
public
imgUrl
?:
string
;
/**
/**
* 图
片地址
* 图
标
*
*
* @type {string}
* @type {string}
* @memberof AppRawItemImage
* @memberof AppRawItemImage
*/
*/
@
Prop
()
public
im
gUrl
?:
string
;
@
Prop
()
public
im
ageClass
?:
string
;
/**
/**
*
图标
*
容器样式
*
*
* @type {
string
}
* @type {
any
}
* @memberof AppRawItemImage
* @memberof AppRawItemImage
*/
*/
@
Prop
()
public
imageClass
?:
string
;
public
containerStyle
:
any
=
null
;
created
()
{
if
(
this
.
model
)
{
this
.
containerStyle
=
this
.
model
.
getElementStyle
();
}
}
}
}
</
script
>
</
script
>
<
style
lang =
"less"
>
<
style
lang =
"less"
>
...
...
app_Web/src/components/layout-element/media/app-rawitem-video/app-rawitem-video.vue
浏览文件 @
185531d2
...
@@ -10,19 +10,41 @@
...
@@ -10,19 +10,41 @@
</
template
>
</
template
>
<
script
lang=
"ts"
>
<
script
lang=
"ts"
>
import
{
PanelFieldModel
}
from
'@/model/panel-detail'
;
import
{
Util
}
from
'@/utils'
;
import
{
Util
}
from
'@/utils'
;
import
{
Component
,
Vue
,
Prop
}
from
'vue-property-decorator'
;
import
{
Component
,
Vue
,
Prop
}
from
'vue-property-decorator'
;
@
Component
({})
@
Component
({})
export
default
class
AppVideo
extends
Vue
{
export
default
class
AppRawItemVideo
extends
Vue
{
/**
* 视频播放数据
* @memberof AppRawItemVideo
*/
@
Prop
()
public
videoParmas
?:
any
;
/**
* 模型
*
* @type {*}
* @memberof @memberof AppRawItemVideo
*/
@
Prop
()
public
model
!
:
PanelFieldModel
;
/**
/**
* 播放器唯一标识
* 播放器唯一标识
* @memberof AppRawItemVideo
*/
*/
public
uuid
:
string
=
Util
.
createUUID
();
public
uuid
:
string
=
Util
.
createUUID
();
/**
/**
* 视频播放数据
* 容器样式
*
* @type {any}
* @memberof AppRawItemVideo
*/
*/
@
Prop
()
public
videoParmas
?:
any
;
public
containerStyle
:
any
=
null
;
//视频播放参数
//视频播放参数
public
playerParams
=
{
public
playerParams
=
{
...
@@ -39,6 +61,7 @@ export default class AppVideo extends Vue {
...
@@ -39,6 +61,7 @@ export default class AppVideo extends Vue {
/**
/**
* 生命周期
* 生命周期
* @memberof AppRawItemVideo
*/
*/
public
mounted
()
{
public
mounted
()
{
this
.
handleStaticVideo
();
this
.
handleStaticVideo
();
...
@@ -47,15 +70,15 @@ export default class AppVideo extends Vue {
...
@@ -47,15 +70,15 @@ export default class AppVideo extends Vue {
/**
/**
* 处理静态视频播放
* 处理静态视频播放
*
*
* @memberof App
PresetRawitem
* @memberof App
RawItemVideo
*/
*/
protected
handleStaticVideo
()
{
protected
handleStaticVideo
()
{
if
(
this
.
videoParmas
&&
this
.
videoParmas
.
length
>
0
)
{
if
(
this
.
videoParmas
&&
this
.
videoParmas
.
length
>
0
)
{
const
rawParams
:
any
=
{};
const
rawParams
:
any
=
{};
this
.
videoParmas
.
forEach
((
param
:
any
)
=>
{
this
.
videoParmas
.
forEach
((
param
:
any
)
=>
{
rawParams
[
param
.
key
]
=
param
.
value
;
rawParams
[
param
.
key
]
=
param
.
value
;
})
})
Object
.
assign
(
this
.
playerParams
,
rawParams
);
Object
.
assign
(
this
.
playerParams
,
rawParams
);
}
}
}
}
}
}
...
...
app_Web/src/interface/logic/index.ts
0 → 100644
浏览文件 @
185531d2
export
*
from
'./logic-node'
;
export
*
from
'./logic-link'
;
\ No newline at end of file
app_Web/src/interface/logic/logic-link.ts
0 → 100644
浏览文件 @
185531d2
/**
* 逻辑连接接口
*
* @export
* @interface ILogicLink
*/
export
interface
ILogicLink
{
/**
* 名称
*
* @type {string}
* @memberof ILogicLink
*/
name
:
string
;
/**
* 下一节点标识
*
* @type {string}
* @memberof ILogicLink
*/
dstLogicNode
:
string
;
/**
* 连接条件
*
* @type {any[]}
* @memberof ILogicLink
*/
linkGroupCond
?:
any
[]
}
\ No newline at end of file
app_Web/src/interface/logic/logic-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicLink
}
from
"./logic-link"
;
/**
* 逻辑节点接口
*
* @export
* @interface ILogicNode
*/
export
interface
ILogicNode
{
/**
* 代码标识
*
* @type {string}
* @memberof ILogicNode
*/
codeName
:
string
;
/**
* 名称
*
* @type {string}
* @memberof ILogicNode
*/
name
:
string
;
/**
* 逻辑节点类型
* @description 值模式 [云实体逻辑处理节点类型(全部,包括界面逻辑)] {BEGIN:开始、 DEACTION:实体行为、 PREPAREPARAM:准备参数、 RESETPARAM:重置参数、 COPYPARAM:拷贝参数、 BINDPARAM:绑定参数、 APPENDPARAM:附加到数组参数、 SORTPARAM:排序数组参数、 RENEWPARAM:重新建立参数、 RAWSQLCALL:直接SQL调用、 RAWSQLANDLOOPCALL:直接SQL并循环调用、 RAWWEBCALL:直接Web调用、 STARTWF:启动流程、 CANCELWF:取消流程、 THROWEXCEPTION:抛出异常、 SFPLUGIN:系统服务插件、 RAWSFCODE:直接后台代码、 SYSLOGIC:系统逻辑处理、 PREPAREJSPARAM:准备参数、 VIEWCTRLINVOKE:视图部件调用、 RAWJSCODE:直接前台代码、 MSGBOX:消息弹窗、 PFPLUGIN:前端插件调用、 DEUIACTION:实体界面行为调用、 MAINSTATE:主状态、 DEDATASET:实体数据集、 DENOTIFY:实体通知、 DELOGIC:实体逻辑、 COMMIT:提交事务、 ROLLBACK:回滚事务、 DEBUGPARAM:调试逻辑参数、 DEDATAQUERY:实体数据查询、 DEPRINT:实体打印、 DEREPORT:实体报表、 DEDTSQUEUE:实体异步处理队列、 DEDATASYNC:实体数据同步、 DEDATAIMP:实体数据导入、 DEDATAEXP:实体数据导出、 DEDATAAUDIT:实体访问审计、 SUBSYSSAMETHOD:外部服务接口方法、 SYSDATASYNCAGENTOUT:系统数据同步代理输出、 SYSDBTABLEACTION:系统数据库表操作、 SYSBDTABLEACTION:系统大数据表操作、 SYSSEARCHDOCACTION:系统检索文档操作、 SYSBIREPORT:系统智能报表、 END:结束 }
* @type {( string | 'BEGIN' | 'DEACTION' | 'PREPAREPARAM' | 'RESETPARAM' | 'COPYPARAM' | 'BINDPARAM' | 'APPENDPARAM' | 'SORTPARAM' | 'RENEWPARAM' | 'RAWSQLCALL' | 'RAWSQLANDLOOPCALL' | 'RAWWEBCALL' | 'STARTWF' | 'CANCELWF' | 'THROWEXCEPTION' | 'SFPLUGIN' | 'RAWSFCODE' | 'SYSLOGIC' | 'PREPAREJSPARAM' | 'VIEWCTRLINVOKE' | 'RAWJSCODE' | 'MSGBOX' | 'PFPLUGIN' | 'DEUIACTION' | 'MAINSTATE' | 'DEDATASET' | 'DENOTIFY' | 'DELOGIC' | 'COMMIT' | 'ROLLBACK' | 'DEBUGPARAM' | 'DEDATAQUERY' | 'DEPRINT' | 'DEREPORT' | 'DEDTSQUEUE' | 'DEDATASYNC' | 'DEDATAIMP' | 'DEDATAEXP' | 'DEDATAAUDIT' | 'SUBSYSSAMETHOD' | 'SYSDATASYNCAGENTOUT' | 'SYSDBTABLEACTION' | 'SYSBDTABLEACTION' | 'SYSSEARCHDOCACTION' | 'SYSBIREPORT' | 'END')}
*/
logicNodeType
:
string
|
'BEGIN'
|
'DEACTION'
|
'PREPAREPARAM'
|
'RESETPARAM'
|
'COPYPARAM'
|
'BINDPARAM'
|
'APPENDPARAM'
|
'SORTPARAM'
|
'RENEWPARAM'
|
'RAWSQLCALL'
|
'RAWSQLANDLOOPCALL'
|
'RAWWEBCALL'
|
'STARTWF'
|
'CANCELWF'
|
'THROWEXCEPTION'
|
'SFPLUGIN'
|
'RAWSFCODE'
|
'SYSLOGIC'
|
'PREPAREJSPARAM'
|
'VIEWCTRLINVOKE'
|
'RAWJSCODE'
|
'MSGBOX'
|
'PFPLUGIN'
|
'DEUIACTION'
|
'MAINSTATE'
|
'DEDATASET'
|
'DENOTIFY'
|
'DELOGIC'
|
'COMMIT'
|
'ROLLBACK'
|
'DEBUGPARAM'
|
'DEDATAQUERY'
|
'DEPRINT'
|
'DEREPORT'
|
'DEDTSQUEUE'
|
'DEDATASYNC'
|
'DEDATAIMP'
|
'DEDATAEXP'
|
'DEDATAAUDIT'
|
'SUBSYSSAMETHOD'
|
'SYSDATASYNCAGENTOUT'
|
'SYSDBTABLEACTION'
|
'SYSBDTABLEACTION'
|
'SYSSEARCHDOCACTION'
|
'SYSBIREPORT'
|
'END'
;
/**
* 目标逻辑参数
*
* @type {string}
* @memberof ILogicNode
*/
dstParam
?:
string
;
/**
* 目标参数属性
*
* @type {string}
* @memberof ILogicNode
*/
dstFieldName
?:
string
;
/**
* 目标列表参数起始位置
*
* @type {number}
* @memberof ILogicNode
*/
dstIndex
?:
number
;
/**
* 源逻辑参数
*
* @type {string}
* @memberof ILogicNode
*/
srcParam
?:
string
;
/**
* 源属性名称
*
* @type {string}
* @memberof ILogicNode
*/
srcFieldName
?:
string
;
/**
* 源列表参数起始位置
*
* @type {number}
* @memberof ILogicNode
*/
srcIndex
?:
number
;
/**
* 直接值
*
* @type {string}
* @memberof ILogicNode
*/
srcValue
?:
string
;
/**
* 源列表参数大小
*
* @type {number}
* @memberof ILogicNode
*/
srcSize
?:
number
;
/**
* 逻辑节点连出连接集合
*
* @type {ILogicLink[]}
* @memberof ILogicNode
*/
logicLinks
?:
ILogicLink
[];
/**
* 返回值类型
* @description 值模式 [云实体处理处理返回值类型] {NONEVALUE:无值(NONE)、 NULLVALUE:空值(NULL)、 SRCVALUE:直接值、 LOGICPARAM:逻辑参数对象、 LOGICPARAMFIELD:逻辑参数属性、 BREAK:跳出循环(BREAK) }
* @type {( string | 'NONEVALUE' | 'NULLVALUE' | 'SRCVALUE' | 'LOGICPARAM' | 'LOGICPARAMFIELD' | 'BREAK')}
*/
returnType
?:
string
|
'NONEVALUE'
|
'NULLVALUE'
|
'SRCVALUE'
|
'LOGICPARAM'
|
'LOGICPARAMFIELD'
|
'BREAK'
;
/**
* 返回参数
*
* @type {string}
* @memberof ILogicNode
*/
returnParam
?:
string
;
/**
* 返回直接值
*
* @type {string}
* @memberof ILogicNode
*/
returnRawValue
?:
string
;
}
\ No newline at end of file
app_Web/src/logic/const/logic-param-type.ts
0 → 100644
浏览文件 @
185531d2
export
enum
LogicParamType
{
/**
* 简单数据变量
*/
simpleParam
=
'simpleParam'
,
/**
* 数据对象变量
*/
entityParam
=
'entityParam'
,
/**
* 分页查询结果变量
*/
entityPageParam
=
'entityPageParam'
,
/**
* 数据对象列表变量
*/
entityListParam
=
'entityListParam'
,
/**
* 上一次调用返回变量
*/
lastReturnParam
=
'lastReturnParam'
,
/**
* 过滤器对象变量
*/
filterParam
=
'filterParam'
,
/**
* 简单数据列表变量
*/
simpleListParam
=
'simpleListParam'
,
/**
* 应用上下文变量
*/
appContextParam
=
'appContextParam'
,
/**
* 应用全局变量
*/
appGlobalParam
=
'appGlobalParam'
}
\ No newline at end of file
app_Web/src/logic/const/logic-param-value-type.ts
0 → 100644
浏览文件 @
185531d2
export
enum
LogicParamValueType
{
/**
* 设置变量
*/
SETPARAMVALUE
=
"SETPARAMVALUE"
,
/**
* 重置变量
*/
RESETPARAM
=
"RESETPARAM"
,
/**
* 拷贝变量
*/
COPYPARAM
=
"COPYPARAM"
,
/**
* 绑定参数
*/
BINDPARAM
=
"BINDPARAM"
,
/**
* 重新建立变量
*/
RENEWPARAM
=
"RENEWPARAM"
,
/**
* 附加到数组变量
*/
APPENDPARAM
=
"APPENDPARAM"
,
/**
* 排序数组变量
*/
SORTPARAM
=
"SORTPARAM"
}
\ No newline at end of file
app_Web/src/logic/const/logic-return-type.ts
0 → 100644
浏览文件 @
185531d2
export
enum
LogicReturnType
{
/**
* 无值(NONE)
*/
NONEVALUE
=
"NONEVALUE"
,
/**
* 空值(NULL)
*/
NULLVALUE
=
"NULLVALUE"
,
/**
* 直接值
*/
SRCVALUE
=
"SRCVALUE"
,
/**
* 逻辑参数对象
*/
LOGICPARAM
=
"LOGICPARAM"
,
/**
* 逻辑参数属性
*/
LOGICPARAMFIELD
=
"LOGICPARAMFIELD"
,
/**
* 跳出循环(BREAK)
*/
BREAK
=
"BREAK"
,
}
\ No newline at end of file
app_Web/src/logic/de-logic/action-context.ts
0 → 100644
浏览文件 @
185531d2
/**
* 实体处理逻辑上下文参数对象
*
* @export
* @class ActionContext
*/
export
class
ActionContext
{
/**
* 实体行为服务context
*
* @type {IContext}
* @memberof ActionContext
*/
public
appContext
:
any
;
/**
* 逻辑处理参数集合
*
* @type {Map<string, any>}
* @memberof ActionContext
*/
public
paramsMap
:
Map
<
string
,
any
>
=
new
Map
();
/**
* 默认逻辑处理参数名称
*
* @type {string}
* @memberof ActionContext
*/
private
defaultParamName
:
string
=
''
;
/**
* 默认逻辑处理参数
*
* @readonly
* @memberof ActionContext
*/
get
defaultParam
()
{
return
this
.
paramsMap
.
get
(
this
.
defaultParamName
);
}
/**
* 上一次调用返回参数名称
*
* @type {string}
* @memberof ActionContext
*/
private
lastReturnParamName
:
string
=
''
;
/**
* 绑定上一次调用返回参数
*
* @readonly
* @memberof ActionContext
*/
public
bindLastReturnParam
(
value
:
any
)
{
const
lastReturnParam
=
this
.
paramsMap
.
get
(
this
.
lastReturnParamName
);
if
(
lastReturnParam
)
{
lastReturnParam
.
bind
(
value
);
}
}
/**
* 应用上下文参数名称
*
* @type {string}
* @memberof ActionContext
*/
public
appContextParamName
:
string
=
''
;
/**
* 上下文数据(包括应用上下文和逻辑局部上下文参数)
*
* @readonly
* @memberof UIActionContext
*/
get
context
()
{
const
navContextParam
=
this
.
paramsMap
.
get
(
this
.
appContextParamName
);
if
(
navContextParam
)
{
return
navContextParam
.
getReal
();
}
else
{
return
this
.
appContext
;
}
}
/**
* 获取逻辑处理参数
*
* @param {string} key 逻辑处理参数的codeName
* @memberof ActionContext
*/
public
getParam
(
key
:
string
)
{
return
this
.
paramsMap
.
get
(
key
);
}
/**
* 返回结果
*
* @type {*}
* @memberof ActionContext
*/
private
result
:
any
;
/**
* 设置返回结果
*
* @param {*} opts
* @memberof ActionContext
*/
public
setResult
(
opts
:
any
)
{
this
.
result
=
opts
;
}
/**
* 获取返回结果
*
* @return {*}
* @memberof ActionContext
*/
public
getResult
()
{
return
this
.
result
;
}
/**
* 构造函数
*
* @param {IPSAppDELogic} logic 处理逻辑模型对象
* @param {IContext} context 实体行为服务context
* @param {IParams} params 实体行为服务data
* @memberof ActionContext
*/
constructor
(
logicParams
:
any
[],
context
:
any
,
params
:
any
)
{
this
.
appContext
=
context
;
// 初始化逻辑处理参数
// if (logic.getPSDELogicParams() && (logic.getPSDELogicParams() as IPSDELogicParam[]).length > 0) {
// for (let logicParam of (logic.getPSDELogicParams() as IPSDELogicParam[])) {
// const initValue = logicParam.default ? params : undefined;
// const logicParamInstance = AppDeLogicParamService.getLogicParamInstance(this, logicParam, initValue);
// this.paramsMap.set(logicParam.codeName, logicParamInstance);
// if (logicParam.default) this.defaultParamName = logicParam.codeName;
// if (logicParam.lastReturnParam) this.lastReturnParamName = logicParam.codeName;
// if(logicParam.appContextParam) this.appContextParamName = logicParam.codeName;
// }
// }
}
}
app_Web/src/logic/ui-logic/index.ts
0 → 100644
浏览文件 @
185531d2
export
*
from
'./logic-node'
;
export
{
UIActionContext
}
from
'./uiaction-context'
;
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/appendparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
/**
* 附加到数组参数节点
*
* @export
* @class AppendParamNode
* @extends {LogicNodeBase}
*/
export
class
UILogicAppendParamNode
extends
UILogicNodeBase
{
/**
* 执行节点
*
* @static
* @param {IPSDEAppendParamLogic} logicNode 逻辑节点
* @param {UIActionContext} actionContext 逻辑上下文
* @memberof AppDeLogicAppendParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
onAppendParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
?.
message
?
error
?.
message
:
'发生未知错误!'
}
`);
}
}
/**
* 附加到数组
*
* @param {IPSDEAppendParamLogic} logicNode
* @param {UIActionContext} actionContext
* @memberof AppDeLogicAppendParamNode
*/
public onAppendParam(logicNode: ILogicNode, actionContext: UIActionContext) {
// 源数据
const srcParam: any = actionContext.getParam(logicNode.srcParam as string);
// 目标数据
const dstParam: any = actionContext.getParam(logicNode.dstParam as string);
// 源属性
const srcFieldName: string = (logicNode.srcFieldName as string).toLowerCase();
let objParam: any;
if (srcFieldName) {
// objParam = srcParam.get(srcFieldName);
objParam = srcParam.getReal();
} else {
objParam = srcParam.getReal();
}
dstParam.append(logicNode.dstIndex, objParam, logicNode.srcIndex, logicNode.srcSize);
actionContext.bindLastReturnParam(null);
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/begin-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic/logic-node"
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
export
class
UILogicBeginNode
extends
UILogicNodeBase
{
/**
* 执行节点
*
* @static
* @param {IPSDELogicNode} logicNode 逻辑节点
* @param {ActionContext} actionContext 逻辑上下文
* @memberof AppDeLogicBeginNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// 默认设置当前逻辑返回结果为当前默认输入参数
actionContext
.
setResult
(
actionContext
.
defaultParam
.
getReal
());
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/bindparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
export
class
UILogicBindParamNode
extends
UILogicNodeBase
{
/**
* 执行节点
*
* @param {IPSDEUIBindParamLogic} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof AppUILogicBindParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
onBindParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
?.
message
?
error
?.
message
:
'发生未知错误!'
}
`);
}
}
/**
* 处理参数
*
* @param {IPSDEUIBindParamLogic} logicNode 节点模型数据
* @param {UIActionContext} actionContext 逻辑上下文
* @memberof AppUILogicBindParamNode
*/
public onBindParam(logicNode: ILogicNode, actionContext: UIActionContext) {
if (!logicNode || !logicNode.dstParam || !logicNode.srcParam) {
throw new Error(`
操作参数或者源参数缺失!
`);
}
try {
// 源数据
const srcParam: any = actionContext.getParam(logicNode.srcParam);
// 目标数据
const dstParam: any = actionContext.getParam(logicNode.dstParam);
// 源属性
const srcFieldName: string = logicNode.srcFieldName ? logicNode.srcFieldName.toLowerCase() : '';
if (srcFieldName) {
dstParam.bind(srcParam.get(srcFieldName));
} else {
dstParam.bind(srcParam.getReal());
}
actionContext.bindLastReturnParam(null);
} catch (error: any) {
throw new Error(`
逻辑参数
$
{
logicNode
.
dstParam
}
$
{
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`);
}
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/copyparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
/**
* 拷贝参数节点
*
* @export
* @class UILogicCopyParamNode
* @extends {UILogicNodeBase}
*/
export
class
UILogicCopyParamNode
extends
UILogicNodeBase
{
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicCopyParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
onCopyParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
"发生未知错误!"
}
`
);
}
}
/**
* 处理参数
*
* @param {ILogicNode} logicNode 节点模型数据
* @param {UIActionContext} actionContext 逻辑上下文
* @memberof UILogicCopyParamNode
*/
public
onCopyParam
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
if
(
!
logicNode
||
!
logicNode
.
dstParam
||
!
logicNode
.
srcParam
)
{
throw
new
Error
(
`操作参数或者源参数缺失!`
);
}
try
{
// 源数据
const
srcParam
:
any
=
actionContext
.
getParam
(
logicNode
.
srcParam
);
// 目标数据
const
dstParam
:
any
=
actionContext
.
getParam
(
logicNode
.
dstParam
);
srcParam
.
copyTo
(
dstParam
);
actionContext
.
bindLastReturnParam
(
null
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑参数
${
logicNode
.
dstParam
}${
error
&&
error
.
message
?
error
.
message
:
"发生未知错误!"
}
`
);
}
}
}
app_Web/src/logic/ui-logic/logic-node/deaction-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
/**
* 实体行为调用节点
*
* @export
* @class AppUILogicDeactionNode
*/
export
class
UILogicDeActionNode
extends
UILogicNodeBase
{
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof AppUILogicDeactionNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
await
this
.
handleDEAction
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理实体行为
*
* @private
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof AppUILogicDeactionNode
*/
private
async
handleDEAction
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// const dstEntity = logicNode.getDstPSAppDataEntity();
// const deAction = await getDstPSAppDEAction(logicNode);
// const dstParam = actionContext.getParam((logicNode.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// if (!Object.is(dstParam.logicParamType, UILogicParamType.entityListParam) && !Object.is(dstParam.logicParamType, UILogicParamType.entityParam)) {
// throw new Error(`实体行为操作参数只能为数据对象变量类型或者数据对象列表类型`);
// }
// const retParam = actionContext.getParam((logicNode.getRetPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// if (dstEntity && deAction && dstParam) {
// try {
// const service = await DataServiceHelp.getInstance().getService(dstEntity);
// const getTempContext = (data: any) => {
// const tempContext = Util.deepCopy(actionContext.context);
// if (data) {
// Object.assign(tempContext, data);
// }
// return tempContext;
// }
// // 数据对象变量类型
// if (Object.is(dstParam.logicParamType, UILogicParamType.entityParam)) {
// const tempContext = getTempContext(dstParam.getReal());
// const res = await service.execute(deAction.codeName, tempContext, dstParam.getReal() ? dstParam.getReal() : {});
// if (res && res.ok && res.data) {
// if (retParam) {
// retParam.bind(res.data);
// }
// actionContext.bindLastReturnParam(res.data);
// } else {
// throw new Error(`执行实体行为失败`);
// }
// } else {
// // 数据对象列表类型
// if (dstParam.getReal() && (dstParam.getReal().length > 0)) {
// if (dstParam.getReal().length > 20) {
// throw new Error(`操作数据量超过20条,建议使用后台处理逻辑`);
// }
// let promises: any[] = [];
// dstParam.getReal().forEach((item: any) => {
// const tempContext = getTempContext(item);
// promises.push(service.execute(deAction.codeName, tempContext, item ? item : {}));
// })
// const resArray = await Promise.all(promises);
// if (resArray && resArray.length > 0) {
// const resultArray: any[] = [];
// resArray.forEach((res: any) => {
// if (res && res.ok && res.data) {
// resultArray.push(res.data);
// }
// })
// if (retParam) {
// retParam.bind(resultArray);
// }
// actionContext.bindLastReturnParam(resultArray);
// } else {
// throw new Error(`执行实体行为失败`);
// }
// } else {
// if (retParam) {
// retParam.bind([]);
// }
// actionContext.bindLastReturnParam([]);
// }
// }
// } catch (error: any) {
// throw new Error(`${error.message ? error.message : error.data?.message ? error.data.message : '执行实体行为失败'}`);
// }
// } else {
// throw new Error(`执行实体行为所需参数不足`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/debugparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 调试逻辑参数节点
*
* @export
* @class UILogicDebugParamNode
*/
export
class
UILogicDebugParamNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicDebugParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
handleDebugParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
?.
message
?
error
?.
message
:
'发生未知错误!'
}
`);
}
}
/**
* 处理调试逻辑参数
*
* @private
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof UILogicDebugParamNode
*/
private handleDebugParam(logicNode: ILogicNode, actionContext: UIActionContext) {
// if (logicNode.getDstPSDEUILogicParam()) {
// const dstParamValue = actionContext.getParam(logicNode.getDstPSDEUILogicParam()?.codeName as string).getReal();
// actionContext.bindLastReturnParam(null);
// console.log(`
逻辑节点
$
{
logicNode
.
name
}
操作参数值
:
`, dstParamValue);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/dedataset-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
/**
* 实体数据集节点
*
* @export
* @class UILogicDataSetNode
* @extends {AppUILogicNodeBase}
*/
export
class
UILogicDataSetNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @static
* @param {ILogicNode} logicNode 逻辑节点
* @param {ActionContext} actionContext 逻辑上下文
* @memberof UILogicDataSetNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
await
this
.
handleDataSet
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
?.
message
?
error
?.
message
:
'发生未知错误!'
}
`);
}
}
/**
* 处理实体数据集
*
* @private
* @param {ILogicNode} logicNode
* @param {ActionContext} actionContext
* @memberof UILogicDataSetNode
*/
private async handleDataSet(logicNode: ILogicNode, actionContext: UIActionContext) {
// const dstEntity = logicNode.getDstPSAppDataEntity();
// await dstEntity?.fill();
// const dstDataSet = logicNode.getDstPSAppDEDataSet();
// // 过滤器
// const dstParamModel = logicNode.getDstPSDEUILogicParam();
// const dstParam = actionContext.getParam(dstParamModel?.codeName as string);
// if (!dstParamModel || !Object.is(dstParam.logicParamType, UILogicParamType.filterParam)) {
// throw new Error(`
传入参数
$
{
dstParamModel
?.
codeName
}
类型不正确,必须为过滤器对象
`);
// }
// if (dstEntity && dstDataSet) {
// try {
// const service = await DataServiceHelp.getInstance().getService(dstEntity);
// const res = await service.execute(dstDataSet.codeName, actionContext.context, dstParam.getReal() ? dstParam.getReal() : {});
// if (res && res.ok && res.data) {
// // 返回值绑定逻辑参数对象
// if (logicNode.getRetPSDEUILogicParam()) {
// const retParam = actionContext.getParam(logicNode.getRetPSDEUILogicParam()?.codeName as string);
// retParam.bind(res.data);
// }
// actionContext.bindLastReturnParam(res.data);
// } else {
// throw new Error(`
查询实体数据集失败
`);
// }
// } catch (error: any) {
// throw new Error(`
$
{
error
.
message
?
error
.
message
:
error
.
data
?.
message
?
error
.
data
.
message
:
'查询实体数据集失败'
}
`);
// }
// } else {
// throw new Error(`
查询实体数据集参数不足
`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/delogic-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 实体处理逻辑节点
*
* @export
* @class UILogicNodeBase
*/
export
class
UILogicDeLogicNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicDeLogicNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
await
this
.
handleDELogic
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
?.
message
?
error
?.
message
:
'发生未知错误!'
}
`);
}
}
/**
* 处理实体处理逻辑
*
* @private
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicDeLogicNode
*/
private async handleDELogic(logicNode: ILogicNode, actionContext: UIActionContext) {
// const dstEntity = logicNode.getDstPSAppDataEntity();
// const deLogicCodeName = logicNode.getDstPSAppDELogic()?.codeName;
// const dstParam = actionContext.getParam((logicNode.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// const retParam = actionContext.getParam((logicNode.getRetPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// if (dstEntity && dstParam && deLogicCodeName) {
// try {
// const service = await DataServiceHelp.getInstance().getService(dstEntity);
// const result = await service['executeAppDELogic'](deLogicCodeName, actionContext.context, dstParam.getReal() ? dstParam.getReal() : {});
// if (result) {
// if(retParam){
// retParam.bind(result);
// }
// actionContext.bindLastReturnParam(result);
// return retParam;
// } else {
// throw new Error(`
调用实体处理逻辑异常
`);
// }
// } catch (error: any) {
// throw new Error(`
调用实体处理逻辑异常
$
{
error
?.
message
?
error
.
message
:
''
}
`);
// }
// } else {
// throw new Error(`
调用实体处理逻辑参数不足
`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/deuiaction-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 实体界面行为调用节点
*
* @export
* @class AppUILogicDeUIActionNode
*/
export
class
UILogicDeUIActionNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof AppUILogicDeUIActionNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
await
this
.
handleDEUIAction
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
)
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理界面行为
*
* @private
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof AppUILogicDeUIActionNode
*/
private
async
handleDEUIAction
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// const data = actionContext.defaultParam.getReal();
// const { context, viewparams } = actionContext;
// const additionalParam = actionContext.additionalParam;
// const dstEntity = logicNode.getDstPSAppDataEntity();
// const dstUIAction = await getDstPSAppDEUIAction(logicNode);
// if (dstEntity && dstUIAction) {
// try {
// const targetUIService = await UIServiceHelp.getInstance().getService(dstEntity,{context});
// await targetUIService.loaded();
// const result = await targetUIService.excuteAction(
// dstUIAction.uIActionTag,
// [data],
// context,
// viewparams,
// additionalParam?.$event,
// actionContext.getParam(actionContext.activeCtrlParamName).getReal(),
// actionContext.getParam(actionContext.activeContainerParamName).getReal(),
// additionalParam?.parentDeName,
// );
// const dstParam = actionContext.getParam((logicNode.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// if (result && result.ok && result.result) {
// dstParam.bind(Array.isArray(result?.result) ? result.result[0] : result.result);
// actionContext.bindLastReturnParam(Array.isArray(result?.result) ? result.result[0] : result.result);
// }
// return dstParam;
// } catch (error: any) {
// throw new Error(`调用实体行为异常${error?.message ? error.message : ''}`);
// }
// } else {
// throw new Error(`调用界面行为参数不足`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/end-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
LogicReturnType
}
from
"@/logic/const/logic-return-type"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
/**
* 结束节点
*
* @export
* @class EndNode
*/
export
class
UILogicEndNode
extends
UILogicNodeBase
{
/**
* 执行节点
*
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @return {*}
* @memberof EndNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
handleEndNode
(
logicNode
,
actionContext
);
console
.
log
(
`已完成执行
${
logicNode
?.
name
}
节点,操作参数数据如下
:
`);
if (actionContext.paramsMap && (actionContext.paramsMap.size > 0)) {
for (let [key, value] of actionContext.paramsMap) {
console.log(`
$
{
key
}
:`
,
value
.
getReal
());
}
}
return
{
nextNodes
:
[],
actionContext
};
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理结束节点
*
* @private
* @param {IPSDEEndLogic} logicNode
* @param {UIActionContext} actionContext
* @memberof EndNode
*/
private
handleEndNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
const
strReturnType
:
string
=
logicNode
.
returnType
as
string
;
if
(
Object
.
is
(
strReturnType
,
LogicReturnType
.
NONEVALUE
)
||
Object
.
is
(
strReturnType
,
LogicReturnType
.
NULLVALUE
))
{
actionContext
.
setResult
(
null
);
}
else
if
(
Object
.
is
(
strReturnType
,
LogicReturnType
.
SRCVALUE
))
{
actionContext
.
setResult
(
logicNode
.
returnRawValue
);
}
else
if
(
Object
.
is
(
strReturnType
,
LogicReturnType
.
BREAK
))
{
actionContext
.
setResult
(
LogicReturnType
.
BREAK
);
}
else
if
(
Object
.
is
(
strReturnType
,
LogicReturnType
.
LOGICPARAM
)
||
Object
.
is
(
strReturnType
,
LogicReturnType
.
LOGICPARAMFIELD
))
{
const
returnParam
=
actionContext
.
getParam
(
logicNode
.
returnParam
as
string
);
if
(
Object
.
is
(
strReturnType
,
LogicReturnType
.
LOGICPARAM
))
{
actionContext
.
setResult
(
returnParam
.
getReal
());
}
else
{
actionContext
.
setResult
(
returnParam
.
get
(
logicNode
.
dstFieldName
));
}
}
else
{
throw
new
Error
(
`无法识别的返回值类型
${
strReturnType
}
`
);
}
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/index.ts
0 → 100644
浏览文件 @
185531d2
export
{
UILogicAppendParamNode
}
from
'./appendparam-node'
;
export
{
UILogicBeginNode
}
from
'./begin-node'
;
export
{
UILogicBindParamNode
}
from
'./bindparam-node'
;
export
{
UILogicCopyParamNode
}
from
'./copyparam-node'
;
export
{
UILogicDeActionNode
}
from
'./deaction-node'
;
export
{
UILogicDebugParamNode
}
from
'./debugparam-node'
;
export
{
UILogicDataSetNode
}
from
'./dedataset-node'
;
export
{
UILogicDeLogicNode
}
from
'./delogic-node'
;
export
{
UILogicDeUIActionNode
}
from
'./deuiaction-node'
;
export
{
UILogicEndNode
}
from
'./end-node'
;
export
{
UILogicNodeBase
}
from
'./logic-node-base'
;
export
{
UILogicMsgboxNode
}
from
'./msgbox-node'
;
export
{
UILogicPluginNode
}
from
'./plugin-node'
;
export
{
UILogicPrepareParamNode
}
from
'./prepareparam-node'
;
export
{
UILogicRawCodeNode
}
from
'./rawcode-node'
;
export
{
UILogicReNewParamNode
}
from
'./renewparam-node'
;
export
{
UILogicResetParamNode
}
from
'./resetparam-node'
;
export
{
UILogicSortParamNode
}
from
'./sortparam-node'
;
export
{
UILogicThrowExceptionNode
}
from
'./throw-exception-node'
;
export
{
UILogicViewctrlFireEventNode
}
from
'./viewctrl-fire-event'
;
export
{
UILogicViewctrlInvokeNode
}
from
'./viewctrl-invoke-node'
;
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/logic-node-base.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
Util
,
Verify
}
from
"@/utils"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
/**
* 处理逻辑节点基类
*
* @export
* @class UILogicNodeBase
*/
export
class
UILogicNodeBase
{
constructor
()
{}
/**
* 根据处理链接计算后续逻辑节点
*
* @param {*} logicNode
* @param {UIActionContext} actionContext
* @return {*}
* @memberof LogicNodeBase
*/
public
computeNextNodes
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
console
.
log
(
`已完成执行
${
logicNode
?.
name
}
节点,操作参数数据如下
:
`)
if (actionContext.paramsMap && (actionContext.paramsMap.size > 0)) {
for (let [key, value] of actionContext.paramsMap) {
console.log(`
$
{
key
}
:`
,
Util
.
deepCopy
(
value
.
getReal
()));
}
}
let
result
:
any
=
{
nextNodes
:
[],
actionContext
};
if
(
logicNode
&&
logicNode
.
logicLinks
&&
logicNode
.
logicLinks
.
length
>
0
)
{
for
(
let
logicLink
of
logicNode
.
logicLinks
)
{
let
nextNode
=
logicLink
.
dstLogicNode
;
// 没有连接条件组或有条件组且满足条件组时执行下一个节点
if
(
!
logicLink
.
dstLogicNode
||
this
.
computeCond
(
logicLink
.
linkGroupCond
||
[],
actionContext
))
{
// console.log(`即将执行${nextNode?}节点`);
console
.
log
(
'执行下一节点'
);
result
.
nextNodes
.
push
(
nextNode
);
}
}
}
return
result
;
}
/**
* 计算是否通过逻辑连接
*
* @param {} logicLinkCond
* @return {*}
* @memberof UILogicNodeBase
*/
public
computeCond
(
logicLinkCond
:
any
,
actionContext
:
UIActionContext
):
any
{
if
(
logicLinkCond
.
logicType
==
'GROUP'
)
{
const
logicLinkGroupCond
=
logicLinkCond
const
childConds
:
any
=
logicLinkGroupCond
.
getPSDELogicLinkConds
();
if
(
childConds
?.
length
>
0
)
{
// return Verify.logicForEach(
// childConds,
// (item: any) => {
// return this.computeCond(item, actionContext);
// },
// logicLinkGroupCond.groupOP,
// !!logicLinkGroupCond.notMode,
// );
}
}
else
{
if
(
logicLinkCond
.
logicType
==
'SINGLE'
)
{
const
logicLinkSingleCond
=
logicLinkCond
let
dstValue
=
actionContext
.
getParam
(
logicLinkSingleCond
?.
getDstLogicParam
?.()?.
codeName
as
string
);
if
(
logicLinkSingleCond
.
dstFieldName
)
{
dstValue
=
dstValue
.
get
(
logicLinkSingleCond
.
dstFieldName
.
toLowerCase
());
}
let
targetValue
;
if
(
logicLinkSingleCond
.
paramType
)
{
switch
(
logicLinkSingleCond
.
paramType
)
{
case
'CURTIME'
:
targetValue
=
Util
.
dateFormat
(
new
Date
(),
'YYYY-MM-DD'
);
break
;
default
:
targetValue
=
logicLinkSingleCond
.
paramValue
;
}
}
else
{
targetValue
=
logicLinkSingleCond
.
paramValue
;
}
return
Verify
.
testCond
(
dstValue
,
logicLinkSingleCond
.
condOP
,
targetValue
)
}
}
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/msgbox-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
Subject
}
from
'rxjs'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 消息弹窗节点
*
* @export
* @class UILogicMsgboxNode
*/
export
class
UILogicMsgboxNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicMsgboxNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
// return new Promise<void>((resolve) => {
// let msgBoxParam: any = actionContext.getParam((logicNode.getMsgBoxParam() as IPSDEUILogicParam)?.codeName);
// const data = msgBoxParam?.getReal();
// const options = {
// type: logicNode.msgBoxType?.toLowerCase(),
// title: data?.title ? data.title : logicNode.title ? eval('`' + logicNode.title + '`') : '消息',
// content: data?.message ? data.message : logicNode.message ? eval('`' + logicNode.message + '`') : '',
// buttonType: logicNode.buttonsType?.toLowerCase(),
// showMode: logicNode.showMode?.toLowerCase(),
// showClose: false,
// mask: true,
// maskClosable: true
// };
// const subject: Subject<any> | null = AppMessageBoxService.getInstance().open(options);
// const subscription = subject?.subscribe((result: any) => {
// resolve(this.handleResponse(logicNode, actionContext, options, result));
// subscription!.unsubscribe();
// subject.complete();
// })
// });
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理响应
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @param {string} result 响应结果
* @memberof UILogicMsgboxNode
*/
public
handleResponse
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
,
options
:
any
,
result
:
string
)
{
// const { buttonsType } = logicNode;
// if (!Object.is(buttonsType, 'YESNO') && !Object.is(buttonsType, 'YESNOCANCEL') && !Object.is(buttonsType, 'OK') && !Object.is(buttonsType, 'OKCANCEL')) {
// throw new Error(`${buttonsType}未实现`);
// }
// let msgBoxParam: any = actionContext.getParam((logicNode.getMsgBoxParam() as IPSDEUILogicParam)?.codeName);
// if (msgBoxParam){
// msgBoxParam.bind(result);
// }
// actionContext.bindLastReturnParam(result);
// return this.computeNextNodes(logicNode, actionContext);
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/plugin-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 前端扩展插件调用节点
*
* @export
* @class UILogicPluginNode
*/
export
class
UILogicPluginNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicPluginNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}
前端扩展插件类型暂未实现!`
);
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/prepareparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
"@/interface/logic"
;
import
{
UIActionContext
}
from
"../uiaction-context"
;
import
{
UILogicNodeBase
}
from
"./logic-node-base"
;
/**
* 准备处理参数节点
*
* @export
* @class UILogicPrepareParamNode
*/
export
class
UILogicPrepareParamNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicPrepareParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
handleParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
"发生未知错误!"
}
`
);
}
}
/**
* 处理参数
*
* @param {IPSDELogicNode} logicNode 节点模型数据
* @param {ActionContext} actionContext 逻辑上下文
* @memberof UILogicPrepareParamNode
*/
public
handleParam
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// if (!logicNode || !logicNode.getPSDEUILogicNodeParams()) {
// return;
// }
try
{
// for (let logicNodeParam of logicNode.getPSDEUILogicNodeParams() as any[]) {
// // 设置变量
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.SETPARAMVALUE)) {
// this.onSetParamValue(logicNodeParam, actionContext);
// }
// // 重置变量
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.RESETPARAM)) {
// this.onResetParam(logicNodeParam, actionContext);
// }
// // 拷贝变量
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.COPYPARAM)) {
// this.onCopyParam(logicNodeParam, actionContext);
// }
// // 绑定参数
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.BINDPARAM)) {
// this.onBindParam(logicNodeParam, actionContext);
// }
// // 重新建立变量
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.RENEWPARAM)) {
// this.onRenewParam(logicNodeParam, actionContext);
// }
// // 附加到数组变量
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.APPENDPARAM)) {
// this.onAppendParam(logicNodeParam, actionContext);
// }
// // 排序数组变量
// if (Object.is(logicNodeParam.paramAction, UILogicParamValueType.SORTPARAM)) {
// this.onSortParam(logicNodeParam, actionContext);
// }
// }
}
catch
(
error
:
any
)
{
throw
new
Error
(
`
${
error
&&
error
.
message
?
error
.
message
:
"发生未知错误!"
}
`
);
}
}
/**
* 设置参数(根据配置把源逻辑参数的值赋给目标逻辑参数)
*
* @param {any} logicNodeParam 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicPrepareParamNode
*/
public
onSetParamValue
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 源类型参数/目标逻辑参数/目标属性缺一跳过不做处理
// if (!logicNodeParam.getDstPSDEUILogicParam() || !logicNodeParam.srcValueType) {
// throw new Error(`逻辑参数${logicNodeParam.name}源类型参数或者目标逻辑参数缺失`);
// }
// // 目标数据
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 无值类型
// if (Object.is(logicNodeParam.srcValueType, "NONEVALUE")) {
// if (logicNodeParam.dstFieldName) {
// dstParam.reset(logicNodeParam.dstFieldName.toLowerCase());
// } else {
// dstParam.bind(undefined);
// }
// } else {
// const result = this.computeTargetParam(logicNodeParam, actionContext);
// if (logicNodeParam.dstFieldName) {
// dstParam.set(logicNodeParam.dstFieldName.toLowerCase(), result);
// } else {
// dstParam.bind(result);
// }
// }
// } catch (error) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 重置变量
*
* @param {any} logicNodeParam
* @param {ActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onResetParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 目标数据
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// dstParam.resetAll();
// } catch (error: any) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 拷贝变量
*
* @param {any} logicNodeParam
* @param {ActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onCopyParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 源数据
// const srcParam: any = actionContext.getParam(
// (logicNodeParam.getSrcPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 目标数据
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// srcParam.copyTo(dstParam);
// } catch (error) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 绑定参数
*
* @param {any} logicNodeParam
* @param {ActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onBindParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 源数据
// const srcParam: any = actionContext.getParam(
// (logicNodeParam.getSrcPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 目标数据
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 源属性
// const srcFieldName: string = logicNodeParam.srcFieldName?.toLowerCase?.();
// if (srcFieldName) {
// dstParam.bind(srcParam.get(srcFieldName));
// } else {
// dstParam.bind(srcParam.getReal());
// }
// } catch (error) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 重新建立变量
*
* @param {any} logicNodeParam
* @param {UIActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onRenewParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 目标参数
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// dstParam.renew();
// } catch (error) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 附加到数组变量
*
* @param {any} logicNodeParam
* @param {UIActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onAppendParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 源数据
// const srcParam: any = actionContext.getParam(
// (logicNodeParam.getSrcPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 目标数据
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 源属性
// const srcFieldName: string = logicNodeParam.srcFieldName?.toLowerCase?.();
// let objParam: any;
// if (srcFieldName) {
// objParam = srcParam.get(srcFieldName);
// } else {
// objParam = srcParam.getReal();
// }
// dstParam.append(logicNodeParam.dstIndex, objParam, logicNodeParam.srcIndex, logicNodeParam.srcSize);
// } catch (error) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 排序数组变量
*
* @param {any} logicNodeParam
* @param {UIActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onSortParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// try {
// // 目标数据
// const dstParam: any = actionContext.getParam(
// (logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 目标属性
// const dstFieldName: string = logicNodeParam.dstFieldName?.toLowerCase?.();
// if (!dstFieldName) {
// throw new Error(`逻辑参数${logicNodeParam.name}未指定设置排序属性`);
// }
// dstParam.sort(dstFieldName, logicNodeParam.dstSortDir);
// } catch (error) {
// throw new Error(
// `逻辑参数${logicNodeParam.name}${error && error.message ? error.message : "发生未知错误!"}`
// );
// }
}
/**
* 计算目标值
*
* @param {any} logicNodeParam 节点参数
* @param {ActionContext} actionContext 逻辑上下文
* @memberof UILogicPrepareParamNode
*/
public
computeTargetParam
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
// let targetValue: any;
// // 源数据
// const srcParam: any = actionContext.getParam(
// (logicNodeParam.getSrcPSDEUILogicParam() as IPSDEUILogicParam)?.codeName
// );
// // 源属性
// try {
// const srcFieldName: string = logicNodeParam?.srcFieldName?.toLowerCase();
// switch (logicNodeParam.srcValueType) {
// case "SRCDLPARAM": // 源逻辑参数
// case "WEBCONTEXT": // 网页请求上下文
// case "VIEWPARAM": // 当前视图参数
// targetValue = srcParam.get(srcFieldName) ? srcParam.get(srcFieldName) : null;
// break;
// case "APPLICATION": // 系统全局对象
// case "SESSION": // 用户全局对象
// case "APPDATA": // 应用上下文
// case "DATACONTEXT": // 数据上下文
// const { context } = actionContext;
// targetValue = context[srcFieldName];
// break;
// case "ENVPARAM": // 当前环境参数
// const Environment = AppServiceBase.getInstance().getAppEnvironment();
// targetValue = Environment[srcFieldName];
// break;
// case "EXPRESSION": // 计算式
// targetValue = this.computeExpRessionValue(logicNodeParam, actionContext);
// break;
// case "SRCVALUE": // 直接值
// targetValue = logicNodeParam?.srcValue;
// break;
// case "NULLVALUE": // 空值(NULL)
// targetValue = null;
// break;
// default:
// throw new Error(`源值类型${logicNodeParam.srcValueType}暂未支持`);
// }
// return targetValue;
// } catch (error) {
// throw new Error(`${error && error.message ? error.message : "发生未知错误!"}`);
// }
}
/**
* 计算表达式值
*
* @param {any} logicNodeParam 节点参数
* @param {ActionContext} actionContext 逻辑上下文
* @memberof UILogicPrepareParamNode
*/
private
computeExpRessionValue
(
logicNodeParam
:
any
,
actionContext
:
UIActionContext
)
{
let
expression
:
string
=
logicNodeParam
?.
expression
;
let
data
:
any
=
actionContext
.
defaultParam
.
getReal
();
let
{
context
}
=
actionContext
;
if
(
!
expression
)
{
throw
new
Error
(
`表达式不能为空`
);
}
try
{
expression
=
this
.
translateExpression
(
expression
);
return
eval
(
expression
);
}
catch
(
error
)
{
throw
new
Error
(
`表达式计算异常:
${
error
}
`
);
}
}
/**
* 解析表达式
*
* @param {string} expression 表达式
* @memberof UILogicPrepareParamNode
*/
private
translateExpression
(
expression
:
string
):
string
{
if
(
expression
.
indexOf
(
"${"
)
!=
-
1
&&
expression
.
indexOf
(
"}"
)
!=
-
1
)
{
const
start
:
number
=
expression
.
indexOf
(
"${"
);
const
end
:
number
=
expression
.
indexOf
(
"}"
);
const
contentStr
:
string
=
expression
.
slice
(
start
+
2
,
end
);
expression
=
expression
.
replace
(
expression
.
slice
(
start
,
end
+
1
),
`data.
${
contentStr
}
`
);
return
this
.
translateExpression
(
expression
);
}
return
expression
;
}
}
app_Web/src/logic/ui-logic/logic-node/rawcode-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 直接前台代码节点
*
* @export
* @class UILogicRawCodeNode
*/
export
class
UILogicRawCodeNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicRawCodeNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
handleRawCode
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处置直接执行代码
*
* @private
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof UILogicRawCodeNode
*/
private
handleRawCode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// let data: any = actionContext.defaultParam.getReal();
// let { context } = actionContext;
// if (logicNode && logicNode.code) {
// eval(logicNode?.code);
// } else {
// throw new Error('无代码片段');
// }
// actionContext.bindLastReturnParam(null);
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/renewparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 重新建立参数节点
*
* @export
* @class UILogicReNewParamNode
*/
export
class
UILogicReNewParamNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicReNewParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
onRenewParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理参数
*
* @param {ILogicNode} logicNode 节点模型数据
* @param {UIActionContext} actionContext 逻辑上下文
* @memberof UILogicReNewParamNode
*/
public
onRenewParam
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// if (!logicNode || !logicNode.getDstPSDEUILogicParam()) {
// throw new Error(`操作参数缺失!`);
// }
// try {
// // 目标数据
// const dstParam: any = actionContext.getParam((logicNode.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// dstParam.renew();
// actionContext.bindLastReturnParam(null);
// } catch (error: any) {
// throw new Error(`逻辑参数${logicNode.getDstPSDEUILogicParam()?.name}${error && error.message ? error.message : '发生未知错误!'}`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/resetparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 重置参数节点
*
* @export
* @class UILogicResetParamNode
*/
export
class
UILogicResetParamNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicResetParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
onResetParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理参数
*
* @param {IPSDELogicNode} logicNode 节点模型数据
* @param {ActionContext} actionContext 逻辑上下文
* @memberof UILogicResetParamNode
*/
public
onResetParam
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// if (!logicNode || !logicNode.getDstPSDEUILogicParam()) {
// throw new Error(`操作参数缺失!`);
// }
// try {
// // 目标数据
// const dstParam: any = actionContext.getParam((logicNode.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// dstParam.resetAll();
// actionContext.bindLastReturnParam(null);
// } catch (error: any) {
// throw new Error(`逻辑参数${logicNode.getDstPSDEUILogicParam()?.name}${error && error.message ? error.message : '发生未知错误!'}`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/sortparam-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 排序数组参数节点
*
* @export
* @class UILogicSortParamNode
*/
export
class
UILogicSortParamNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicSortParamNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
this
.
onSortParam
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 排序数组变量
*
* @param {ILogicNode} logicNodeParam
* @param {UIActionContext} actionContext
* @memberof UILogicPrepareParamNode
*/
public
onSortParam
(
logicNodeParam
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// // 目标数据
// const dstParam: any = actionContext.getParam((logicNodeParam.getDstPSDEUILogicParam() as IPSDEUILogicParam)?.codeName);
// // 目标属性
// const dstFieldName: string = logicNodeParam.dstFieldName?.toLowerCase?.();
// if (!dstFieldName) {
// throw new Error(`逻辑参数${logicNodeParam.name}未指定设置排序属性`);
// }
// dstParam.sort(dstFieldName, logicNodeParam.dstSortDir);
// actionContext.bindLastReturnParam(null);
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/throw-exception-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 抛出异常节点
*
* @export
* @class UILogicThrowExceptionNode
*/
export
class
UILogicThrowExceptionNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicThrowExceptionNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// actionContext.actionContainer.$throw(logicNode.errorInfo);
// actionContext.bindLastReturnParam(null);
// console.log(`已完成执行${logicNode?.name}节点,操作参数数据如下:`);
// if (actionContext.paramsMap && (actionContext.paramsMap.size > 0)) {
// for (let [key, value] of actionContext.paramsMap) {
// console.log(`${key}:`, value.getReal());
// }
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/viewctrl-fire-event.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 视图部件事件触发节点
*
* @export
* @class UILogicViewctrlFireEventNode
*/
export
class
UILogicViewctrlFireEventNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicViewctrlFireEventNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
await
this
.
handleViewCtrFireEvent
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理视图部件触发事件
*
* @private
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof UILogicViewctrlFireEventNode
*/
private
async
handleViewCtrFireEvent
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// // 事件名称
// const eventName = logicNode.eventName;
// // 事件参数
// const eventParam = logicNode.getEventParam();
// // 触发对象
// const fireCtrl = logicNode.getFireCtrl();
// if (!eventName || !eventParam || !fireCtrl) {
// throw new Error(`触发对象、事件名称或者事件参数缺失`);
// }
// // 触发UI对象
// const fireUICtrl = actionContext.getParam(fireCtrl.codeName).getReal();
// // 事件参数
// const eventArgs = actionContext.getParam(eventParam.codeName).getReal();
// if (!fireUICtrl) {
// throw new Error(`获取触发对象异常`);
// }
// try {
// // 自身触发
// fireUICtrl.$emit(eventName, eventArgs);
// // 如果是部件,需向视图抛出
// if (fireUICtrl.controlInstance) {
// fireUICtrl.ctrlEvent({
// controlname: fireUICtrl.controlInstance.name,
// action: eventName,
// data: eventArgs
// })
// }
// // 如果是视图,需向外抛出
// if (fireUICtrl.viewInstance) {
// fireUICtrl.$emit('view-event', { viewName: fireUICtrl.viewCodeName, action: eventName, data: eventArgs });
// }
// actionContext.bindLastReturnParam(null);
// } catch (error:any) {
// throw new Error(`视图部件事件触发未执行成功!`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/logic-node/viewctrl-invoke-node.ts
0 → 100644
浏览文件 @
185531d2
import
{
ILogicNode
}
from
'@/interface/logic'
;
import
{
UIActionContext
}
from
'../uiaction-context'
;
import
{
UILogicNodeBase
}
from
'./logic-node-base'
;
/**
* 视图部件调用节点
*
* @export
* @class UILogicViewctrlInvokeNode
*/
export
class
UILogicViewctrlInvokeNode
extends
UILogicNodeBase
{
constructor
()
{
super
();
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode 逻辑节点模型数据
* @param {UIActionContext} actionContext 界面逻辑上下文
* @memberof UILogicViewctrlInvokeNode
*/
public
async
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
await
this
.
handleViewCtrlInvoke
(
logicNode
,
actionContext
);
return
this
.
computeNextNodes
(
logicNode
,
actionContext
);
}
catch
(
error
:
any
)
{
throw
new
Error
(
`逻辑节点
${
logicNode
.
name
}${
error
&&
error
.
message
?
error
.
message
:
'发生未知错误!'
}
`
);
}
}
/**
* 处理视图部件调用
*
* @private
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof UILogicViewctrlInvokeNode
*/
private
async
handleViewCtrlInvoke
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
// const invokeCtrl = logicNode.getInvokeCtrl()?.codeName;
// const invokeMethod = logicNode.invokeMethod;
// const invokeParam = logicNode.getInvokeParam()?.codeName;
// if (!invokeCtrl || !invokeMethod) {
// throw new Error(`界面对象或者调用方法缺失`);
// }
// const invokeUICtrl = actionContext.getParam(invokeCtrl).getReal();
// if (invokeUICtrl[invokeMethod] && invokeUICtrl[invokeMethod] instanceof Function) {
// try {
// const result = await invokeUICtrl[invokeMethod]();
// if (invokeParam) {
// actionContext.getParam(invokeParam).bind(result);
// }
// actionContext.bindLastReturnParam(result);
// } catch (error:any) {
// throw new Error(`${invokeCtrl}界面对象调用${invokeMethod}方法发生异常`);
// }
// } else {
// throw new Error(`${invokeCtrl}界面对象不存在${invokeMethod}方法`);
// }
}
}
\ No newline at end of file
app_Web/src/logic/ui-logic/uiaction-context.ts
0 → 100644
浏览文件 @
185531d2
/**
* 界面处理逻辑上下文参数对象
*
* @export
* @class UIActionContext
*/
export
class
UIActionContext
{
/**
* 应用上下文
*
* @type {IContext}
* @memberof UIActionContext
*/
private
appContext
:
any
;
/**
* 视图参数
*
* @type {IParams}
* @memberof UIActionContext
*/
private
viewParam
:
any
;
/**
* 默认逻辑处理参数名称
*
* @type {string}
* @memberof UIActionContext
*/
public
defaultParamName
:
string
=
''
;
/**
* 应用上下文参数名称
*
* @type {string}
* @memberof UIActionContext
*/
public
navContextParamName
:
string
=
''
;
/**
* 视图参数名称
*
* @type {string}
* @memberof UIActionContext
*/
public
navViewParamParamName
:
string
=
''
;
/**
* 当前容器对象名称
*
* @type {string}
* @memberof UIActionContext
*/
public
activeContainerParamName
:
string
=
''
;
/**
* 当前激活部件对象名称
*
* @type {string}
* @memberof UIActionContext
*/
public
activeCtrlParamName
:
string
=
''
;
/**
* 当前激活视图对象名称
*
* @type {string}
* @memberof UIActionContext
*/
public
activeViewParamName
:
string
=
''
;
/**
* 容器对象
*
* @type {*}
* @memberof UIActionContext
*/
public
actionContainer
:
any
;
/**
* 附加参数
*
* @type {*}
* @memberof UIActionContext
*/
public
additionalParam
:
any
;
/**
* 逻辑处理参数集合
*
* @type {Map<string, any>}
* @memberof UIActionContext
*/
public
paramsMap
:
Map
<
string
,
any
>
=
new
Map
();
/**
* 默认逻辑处理参数
*
* @readonly
* @memberof UIActionContext
*/
get
defaultParam
()
{
return
this
.
paramsMap
.
get
(
this
.
defaultParamName
);
}
/**
* 上下文数据(包括应用上下文和逻辑局部上下文参数)
*
* @readonly
* @memberof UIActionContext
*/
get
context
()
{
const
navContextParam
=
this
.
paramsMap
.
get
(
this
.
navContextParamName
);
if
(
navContextParam
)
{
return
navContextParam
.
getReal
();
}
else
{
return
this
.
appContext
;
}
}
/**
* 视图参数数据(包括外部传入视图参数和逻辑局部视图参数)
*
* @readonly
* @memberof UIActionContext
*/
get
viewparams
()
{
const
navViewParamParam
=
this
.
paramsMap
.
get
(
this
.
navViewParamParamName
);
if
(
navViewParamParam
)
{
return
navViewParamParam
.
getReal
();
}
else
{
return
this
.
viewParam
;
}
}
/**
* 获取逻辑处理参数
*
* @param {string} key 逻辑处理参数的codeName
* @memberof UIActionContext
*/
public
getParam
(
key
:
string
)
{
return
this
.
paramsMap
.
get
(
key
);
}
/**
* 返回结果
*
* @type {*}
* @memberof UIActionContext
*/
private
result
:
any
;
/**
* 设置返回结果
*
* @param {*} opts
* @memberof UIActionContext
*/
public
setResult
(
opts
:
any
)
{
this
.
result
=
opts
;
}
/**
* 获取返回结果
*
* @return {*}
* @memberof UIActionContext
*/
public
getResult
()
{
return
this
.
result
;
}
/**
* 上一次调用返回参数名称
*
* @type {string}
* @memberof UIActionContext
*/
private
lastReturnParamName
:
string
=
''
;
/**
* 绑定上一次调用返回参数
*
* @readonly
* @memberof UIActionContext
*/
public
bindLastReturnParam
(
value
:
any
)
{
const
lastReturnParam
=
this
.
paramsMap
.
get
(
this
.
lastReturnParamName
);
if
(
lastReturnParam
)
{
lastReturnParam
.
bind
(
value
);
}
}
/**
* 构造函数
*
* @param {*} logic 处理逻辑模型对象
* @param {any[]} args 数据对象
* @param {*} context 应用上下文
* @param {*} params 视图参数
* @param {*} $event 事件源对象
* @param {*} xData 部件对象
* @param {*} actioncontext 界面容器对象
* @param {*} srfParentDeName 关联父应用实体代码名称
* @memberof UIActionContext
*/
constructor
(
logicParams
:
any
,
args
:
any
[],
context
:
any
=
{},
params
:
any
=
{},
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
this
.
appContext
=
context
;
this
.
viewParam
=
params
;
this
.
actionContainer
=
actioncontext
;
this
.
additionalParam
=
{
args
,
$event
,
xData
,
actioncontext
,
srfParentDeName
};
// 初始化界面逻辑处理参数
if
(
logicParams
&&
logicParams
.
length
>
0
)
{
for
(
let
logicParam
of
logicParams
)
{
// const uiLogicParamInstance = AppDeUILogicParamService.getLogicParamInstance(this, logicParam, { args, context, params, $event, xData, actioncontext, srfParentDeName });
// this.paramsMap.set(logicParam.codeName, uiLogicParamInstance);
// if (logicParam.default) this.defaultParamName = logicParam.codeName;
// if (logicParam.navContextParam) this.navContextParamName = logicParam.codeName;
// if (logicParam.navViewParamParam) this.navViewParamParamName = logicParam.codeName;
// if (logicParam.activeContainerParam) this.activeContainerParamName = logicParam.codeName;
// if (logicParam.activeCtrlParam) this.activeCtrlParamName = logicParam.codeName;
// if (logicParam.activeViewParam) this.activeViewParamName = logicParam.codeName;
// if (logicParam.lastReturnParam) this.lastReturnParamName = logicParam.codeName;
}
}
}
}
app_Web/src/uiservice/ibizorder/grid-view-load-ui-logic-base.ts
浏览文件 @
185531d2
import
{
UIActionContext
}
from
"@/logic/uiaction-context
"
;
import
{
ILogicNode
}
from
"@/interface/logic
"
;
import
{
BeginNode
,
EndNode
,
AppendParamNode
}
from
"@/logic/logic-node
"
;
import
{
UIActionContext
}
from
"@/logic/ui-logic
"
;
/**
/**
* 自定义表格数据加载
* 自定义表格数据加载
...
@@ -13,12 +13,26 @@ export default class GridViewLoadUILogicBase {
...
@@ -13,12 +13,26 @@ export default class GridViewLoadUILogicBase {
* Creates an instance of GridViewLoadBase.
* Creates an instance of GridViewLoadBase.
*
*
* @param {*} [opts={}]
* @param {*} [opts={}]
* @memberof
GridViewLoadUILogicBase
* @memberof GridViewLoadUILogicBase
*/
*/
constructor
(
opts
:
any
=
{})
{
}
constructor
(
opts
:
any
=
{})
{
}
/**
* 开始节点
*
* @protected
* @type {string}
* @memberof GridViewLoadUILogicBase
*/
protected
readonly
startLogicNode
:
string
=
'Begin'
;
protected
readonly
startLogicNode
:
string
=
'Begin'
;
/**
* 逻辑参数
*
* @protected
* @type {any[]}
* @memberof GridViewLoadUILogicBase
*/
protected
logicParams
:
any
[]
=
[
protected
logicParams
:
any
[]
=
[
{
{
name
:
'当前视图参数'
,
name
:
'当前视图参数'
,
...
@@ -77,7 +91,13 @@ export default class GridViewLoadUILogicBase {
...
@@ -77,7 +91,13 @@ export default class GridViewLoadUILogicBase {
},
},
];
];
/**
* 逻辑节点
*
* @protected
* @type {ILogicNode[]}
* @memberof GridViewLoadUILogicBase
*/
protected
logicNodes
:
ILogicNode
[]
=
[
protected
logicNodes
:
ILogicNode
[]
=
[
{
codeName
:
'Begin'
,
name
:
'开始'
,
logicNodeType
:
'BEGIN'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'BINDPARAM1'
,
}
]
},
{
codeName
:
'Begin'
,
name
:
'开始'
,
logicNodeType
:
'BEGIN'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'BINDPARAM1'
,
}
]
},
{
codeName
:
'BINDPARAM1'
,
name
:
'绑定当前搜索表单'
,
logicNodeType
:
'BINDPARAM'
,
dstParam
:
'searchForm'
,
srcParam
:
'view'
,
srcFieldName
:
'searchForm'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'VIEWCTRLINVOKE1'
,
}
]
},
{
codeName
:
'BINDPARAM1'
,
name
:
'绑定当前搜索表单'
,
logicNodeType
:
'BINDPARAM'
,
dstParam
:
'searchForm'
,
srcParam
:
'view'
,
srcFieldName
:
'searchForm'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'VIEWCTRLINVOKE1'
,
}
]
},
...
@@ -86,6 +106,19 @@ export default class GridViewLoadUILogicBase {
...
@@ -86,6 +106,19 @@ export default class GridViewLoadUILogicBase {
{
codeName
:
'VIEWCTRLINVOKE2'
,
name
:
'视图部件调用'
,
logicNodeType
:
'VIEWCTRLINVOKE'
,
dstParam
:
'viewParam'
,
srcParam
:
'grid'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'END1'
,
}
]
},
{
codeName
:
'VIEWCTRLINVOKE2'
,
name
:
'视图部件调用'
,
logicNodeType
:
'VIEWCTRLINVOKE'
,
dstParam
:
'viewParam'
,
srcParam
:
'grid'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'END1'
,
}
]
},
];
];
/**
* 执行前
*
* @param {*} args
* @param {*} [context={}]
* @param {*} [params={}]
* @param {*} [$event]
* @param {*} [xData]
* @param {*} [actioncontext]
* @param {string} [srfParentDeName]
* @return {*}
* @memberof GridViewLoadUILogicBase
*/
public
beforeExecute
(
args
:
any
,
context
:
any
=
{},
params
:
any
=
{},
public
beforeExecute
(
args
:
any
,
context
:
any
=
{},
params
:
any
=
{},
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
return
new
UIActionContext
(
this
.
logicParams
,
args
,
context
,
params
,
$event
,
xData
,
actioncontext
,
srfParentDeName
)
return
new
UIActionContext
(
this
.
logicParams
,
args
,
context
,
params
,
$event
,
xData
,
actioncontext
,
srfParentDeName
)
...
@@ -117,6 +150,13 @@ export default class GridViewLoadUILogicBase {
...
@@ -117,6 +150,13 @@ export default class GridViewLoadUILogicBase {
}
}
}
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof GridViewLoadUILogicBase
*/
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
try
{
switch
(
logicNode
.
logicNodeType
)
{
switch
(
logicNode
.
logicNodeType
)
{
...
...
app_Web/src/uiservice/ibizorder/open-yu-que-ui-logic-base.ts
浏览文件 @
185531d2
import
{
UIActionContext
}
from
"@/logic/uiaction-context
"
;
import
{
ILogicNode
}
from
"@/interface/logic
"
;
import
{
BeginNode
,
EndNode
,
AppendParamNode
}
from
"@/logic/logic-node
"
;
import
{
UIActionContext
}
from
"@/logic/ui-logic
"
;
/**
/**
* 打开语雀文档
* 打开语雀文档
...
@@ -13,12 +13,26 @@ export default class OpenYuQueUILogicBase {
...
@@ -13,12 +13,26 @@ export default class OpenYuQueUILogicBase {
* Creates an instance of OpenYuQueBase.
* Creates an instance of OpenYuQueBase.
*
*
* @param {*} [opts={}]
* @param {*} [opts={}]
* @memberof
OpenYuQueUILogicBase
* @memberof OpenYuQueUILogicBase
*/
*/
constructor
(
opts
:
any
=
{})
{
}
constructor
(
opts
:
any
=
{})
{
}
/**
* 开始节点
*
* @protected
* @type {string}
* @memberof OpenYuQueUILogicBase
*/
protected
readonly
startLogicNode
:
string
=
'Begin'
;
protected
readonly
startLogicNode
:
string
=
'Begin'
;
/**
* 逻辑参数
*
* @protected
* @type {any[]}
* @memberof OpenYuQueUILogicBase
*/
protected
logicParams
:
any
[]
=
[
protected
logicParams
:
any
[]
=
[
{
{
name
:
'传入变量'
,
name
:
'传入变量'
,
...
@@ -33,13 +47,32 @@ export default class OpenYuQueUILogicBase {
...
@@ -33,13 +47,32 @@ export default class OpenYuQueUILogicBase {
},
},
];
];
/**
* 逻辑节点
*
* @protected
* @type {ILogicNode[]}
* @memberof OpenYuQueUILogicBase
*/
protected
logicNodes
:
ILogicNode
[]
=
[
protected
logicNodes
:
ILogicNode
[]
=
[
{
codeName
:
'Begin'
,
name
:
'开始'
,
logicNodeType
:
'BEGIN'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'DEUIACTION1'
,
}
]
},
{
codeName
:
'Begin'
,
name
:
'开始'
,
logicNodeType
:
'BEGIN'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'DEUIACTION1'
,
}
]
},
{
codeName
:
'END1'
,
name
:
'结束'
,
logicNodeType
:
'END'
,
returnType
:
'NONEVALUE'
,
returnRawValue
:
''
,
},
{
codeName
:
'END1'
,
name
:
'结束'
,
logicNodeType
:
'END'
,
returnType
:
'NONEVALUE'
,
returnRawValue
:
''
,
},
{
codeName
:
'DEUIACTION1'
,
name
:
'界面行为'
,
logicNodeType
:
'DEUIACTION'
,
dstParam
:
'Default'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'END1'
,
}
]
},
{
codeName
:
'DEUIACTION1'
,
name
:
'界面行为'
,
logicNodeType
:
'DEUIACTION'
,
dstParam
:
'Default'
,
logicLinks
:
[
{
name
:
'连接名称'
,
dstLogicNode
:
'END1'
,
}
]
},
];
];
/**
* 执行前
*
* @param {*} args
* @param {*} [context={}]
* @param {*} [params={}]
* @param {*} [$event]
* @param {*} [xData]
* @param {*} [actioncontext]
* @param {string} [srfParentDeName]
* @return {*}
* @memberof OpenYuQueUILogicBase
*/
public
beforeExecute
(
args
:
any
,
context
:
any
=
{},
params
:
any
=
{},
public
beforeExecute
(
args
:
any
,
context
:
any
=
{},
params
:
any
=
{},
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
return
new
UIActionContext
(
this
.
logicParams
,
args
,
context
,
params
,
$event
,
xData
,
actioncontext
,
srfParentDeName
)
return
new
UIActionContext
(
this
.
logicParams
,
args
,
context
,
params
,
$event
,
xData
,
actioncontext
,
srfParentDeName
)
...
@@ -55,7 +88,7 @@ export default class OpenYuQueUILogicBase {
...
@@ -55,7 +88,7 @@ export default class OpenYuQueUILogicBase {
* @param {*} [xData]
* @param {*} [xData]
* @param {*} [actionContext]
* @param {*} [actionContext]
* @param {string} [srfParentDeName]
* @param {string} [srfParentDeName]
* @memberof
GridViewLoad
UILogicBase
* @memberof
OpenYuQue
UILogicBase
*/
*/
async
execute
(
args
:
any
[],
context
:
any
=
{}
,
params
:
any
=
{},
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
async
execute
(
args
:
any
[],
context
:
any
=
{}
,
params
:
any
=
{},
$event
?:
any
,
xData
?:
any
,
actioncontext
?:
any
,
srfParentDeName
?:
string
)
{
try
{
try
{
...
@@ -71,6 +104,13 @@ export default class OpenYuQueUILogicBase {
...
@@ -71,6 +104,13 @@ export default class OpenYuQueUILogicBase {
}
}
}
}
/**
* 执行节点
*
* @param {ILogicNode} logicNode
* @param {UIActionContext} actionContext
* @memberof OpenYuQueUILogicBase
*/
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
executeNode
(
logicNode
:
ILogicNode
,
actionContext
:
UIActionContext
)
{
try
{
try
{
switch
(
logicNode
.
logicNodeType
)
{
switch
(
logicNode
.
logicNodeType
)
{
...
...
app_Web/src/widgets/ibizbook/default-searchform/default-searchform-base.vue
浏览文件 @
185531d2
...
@@ -663,7 +663,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
...
@@ -663,7 +663,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
*/
public
load
(
opt
:
any
=
{}):
void
{
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
){
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKUsr
5Data
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loadAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKUsr
3Grid
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loadAction'
)
as
string
)
});
return
;
return
;
}
}
const
arg
:
any
=
{
...
opt
};
const
arg
:
any
=
{
...
opt
};
...
@@ -699,7 +699,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
...
@@ -699,7 +699,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/
*/
public
loadDraft
(
opt
:
any
=
{},
mode
?:
string
):
void
{
public
loadDraft
(
opt
:
any
=
{},
mode
?:
string
):
void
{
if
(
!
this
.
loaddraftAction
){
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKUsr
5Data
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loaddraftAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKUsr
3Grid
View'
+
(
this
.
$t
(
'app.searchForm.notConfig.loaddraftAction'
)
as
string
)
});
return
;
return
;
}
}
const
arg
:
any
=
{
...
opt
}
;
const
arg
:
any
=
{
...
opt
}
;
...
...
app_Web/src/widgets/ibizbook/main-form/main-form-base.vue
浏览文件 @
185531d2
...
@@ -1800,7 +1800,7 @@ export default class MainBase extends Vue implements ControlInterface {
...
@@ -1800,7 +1800,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
*/
public
load
(
opt
:
any
=
{}):
void
{
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
){
if
(
!
this
.
loadAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView'
+
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
return
;
return
;
}
}
const
arg
:
any
=
{
...
opt
};
const
arg
:
any
=
{
...
opt
};
...
@@ -1835,7 +1835,7 @@ export default class MainBase extends Vue implements ControlInterface {
...
@@ -1835,7 +1835,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
*/
public
loadDraft
(
opt
:
any
=
{}):
void
{
public
loadDraft
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loaddraftAction
){
if
(
!
this
.
loaddraftAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.loaddraftaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView'
+
(
this
.
$t
(
'app.formpage.notconfig.loaddraftaction'
)
as
string
)
});
return
;
return
;
}
}
const
arg
:
any
=
{
...
opt
}
;
const
arg
:
any
=
{
...
opt
}
;
...
@@ -1897,7 +1897,7 @@ export default class MainBase extends Vue implements ControlInterface {
...
@@ -1897,7 +1897,7 @@ export default class MainBase extends Vue implements ControlInterface {
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
){
if
(
!
action
){
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
return
;
}
}
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
...
@@ -2005,7 +2005,7 @@ export default class MainBase extends Vue implements ControlInterface {
...
@@ -2005,7 +2005,7 @@ export default class MainBase extends Vue implements ControlInterface {
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
){
if
(
!
action
){
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
return
;
}
}
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
Object
.
assign
(
arg
,{
viewparams
:
this
.
viewparams
});
...
@@ -2082,7 +2082,7 @@ export default class MainBase extends Vue implements ControlInterface {
...
@@ -2082,7 +2082,7 @@ export default class MainBase extends Vue implements ControlInterface {
public
remove
(
opt
:
Array
<
any
>
=
[],
showResultInfo
?:
boolean
):
Promise
<
any
>
{
public
remove
(
opt
:
Array
<
any
>
=
[],
showResultInfo
?:
boolean
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
if
(
!
this
.
removeAction
){
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView
_layout
'
+
(
this
.
$t
(
'app.formpage.notconfig.removeaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZBOOKOptionView'
+
(
this
.
$t
(
'app.formpage.notconfig.removeaction'
)
as
string
)
});
return
;
return
;
}
}
const
arg
:
any
=
opt
[
0
];
const
arg
:
any
=
opt
[
0
];
...
...
app_Web/src/widgets/ibizorder/list-exp-list/list-exp-list-base.vue
浏览文件 @
185531d2
...
@@ -522,7 +522,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
...
@@ -522,7 +522,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
*/
*/
public
load
(
opt
:
any
=
{}):
void
{
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
fetchAction
){
if
(
!
this
.
fetchAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderListExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.fetchAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderListExpView'
+
(
this
.
$t
(
'app.list.notConfig.fetchAction'
)
as
string
)
});
return
;
return
;
}
}
const
arg
:
any
=
{...
opt
};
const
arg
:
any
=
{...
opt
};
...
@@ -638,7 +638,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
...
@@ -638,7 +638,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
*/
*/
public
async
remove
(
datas
:
any
[]):
Promise
<
any
>
{
public
async
remove
(
datas
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
){
if
(
!
this
.
removeAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderListExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.removeAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderListExpView'
+
(
this
.
$t
(
'app.list.notConfig.removeAction'
)
as
string
)
});
return
;
return
;
}
}
if
(
datas
.
length
===
0
)
{
if
(
datas
.
length
===
0
)
{
...
@@ -733,7 +733,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
...
@@ -733,7 +733,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
try
{
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
)){
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
)){
if
(
!
this
.
createAction
){
if
(
!
this
.
createAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderListExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.createAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'IBIZOrderListExpView'
+
(
this
.
$t
(
'app.list.notConfig.createAction'
)
as
string
)
});
}
else
{
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
...
@@ -741,7 +741,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
...
@@ -741,7 +741,7 @@ export default class ListExpBase extends Vue implements ControlInterface {
}
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
)){
if
(
!
this
.
updateAction
){
if
(
!
this
.
updateAction
){
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.warning'
)
as
string
),
desc
:
'IBIZOrderListExpView
_layout
'
+
(
this
.
$t
(
'app.list.notConfig.updateAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.warning'
)
as
string
),
desc
:
'IBIZOrderListExpView'
+
(
this
.
$t
(
'app.list.notConfig.updateAction'
)
as
string
)
});
}
else
{
}
else
{
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
Object
.
assign
(
item
,{
viewparams
:
this
.
viewparams
});
if
(
item
.
ibizorder
){
if
(
item
.
ibizorder
){
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录