郑根木 hace 2 años
padre
commit
a5a7cd6aff
Se han modificado 4 ficheros con 518 adiciones y 11 borrados
  1. +1
    -0
      smtweb-framework/bpm/src/main/resources/static/template/incModel/inc_list_query.ftl
  2. +46
    -7
      smtweb-framework/bpm/src/main/resources/static/template/index.yaml
  3. +4
    -4
      smtweb-framework/bpm/src/main/resources/static/template/model_list_list.ftl
  4. +467
    -0
      smtweb-framework/bpm/src/main/resources/static/template/model_tree_list.ftl

+ 1
- 0
smtweb-framework/bpm/src/main/resources/static/template/incModel/inc_list_query.ftl Ver fichero

@@ -25,6 +25,7 @@
</#if>
"placeholder": "请输入查询内容",
"labelWidth": 100,
"affixError": false,
"dataset": "${filter.dataset}",
"field": "${filter.id}",
"name": "${filter.name}"


+ 46
- 7
smtweb-framework/bpm/src/main/resources/static/template/index.yaml Ver fichero

@@ -88,7 +88,7 @@ model:
type: 'list'
hasGroup: false
- name: 'c2'
label: '列表'
label: '列表'
type: 'list'
hasGroup: false
- name: 'c3'
@@ -96,7 +96,7 @@ model:
type: 'card'
hasGroup: false
- name: 'c4'
label: '编辑卡片'
label: '编辑卡片'
type: 'card'
hasGroup: false
# 变量
@@ -121,23 +121,62 @@ model:
type: 'input'
label: '主卡片标题'
desc: '请选择主弹窗卡片标题'
is_isolation: 'true'
-
name: 'listDs_assist'
type: 'ds'
label: '列表数据集'
label: '列表数据集'
desc: '请选择附列表数据集'
-
name: 'editDs_assist'
type: 'ds'
label: '卡片数据集'
label: '卡片数据集'
desc: '请选择弹窗附列表卡片数据集'
-
name: 'assist_col'
type: 'number'
label: '卡片列数'
label: '卡片列数'
desc: '请选择弹窗附列表卡片列数(1或2)'
-
name: 'editDs_assist_title'
type: 'input'
label: '附卡片标题'
desc: '请选择附弹窗卡片标题'
label: '副卡片标题'
desc: '请选择附弹窗卡片标题'
-
name: 'model_tree_list'
label: '左侧树+列表(含卡片)'
# list/card/view
type: 'list'
# 布局
layout:
-
name: 'c1'
label: '简单列表'
type: 'list'
hasGroup: false
- name: 'c2'
label: '编辑卡片'
type: 'card'
hasGroup: false
# 变量
param:
-
name: 'queryDs'
type: 'ds'
label: '列表数据集'
desc: '请选择列表数据集'
-
name: 'editDs'
type: 'ds'
label: '卡片数据集'
desc: '请选择弹窗卡片数据集'
-
name: 'editTitle'
type: 'input'
label: '卡片标题'
desc: '请选择弹窗卡片标题'
-
name: 'col'
type: 'number'
label: '弹窗卡片列数'
desc: '请选择弹窗卡片列数(1或2)'

+ 4
- 4
smtweb-framework/bpm/src/main/resources/static/template/model_list_list.ftl Ver fichero

@@ -486,8 +486,8 @@
"id": "id${newId()}",
"type": "fx-dialog",
"props": {
<#if (assist_dialog.label == "")>
"title": "卡片",
<#if (param.editDs_assist_title == "")>
"title": "卡片",
<#else>
"title": "${param.editDs_assist_title}",
</#if>
@@ -595,8 +595,8 @@
"id": "id${newId()}",
"type": "fx-dialog",
"props": {
<#if (main_dialog.label == "")>
"title": "卡片",
<#if (param.editDs_main_title == "")>
"title": "卡片",
<#else>
"title": "${param.editDs_main_title}",
</#if>


+ 467
- 0
smtweb-framework/bpm/src/main/resources/static/template/model_tree_list.ftl Ver fichero

@@ -0,0 +1,467 @@
{
"version": 6,
<#list layout.c1 as group>
"form": [
{
"page": {
"id": "id${newId()}",
"type": "fx-page",
"props": {
"title": "${title}",
"key": "${newId()}"
}
},
"graph": {
"shape": "panel",
"id": "root_panel",
"type": "fx-split-panel",
"props": {
"shadow": ""
},
"children": [
{
"shape": "panel",
"id": "root_panel",
"type": "fx-split-panel",
"props": {
"horizontal": true,
"shadow": ""
},
"children": [
{
"id": "${newId()}",
"type": "fx-split-panel",
"shape": "panel",
"props": {
"horizontal": false,
"size": "300"
},
"children": [
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"size": "56",
"alignY": "center",
"backgroundImage": "bgImg-region-title",
"paddingLeft": 32,
"colNum": 2,
"gridTemplateColumns": "",
"paddingRight": 32
},
"children": [
{
"id": "id${newId()}",
"type": "fx-title",
"props": {
"label": "苹果树"
}
}
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"size": "0"
},
"children": [
{
"id": "${newId()}",
"type": "fx-divider",
"props": {
"label": "",
"contentPosition": "center",
"direction": "horizontal"
}
}
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"size": "",
"colNum": 0,
"align": "full",
"paddingTop": 10,
"paddingLeft": 10,
"paddingRight": 10
},
"children": [
{
"id": "id${newId()}",
"type": "fx-tree",
"props": {
"defaultExpandAll": true,
"expandOnClickNode": false,
"filterShow": true,
"filterPlaceholder": "查询",
"dataset": "ds_18210085a45",
"field": "fid18210085a51",

"label": "编码"
},
"events": {}
}
]
}
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"size": "10",
"backgroundColor": "--color-transparent"
},
"children": []
},
{
"id": "${newId()}",
"type": "fx-split-panel",
"shape": "panel",
"props": {
"horizontal": false
},
"children": [
<#list group.cfilters as cfilters>
{
"shape": "panel",
"id": "form_panel",
"type": "fx-form-panel",
"props": {
"colNum": 3,
"label": "查询条件",
"size": "80",
"alignY": "center"
},
"children": [

{
"id": "id${newId()}",
"type": "fx-${cfilters.editor}",
"props": {
"label": "${cfilters.label}",
"type": "text",
"maxlength": 50,
"placeholder": "请输入内容",
"labelWidth": 100,
"affixError": false
},
"events": {}
},

{
"id": "${newId()}",
"type": "fx-button-group",
"props": {
"menus": [],
"showDropdown": false
},
"slots": {
"default": [
{
"type": "fx-button",
"props": {
"label": "查询",
"leftIcon": "search",
"type": "primary",
"action": "button:search",
"linkType": "",
"dataset": "${param.queryDs}"
},
"id": "id${newId()}"
},
{
"type": "fx-button",
"props": {
"label": "重置",
"leftIcon": "clear",
"action": "button:reset"
},
"id": "id${newId()}"
}
],
"dropdown": []
}
}
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"label": "间隔",
"size": "10",
"backgroundColor": "--color-transparent"
},
"children": []
},
</#list>
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"label": "表格标题区",
"size": "68",
"backgroundImage": "bgImg-region-title",
"colNum": 2,
"alignY": "center",
"paddingLeft": 32,
"paddingRight": 32
},
"children": [
{
"id": "id${newId()}",
"type": "fx-title",
"props": {
"label": "${group.label}"
}
},
{
"id": "id${newId()}",
"type": "fx-button-group",
"props": {
"menus": [],
"textAlign": "right",
"showDropdown": false
},
"slots": {
"default": [
{
"type": "fx-button",
"props": {
"label": "新增",
"leftIcon": "plus",
"type": "primary",
"action": "button:add",
"linkType": "dialog",
"dataset": "",
"fxLink": "dialog:editMainDialog",
"fxLink_text": "卡片一号",
"preAction": ""
},
"id": "id${newId()}"
}
],
"dropdown": []
}
}
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"label": "表格区",
"colNum": 0
},
"children": [
{
"id": "id${newId()}",
"type": "fx-table",
"props": {
"label": "表格",
"border": true,
"stripe": true,
"showHeader": true,
"fit": true,
"dataset": "${param.queryDs}",
"actionWidth": 150
},
"slots": {
"button": [
{
"type": "fx-button",
"props": {
"label": "编辑",
"type": "primary",
"leftIcon": "edit",
"action": "button:edit",
"link": true,
"dataset": "${param.editDs}",
"linkType": "dialog",
"fxLink": "dialog:editMainDialog",
"fxLink_text": ""
},
"id": "id${newId()}"
},
{
"type": "fx-button",
"props": {
"label": "删除",
"type": "primary",
"leftIcon": "delete",
"action": "button:remove",
"link": true,
"dataset": "${param.editDs}",
"preAction": ""
},
"id": "id${newId()}"
}
],
"default": [
<#if (group.fields?size>0)>
<#list group.fields as col>
{
"id": "id${newId()}",
"type": "fx-table-column",
"props": {
"field": "${col.id}",
"label": "${col.label}"
}
}<#if col_has_next>,</#if>
</#list>
</#if>
]
},
"events": {}
}
]
}
]
}
]
},
{
"shape": "panel",
"id": "fx-form-panel",
"type": "fx-split-panel",
"props": {
"shadow": "",
"size": 24
},
"children": []
}
]
}
},
<#list layout.c2 as main_dialog>
{
"page": {
"id": "id${newId()}",
"type": "fx-dialog",
"props": {
<#if (param.editTitle == "")>
"title": "卡片一号",
<#else>
"title": "${param.editTitle}",
</#if>
"key": "editMainDialog",
"closeOnClickModal": false
},
"events": {}
},
"graph": {
"shape": "panel",
"id": "root_panel",
"type": "fx-split-panel",
"props": {
"horizontal": false,
"shadow": "never"
},
"children": [
{
"id": "${newId()}",
"type": "fx-split-panel",
"shape": "panel",
"props": {
"horizontal": false,
"scroll": true,
"backgroundColor": "--color-white"
},
"children": [
<#assign dfields = main_dialog.fields>
<#assign col = param.col>
<#include "incModel/inc_list_dialog.ftl"/>
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"size": "0"
},
"children": [
{
"id": "id${newId()}",
"type": "fx-divider",
"props": {
"label": "",
"contentPosition": "center",
"direction": "horizontal"
}
}
]
},
{
"id": "${newId()}",
"type": "fx-form-panel",
"shape": "panel",
"props": {
"size": "56",
"paddingRight": 10,
"alignY": "center"
},
"children": [
{
"id": "id${newId()}",
"type": "fx-button-group",
"props": {
"menus": [],
"textAlign": "right"
},
"slots": {
"default": [
{
"type": "fx-button",
"props": {
"label": "保存",
"leftIcon": "save",
"type": "success",
"action": "button:save",
"dataset": "${param.editDs}"
},
"id": "id${newId()}"
},
{
"type": "fx-button",
"props": {
"label": "关闭",
"leftIcon": "close",
"type": "",
"action": "button:closeDialog",
"nextAction": "button:search"
},
"id": "id${newId()}"
}
]
}
}
]
}
]
}
}
</#list>
],
</#list>
"model": [
<#list datasets as dataset>
<#include "incModel/inc_model.ftl"/><#if dataset_has_next>,</#if>
</#list>
],
"option": {
"widgetRef": [${widgetRef}],
"vars": []
}
}

Cargando…
Cancelar
Guardar