Commit 5fc1b413 authored by 王万里's avatar 王万里

add: 配置视图信息

parent e7677e0d
...@@ -219,24 +219,44 @@ angular.module('flowableModeler').controller('FieldTextPopup', ['$rootScope','$s ...@@ -219,24 +219,44 @@ angular.module('flowableModeler').controller('FieldTextPopup', ['$rootScope','$s
}]); }]);
angular.module('flowableModeler').controller('ExtraFormReadConfig', ['$rootScope','$scope', '$http', function($rootScope,$scope, $http) { angular.module('flowableModeler').controller('ExtraFormReadConfig', ['$rootScope','$scope', '$http', function($rootScope, $scope, $http) {
$scope.isShow = true let componentList = []
$scope.componentList = [{ let arr = []
name: '产品信息', let chArr = []
component: 'ProductInfo', console.log(nodeIdParams, "nodeIdParams")
defaultChecked: false if (nodeIdParams) {
}, $http.get(FLOWABLE.APP_URL.GetAssemblyModel(''))
{ .success((res)=>{
name: '客户信息', res.getMe.forEach((item)=>{
component: 'BusInfo', item.defaultChecked = false
defaultChecked: false })
}, arr = res.getMe
{ $http.get(FLOWABLE.APP_URL.GetAssemblyModel(nodeIdParams))
name: '商机信息', .success((response)=>{
component: 'BusInfo', chArr = response.getMe
defaultChecked: false arr.forEach((item)=>{
}] chArr.forEach(cItem=>{
if (item.AssemblyName === cItem.AssemblyName) {
item.defaultChecked = true
}
})
})
componentList = arr
$scope.componentList = componentList
console.log($scope.componentList, '$scope.componentList')
})
})
}
$scope.changeValue = function(params) { $scope.changeValue = function(params) {
console.log(params) let OperType = 0
if (params.defaultChecked) {
OperType = 1
}
$http.get(FLOWABLE.APP_URL.SaveAssemblyConfig(nodeIdParams, params.AssemblyName, OperType))
.success(res=>{
console.log(res)
})
} }
}]); }]);
\ No newline at end of file
<div ng-controller="ExtraFormReadConfig"> <div ng-controller="ExtraFormReadConfig">
<table class="table" ng-if="isShow"> <table class="table">
<tr> <tr>
<th>显示</th> <th style="width: 10%;"></th>
<th>外接表名称</th> <th>外接表名称</th>
<th>描述</th>
</tr> </tr>
<tr ng-repeat="child in componentList"> <tr ng-repeat="child in componentList">
<td style="width: 20px;"> <td>
<input type="checkbox" ng-model="child.defaultChecked" ng-change="changeValue(child)"/> <input type="checkbox" ng-model="child.defaultChecked" ng-change="changeValue(child)"/>
</td> </td>
<td class="active" style="width: 80px;" title="{{child.name}}">{{child.name}}</td> <td class="active" style="max-width: 110px;" title="{{child.AssemblyName}}">
<p style="margin: 0;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">
{{child.AssemblyName}}
</p>
</td>
<td class="active" style="max-width: 150px;" title="{{child.Describe}}">
<p style="margin: 0;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">
{{child.Describe}}
</p>
</td>
</tr> </tr>
</table> </table>
</div> </div>
<div ng-controller="ExtraFormReadConfig"> <div ng-controller="ExtraFormReadConfig">
<table class="table" ng-if="isShow"> <table class="table">
<tr> <tr>
<th>显示</th> <th style="width: 10%;"></th>
<th>外接表名称</th> <th>外接表名称</th>
<th>描述</th>
</tr> </tr>
<tr ng-repeat="child in componentList"> <tr ng-repeat="child in componentList">
<td style="width: 20px;"> <td>
<input type="checkbox" ng-model="child.defaultChecked" ng-change="changeValue(child)"/> <input type="checkbox" ng-model="child.defaultChecked" ng-change="changeValue(child)"/>
</td> </td>
<td class="active" style="width: 80px;" title="{{child.name}}">{{child.name}}</td> <td class="active" style="max-width: 110px;" title="{{child.AssemblyName}}">
<p style="margin: 0;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">
{{child.AssemblyName}}
</p>
</td>
<td class="active" style="max-width: 150px;" title="{{child.Describe}}">
<p style="margin: 0;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">
{{child.Describe}}
</p>
</td>
</tr> </tr>
</table> </table>
</div> </div>
...@@ -222,6 +222,16 @@ FLOWABLE.APP_URL = { ...@@ -222,6 +222,16 @@ FLOWABLE.APP_URL = {
return `${window.API_ADDRESS}/getUserListForRole?_version=9999` return `${window.API_ADDRESS}/getUserListForRole?_version=9999`
}, },
// 节点中组件设置接口
SaveAssemblyConfig: function(ACTID, ASSEMBLYNAME, OPERTYPE) {
return `${window.API_ADDRESS}/SaveAssemblyConfig?ActID=${ACTID}&AssemblyName=${ASSEMBLYNAME}&OperType=${OPERTYPE}`
},
// 根据节点ID查询组件接口
GetAssemblyModel: function(ACTID) {
return `${window.API_ADDRESS}/GetAssemblyModel?AssemblyName=&pageIndex=1&pageSize=1000&sortFields=&direction=&ActID=${ACTID}`
},
getFormModelValuesUrl: function (query) { getFormModelValuesUrl: function (query) {
return FLOWABLE.CONFIG.contextModelerRestRoot + '/rest/form-models/values?' + query; return FLOWABLE.CONFIG.contextModelerRestRoot + '/rest/form-models/values?' + query;
}, },
......
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 to comment