Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibizlab-generator
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibizlab-generator
提交
8be0ecd3
提交
8be0ecd3
编写于
1月 20, 2022
作者:
RedPig97
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update: 选择视图更新
上级
894e2457
变更
15
隐藏空白字符变更
内嵌
并排
正在显示
15 个修改的文件
包含
71 行增加
和
63 行删除
+71
-63
include-view-control.hbs
.../templ/r7/@macro/front-end/views/include-view-control.hbs
+1
-0
view-pickup-panel.hbs
...iews/view-control/view-pickup-panel/view-pickup-panel.hbs
+10
-0
app-data-picker.vue
...7/app_{{apps}}/src/components/editors/app-data-picker.vue
+5
-1
app-pick-up-grid-view-layout.vue
...}}/src/components/layout/app-pick-up-grid-view-layout.vue
+1
-6
app-pick-up-view-layout.vue
...{apps}}/src/components/layout/app-pick-up-view-layout.vue
+1
-6
pickup-view-panel-control.ts
...ts/pickup-view-panel-control/pickup-view-panel-control.ts
+3
-3
app-pick-up-view-layout.scss
.../src/style/components/layout/app-pick-up-view-layout.scss
+10
-0
index.scss
...pl/r7/app_{{apps}}/src/style/components/layout/index.scss
+2
-1
app-modal.ts
...es/templ/r7/app_{{apps}}/src/utils/app-modal/app-modal.ts
+2
-2
open-view-service.ts
.../r7/app_{{apps}}/src/utils/open-view/open-view-service.ts
+1
-1
{{pages@DEPICKUPGRIDVIEW}}.vue.hbs
...ges@DEPICKUPGRIDVIEW}}/{{pages@DEPICKUPGRIDVIEW}}.vue.hbs
+3
-13
{{pages@DEPICKUPVIEW}}.vue.hbs
...s}}/{{pages@DEPICKUPVIEW}}/{{pages@DEPICKUPVIEW}}.vue.hbs
+10
-21
index.ts.hbs
.../{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel/index.ts.hbs
+1
-1
{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel-state.ts.hbs
.../{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel-state.ts.hbs
+5
-0
{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel.vue.hbs
...panel/{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel.vue.hbs
+16
-8
未找到文件。
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/views/include-view-control.hbs
浏览文件 @
8be0ecd3
...
@@ -2,3 +2,4 @@
...
@@ -2,3 +2,4 @@
{{#
*
inline
"SEARCHFORM"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-search-form
/
view-control-search-form
.
hbs
}}{{/
inline
}}
{{#
*
inline
"SEARCHFORM"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-search-form
/
view-control-search-form
.
hbs
}}{{/
inline
}}
{{#
*
inline
"GRID"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-grid
/
view-control-grid
.
hbs
}}{{/
inline
}}
{{#
*
inline
"GRID"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-grid
/
view-control-grid
.
hbs
}}{{/
inline
}}
{{#
*
inline
"APPMENU"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-menu
/
view-control-menu
.
hbs
}}{{/
inline
}}
{{#
*
inline
"APPMENU"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-menu
/
view-control-menu
.
hbs
}}{{/
inline
}}
{{#
*
inline
"PICKUPVIEWPANEL"
}}{{>
@macro
/
front-end
/
views
/
view-control
/
view-pickup-panel
/
view-pickup-panel
.
hbs
}}{{/
inline
}}
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/views/view-control/view-pickup-panel/view-pickup-panel.hbs
0 → 100644
浏览文件 @
8be0ecd3
{{
name
}}
:{
action:{
loadAction: '
{{
ctrl
.
getPSControlAction
.
psAppDEMethod
.
codeName
}}
',
removeAction: '
{{
ctrl
.
removePSControlAction
.
psAppDEMethod
.
codeName
}}
',
updateAction: '
{{
ctrl
.
updatePSControlAction
.
psAppDEMethod
.
codeName
}}
',
loadDraftAction: '
{{
ctrl
.
getDraftPSControlAction
.
psAppDEMethod
.
codeName
}}
',
createAction: '
{{
ctrl
.
createPSControlAction
.
psAppDEMethod
.
codeName
}}
',
fetchAction:'
{{
ctrl
.
fetchPSControlAction
.
psAppDEMethod
.
codeName
}}
'
}
}
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/components/editors/app-data-picker.vue
浏览文件 @
8be0ecd3
...
@@ -232,7 +232,11 @@ const openView = () => {
...
@@ -232,7 +232,11 @@ const openView = () => {
if
(
!
view
)
{
if
(
!
view
)
{
return
;
return
;
}
}
const
subject
=
App
.
getOpenViewService
().
openView
(
view
,
{});
const
params
:
IParam
=
{};
if
(
!
Object
.
is
(
view
.
openMode
,
'POPOVER'
)
&&
!
Object
.
is
(
view
.
openMode
,
'POPOVER'
))
{
Object
.
assign
(
params
,{
openMode
:
'POPUPMODAL'
})
}
const
subject
=
App
.
getOpenViewService
().
openView
(
view
,
params
);
const
subjectEvent
=
subject
?.
subscribe
((
data
:
any
)
=>
{
const
subjectEvent
=
subject
?.
subscribe
((
data
:
any
)
=>
{
if
(
data
?.
ret
==
'OK'
&&
data
.
resultData
)
{
if
(
data
?.
ret
==
'OK'
&&
data
.
resultData
)
{
doEditorEmit
(
data
.
resultData
);
doEditorEmit
(
data
.
resultData
);
...
...
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/components/layout/app-pick-up-grid-view-layout.vue
浏览文件 @
8be0ecd3
...
@@ -23,9 +23,4 @@
...
@@ -23,9 +23,4 @@
<slot
name=
"footer"
/>
<slot
name=
"footer"
/>
</
template
>
</
template
>
</AppViewBaseLayout>
</AppViewBaseLayout>
</template>
</template>
\ No newline at end of file
<
style
lang=
"scss"
>
</
style
>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/components/layout/app-pick-up-view-layout.vue
浏览文件 @
8be0ecd3
...
@@ -21,9 +21,4 @@
...
@@ -21,9 +21,4 @@
<slot
name=
"footer"
/>
<slot
name=
"footer"
/>
</
template
>
</
template
>
</AppViewBaseLayout>
</AppViewBaseLayout>
</template>
</template>
\ No newline at end of file
<
style
lang=
"scss"
>
</
style
>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/core/modules/widgets/pickup-view-panel-control/pickup-view-panel-control.ts
浏览文件 @
8be0ecd3
...
@@ -45,11 +45,11 @@ export class PickupViewPanelControl extends MainControl {
...
@@ -45,11 +45,11 @@ export class PickupViewPanelControl extends MainControl {
* @param {IActionParam} actionParam
* @param {IActionParam} actionParam
* @memberof PickupViewPanelControl
* @memberof PickupViewPanelControl
*/
*/
public
handle
ViewEvent
(
actionParam
:
IActionParam
)
{
public
on
ViewEvent
(
actionParam
:
IActionParam
)
{
const
{
tag
,
action
,
data
}
=
actionParam
;
const
{
tag
,
action
,
data
}
=
actionParam
;
const
{
controlName
}
=
this
.
state
;
const
{
controlName
}
=
this
.
state
;
if
(
Object
.
is
(
"selectionChange"
,
action
))
{
if
(
Object
.
is
(
"selectionChange"
,
action
))
{
this
.
emit
(
"
c
trlEvent"
,
{
tag
:
this
.
props
.
name
,
action
:
action
,
data
:
data
});
this
.
emit
(
"
onC
trlEvent"
,
{
tag
:
this
.
props
.
name
,
action
:
action
,
data
:
data
});
}
}
}
}
...
@@ -62,7 +62,7 @@ export class PickupViewPanelControl extends MainControl {
...
@@ -62,7 +62,7 @@ export class PickupViewPanelControl extends MainControl {
const
superParams
=
super
.
moduleInstall
();
const
superParams
=
super
.
moduleInstall
();
return
{
return
{
...
superParams
,
...
superParams
,
handleViewEvent
:
this
.
handle
ViewEvent
.
bind
(
this
)
onViewEvent
:
this
.
on
ViewEvent
.
bind
(
this
)
};
};
}
}
}
}
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/style/components/layout/app-pick-up-view-layout.scss
0 → 100644
浏览文件 @
8be0ecd3
.app-pickup-view
{
padding
:
0
;
.app-pickup-grid-view
{
padding
:
0
;
}
.app-view-layout__footer
{
padding
:
12px
0
;
justify-content
:
flex-end
;
}
}
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/style/components/layout/index.scss
浏览文件 @
8be0ecd3
@use
'./app-view-base-layout.scss'
;
@use
'./app-view-base-layout.scss'
;
@use
'./app-index-view-base-layout.scss'
;
@use
'./app-index-view-base-layout.scss'
;
@use
'./app-default-index-view-base-layout.scss'
;
@use
'./app-default-index-view-base-layout.scss'
;
\ No newline at end of file
@use
'./app-pick-up-view-layout.scss'
;
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/utils/app-modal/app-modal.ts
浏览文件 @
8be0ecd3
...
@@ -65,10 +65,10 @@ export class AppModal {
...
@@ -65,10 +65,10 @@ export class AppModal {
let
props
=
{
view
:
view
,
context
:
params
.
context
,
viewParams
:
params
.
viewParams
,
isFullscreen
:
params
.
isFullscreen
,
subject
:
subject
,
options
:
options
};
let
props
=
{
view
:
view
,
context
:
params
.
context
,
viewParams
:
params
.
viewParams
,
isFullscreen
:
params
.
isFullscreen
,
subject
:
subject
,
options
:
options
};
let
dir
=
view
.
fileDir
?.
replace
(
/@views/
,
''
);
let
dir
=
view
.
fileDir
?.
replace
(
/@views/
,
''
);
//Vite 支持使用特殊的 import.meta.glob 函数从文件系统导入多个模块
//Vite 支持使用特殊的 import.meta.glob 函数从文件系统导入多个模块
const
modules
=
import
.
meta
.
glob
(
'../../
page
/*/*/index.ts'
);
const
modules
=
import
.
meta
.
glob
(
'../../
views
/*/*/index.ts'
);
const
AsyncComp
=
defineAsyncComponent
({
const
AsyncComp
=
defineAsyncComponent
({
// 工厂函数
// 工厂函数
loader
:
modules
[
'../../
page
'
+
dir
+
'/index.ts'
],
loader
:
modules
[
'../../
views
'
+
dir
+
'/index.ts'
],
// 加载异步组件时要使用的组件
// 加载异步组件时要使用的组件
loadingComponent
:
AppLoading
,
loadingComponent
:
AppLoading
,
// 在显示 loadingComponent 之前的延迟 | 默认值:200(单位 ms)
// 在显示 loadingComponent 之前的延迟 | 默认值:200(单位 ms)
...
...
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/utils/open-view/open-view-service.ts
浏览文件 @
8be0ecd3
...
@@ -67,7 +67,7 @@ export class OpenViewService implements IOpenViewService {
...
@@ -67,7 +67,7 @@ export class OpenViewService implements IOpenViewService {
* @param params 相关参数
* @param params 相关参数
*/
*/
public
openByOpenMode
(
view
:
ViewDetail
,
params
:
Params
):
Subject
<
any
>
|
undefined
{
public
openByOpenMode
(
view
:
ViewDetail
,
params
:
Params
):
Subject
<
any
>
|
undefined
{
const
{
openMode
}
=
view
;
const
openMode
=
params
.
openMode
||
view
.
openMode
;
const
{
viewParams
,
context
}
=
params
;
const
{
viewParams
,
context
}
=
params
;
// 路由打开视图
// 路由打开视图
if
(
openMode
==
'INDEXVIEWTAB'
||
openMode
==
'POPUPAPP'
)
{
if
(
openMode
==
'INDEXVIEWTAB'
||
openMode
==
'POPUPAPP'
)
{
...
...
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/views/{{appModules}}/{{pages@DEPICKUPGRIDVIEW}}/{{pages@DEPICKUPGRIDVIEW}}.vue.hbs
浏览文件 @
8be0ecd3
...
@@ -36,7 +36,7 @@ const { state, confirm, onCtrlEvent } = new PickupGridView(viewState, props, emi
...
@@ -36,7 +36,7 @@ const { state, confirm, onCtrlEvent } = new PickupGridView(viewState, props, emi
</script>
</script>
<template>
<template>
<AppPick
er
UpGridViewLayout
:class=
"['app-pickup-grid-view', state.viewSysCss]"
>
<AppPickUpGridViewLayout
:class=
"['app-pickup-grid-view', state.viewSysCss]"
>
<template
v-slot:header-left
>
<template
v-slot:header-left
>
<AppIconText
class=
"app-view__caption"
size=
"large"
:text=
"state.viewCaption"
/>
<AppIconText
class=
"app-view__caption"
size=
"large"
:text=
"state.viewCaption"
/>
</template>
</template>
...
@@ -49,20 +49,10 @@ const { state, confirm, onCtrlEvent } = new PickupGridView(viewState, props, emi
...
@@ -49,20 +49,10 @@ const { state, confirm, onCtrlEvent } = new PickupGridView(viewState, props, emi
:rowActiveMode=
"state.gridRowActiveMode"
:rowActiveMode=
"state.gridRowActiveMode"
:showBusyIndicator=
"true"
:showBusyIndicator=
"true"
:viewParams=
"state.viewParams"
:viewParams=
"state.viewParams"
:controlAction=
"state.
controlsAction.
{{
name
}}
"
:controlAction=
"state.
{{
name
}}
.action
"
:viewSubject=
"state.viewSubject"
:viewSubject=
"state.viewSubject"
></
{{
codeName
}}
Grid>
></
{{
codeName
}}
Grid>
{{/
eq
}}
{{/
eq
}}
{{/
page
.
ctrls
}}
{{/
page
.
ctrls
}}
<MainGrid
</AppPickUpGridViewLayout>
:context=
"state.context"
:rowEditState=
"state.rowEditState"
:rowActiveMode=
"state.gridRowActiveMode"
:showBusyIndicator=
"true"
:viewParams=
"state.viewParams"
:controlAction=
"state.controlsAction.grid"
:viewSubject=
"state.viewSubject"
@
ctrlEvent=
"onCtrlEvent"
></MainGrid>
</AppPickerUpGridViewLayout>
</template>
</template>
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/views/{{appModules}}/{{pages@DEPICKUPVIEW}}/{{pages@DEPICKUPVIEW}}.vue.hbs
浏览文件 @
8be0ecd3
...
@@ -4,7 +4,7 @@ import { PickupView, IActionParam, IParam, IContext } from '@core';
...
@@ -4,7 +4,7 @@ import { PickupView, IActionParam, IParam, IContext } from '@core';
import
{
viewState
}
from
'./
{{
spinalCase
page
.
codeName
}}
-state'
;
import
{
viewState
}
from
'./
{{
spinalCase
page
.
codeName
}}
-state'
;
{{#
page
.
ctrls
}}
{{#
page
.
ctrls
}}
{{#
eq
controlType
"PICKUPVIEWPANEL"
}}
{{#
eq
controlType
"PICKUPVIEWPANEL"
}}
import
{
{{
codeName
}}
Pick
U
pViewPanel
}
from
'@widgets/
{{
spinalCase
appEntity
.
codeName
}}
/
{{
spinalCase
codeName
}}
-pickup-view-panel'
;
import
{
{{
codeName
}}
Pick
u
pViewPanel
}
from
'@widgets/
{{
spinalCase
appEntity
.
codeName
}}
/
{{
spinalCase
codeName
}}
-pickup-view-panel'
;
{{/
eq
}}
{{/
eq
}}
{{/
page
.
ctrls
}}
{{/
page
.
ctrls
}}
// props声明和默认值处理
// props声明和默认值处理
...
@@ -28,15 +28,14 @@ interface ViewEmit {
...
@@ -28,15 +28,14 @@ interface ViewEmit {
const
emit
=
defineEmits
<
ViewEmit
>
();
const
emit
=
defineEmits
<
ViewEmit
>
();
// 安装功能模块,提供状态和能力方法
// 安装功能模块,提供状态和能力方法
const
{
state
,
cancel
,
confirm
,
onCtrlEvent
}
=
new
PickupView
(
viewState
,
props
,
emit
).
moduleInstall
();
const
{
state
,
cancel
,
confirm
,
onCtrlEvent
}
=
new
PickupView
(
viewState
,
props
,
emit
).
moduleInstall
();
</script>
</script>
<template>
<template>
<AppPick
er
UpViewLayout
:class=
"['app-pickup-view', state.viewSysCss]"
>
<AppPickUpViewLayout
:class=
"['app-pickup-view', state.viewSysCss]"
>
<template
v-slot:header-left
>
<template
#
caption
>
<AppIconText
class=
"app-view__caption"
size=
"large"
:text=
"state.viewCaption"
/>
<AppIconText
class=
"app-view__caption"
size=
"large"
:text=
"state.viewCaption"
/>
</template>
</template>
{{#
page
.
ctrls
}}
{{#
page
.
ctrls
}}
{{#
eq
controlType
"TOOLBAR"
}}
{{#
eq
controlType
"TOOLBAR"
}}
<template
v-slot:toolbar
>
<template
v-slot:toolbar
>
...
@@ -48,16 +47,16 @@ const { state, cancel, confirm,onCtrlEvent } = new PickupView(viewState, props,
...
@@ -48,16 +47,16 @@ const { state, cancel, confirm,onCtrlEvent } = new PickupView(viewState, props,
</template>
</template>
{{/
eq
}}
{{/
eq
}}
{{#
eq
controlType
"PICKUPVIEWPANEL"
}}
{{#
eq
controlType
"PICKUPVIEWPANEL"
}}
<
{{
codeName
}}
Pick
U
pViewPanel
<
{{
codeName
}}
Pick
u
pViewPanel
:context=
"state.context"
:context=
"state.context"
:rowEditState=
"state.rowEditState"
:rowEditState=
"state.rowEditState"
:rowActiveMode=
"state.gridRowActiveMode"
:rowActiveMode=
"state.gridRowActiveMode"
:showBusyIndicator=
"true"
:showBusyIndicator=
"true"
:viewParams=
"state.viewParams"
:viewParams=
"state.viewParams"
:controlAction=
"state.
controlsAction.
{{
name
}}
"
:controlAction=
"state.
{{
name
}}
.action
"
:viewSubject=
"state.viewSubject"
:viewSubject=
"state.viewSubject"
@
c
trlEvent=
"onCtrlEvent"
@
onC
trlEvent=
"onCtrlEvent"
></
{{
codeName
}}
Pick
U
pViewPanel>
></
{{
codeName
}}
Pick
u
pViewPanel>
{{/
eq
}}
{{/
eq
}}
{{/
page
.
ctrls
}}
{{/
page
.
ctrls
}}
<template
v-slot:footer
>
<template
v-slot:footer
>
...
@@ -66,15 +65,5 @@ const { state, cancel, confirm,onCtrlEvent } = new PickupView(viewState, props,
...
@@ -66,15 +65,5 @@ const { state, cancel, confirm,onCtrlEvent } = new PickupView(viewState, props,
<a-button
@
click=
"confirm"
>
确认
</a-button>
<a-button
@
click=
"confirm"
>
确认
</a-button>
</a-space>
</a-space>
</template>
</template>
</AppPickerUpViewLayout>
</AppPickUpViewLayout>
</template>
</template>
<style
lang=
"scss"
>
\ No newline at end of file
.app-pickup-view
{
position
:
relative
;
.app-pickup-view--footer
{
position
:
absolute
;
bottom
:
20px
;
right
:
35px
;
}
}
</style>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/widgets/{{appEntities}}/{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel/index.ts.hbs
浏览文件 @
8be0ecd3
import
{{
ctrl
.
codeName
}}
PickupViewPanel from "./
{{
ctrl
.
codeName
.
spinalCase
}}
-pickupview
panel.vue";
import
{{
ctrl
.
codeName
}}
PickupViewPanel from "./
{{
spinalCase
ctrl
.
codeName
}}
-pickup-view-
panel.vue";
export {
{{
ctrl
.
codeName
}}
PickupViewPanel };
export {
{{
ctrl
.
codeName
}}
PickupViewPanel };
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/widgets/{{appEntities}}/{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel/{{ctrls@PICKUPVIEWPANEL}}-pickup
viewpanel
state.ts.hbs
→
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/widgets/{{appEntities}}/{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel/{{ctrls@PICKUPVIEWPANEL}}-pickup
-view-panel-
state.ts.hbs
浏览文件 @
8be0ecd3
...
@@ -2,9 +2,4 @@ export const ctrlState = {
...
@@ -2,9 +2,4 @@ export const ctrlState = {
controlCodeName: '
{{
ctrl
.
codeName
}}
',
controlCodeName: '
{{
ctrl
.
codeName
}}
',
controlName: '
{{
ctrl
.
name
}}
',
controlName: '
{{
ctrl
.
name
}}
',
data: {},
data: {},
embeddedView: {
{{#if
ctrl
.
embeddedPSAppDEView
}}
viewName: '
{{
ctrl
.
embeddedPSAppDEView
.
codeName
}}
'
{{/if}}
}
};
};
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/widgets/{{appEntities}}/{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel/{{ctrls@PICKUPVIEWPANEL}}-pickup
view
panel.vue.hbs
→
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/widgets/{{appEntities}}/{{ctrls@PICKUPVIEWPANEL}}-pickup-view-panel/{{ctrls@PICKUPVIEWPANEL}}-pickup
-view-
panel.vue.hbs
浏览文件 @
8be0ecd3
<script
setup
lang=
"ts"
>
<script
setup
lang=
"ts"
>
import
{
Subject
}
from
'rxjs'
;
import
{
Subject
}
from
'rxjs'
;
import
{
IActionParam
,
IParam
,
ControlAction
,
PickupViewPanelControl
,
IContext
}
from
'@core'
;
import
{
IActionParam
,
IParam
,
ControlAction
,
PickupViewPanelControl
,
IContext
}
from
'@core'
;
import
{
ctrlState
}
from
'./
{{
ctrl
.
codeName
.
spinalCase
}}
-pickupviewpanelstate'
;
import
{
ctrlState
}
from
'./
{{
spinalCase
ctrl
.
codeName
}}
-pickup-view-panel-state'
;
{{#if
ctrl
.
embeddedPSAppDEView
}}
import
{{
ctrl
.
embeddedPSAppDEView
.
codeName
}}
from
'@views/
{{
spinalCase
ctrl
.
embeddedPSAppDEView
.
psAppModule
.
codeName
}}
/
{{
spinalCase
ctrl
.
embeddedPSAppDEView
.
codeName
}}
'
;
{{/if}}
interface
Props
{
interface
Props
{
context
:
IContext
;
context
:
IContext
;
viewParams
?:
IParam
;
viewParams
?:
IParam
;
...
@@ -25,22 +27,28 @@ const props = withDefaults(defineProps < Props > (), {
...
@@ -25,22 +27,28 @@ const props = withDefaults(defineProps < Props > (), {
// emit声明
// emit声明
interface
CtrlEmit
{
interface
CtrlEmit
{
(
name
:
"
c
trlEvent"
,
value
:
IActionParam
):
void
;
(
name
:
"
onC
trlEvent"
,
value
:
IActionParam
):
void
;
}
}
const
emit
=
defineEmits
<
CtrlEmit
>
();
const
emit
=
defineEmits
<
CtrlEmit
>
();
// 安装功能模块,提供状态和能力方法
// 安装功能模块,提供状态和能力方法
const
{
state
,
inited
,
viewdata
,
viewparam
}
=
new
PickupViewPanelControl
(
ctrlState
,
props
,
emit
).
moduleInstall
();
const
{
state
}
=
new
PickupViewPanelControl
(
ctrlState
,
props
,
emit
).
moduleInstall
();
// 暴露内部状态及能力
// 暴露内部状态及能力
defineExpose
({
state
,
name
:
'
{{
ctrl
.
name
}}
'
});
defineExpose
({
state
,
name
:
'
{{
ctrl
.
name
}}
'
});
</script>
</script>
<template>
<template>
<div
class=
"app-pickupviewpanel
{{#if
ctrl
.
psSysCss
}}
{{
ctrl
.
psSysCss
.
cssName
}}{{/if}}
"
>
<component
v-if=
"inited && state.embeddedView && state.embeddedView.viewName"
:if=
"state.embeddedView.viewName"
<div
class=
"app-pickup-view-panel
{{#if
ctrl
.
psSysCss
}}
{{
ctrl
.
psSysCss
.
cssName
}}{{/if}}
"
>
:viewdata=
"viewdata"
:viewparam=
"viewparam"
:isSingleSelect=
"state.isSingleSelect"
{{#if
ctrl
.
embeddedPSAppDEView
}}
:isShowButton=
"state.isShowButton"
:selectedData=
"state.selectedData"
></component>
<
{{
ctrl
.
embeddedPSAppDEView
.
codeName
}}
:isShowButton
="
state
.
isShowButton
"
:selectedData=
"state.selectedData"
/>
{{else}}
<div
class=
"app-pickup-view-panel--empty"
>
视图不存在,请配置选择视图
</div>
{{/if}}
</div>
</div>
</template>
</template>
\ No newline at end of file
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录