diff --git a/back/src/views/modules/ability/components/combine-ability.vue b/back/src/views/modules/ability/components/combine-ability.vue
index 5da84a14..55c9fb28 100644
--- a/back/src/views/modules/ability/components/combine-ability.vue
+++ b/back/src/views/modules/ability/components/combine-ability.vue
@@ -23,20 +23,7 @@
-
-
-
-
-
-
-
- {{ item.name || '--' }}
-
-
-
-
-
-
+
@@ -149,8 +136,8 @@ let keyObj = {
nameKey: 'zyname'
},
'组件服务': {
- idKey: 'zycode',
- nameKey: 'zyname'
+ idKey: 'id',
+ nameKey: 'name'
},
}
@@ -204,15 +191,15 @@ export default {
let attrValue = dataForm.fuseResourceList.filter(v => v.type == this.type);
if (attrValue.length > 0) {
attrValue.map(val => {
- let item = this.allData.find(v => v.id == val.resourceId) || {};
let _obj = {
type: val.type,
id: val.resourceId,
- name: item.name
+ name: val.resource && val.resource.name
};
arr.push(_obj);
});
}
+
// 展示
this.displayList = JSON.parse(JSON.stringify(arr));
// 已选中
@@ -223,27 +210,17 @@ export default {
},
// 获取列表
getData() {
- // this.allData = [];
- // this.transferData = [];
- // let arr = JSON.parse(JSON.stringify(sjzyArray));
- // arr.map(v => {
- // this.transferData.push({
- // type: this.type,
- // id: v[keyObj[this.type].idKey],
- // name: v[keyObj[this.type].nameKey] || "--"
- // });
- // });
- // this.allData = JSON.parse(JSON.stringify(this.transferData));
- // return;
if (this.getDataParams.url === '') {
return;
}
- this.$http[this.getDataParams.methods](this.getDataParams.url, this.getDataParams.postData).then(res => {
+ this.$http[this.getDataParams.methods](this.getDataParams.url, {
+ params: this.getDataParams.postData
+ }).then(res => {
console.log('res.data----获取列表-------->', res.data);
if (res.data.code !== 0) {
return this.$message.error(res.msg);
}
- this.transferData = []; // allData
+ this.transferData = [];
this.allData = [];
(res.data.data || []).map(v => {
this.transferData.push({