Commit 4fb2b661 by 张蕴鹏

添加例子

parent 4f538d7e
......@@ -12,7 +12,7 @@ import com.qinqinxiaobao.report.uniplat.workflow.engine.WorkflowDao
import com.qinqinxiaobao.report.uniplat.workflow.params.StartPlanTaskParam
class CityChange {
def model_name = "city"
def model_name = "city_example"
def multiCascadeInput(ActionBehaviorContext context) {
// 测试树
......@@ -139,7 +139,6 @@ class CityChange {
def tree_type_updator(Host host, InputParameter parameter, DataList dataList, EnvDataObject envDataObject,
Map params, String sender) {
def model = host.getDataModel("city")
def treeType = params.get("tree_type")
if (treeType == null) {
return [
......@@ -147,7 +146,7 @@ class CityChange {
]
} else {
return [
"treeModelName": "province",
"treeModelName": "province_example",
"treeRootNode": treeType,
"type":"tree"
]
......
......@@ -15,7 +15,7 @@
"multi": true,
"mapping": "product_type_mapping",
"label": "产品类型",
"default_value": "{{host.invokeModelFunc(\"city\",\"getMultiCascadeList\",object)}}"
"default_value": "{{host.invokeModelFunc(\"city_example\",\"getMultiCascadeList\",object)}}"
},
"behavior": "multiCascadeInput"
},
......@@ -100,7 +100,7 @@
{
"property": "tree_id",
"type": "tree_cascader",
"treeModelName": "province",
"treeModelName": "province_example",
"treePrefilters": [
{
"property": "type",
......@@ -130,7 +130,7 @@
"multi": true,
"mapping": "product_type_mapping",
"label": "产品类型",
"default_value": "{{host.invokeModelFunc(\"city\",\"getMultiCascadeList\",object)}}"
"default_value": "{{host.invokeModelFunc(\"city_example\",\"getMultiCascadeList\",object)}}"
}
]
}
......@@ -883,7 +883,7 @@
"type": "tree",
"property": "province_id",
"label": "省份ID",
"treeModelName": "province",
"treeModelName": "province_example",
"treeRootNode": "1",
"required": true,
"updator": "tree_type_updator"
......@@ -917,7 +917,7 @@
"type": "tree_cascader",
"property": "province_id",
"label": "省份ID",
"treeModelName": "province"
"treeModelName": "province_example"
}
]
},
......@@ -949,7 +949,7 @@
"label": "省份ID",
"default_value": "object.province_id.value",
"type": "tree_cascader",
"treeModelName": "province",
"treeModelName": "province_example",
"readonly": true,
"treeShowAllPath": false
}
......@@ -1119,7 +1119,7 @@
"name": "openSideWorkflowDetail",
"label": "工作流详情",
"action": "openWorkflowDetail",
"model": "city",
"model": "city_example",
"when": "1",
"enabled": "1",
"parameters": {
......@@ -1143,7 +1143,7 @@
"name": "showSidebarDetail",
"label": "intent-插入",
"action": "execute",
"model": "city",
"model": "city_example",
"container": "dialog",
"when": "1",
"enabled": "1",
......@@ -1166,7 +1166,7 @@
"type": "tree",
"property": "province_id",
"label": "省份ID",
"treeModelName": "province",
"treeModelName": "province_example",
"required": false
}
]
......@@ -1177,7 +1177,7 @@
"name": "testCascader",
"label": "intent-测试onObject",
"action": "execute",
"model": "city",
"model": "city_example",
"container": "dialog",
"when": "1",
"enabled": "1",
......@@ -1257,7 +1257,7 @@
"label": "树测试",
"type": "tree",
"field": "province_id",
"treeModelName": "province",
"treeModelName": "province_example",
"width": 450
},
{
......@@ -1319,23 +1319,9 @@
"log_action_visible": false,
"tree": {
"field": "province_id",
"treeModelName": "province",
"treeModelName": "province_example",
"treeRootNode": "env.user_id.value",
"cancelButtonLabel": "取消"
},
"_tree_with_data": {
"treeModelName": "province",
"template": "{name}",
"dataModelName": "city",
"foreignKey": "id",
"treeForeignKey": "province_id",
"treeForeignField": "province#joint.id",
"cancelButtonLabel": "测试1",
"fields": [
"id",
"name",
"province_id"
]
}
},
"detail": {
......@@ -1393,7 +1379,7 @@
"field_groups": [
{
"label": "描述",
"template": "{{host.getDataModel(\"city\").getModelDescription()}}"
"template": "{{host.getDataModel(\"city_example\").getModelDescription()}}"
},
{
"label": "id",
......@@ -1410,7 +1396,7 @@
{
"label": "省份",
"_template": "{province_id#province_joint.name}",
"template": "{{object.getTreeDisplay(object.province_id.value, 'province')}}"
"template": "{{object.getTreeDisplay(object.province_id.value, 'province_example')}}"
}
],
"actions": [
......@@ -1467,7 +1453,7 @@
],
"sections": [],
"workflow_list": {
"name": "city",
"name": "city_example",
"prefilters": []
}
},
......@@ -1502,7 +1488,7 @@
"property": "province_id",
"type": "tree",
"label": "省份",
"treeModelName": "province",
"treeModelName": "province_example",
"treeGroupLevel": [
"省",
"市",
......
......@@ -7,7 +7,7 @@ import com.qinqinxiaobao.report.uniplat.list.ListDef
import com.qinqinxiaobao.report.uniplat.models.meta.DataModel
class province {
def model_name = "province"
def model_name = "province_example"
def methodTest(Host host, String a, int b, Long c, ListDef pureDataObject) {
return 0
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment