Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibizlab-generator
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibizlab-generator
提交
2f4cc689
提交
2f4cc689
编写于
1月 17, 2022
作者:
RedPig97
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update: 优化事件回调参数
上级
4bbf7cb6
变更
22
显示空白字符变更
内嵌
并排
正在显示
22 个修改的文件
包含
33 行增加
和
22 行删除
+33
-22
auto-complete.hbs
...urces/templ/r7/@macro/front-end/editors/auto-complete.hbs
+1
-1
checkbox-list.hbs
...urces/templ/r7/@macro/front-end/editors/checkbox-list.hbs
+1
-1
checkbox.hbs
.../resources/templ/r7/@macro/front-end/editors/checkbox.hbs
+1
-1
code.hbs
...main/resources/templ/r7/@macro/front-end/editors/code.hbs
+1
-1
data-picker-view.hbs
...es/templ/r7/@macro/front-end/editors/data-picker-view.hbs
+1
-1
data-picker.hbs
...sources/templ/r7/@macro/front-end/editors/data-picker.hbs
+1
-1
date-picker.hbs
...sources/templ/r7/@macro/front-end/editors/date-picker.hbs
+1
-1
dropdown-list.hbs
...urces/templ/r7/@macro/front-end/editors/dropdown-list.hbs
+1
-1
input-ip.hbs
.../resources/templ/r7/@macro/front-end/editors/input-ip.hbs
+1
-1
input.hbs
...ain/resources/templ/r7/@macro/front-end/editors/input.hbs
+1
-1
list-box.hbs
.../resources/templ/r7/@macro/front-end/editors/list-box.hbs
+1
-1
radio-group.hbs
...sources/templ/r7/@macro/front-end/editors/radio-group.hbs
+1
-1
rating.hbs
...in/resources/templ/r7/@macro/front-end/editors/rating.hbs
+1
-1
raw.hbs
.../main/resources/templ/r7/@macro/front-end/editors/raw.hbs
+1
-1
rich-text.hbs
...resources/templ/r7/@macro/front-end/editors/rich-text.hbs
+1
-1
slider.hbs
...in/resources/templ/r7/@macro/front-end/editors/slider.hbs
+1
-1
stepper.hbs
...n/resources/templ/r7/@macro/front-end/editors/stepper.hbs
+1
-1
switch.hbs
...in/resources/templ/r7/@macro/front-end/editors/switch.hbs
+1
-1
upload.hbs
...in/resources/templ/r7/@macro/front-end/editors/upload.hbs
+1
-1
grid-column.hbs
...l/r7/@macro/front-end/widgets/grid-detail/grid-column.hbs
+1
-1
grid-control.ts
...s}}/src/core/modules/widgets/grid-control/grid-control.ts
+12
-1
{{ctrls@GRID}}-grid.vue.hbs
...ntities}}/{{ctrls@GRID}}-grid/{{ctrls@GRID}}-grid.vue.hbs
+1
-1
未找到文件。
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/auto-complete.hbs
浏览文件 @
2f4cc689
...
@@ -44,6 +44,6 @@
...
@@ -44,6 +44,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/checkbox-list.hbs
浏览文件 @
2f4cc689
...
@@ -26,6 +26,6 @@
...
@@ -26,6 +26,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/checkbox.hbs
浏览文件 @
2f4cc689
...
@@ -12,6 +12,6 @@
...
@@ -12,6 +12,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/code.hbs
浏览文件 @
2f4cc689
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
:context=
"state.context"
:context=
"state.context"
:viewParams=
"state.viewParams"
/>
:viewParams=
"state.viewParams"
/>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/data-picker-view.hbs
浏览文件 @
2f4cc689
...
@@ -30,6 +30,6 @@
...
@@ -30,6 +30,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/data-picker.hbs
浏览文件 @
2f4cc689
...
@@ -57,6 +57,6 @@
...
@@ -57,6 +57,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/date-picker.hbs
浏览文件 @
2f4cc689
...
@@ -51,6 +51,6 @@
...
@@ -51,6 +51,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/dropdown-list.hbs
浏览文件 @
2f4cc689
...
@@ -33,6 +33,6 @@
...
@@ -33,6 +33,6 @@
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:data=
"record"
:data=
"record"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/input-ip.hbs
浏览文件 @
2f4cc689
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/input.hbs
浏览文件 @
2f4cc689
...
@@ -42,6 +42,6 @@
...
@@ -42,6 +42,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/list-box.hbs
浏览文件 @
2f4cc689
...
@@ -42,6 +42,6 @@
...
@@ -42,6 +42,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/radio-group.hbs
浏览文件 @
2f4cc689
...
@@ -26,6 +26,6 @@
...
@@ -26,6 +26,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
\ No newline at end of file
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/rating.hbs
浏览文件 @
2f4cc689
...
@@ -18,6 +18,6 @@
...
@@ -18,6 +18,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/raw.hbs
浏览文件 @
2f4cc689
...
@@ -16,6 +16,6 @@
...
@@ -16,6 +16,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/rich-text.hbs
浏览文件 @
2f4cc689
...
@@ -25,6 +25,6 @@
...
@@ -25,6 +25,6 @@
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:data=
"record"
:data=
"record"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/slider.hbs
浏览文件 @
2f4cc689
...
@@ -22,6 +22,6 @@
...
@@ -22,6 +22,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/stepper.hbs
浏览文件 @
2f4cc689
...
@@ -24,6 +24,6 @@
...
@@ -24,6 +24,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/switch.hbs
浏览文件 @
2f4cc689
...
@@ -15,6 +15,6 @@
...
@@ -15,6 +15,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/editors/upload.hbs
浏览文件 @
2f4cc689
...
@@ -35,6 +35,6 @@
...
@@ -35,6 +35,6 @@
{{/if}}
{{/if}}
{{#
eq
ctrlType
'grid'
}}
{{#
eq
ctrlType
'grid'
}}
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
:value=
"record.
{{
item
.
psEditor
.
name
}}
"
@
editorEvent=
"
($event: any) => onEditorEvent(index,$event
)"
@
editorEvent=
"
onEditorEvent($event,index
)"
{{/
eq
}}
{{/
eq
}}
/>
/>
modules/ibizlab-generator-core/src/main/resources/templ/r7/@macro/front-end/widgets/grid-detail/grid-column.hbs
浏览文件 @
2f4cc689
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
mode=
"link"
mode=
"link"
name=
"
{{
lowerCase
item
.
codeName
}}
"
name=
"
{{
lowerCase
item
.
codeName
}}
"
:actionModel=
"record.
{{
lowerCase
item
.
codeName
}}
"
:actionModel=
"record.
{{
lowerCase
item
.
codeName
}}
"
@
onToolbarEvent=
"
($event: IActionParam) => onToolbarEvent(record, $event
)"
/>
@
onToolbarEvent=
"
onToolbarEvent($event, record
)"
/>
{{/if}}
{{/if}}
</div>
</div>
{{/
unless
}}
{{/
unless
}}
...
...
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/core/modules/widgets/grid-control/grid-control.ts
浏览文件 @
2f4cc689
...
@@ -116,7 +116,7 @@ export class GridControl extends MDControl {
...
@@ -116,7 +116,7 @@ export class GridControl extends MDControl {
* @param {IActionParam} actionParam 行为参数
* @param {IActionParam} actionParam 行为参数
* @memberof GridControl
* @memberof GridControl
*/
*/
public
onEditorEvent
(
rowIndex
:
number
,
actionParam
:
IActionParam
)
{
public
onEditorEvent
(
actionParam
:
IActionParam
,
rowIndex
:
number
)
{
const
{
tag
,
action
,
data
}
=
actionParam
;
const
{
tag
,
action
,
data
}
=
actionParam
;
switch
(
action
)
{
switch
(
action
)
{
case
"valueChange"
:
case
"valueChange"
:
...
@@ -131,6 +131,16 @@ export class GridControl extends MDControl {
...
@@ -131,6 +131,16 @@ export class GridControl extends MDControl {
}
}
}
}
/**
* @description 操作列事件触发
* @param {IActionParam} action
* @param {IParam} record
* @memberof GridControl
*/
public
onToolbarEvent
(
action
:
IActionParam
,
record
:
IParam
)
{
//todo 界面行为
}
/**
/**
* @description 处理表格操作列事件
* @description 处理表格操作列事件
* @param {IActionParam} actionParam 行为参数
* @param {IActionParam} actionParam 行为参数
...
@@ -433,6 +443,7 @@ export class GridControl extends MDControl {
...
@@ -433,6 +443,7 @@ export class GridControl extends MDControl {
...
superParams
,
...
superParams
,
useCustom
:
this
.
useCustom
(),
useCustom
:
this
.
useCustom
(),
onEditorEvent
:
this
.
onEditorEvent
.
bind
(
this
),
onEditorEvent
:
this
.
onEditorEvent
.
bind
(
this
),
onToolbarEvent
:
this
.
onToolbarEvent
.
bind
(
this
)
};
};
}
}
}
}
modules/ibizlab-generator-core/src/main/resources/templ/r7/app_{{apps}}/src/widgets/{{appEntities}}/{{ctrls@GRID}}-grid/{{ctrls@GRID}}-grid.vue.hbs
浏览文件 @
2f4cc689
...
@@ -30,7 +30,7 @@ const props = withDefaults(defineProps < Props > (), {
...
@@ -30,7 +30,7 @@ const props = withDefaults(defineProps < Props > (), {
const
emit
=
defineEmits
<
{(
event
:
'onCtrlEvent'
,
value
:
IActionParam
):
void
;}
>
();
const
emit
=
defineEmits
<
{(
event
:
'onCtrlEvent'
,
value
:
IActionParam
):
void
;}
>
();
// 安装功能模块,提供状态和能力
// 安装功能模块,提供状态和能力
const
{
state
,
useCustom
,
onEditorEvent
}
=
new
GridControl
(
ctrlState
,
props
,
emit
).
moduleInstall
();
const
{
state
,
useCustom
,
onEditorEvent
,
onToolbarEvent
}
=
new
GridControl
(
ctrlState
,
props
,
emit
).
moduleInstall
();
const
{
useScrollOption
,
useRowKey
,
useRowClassName
,
useCustomRow
,
useRowSelectionOption
,
onResizeColumn
,
onGridChange
}
=
useCustom
;
const
{
useScrollOption
,
useRowKey
,
useRowClassName
,
useCustomRow
,
useRowSelectionOption
,
onResizeColumn
,
onGridChange
}
=
useCustom
;
// 暴露内部状态及能力
// 暴露内部状态及能力
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录