Merge branch 'hi-ucs-dev' of http://15.2.21.221:3000/wuhongjian/hi-ucs into hi-ucs-dev
This commit is contained in:
commit
60e26e151c
|
@ -2,7 +2,7 @@
|
||||||
<div>
|
<div>
|
||||||
<el-dialog :visible.sync="addOrUpdateVisibleCopy" :title="modalType === 'display' ? '能力展示' : '挂接'"
|
<el-dialog :visible.sync="addOrUpdateVisibleCopy" :title="modalType === 'display' ? '能力展示' : '挂接'"
|
||||||
@close="closeModal" :close-on-click-modal="false" :close-on-press-escape="false">
|
@close="closeModal" :close-on-click-modal="false" :close-on-press-escape="false">
|
||||||
<div v-if="modalType !== 'display'" style="
|
<div v-show="modalType !== 'display'" style="
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
|
@ -10,7 +10,7 @@
|
||||||
">
|
">
|
||||||
填写字段
|
填写字段
|
||||||
</div>
|
</div>
|
||||||
<el-checkbox-group v-if="modalType !== 'display'" v-model="checkList" @change="changeBtn"
|
<el-checkbox-group v-show="modalType !== 'display'" v-model="checkList" @change="changeBtn"
|
||||||
style="margin-bottom: 20px">
|
style="margin-bottom: 20px">
|
||||||
<el-checkbox-button v-for="(item, i) in btnList" :label="item.name" :key="i">{{ item.name }}
|
<el-checkbox-button v-for="(item, i) in btnList" :label="item.name" :key="i">{{ item.name }}
|
||||||
</el-checkbox-button>
|
</el-checkbox-button>
|
||||||
|
@ -21,7 +21,7 @@
|
||||||
<el-form :model="dataForm" :rules="rules" ref="dataForm" @keyup.enter.native="dataFormSubmitHandle()"
|
<el-form :model="dataForm" :rules="rules" ref="dataForm" @keyup.enter.native="dataFormSubmitHandle()"
|
||||||
:label-width="$i18n.locale === 'en-US' ? '120px' : 'auto'">
|
:label-width="$i18n.locale === 'en-US' ? '120px' : 'auto'">
|
||||||
<!-- 基本信息 -->
|
<!-- 基本信息 -->
|
||||||
<div style="margin-bottom:20px" v-if="checkList.includes('基本信息')">
|
<div style="margin-bottom:20px" v-show="checkList.includes('基本信息')">
|
||||||
<div style="
|
<div style="
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
@ -60,13 +60,15 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 组合能力 -->
|
<!-- 组合能力 -->
|
||||||
<div class="" v-if="checkList.includes('组合能力')">
|
<div class="" style="marigin-bottom:40px" v-show="checkList.includes('组合能力')">
|
||||||
<integrated-combine-ability v-model="dataForm" :dataForm="dataForm" @update="updateDataForm">
|
<integrated-combine-ability v-model="dataForm" :dataForm="dataForm" @update="updateDataForm" title="组合能力"
|
||||||
|
ref="combineAbility" :disabledType="modalType === 'display'">
|
||||||
</integrated-combine-ability>
|
</integrated-combine-ability>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<!-- 技术文档 -->
|
<!-- 技术文档 -->
|
||||||
<div style="margin-bottom:20px" v-if="checkList.includes('技术文档')">
|
<div style="margin-bottom:20px" v-show="checkList.includes('技术文档')">
|
||||||
<div style="
|
<div style="
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
@ -92,8 +94,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 常见问题 -->
|
<!-- 常见问题 -->
|
||||||
<div v-if="checkList.includes('常见问题')">
|
<div v-show="checkList.includes('常见问题')">
|
||||||
<common-question :dataForm="dataForm" @update="updateDataForm"></common-question>
|
<common-question :dataForm="dataForm" @update="updateDataForm" ref="commonQuestion"></common-question>
|
||||||
</div>
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
|
@ -138,6 +140,7 @@ import qs from "qs";
|
||||||
import CommonQuestion from './components/common-question.vue';
|
import CommonQuestion from './components/common-question.vue';
|
||||||
import IntegratedCombineAbility from './components/integrated-combine-ability.vue';
|
import IntegratedCombineAbility from './components/integrated-combine-ability.vue';
|
||||||
import Cookies from 'js-cookie'
|
import Cookies from 'js-cookie'
|
||||||
|
import { tableColumns } from './IntegratedServices.vue';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
@ -158,7 +161,7 @@ export default {
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"attrType": "常见问题",
|
"attrType": "常见问题",
|
||||||
"attrValue": [{ question: "", answer: "" }],
|
"attrValue": '[{ question: "", answer: "" }]',
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"fuseResourceList": [
|
"fuseResourceList": [
|
||||||
|
@ -172,11 +175,8 @@ export default {
|
||||||
"provider": "",
|
"provider": "",
|
||||||
"providerMobile": "",
|
"providerMobile": "",
|
||||||
"providerUser": "",
|
"providerUser": "",
|
||||||
// "updateDate": "",
|
|
||||||
// "updater": 0,
|
|
||||||
// "createDate": "",
|
|
||||||
// "creator": 0,
|
|
||||||
"deptUser": "",
|
"deptUser": "",
|
||||||
|
type: '融合服务'
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
name: [
|
name: [
|
||||||
|
@ -220,16 +220,7 @@ export default {
|
||||||
areaList: [],
|
areaList: [],
|
||||||
fileNameList: [],
|
fileNameList: [],
|
||||||
addOrUpdateVisibleCopy: this.addOrUpdateVisible,
|
addOrUpdateVisibleCopy: this.addOrUpdateVisible,
|
||||||
displayInfo: {
|
displayInfo: tableColumns,
|
||||||
'name': '融合服务名称',
|
|
||||||
'description': '融合服务描述',
|
|
||||||
'applicationArea': '应用领域',
|
|
||||||
'deptUser': '部门联系人',
|
|
||||||
'mobile': '部门联系人电话',
|
|
||||||
'provider': '服务商',
|
|
||||||
'providerMobile': '服务商联系人',
|
|
||||||
'providerMobile': '服务商联系人电话',
|
|
||||||
},
|
|
||||||
displayListInfo: {
|
displayListInfo: {
|
||||||
'常见问题': [],
|
'常见问题': [],
|
||||||
'组合能力': []
|
'组合能力': []
|
||||||
|
@ -257,9 +248,12 @@ export default {
|
||||||
addOrUpdateVisible: {
|
addOrUpdateVisible: {
|
||||||
handler(newVal) {
|
handler(newVal) {
|
||||||
this.addOrUpdateVisibleCopy = newVal;
|
this.addOrUpdateVisibleCopy = newVal;
|
||||||
|
if (this.modalType == 'add' && newVal) {
|
||||||
|
this.getDetail(this.dataForm)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
immediate: true,
|
immediate: true,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
// 获取应用领域
|
// 获取应用领域
|
||||||
|
@ -365,21 +359,24 @@ export default {
|
||||||
getDetail(data) {
|
getDetail(data) {
|
||||||
this.dataForm = data;
|
this.dataForm = data;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
|
this.$refs.combineAbility && this.$refs.combineAbility.getDataInfo(data)
|
||||||
|
this.$refs.commonQuestion && this.$refs.commonQuestion.getDataInfo(data)
|
||||||
console.log('this.dataForm----详情-------->', this.dataForm);
|
console.log('this.dataForm----详情-------->', this.dataForm);
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 重组数据
|
// 重组数据
|
||||||
getDisPlayData() {
|
getDisPlayData() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
console.log('this.dataForm----重组数据-------->', this.dataForm);
|
|
||||||
const questionObj = this.dataForm.fuseAttrList.find(v => v.attrType == '常见问题') || {};
|
const questionObj = this.dataForm.fuseAttrList.find(v => v.attrType == '常见问题') || {};
|
||||||
let fuseResourceList = this.dataForm.fuseResourceList || [];
|
let fuseResourceList = this.dataForm.fuseResourceList || [];
|
||||||
let arr = []
|
let arr = []
|
||||||
fuseResourceList.map(v => {
|
fuseResourceList.map(v => {
|
||||||
|
if (v.resource) {
|
||||||
arr.push({
|
arr.push({
|
||||||
name: v.resource.name,
|
name: v.resource.name,
|
||||||
type: v.resource.type,
|
type: v.resource.type,
|
||||||
})
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.displayListInfo['常见问题'] = JSON.parse(questionObj.attrValue || '[]')
|
this.displayListInfo['常见问题'] = JSON.parse(questionObj.attrValue || '[]')
|
||||||
this.displayListInfo['组合能力'] = arr
|
this.displayListInfo['组合能力'] = arr
|
||||||
|
|
|
@ -21,25 +21,8 @@
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle"
|
<el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle"
|
||||||
style="width: 100%" :height="qp ? '810px' : '650px'">
|
style="width: 100%" :height="qp ? '810px' : '650px'">
|
||||||
|
<el-table-column v-for="(item) in Object.keys(tableColumns)" :key="item" :prop="item" label="融合服务名称"
|
||||||
<el-table-column prop="name" label="融合服务名称" header-align="center" align="center"></el-table-column>
|
header-align="center" align="center"></el-table-column>
|
||||||
|
|
||||||
<el-table-column prop="description" label="融合服务描述" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="provider" label="服务商" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="providerUser" label="服务商联系人" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="providerMobile" label="服务商联系人电话" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="applicationArea" label="应用领域" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="deptId" label="所属部门" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="deptUser" label="部门联系人" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column prop="mobile" label="部门联系人电话" header-align="center" align="center"></el-table-column>
|
|
||||||
|
|
||||||
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="94" right="0">
|
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="94" right="0">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button v-if="$hasPermission('ability:bsabilityai:update')" type="text" size="small"
|
<el-button v-if="$hasPermission('ability:bsabilityai:update')" type="text" size="small"
|
||||||
|
@ -61,9 +44,7 @@
|
||||||
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="query" @closeModal="closeModal"
|
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="query" @closeModal="closeModal"
|
||||||
:addOrUpdateVisible="addOrUpdateVisible" :modalType="modalType">
|
:addOrUpdateVisible="addOrUpdateVisible" :modalType="modalType">
|
||||||
</add-or-update>
|
</add-or-update>
|
||||||
<relate-application v-if="relateApplicationResourceVisible" ref="relateApplication" :relateInfo="relationData"
|
|
||||||
:nameArray="topNameArray" @isShowRelatePopup="handleIsShowRelatePopupApply"></relate-application>
|
|
||||||
<show-child v-if="showData" :tableData="tableData" :childName="childName" :isShow="showData"></show-child>
|
|
||||||
</div>
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
</template>
|
</template>
|
||||||
|
@ -71,20 +52,28 @@
|
||||||
<script>
|
<script>
|
||||||
import mixinViewModule from "@/mixins/view-module";
|
import mixinViewModule from "@/mixins/view-module";
|
||||||
import AddOrUpdate from "./IntegratedServices-add";
|
import AddOrUpdate from "./IntegratedServices-add";
|
||||||
import dictionaries from "@/utils/dictionaries";
|
|
||||||
import RelateApplication from "./bsabilityai-relate-application.vue";
|
|
||||||
import showChild from './showChild.vue'
|
|
||||||
import qs from "qs";
|
import qs from "qs";
|
||||||
import { type } from "os";
|
import { type } from "os";
|
||||||
|
|
||||||
|
export const tableColumns = {
|
||||||
|
'name': '融合服务名称',
|
||||||
|
'description': '融合服务描述',
|
||||||
|
'provider': '服务商',
|
||||||
|
'providerUser': '服务商联系人',
|
||||||
|
'providerMobile': '服务商联系人电话',
|
||||||
|
'applicationArea': '应用领域',
|
||||||
|
'deptId': '所属部门',
|
||||||
|
'deptUser': '部门联系人',
|
||||||
|
'mobile': '部门联系人电话',
|
||||||
|
}
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
mixins: [mixinViewModule],
|
mixins: [mixinViewModule],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
// 表格--列
|
||||||
|
tableColumns: tableColumns,
|
||||||
tableData: [],
|
tableData: [],
|
||||||
showData: false,
|
|
||||||
childName: '',
|
|
||||||
mixinViewModuleOptions: {
|
mixinViewModuleOptions: {
|
||||||
getDataListURL: "/fuse/page",
|
getDataListURL: "/fuse/page",
|
||||||
exportURL: "/ability/bsabilityai/export",
|
exportURL: "/ability/bsabilityai/export",
|
||||||
|
@ -92,27 +81,18 @@ export default {
|
||||||
getDataListIsPage: true,
|
getDataListIsPage: true,
|
||||||
deleteIsBatch: false,
|
deleteIsBatch: false,
|
||||||
},
|
},
|
||||||
disabled: false,
|
|
||||||
sceneArr: dictionaries.sceneArr,
|
|
||||||
fieldArr: dictionaries.fieldArr,
|
|
||||||
shareFormArr: dictionaries.shareFormArr,
|
|
||||||
dataForm: {
|
dataForm: {
|
||||||
name: "",
|
name: "",
|
||||||
order: 'desc',
|
order: 'desc',
|
||||||
orderField: 'create_date',
|
orderField: 'create_date',
|
||||||
|
type: '融合服务'
|
||||||
},
|
},
|
||||||
qp: false,
|
qp: false,
|
||||||
relateApplicationResourceVisible: false,
|
|
||||||
relationData: {}, //打开穿梭框时传递的参数
|
|
||||||
topNameArray: [], //
|
|
||||||
modalType: 'add',
|
modalType: 'add',
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
watch: {},
|
|
||||||
components: {
|
components: {
|
||||||
AddOrUpdate,
|
AddOrUpdate,
|
||||||
RelateApplication,
|
|
||||||
showChild,
|
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
window.addEventListener("resize", this.a);
|
window.addEventListener("resize", this.a);
|
||||||
|
@ -154,7 +134,6 @@ export default {
|
||||||
this.modalType = 'update';
|
this.modalType = 'update';
|
||||||
const cloneVal = JSON.parse(JSON.stringify(val))
|
const cloneVal = JSON.parse(JSON.stringify(val))
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
// this.$refs.addOrUpdate.dataForm = cloneVal;
|
|
||||||
this.$refs.addOrUpdate.getDetail(cloneVal)
|
this.$refs.addOrUpdate.getDetail(cloneVal)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -183,50 +162,26 @@ export default {
|
||||||
"_blank"
|
"_blank"
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
// findValue(list, type) {
|
|
||||||
// const found = list.find((item) => item.attrType === type);
|
|
||||||
// if (found) {
|
|
||||||
// return found.attrValue;
|
|
||||||
// } else {
|
|
||||||
// return "暂无数据";
|
|
||||||
// }
|
|
||||||
// },
|
|
||||||
fullScreen() {
|
fullScreen() {
|
||||||
if (window.outerHeight === screen.availHeight) {
|
if (window.outerHeight === screen.availHeight) {
|
||||||
if (window.outerWidth === screen.availWidth) {
|
if (window.outerWidth === screen.availWidth) {
|
||||||
console.log(
|
console.log(
|
||||||
"全屏1",
|
"全屏1",
|
||||||
window.outerHeight,
|
|
||||||
screen.availHeight,
|
|
||||||
window.outerWidth,
|
|
||||||
screen.availWidth
|
|
||||||
);
|
);
|
||||||
this.qp = false;
|
this.qp = false;
|
||||||
} else {
|
} else {
|
||||||
console.log(
|
console.log(
|
||||||
"不是全屏2",
|
"不是全屏2",
|
||||||
window.outerHeight,
|
|
||||||
screen.availHeight,
|
|
||||||
window.outerWidth,
|
|
||||||
screen.availWidth
|
|
||||||
);
|
);
|
||||||
this.qp = true;
|
this.qp = true;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
console.log(
|
console.log(
|
||||||
"不是全屏3",
|
"不是全屏3",
|
||||||
window.outerHeight,
|
|
||||||
screen.availHeight,
|
|
||||||
window.outerWidth,
|
|
||||||
screen.availWidth
|
|
||||||
);
|
);
|
||||||
this.qp = true;
|
this.qp = true;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 是否展示关联应用弹窗
|
|
||||||
handleIsShowRelatePopupApply(type) {
|
|
||||||
this.relateApplicationResourceVisible = type;
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<el-dialog :visible.sync="addOrUpdateVisibleCopy" :title="modalType === 'display' ? '能力展示' : '挂接'"
|
<el-dialog :visible.sync="addOrUpdateVisibleCopy" :title="modalTypeText[modalType]" @close="closeModal"
|
||||||
@close="closeModal" :close-on-click-modal="false" :close-on-press-escape="false">
|
:close-on-click-modal="false" :close-on-press-escape="false">
|
||||||
<div v-if="modalType !== 'display'" style="
|
<div v-if="modalType !== 'display'" style="
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
@ -16,12 +16,12 @@
|
||||||
</el-checkbox-button>
|
</el-checkbox-button>
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
|
|
||||||
<!-- 挂载和修改-->
|
<!-- 挂载和修改 -->
|
||||||
<div key="1" v-if="modalType !== 'display'">
|
<div key="1">
|
||||||
<el-form :model="dataForm" :rules="rules" ref="dataForm" @keyup.enter.native="dataFormSubmitHandle()"
|
<el-form v-if="modalType !== 'display'" :model="dataForm" :rules="rules" ref="dataForm"
|
||||||
:label-width="$i18n.locale === 'en-US' ? '120px' : 'auto'">
|
@keyup.enter.native="dataFormSubmitHandle()" :label-width="$i18n.locale === 'en-US' ? '120px' : 'auto'">
|
||||||
<!-- 基本信息 -->
|
<!-- 基本信息 -->
|
||||||
<div style="margin-bottom:20px" v-if="checkList.includes('基本信息')">
|
<div style="margin-bottom:40px" v-show="checkList.includes('基本信息')">
|
||||||
<div style="
|
<div style="
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
@ -30,62 +30,46 @@
|
||||||
">
|
">
|
||||||
基本信息
|
基本信息
|
||||||
</div>
|
</div>
|
||||||
<el-form-item label="融合服务名称" prop="name">
|
<el-form-item label="名称" prop="name">
|
||||||
<el-input v-model="dataForm.name" placeholder="请输入融合服务名称"></el-input>
|
<el-input v-model="dataForm.name" placeholder="请输入名称" :disabled="modalType === 'display'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="融合服务描述" prop="description">
|
<el-form-item label="描述" prop="description">
|
||||||
<el-input v-model="dataForm.description" placeholder="请输入融合服务描述"></el-input>
|
<el-input type="textarea" :rows="3" v-model="dataForm.description" placeholder="请输入描述"
|
||||||
</el-form-item>
|
:disabled="modalType === 'display'"></el-input>
|
||||||
<el-form-item label="应用领域" prop="applicationArea">
|
|
||||||
<el-select v-model="dataForm.applicationArea" placeholder="请选择应用领域" filterable>
|
|
||||||
<el-option v-for="item in areaList" :key="item.value" :label="item.label" :value="item.value">
|
|
||||||
</el-option>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="部门联系人" prop="deptUser">
|
|
||||||
<el-input v-model="dataForm.deptUser" placeholder="请输入部门联系人"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="部门联系人电话" prop="mobile">
|
|
||||||
<el-input v-model="dataForm.mobile" placeholder="请输入部门联系人电话"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="服务商" prop="provider">
|
|
||||||
<el-input v-model="dataForm.provider" placeholder="请输入服务商"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="服务商联系人" prop="providerUser">
|
|
||||||
<el-input v-model="dataForm.providerUser" placeholder="请输入服务商联系人"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="服务商联系人电话" prop="providerMobile">
|
|
||||||
<el-input v-model="dataForm.providerMobile" placeholder="请输入服务商联系人电话"></el-input>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 关联能力 -->
|
<!-- 关联能力 -->
|
||||||
<div class="" v-if="checkList.includes('关联能力')">
|
<div class="" style="marigin-bottom:40px" v-show="checkList.includes('关联能力')">
|
||||||
<integrated-combine-ability v-model="dataForm" :dataForm="dataForm" @update="updateDataForm">
|
<integrated-combine-ability v-model="dataForm" :dataForm="dataForm" @update="updateDataForm" title="关联能力"
|
||||||
|
ref="combineAbility" :disabledType="modalType === 'display'">
|
||||||
</integrated-combine-ability>
|
</integrated-combine-ability>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 使用步骤 -->
|
<!-- 使用步骤 -->
|
||||||
<div v-if="checkList.includes('使用步骤')">
|
<div style="marigin-bottom:20px" v-show="checkList.includes('使用步骤')">
|
||||||
<common-question :dataForm="dataForm" @update="updateDataForm"></common-question>
|
<scene-use-step :dataForm="dataForm" @update="updateDataForm" :disabledType="modalType === 'display'"
|
||||||
|
ref="sceneUseUp">
|
||||||
|
</scene-use-step>
|
||||||
</div>
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 展示 -->
|
<!-- 展示 -->
|
||||||
<el-form key="2" class="detial-form" v-else :label-width="$i18n.locale === 'en-US' ? '120px' : 'auto'">
|
<el-form key="2" v-if="modalType === 'display'" class="detial-form"
|
||||||
|
:label-width="$i18n.locale === 'en-US' ? '120px' : 'auto'">
|
||||||
<el-form-item :label="displayInfo[data]" v-for="(data, i) in Object.keys(displayInfo)" :key="i" :prop="data">
|
<el-form-item :label="displayInfo[data]" v-for="(data, i) in Object.keys(displayInfo)" :key="i" :prop="data">
|
||||||
{{ dataForm[data] || "--" }}
|
{{ dataForm[data] || "--" }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<div v-for="(data, i) in displayListInfo['使用步骤']" :key="`${i}${JSON.stringify(data)}`">
|
<div class="group-box" v-for="(data, i) in displayListInfo['使用步骤']" :key="`${i}${JSON.stringify(data)}`">
|
||||||
<el-form-item :label="`使用步骤${i + 1}`">
|
<el-form-item :label="`使用步骤标题${i + 1}`">
|
||||||
{{ `${data['question']}` }}
|
{{ `${data['question']}` }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item :label="`问题描述${i + 1}`">
|
<el-form-item :label="`描述${i + 1}`">
|
||||||
{{ `${data['answer']} ` }}
|
{{ `${data['answer']} ` }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div v-for="(data, i) in displayListInfo['关联能力']" :key="`${i}${JSON.stringify(data)}`">
|
<div class="group-box" v-for="(data, i) in displayListInfo['关联能力']" :key="`${i}${JSON.stringify(data)}`">
|
||||||
<el-form-item :label="`能力类别${i + 1}`">
|
<el-form-item :label="`能力类别${i + 1}`">
|
||||||
{{ `${data['type']}` }}
|
{{ `${data['type']}` }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -109,13 +93,13 @@
|
||||||
<script>
|
<script>
|
||||||
import debounce from "lodash/debounce";
|
import debounce from "lodash/debounce";
|
||||||
import qs from "qs";
|
import qs from "qs";
|
||||||
import CommonQuestion from '../components/common-question.vue';
|
import SceneUseStep from '../components/scene-use-step.vue';
|
||||||
import IntegratedCombineAbility from '../components/integrated-combine-ability.vue';
|
import IntegratedCombineAbility from '../components/integrated-combine-ability.vue';
|
||||||
import Cookies from 'js-cookie'
|
import Cookies from 'js-cookie'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
CommonQuestion,
|
SceneUseStep,
|
||||||
IntegratedCombineAbility,
|
IntegratedCombineAbility,
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
@ -126,10 +110,6 @@ export default {
|
||||||
"applicationArea": "",
|
"applicationArea": "",
|
||||||
"description": "",
|
"description": "",
|
||||||
"fuseAttrList": [
|
"fuseAttrList": [
|
||||||
// {
|
|
||||||
// "attrType": "技术文档",
|
|
||||||
// "attrValue": "",
|
|
||||||
// },
|
|
||||||
{
|
{
|
||||||
"attrType": "使用步骤",
|
"attrType": "使用步骤",
|
||||||
"attrValue": [{ question: "", answer: "" }],
|
"attrValue": [{ question: "", answer: "" }],
|
||||||
|
@ -137,7 +117,7 @@ export default {
|
||||||
],
|
],
|
||||||
"fuseResourceList": [
|
"fuseResourceList": [
|
||||||
{
|
{
|
||||||
"resourceId": 0,
|
"resourceId": '',
|
||||||
"sequence": ""
|
"sequence": ""
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -183,7 +163,6 @@ export default {
|
||||||
],
|
],
|
||||||
checkList: ['基本信息', '关联能力', '使用步骤'],
|
checkList: ['基本信息', '关联能力', '使用步骤'],
|
||||||
areaList: [],
|
areaList: [],
|
||||||
fileNameList: [],
|
|
||||||
addOrUpdateVisibleCopy: this.addOrUpdateVisible,
|
addOrUpdateVisibleCopy: this.addOrUpdateVisible,
|
||||||
displayInfo: {
|
displayInfo: {
|
||||||
'name': '名称',
|
'name': '名称',
|
||||||
|
@ -193,6 +172,11 @@ export default {
|
||||||
'使用步骤': [],
|
'使用步骤': [],
|
||||||
'关联能力': []
|
'关联能力': []
|
||||||
},
|
},
|
||||||
|
modalTypeText: {
|
||||||
|
add: '挂接',
|
||||||
|
display: '能力展示',
|
||||||
|
update: '修改'
|
||||||
|
}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
|
@ -216,6 +200,9 @@ export default {
|
||||||
addOrUpdateVisible: {
|
addOrUpdateVisible: {
|
||||||
handler(newVal) {
|
handler(newVal) {
|
||||||
this.addOrUpdateVisibleCopy = newVal;
|
this.addOrUpdateVisibleCopy = newVal;
|
||||||
|
if (this.modalType == 'add' && newVal) {
|
||||||
|
this.getDetail(this.dataForm)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
immediate: true,
|
immediate: true,
|
||||||
}
|
}
|
||||||
|
@ -244,7 +231,6 @@ export default {
|
||||||
changeBtn(data) {
|
changeBtn(data) {
|
||||||
this.checkList = data;
|
this.checkList = data;
|
||||||
},
|
},
|
||||||
|
|
||||||
// 表单提交
|
// 表单提交
|
||||||
dataFormSubmitHandle: debounce(
|
dataFormSubmitHandle: debounce(
|
||||||
function () {
|
function () {
|
||||||
|
@ -293,21 +279,24 @@ export default {
|
||||||
getDetail(data) {
|
getDetail(data) {
|
||||||
this.dataForm = data;
|
this.dataForm = data;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
|
this.$refs.combineAbility && this.$refs.combineAbility.getDataInfo(data)
|
||||||
|
this.$refs.sceneUseUp && this.$refs.sceneUseUp.getDataInfo(data)
|
||||||
console.log('this.dataForm----详情-------->', this.dataForm);
|
console.log('this.dataForm----详情-------->', this.dataForm);
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 重组数据
|
// 重组数据
|
||||||
getDisPlayData() {
|
getDisPlayData() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
console.log('this.dataForm----重组数据-------->', this.dataForm);
|
|
||||||
const questionObj = this.dataForm.fuseAttrList.find(v => v.attrType == '使用步骤') || {};
|
const questionObj = this.dataForm.fuseAttrList.find(v => v.attrType == '使用步骤') || {};
|
||||||
let fuseResourceList = this.dataForm.fuseResourceList || [];
|
let fuseResourceList = this.dataForm.fuseResourceList || [];
|
||||||
let arr = []
|
let arr = []
|
||||||
fuseResourceList.map(v => {
|
fuseResourceList.map(v => {
|
||||||
|
if (v.resource) {
|
||||||
arr.push({
|
arr.push({
|
||||||
name: v.resource.name,
|
name: v.resource.name,
|
||||||
type: v.resource.type,
|
type: v.resource.type,
|
||||||
})
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.displayListInfo['使用步骤'] = JSON.parse(questionObj.attrValue || '[]')
|
this.displayListInfo['使用步骤'] = JSON.parse(questionObj.attrValue || '[]')
|
||||||
this.displayListInfo['关联能力'] = arr
|
this.displayListInfo['关联能力'] = arr
|
||||||
|
@ -424,4 +413,8 @@ export default {
|
||||||
color: #606266;
|
color: #606266;
|
||||||
line-height: 32px;
|
line-height: 32px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.group-box {
|
||||||
|
// margin-bottom: 10px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -26,18 +26,16 @@
|
||||||
|
|
||||||
<el-table-column prop="description" label="描述" header-align="center" align="center"></el-table-column>
|
<el-table-column prop="description" label="描述" header-align="center" align="center"></el-table-column>
|
||||||
|
|
||||||
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="94" right="0">
|
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="300" right="0">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button v-if="$hasPermission('ability:bsabilityai:update')" type="text" size="small"
|
<el-button v-if="$hasPermission('ability:bsabilityai:update')" type="text" size="small"
|
||||||
@click="handleUpdate(scope.row)">{{ $t("update") }}</el-button>
|
@click="handleUpdate(scope.row)">{{ $t("update") }}</el-button>
|
||||||
<el-button v-if="$hasPermission('ability:bsabilityai:delete')" type="text" size="small"
|
<el-button v-if="$hasPermission('ability:bsabilityai:delete')" type="text" size="small"
|
||||||
@click="deleteRow(scope.row.id)">{{ $t("delete") }}</el-button>
|
@click="deleteRow(scope.row.id)">{{ $t("delete") }}</el-button>
|
||||||
<el-button type="text" size="small" @click="showDetail(scope.row)">能力展示</el-button>
|
<el-button type="text" size="small" @click="showDetail(scope.row)">能力展示</el-button>
|
||||||
<el-button type="text" size="small" @click="showDocument(scope.row)">技术文档</el-button>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
<el-pagination :current-page="page" :page-sizes="[10, 20, 50, 100]" :page-size="limit" :total="Number(total)"
|
<el-pagination :current-page="page" :page-sizes="[10, 20, 50, 100]" :page-size="limit" :total="Number(total)"
|
||||||
layout="total, sizes, prev, pager, next, jumper" @size-change="pageSizeChangeHandle"
|
layout="total, sizes, prev, pager, next, jumper" @size-change="pageSizeChangeHandle"
|
||||||
@current-change="pageCurrentChangeHandle">
|
@current-change="pageCurrentChangeHandle">
|
||||||
|
@ -54,7 +52,6 @@
|
||||||
<script>
|
<script>
|
||||||
import mixinViewModule from "@/mixins/view-module";
|
import mixinViewModule from "@/mixins/view-module";
|
||||||
import AddUpdateScene from "./add-update-scene";
|
import AddUpdateScene from "./add-update-scene";
|
||||||
// import dictionaries from "@/utils/dictionaries";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
mixins: [mixinViewModule],
|
mixins: [mixinViewModule],
|
||||||
|
@ -70,9 +67,6 @@ export default {
|
||||||
deleteIsBatch: false,
|
deleteIsBatch: false,
|
||||||
},
|
},
|
||||||
disabled: false,
|
disabled: false,
|
||||||
// sceneArr: dictionaries.sceneArr,
|
|
||||||
// fieldArr: dictionaries.fieldArr,
|
|
||||||
// shareFormArr: dictionaries.shareFormArr,
|
|
||||||
dataForm: {
|
dataForm: {
|
||||||
name: "",
|
name: "",
|
||||||
order: 'desc',
|
order: 'desc',
|
||||||
|
@ -80,13 +74,9 @@ export default {
|
||||||
type: '赋能场景'
|
type: '赋能场景'
|
||||||
},
|
},
|
||||||
qp: false,
|
qp: false,
|
||||||
// relateApplicationResourceVisible: false,
|
|
||||||
// relationData: {}, //打开穿梭框时传递的参数
|
|
||||||
// topNameArray: [], //
|
|
||||||
modalType: 'add',
|
modalType: 'add',
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
watch: {},
|
|
||||||
components: {
|
components: {
|
||||||
AddUpdateScene,
|
AddUpdateScene,
|
||||||
},
|
},
|
||||||
|
@ -130,7 +120,6 @@ export default {
|
||||||
this.modalType = 'update';
|
this.modalType = 'update';
|
||||||
const cloneVal = JSON.parse(JSON.stringify(val))
|
const cloneVal = JSON.parse(JSON.stringify(val))
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
// this.$refs.addOrUpdate.dataForm = cloneVal;
|
|
||||||
this.$refs.addOrUpdate.getDetail(cloneVal)
|
this.$refs.addOrUpdate.getDetail(cloneVal)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -152,41 +141,22 @@ export default {
|
||||||
this.$refs.addOrUpdate.getDisPlayData()
|
this.$refs.addOrUpdate.getDisPlayData()
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
showDocument(val) {
|
|
||||||
console.log(val);
|
|
||||||
window.open(
|
|
||||||
window.SITE_CONFIG.frontUrl + "?id=" + val.id + "&&type=" + val.type,
|
|
||||||
"_blank"
|
|
||||||
);
|
|
||||||
},
|
|
||||||
fullScreen() {
|
fullScreen() {
|
||||||
if (window.outerHeight === screen.availHeight) {
|
if (window.outerHeight === screen.availHeight) {
|
||||||
if (window.outerWidth === screen.availWidth) {
|
if (window.outerWidth === screen.availWidth) {
|
||||||
console.log(
|
console.log(
|
||||||
"全屏1",
|
"全屏1",
|
||||||
window.outerHeight,
|
|
||||||
screen.availHeight,
|
|
||||||
window.outerWidth,
|
|
||||||
screen.availWidth
|
|
||||||
);
|
);
|
||||||
this.qp = false;
|
this.qp = false;
|
||||||
} else {
|
} else {
|
||||||
console.log(
|
console.log(
|
||||||
"不是全屏2",
|
"不是全屏2",
|
||||||
window.outerHeight,
|
|
||||||
screen.availHeight,
|
|
||||||
window.outerWidth,
|
|
||||||
screen.availWidth
|
|
||||||
);
|
);
|
||||||
this.qp = true;
|
this.qp = true;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
console.log(
|
console.log(
|
||||||
"不是全屏3",
|
"不是全屏3",
|
||||||
window.outerHeight,
|
|
||||||
screen.availHeight,
|
|
||||||
window.outerWidth,
|
|
||||||
screen.availWidth
|
|
||||||
);
|
);
|
||||||
this.qp = true;
|
this.qp = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -510,45 +510,45 @@ export default {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.submitFrom.infoList = this.submitFrom.infoList.sort((a, b) => arr.indexOf(a.attrType) - arr.indexOf(b.attrType))
|
this.submitFrom.infoList = this.submitFrom.infoList.sort((a, b) => arr.indexOf(a.attrType) - arr.indexOf(b.attrType))
|
||||||
// if (this.submitFrom.id) {
|
if (this.submitFrom.id) {
|
||||||
// // 解决编辑无组件类型
|
// 解决编辑无组件类型
|
||||||
// this.submitFrom.infoList.map(val => {
|
this.submitFrom.infoList.map(val => {
|
||||||
// if (val.attrType === '组件类型') {
|
if (val.attrType === '组件类型') {
|
||||||
// val.attrValue = this.radio
|
val.attrValue = this.radio
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// console.log('编辑===============>', this.submitFrom)
|
console.log('编辑===============>', this.submitFrom)
|
||||||
// console.log(this.submitFrom.infoList, '===============abc')
|
console.log(this.submitFrom.infoList, '===============abc')
|
||||||
// // 去重
|
// 去重
|
||||||
// const newArr = this.submitFrom.infoList.filter((element, index, self) => {
|
const newArr = this.submitFrom.infoList.filter((element, index, self) => {
|
||||||
// return self.findIndex(x => x.attrType === element.attrType) === index
|
return self.findIndex(x => x.attrType === element.attrType) === index
|
||||||
// })
|
})
|
||||||
// this.submitFrom.infoList = newArr
|
this.submitFrom.infoList = newArr
|
||||||
// console.log(this.submitFrom.infoList, '====================================wpwpwp')
|
console.log(this.submitFrom.infoList, '====================================wpwpwp')
|
||||||
// this.$http
|
this.$http
|
||||||
// .put('/resource/update', this.submitFrom)
|
.put('/resource/update', this.submitFrom)
|
||||||
// .then(({ data: res }) => {
|
.then(({ data: res }) => {
|
||||||
// if (res.code !== 0) {
|
if (res.code !== 0) {
|
||||||
// this.$message.error('修改失败!')
|
this.$message.error('修改失败!')
|
||||||
// } else {
|
} else {
|
||||||
// this.$message.success('修改成功!')
|
this.$message.success('修改成功!')
|
||||||
// this.clear()
|
this.clear()
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// .catch(() => {})
|
.catch(() => {})
|
||||||
// } else {
|
} else {
|
||||||
// this.$http
|
this.$http
|
||||||
// .post('/resource/insert?source= b', this.submitFrom)
|
.post('/resource/insert?source= b', this.submitFrom)
|
||||||
// .then(({ data: res }) => {
|
.then(({ data: res }) => {
|
||||||
// if (res.code !== 0) {
|
if (res.code !== 0) {
|
||||||
// this.$message.error('上架失败!')
|
this.$message.error('上架失败!')
|
||||||
// } else {
|
} else {
|
||||||
// this.$message.success('上架成功!')
|
this.$message.success('上架成功!')
|
||||||
// this.clear()
|
this.clear()
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// .catch(() => {})
|
.catch(() => {})
|
||||||
// }
|
}
|
||||||
},
|
},
|
||||||
// 新修改
|
// 新修改
|
||||||
UpdateData (item) {
|
UpdateData (item) {
|
||||||
|
|
|
@ -8,8 +8,10 @@
|
||||||
<el-input v-model="item.question" placeholder="请输入问题名称" style="width:90%"></el-input>
|
<el-input v-model="item.question" placeholder="请输入问题名称" style="width:90%"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="问题描述" prop="question">
|
<el-form-item label="问题描述" prop="question">
|
||||||
<el-input v-model="item.answer" placeholder="请输入问题描述" style="width:90%"></el-input>
|
<el-input type="textarea" :rows="2" v-model="item.answer" placeholder="请输入问题描述" style="width:90%">
|
||||||
<el-button style="margin-left:10px" @click="deleteItem(index)" type="danger" size="small">删除
|
</el-input>
|
||||||
|
<el-button style="margin-left:10px" @click="deleteItem(index)" type="danger" size="small"
|
||||||
|
v-if="dataInfo.length > 1">删除
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-button style="margin-left:120px" size="small" v-if="index == dataInfo.length - 1" @click="addItem"
|
<el-button style="margin-left:120px" size="small" v-if="index == dataInfo.length - 1" @click="addItem"
|
||||||
|
@ -43,26 +45,14 @@ export default {
|
||||||
deep: true,
|
deep: true,
|
||||||
immediate: true,
|
immediate: true,
|
||||||
},
|
},
|
||||||
dataForm: {
|
|
||||||
handler(newVal, oldVal) {
|
|
||||||
// 防止无限循环,简单比较一下
|
|
||||||
if (JSON.stringify(newVal) != JSON.stringify(oldVal)) {
|
|
||||||
this.dataForm = newVal;
|
|
||||||
this.getDataInfo();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
deep: true,
|
|
||||||
immediate: true,
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getDataInfo() {
|
getDataInfo(dataForm) {
|
||||||
let arr = []
|
let arr = []
|
||||||
let fuseAttrList = this.dataForm.fuseAttrList || [];
|
if (dataForm && (dataForm.id || dataForm.id === 0)) {
|
||||||
|
let fuseAttrList = dataForm.fuseAttrList || [];
|
||||||
let obj = fuseAttrList.find(v => v.attrType === '常见问题') || {}
|
let obj = fuseAttrList.find(v => v.attrType === '常见问题') || {}
|
||||||
console.log('obj-------常见问题----->', obj);
|
let attrValue = JSON.parse(obj.attrValue || "[]")
|
||||||
let attrValue = JSON.parse(obj.attrValue)
|
|
||||||
|
|
||||||
if (attrValue.length > 0) {
|
if (attrValue.length > 0) {
|
||||||
attrValue.map(v => {
|
attrValue.map(v => {
|
||||||
arr.push({
|
arr.push({
|
||||||
|
@ -70,6 +60,7 @@ export default {
|
||||||
answer: v.answer,
|
answer: v.answer,
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
arr = []
|
arr = []
|
||||||
arr.push({
|
arr.push({
|
||||||
|
@ -95,8 +86,6 @@ export default {
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.question-box {
|
.question-box {
|
||||||
margin-bottom: 20px;
|
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
|
|
@ -2,25 +2,32 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="content-box">
|
<div class="content-box">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
组合能力
|
{{ title }}
|
||||||
</div>
|
</div>
|
||||||
|
<div class="no-data loading-box" v-loading="loading" v-if="loading">
|
||||||
|
</div>
|
||||||
|
<div v-if="!loading">
|
||||||
<div v-for="(item, index) in dataInfo" :key="index">
|
<div v-for="(item, index) in dataInfo" :key="index">
|
||||||
<el-form-item label="能力类别" prop="">
|
<el-form-item label="能力类别" prop="">
|
||||||
<el-select v-model="item.type" placeholder="请选择能力类别" @change="(data) => changeType(data, item, index)">
|
<el-select v-model="item.type" placeholder="请选择能力类别"
|
||||||
|
@change="(data) => filterSelect(data, item)" :disabled="disabledType">
|
||||||
<el-option v-for="val in typeOptions" :key="val.value" :label="val.value" :value="val.value">
|
<el-option v-for="val in typeOptions" :key="val.value" :label="val.value" :value="val.value">
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
<el-select style="margin-left: 20px" v-model="item.name" placeholder="请选择能力" filterable>
|
<el-select style="margin-left: 20px" v-model="item.resourceId" placeholder="请选择能力"
|
||||||
|
:disabled="disabledType">
|
||||||
<el-option v-for="val in item.abilityOptions" :key="val.id" :label="val.name" :value="val.id">
|
<el-option v-for="val in item.abilityOptions" :key="val.id" :label="val.name" :value="val.id">
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
<el-button style="margin-left:10px" @click="deleteItem(dataInfo, index)" type="danger" size="small">删除
|
<el-button style="margin-left:10px" @click="deleteItem(dataInfo, index)" type="danger" size="small"
|
||||||
|
v-if="!disabledType && dataInfo.length > 1">删除
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button style="margin-left:10px" size="small" v-if="index == dataInfo.length - 1"
|
<el-button style="margin-left:10px" size="small"
|
||||||
@click="addItem(dataInfo, 0)" type="primary">添加
|
v-if="!disabledType && index == dataInfo.length - 1" @click="addItem(dataInfo, 0)"
|
||||||
|
type="primary">添加
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
@ -31,10 +38,22 @@ export default {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => { }
|
default: () => { }
|
||||||
},
|
},
|
||||||
|
title: {
|
||||||
|
type: String,
|
||||||
|
default: '组合能力'
|
||||||
|
},
|
||||||
|
// 是否可编辑
|
||||||
|
disabledType: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
typeOptions: [
|
typeOptions: [
|
||||||
|
{
|
||||||
|
value: '',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
value: '数据资源',
|
value: '数据资源',
|
||||||
},
|
},
|
||||||
|
@ -51,7 +70,10 @@ export default {
|
||||||
value: '知识库',
|
value: '知识库',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
dataInfo: []
|
dataInfo: [],
|
||||||
|
abilityArray: [],
|
||||||
|
abilityArrayCopy: [],
|
||||||
|
loading: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
@ -61,56 +83,52 @@ export default {
|
||||||
let arr = newVal.map((v, index) => {
|
let arr = newVal.map((v, index) => {
|
||||||
return {
|
return {
|
||||||
sequence: index,
|
sequence: index,
|
||||||
resourceId: v.name
|
resourceId: v.resourceId,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.$emit('update', {
|
this.$emit('update', {
|
||||||
title: '组合能力',
|
title: this.title,
|
||||||
list: arr
|
list: arr
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
deep: true,
|
deep: true,
|
||||||
immediate: true,
|
immediate: true,
|
||||||
},
|
},
|
||||||
dataForm: {
|
|
||||||
handler(newVal, oldVal) {
|
|
||||||
// 防止无限循环,简单比较一下
|
|
||||||
if (JSON.stringify(newVal) !== JSON.stringify(oldVal)) {
|
|
||||||
this.dataForm = newVal;
|
|
||||||
this.getDataInfo();
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
deep: true,
|
mounted() {
|
||||||
immediate: true,
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getDataInfo() {
|
async getDataInfo(dataForm) {
|
||||||
|
await this.getAbility()
|
||||||
let arr = []
|
let arr = []
|
||||||
let attrValue = this.dataForm.fuseResourceList || []
|
let attrValue = dataForm.fuseResourceList || []
|
||||||
if (attrValue.length > 0) {
|
if (attrValue.length > 0) {
|
||||||
attrValue.map(v => {
|
attrValue.map(v => {
|
||||||
arr.push({
|
let _obj = {
|
||||||
type: v.resource && v.resource.type,
|
type: v.resource && v.resource.type,
|
||||||
name: v.resourceId,
|
resourceId: v.resourceId,
|
||||||
abilityOptions: []
|
}
|
||||||
})
|
this.filterSelect(v.resource && v.resource.type, _obj)
|
||||||
|
arr.push(_obj)
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
arr = []
|
arr = []
|
||||||
arr.push({
|
arr.push({
|
||||||
type: "",
|
type: "",
|
||||||
name: "",
|
resourceId: "",
|
||||||
abilityOptions: []
|
abilityOptions: []
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
this.dataInfo = arr;
|
this.dataInfo = arr;
|
||||||
|
this.$nextTick(() => {
|
||||||
|
console.log(999, this.dataInfo)
|
||||||
|
})
|
||||||
},
|
},
|
||||||
// 新增
|
// 新增
|
||||||
addItem(list) {
|
addItem(list) {
|
||||||
list.push({
|
list.push({
|
||||||
type: "",
|
type: "",
|
||||||
name: "",
|
resourceId: "",
|
||||||
abilityOptions: []
|
abilityOptions: []
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -119,27 +137,30 @@ export default {
|
||||||
list.splice(index, 1)
|
list.splice(index, 1)
|
||||||
},
|
},
|
||||||
// 获取能力
|
// 获取能力
|
||||||
getAbility(type = '', item) {
|
getAbility() {
|
||||||
this.$http.get(`/resource/list`, {
|
return new Promise((resolve, reject) => {
|
||||||
params: {
|
this.loading = true;
|
||||||
type: type
|
this.$http.get(`/resource/list`, {}).then(({ data: res }) => {
|
||||||
}
|
this.loading = false;
|
||||||
}).then(({ data: res }) => {
|
|
||||||
if (res.code !== 0) {
|
if (res.code !== 0) {
|
||||||
return this.$message.error(res.msg)
|
return this.$message.error(res.msg)
|
||||||
}
|
}
|
||||||
let arr = res.data || []
|
this.abilityArray = res.data || []
|
||||||
let selectArray = this.dataInfo.map(v => v.name) || [];
|
this.abilityArrayCopy = res.data || []
|
||||||
// 过滤掉已选的
|
resolve(res)
|
||||||
item.abilityOptions = arr.filter(v => !selectArray.includes(v.id))
|
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
|
this.loading = false;
|
||||||
this.$message.error(err)
|
this.$message.error(err)
|
||||||
|
reject(err)
|
||||||
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
changeType(data, item) {
|
filterSelect(type, item) {
|
||||||
this.getAbility(data, item)
|
let arr = this.abilityArrayCopy.filter(v => v.type == type)
|
||||||
|
let selectArray = this.dataInfo.map(v => v.resourceId) || [];
|
||||||
|
// 过滤掉已选的
|
||||||
|
item.abilityOptions = arr.filter(v => !selectArray.includes(v.id))
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -154,4 +175,9 @@ export default {
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.loading-box {
|
||||||
|
width: 100%;
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
|
@ -1,21 +1,34 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="question-box">
|
<div class="question-box">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
常见问题
|
能力使用步骤
|
||||||
</div>
|
</div>
|
||||||
<div v-for="(item, index) in dataInfo" :key="index">
|
<div v-for="(item, index) in dataInfo" :key="index">
|
||||||
<el-form-item label="问题名称" prop="question">
|
<el-form-item label="标题" prop="question">
|
||||||
<el-input v-model="item.question" placeholder="请输入问题名称" style="width:90%"></el-input>
|
<el-input v-model="item.question" placeholder="请输入标题" style="width:90%" :disabled="disabledType">
|
||||||
|
</el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="问题描述" prop="question">
|
<el-form-item label="解释说明" prop="question">
|
||||||
<el-input v-model="item.answer" placeholder="请输入问题描述" style="width:90%"></el-input>
|
<el-input type="textarea" :rows="3" v-model="item.answer" placeholder="请输入解释说明" style="width:90%"
|
||||||
<el-button style="margin-left:10px" @click="deleteItem(index)" type="danger" size="small">删除
|
:disabled="disabledType">
|
||||||
|
</el-input>
|
||||||
|
<el-button style="margin-left:10px" @click="deleteItem(index)" type="danger" size="small"
|
||||||
|
v-if="!disabledType && dataInfo.length > 1">删除
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-button style="margin-left:120px" size="small" v-if="index == dataInfo.length - 1" @click="addItem"
|
<el-button style="margin-left:120px" size="small" v-if="!disabledType && index == dataInfo.length - 1"
|
||||||
type="primary">添加
|
@click="addItem" type="primary">添加
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="step-box">
|
||||||
|
<el-steps :active="2">
|
||||||
|
<el-step status="finish" :title="item.question || `标题${index + 1}`" v-for="(item, index) in dataInfo"
|
||||||
|
:key="index">
|
||||||
|
</el-step>
|
||||||
|
</el-steps>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
@ -24,7 +37,12 @@ export default {
|
||||||
dataForm: {
|
dataForm: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => { }
|
default: () => { }
|
||||||
}
|
},
|
||||||
|
// 是否可编辑
|
||||||
|
disabledType: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -36,32 +54,20 @@ export default {
|
||||||
handler(newVal) {
|
handler(newVal) {
|
||||||
this.dataInfo = newVal;
|
this.dataInfo = newVal;
|
||||||
this.$emit('update', {
|
this.$emit('update', {
|
||||||
title: '常见问题',
|
title: '使用步骤',
|
||||||
list: newVal
|
list: newVal
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
deep: true,
|
deep: true,
|
||||||
immediate: true,
|
immediate: true,
|
||||||
},
|
},
|
||||||
dataForm: {
|
|
||||||
handler(newVal, oldVal) {
|
|
||||||
// 防止无限循环,简单比较一下
|
|
||||||
if (JSON.stringify(newVal) != JSON.stringify(oldVal)) {
|
|
||||||
this.dataForm = newVal;
|
|
||||||
this.getDataInfo();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
deep: true,
|
|
||||||
immediate: true,
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getDataInfo() {
|
getDataInfo(dataForm) {
|
||||||
let arr = []
|
let arr = []
|
||||||
let fuseAttrList = this.dataForm.fuseAttrList || [];
|
let fuseAttrList = dataForm.fuseAttrList || [];
|
||||||
let obj = fuseAttrList.find(v => v.attrType === '常见问题') || {}
|
let obj = fuseAttrList.find(v => v.attrType === '使用步骤') || {}
|
||||||
console.log('obj-------常见问题----->', obj);
|
let attrValue = JSON.parse(obj.attrValue || "[]")
|
||||||
let attrValue = JSON.parse(obj.attrValue)
|
|
||||||
|
|
||||||
if (attrValue.length > 0) {
|
if (attrValue.length > 0) {
|
||||||
attrValue.map(v => {
|
attrValue.map(v => {
|
||||||
|
@ -96,6 +102,7 @@ export default {
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.question-box {
|
.question-box {
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
|
margin-top: 40px;
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
@ -104,4 +111,8 @@ export default {
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.step-box {
|
||||||
|
padding: 20px 10px 10px 10px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
|
@ -1,8 +1,8 @@
|
||||||
/*
|
/*
|
||||||
* @Author: hisense.wuhongjian
|
* @Author: hisense.wuhongjian
|
||||||
* @Date: 2022-03-29 17:48:03
|
* @Date: 2022-03-29 17:48:03
|
||||||
* @LastEditors: hisense.wuhongjian
|
* @LastEditors: hisense.liangjunhua
|
||||||
* @LastEditTime: 2022-04-12 10:07:15
|
* @LastEditTime: 2022-07-15 16:42:22
|
||||||
* @Description: 告诉大家这是什么
|
* @Description: 告诉大家这是什么
|
||||||
*/
|
*/
|
||||||
import request from '@/utils/request'
|
import request from '@/utils/request'
|
||||||
|
@ -30,6 +30,13 @@ export function getUserInfo() {
|
||||||
method: 'get',
|
method: 'get',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
export function getDeptAll() {
|
||||||
|
//此处为了兼容mock.js使用data传递accessToken,如果使用mock可以走headers
|
||||||
|
return request({
|
||||||
|
url: '/sys/dept/all',
|
||||||
|
method: 'get',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
export function logout() {
|
export function logout() {
|
||||||
return request({
|
return request({
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* @Author: hisense.liangjunhua
|
* @Author: hisense.liangjunhua
|
||||||
* @Date: 2022-06-13 10:22:27
|
* @Date: 2022-06-13 10:22:27
|
||||||
* @LastEditors: hisense.liangjunhua
|
* @LastEditors: hisense.liangjunhua
|
||||||
* @LastEditTime: 2022-07-15 11:31:36
|
* @LastEditTime: 2022-07-15 16:28:56
|
||||||
* @Description: 算法上架
|
* @Description: 算法上架
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
|
@ -81,6 +81,7 @@
|
||||||
></algorithm-deployment-use> -->
|
></algorithm-deployment-use> -->
|
||||||
</div>
|
</div>
|
||||||
<div class="btn" :class="showView === '基本信息' ? 'first' : ''">
|
<div class="btn" :class="showView === '基本信息' ? 'first' : ''">
|
||||||
|
<button @click="close()">取消</button>
|
||||||
<button v-show="showView !== '基本信息'" @click="back()">上一步</button>
|
<button v-show="showView !== '基本信息'" @click="back()">上一步</button>
|
||||||
<button v-show="showView === '部署与使用'" @click="preview()">
|
<button v-show="showView === '部署与使用'" @click="preview()">
|
||||||
预览
|
预览
|
||||||
|
@ -218,6 +219,9 @@
|
||||||
getUser().then((res) => {
|
getUser().then((res) => {
|
||||||
dataFrom.value.deptId = res.data.data.deptId
|
dataFrom.value.deptId = res.data.data.deptId
|
||||||
})
|
})
|
||||||
|
const close = () => {
|
||||||
|
window.close()
|
||||||
|
}
|
||||||
const back = () => {
|
const back = () => {
|
||||||
navList.value.forEach((val, index) => {
|
navList.value.forEach((val, index) => {
|
||||||
if (val.key === showView.value && index > 0) {
|
if (val.key === showView.value && index > 0) {
|
||||||
|
@ -281,7 +285,7 @@
|
||||||
shangjiaapply(params).then((res3) => {
|
shangjiaapply(params).then((res3) => {
|
||||||
console.log('res3', res3)
|
console.log('res3', res3)
|
||||||
if (res3.data.code == 0) {
|
if (res3.data.code == 0) {
|
||||||
message.success('上架成功!')
|
message.success('上架申请提交成功,请注意查看消息通知!')
|
||||||
window.setTimeout(() => {
|
window.setTimeout(() => {
|
||||||
window.close()
|
window.close()
|
||||||
submitFlag.value = true
|
submitFlag.value = true
|
||||||
|
@ -445,10 +449,15 @@
|
||||||
background: #999;
|
background: #999;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.finish {
|
.btn {
|
||||||
color: #0087ff;
|
display: flex;
|
||||||
.bg-box {
|
justify-content: space-around;
|
||||||
background: #9ccefa;
|
padding: 10px 350px 0;
|
||||||
|
button {
|
||||||
|
cursor: pointer;
|
||||||
|
width: 80px;
|
||||||
|
height: 35px;
|
||||||
|
text-align: center;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
border: 1px solid #9ccefa;
|
border: 1px solid #9ccefa;
|
||||||
span {
|
span {
|
||||||
|
@ -459,6 +468,16 @@
|
||||||
.line {
|
.line {
|
||||||
background: #0087ff;
|
background: #0087ff;
|
||||||
}
|
}
|
||||||
|
button:nth-of-type(1) {
|
||||||
|
color: #0087ff;
|
||||||
|
background: #e1edfa;
|
||||||
|
}
|
||||||
|
button:nth-of-type(2) {
|
||||||
|
background: #01c5dc;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.first {
|
||||||
|
justify-content: space-around;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.btn {
|
.btn {
|
||||||
|
|
|
@ -237,7 +237,7 @@
|
||||||
shangjiaapply(params).then((res3) => {
|
shangjiaapply(params).then((res3) => {
|
||||||
console.log('res3', res3)
|
console.log('res3', res3)
|
||||||
if (res3.data.code == 0) {
|
if (res3.data.code == 0) {
|
||||||
message.success('上架成功!')
|
message.success('上架申请提交成功,请注意查看消息通知!')
|
||||||
window.setTimeout(() => {
|
window.setTimeout(() => {
|
||||||
window.close()
|
window.close()
|
||||||
submitFlag.value = true
|
submitFlag.value = true
|
||||||
|
|
|
@ -261,7 +261,7 @@
|
||||||
shangjiaapply(params).then((res3) => {
|
shangjiaapply(params).then((res3) => {
|
||||||
console.log('res3', res3)
|
console.log('res3', res3)
|
||||||
if (res3.data.code == 0) {
|
if (res3.data.code == 0) {
|
||||||
message.success('上架成功!')
|
message.success('上架申请提交成功,请注意查看消息通知!')
|
||||||
window.setTimeout(() => {
|
window.setTimeout(() => {
|
||||||
window.close()
|
window.close()
|
||||||
submitFlag.value = true
|
submitFlag.value = true
|
||||||
|
|
|
@ -261,7 +261,7 @@
|
||||||
shangjiaapply(params).then((res3) => {
|
shangjiaapply(params).then((res3) => {
|
||||||
console.log('res3', res3)
|
console.log('res3', res3)
|
||||||
if (res3.data.code == 0) {
|
if (res3.data.code == 0) {
|
||||||
message.success('上架成功!')
|
message.success('上架申请提交成功,请注意查看消息通知!')
|
||||||
window.setTimeout(() => {
|
window.setTimeout(() => {
|
||||||
window.close()
|
window.close()
|
||||||
submitFlag.value = true
|
submitFlag.value = true
|
||||||
|
|
|
@ -209,7 +209,7 @@
|
||||||
shangjiaapply(params).then((res3) => {
|
shangjiaapply(params).then((res3) => {
|
||||||
console.log('res3', res3)
|
console.log('res3', res3)
|
||||||
if (res3.data.code == 0) {
|
if (res3.data.code == 0) {
|
||||||
message.success('上架成功!')
|
message.success('上架申请提交成功,请注意查看消息通知!')
|
||||||
window.setTimeout(() => {
|
window.setTimeout(() => {
|
||||||
window.close()
|
window.close()
|
||||||
submitFlag.value = true
|
submitFlag.value = true
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* @Author: hisense.liangjunhua
|
* @Author: hisense.liangjunhua
|
||||||
* @Date: 2022-06-17 14:11:08
|
* @Date: 2022-06-17 14:11:08
|
||||||
* @LastEditors: hisense.liangjunhua
|
* @LastEditors: hisense.liangjunhua
|
||||||
* @LastEditTime: 2022-07-15 11:51:18
|
* @LastEditTime: 2022-07-15 16:56:49
|
||||||
* @Description: 上架
|
* @Description: 上架
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
|
@ -111,7 +111,7 @@
|
||||||
></upload>
|
></upload>
|
||||||
</div>
|
</div>
|
||||||
<div class="submit">
|
<div class="submit">
|
||||||
<a-button type="primary" @click="add(title.name)">提交</a-button>
|
<a-button type="primary" @click="add(title.name)">添加</a-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
@ -265,6 +265,18 @@
|
||||||
{{ itemSelect.dictLabel }}
|
{{ itemSelect.dictLabel }}
|
||||||
</a-select-option>
|
</a-select-option>
|
||||||
</a-select>
|
</a-select>
|
||||||
|
<a-select
|
||||||
|
v-else-if="item.name === '归属部门'"
|
||||||
|
style="width: 240px"
|
||||||
|
v-model:value="item.note1"
|
||||||
|
show-search
|
||||||
|
placeholder="请输入关键字"
|
||||||
|
:options="item.options"
|
||||||
|
:filter-option="filterOption"
|
||||||
|
@focus="handleFocus"
|
||||||
|
@blur="handleBlur"
|
||||||
|
@change="handleChange2"
|
||||||
|
></a-select>
|
||||||
<div
|
<div
|
||||||
v-else-if="item.type == 'checkBox'"
|
v-else-if="item.type == 'checkBox'"
|
||||||
class="application-Area"
|
class="application-Area"
|
||||||
|
@ -317,6 +329,7 @@
|
||||||
import mybus from '@/myplugins/mybus'
|
import mybus from '@/myplugins/mybus'
|
||||||
import upload from '@/views/components/upload'
|
import upload from '@/views/components/upload'
|
||||||
import { message } from 'ant-design-vue'
|
import { message } from 'ant-design-vue'
|
||||||
|
import { getUserInfo, getDeptAll } from '@/api/user'
|
||||||
import {
|
import {
|
||||||
getCategoryTreePage,
|
getCategoryTreePage,
|
||||||
queryApplicationRelByResourceId,
|
queryApplicationRelByResourceId,
|
||||||
|
@ -390,6 +403,9 @@
|
||||||
// }]
|
// }]
|
||||||
})
|
})
|
||||||
// console.log('props==========>', props)
|
// console.log('props==========>', props)
|
||||||
|
const changeAdd = () => {
|
||||||
|
console.log('子组件方法触发~')
|
||||||
|
}
|
||||||
const data = ref({
|
const data = ref({
|
||||||
list: [],
|
list: [],
|
||||||
})
|
})
|
||||||
|
@ -451,6 +467,25 @@
|
||||||
}
|
}
|
||||||
data.value.list.push(item)
|
data.value.list.push(item)
|
||||||
})
|
})
|
||||||
|
} else if (item.name === '归属部门') {
|
||||||
|
getDeptAll().then((res) => {
|
||||||
|
const dataList = []
|
||||||
|
res.data.data.forEach((element) => {
|
||||||
|
dataList.push({
|
||||||
|
value: element.id,
|
||||||
|
label: element.name,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
item.options = dataList
|
||||||
|
if (!item.note1) {
|
||||||
|
getUserInfo().then(({ data: res1 }) => {
|
||||||
|
console.log(res1.data)
|
||||||
|
item.note1 = res1.data.deptId
|
||||||
|
console.log('默认部门=========>', item, res1.data)
|
||||||
|
data.value.list.push(item)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
data.value.list.push(item)
|
data.value.list.push(item)
|
||||||
}
|
}
|
||||||
|
@ -670,6 +705,21 @@
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
const handleChange2 = (value) => {
|
||||||
|
console.log(`selected ${value}`)
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleBlur = () => {
|
||||||
|
console.log('blur')
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleFocus = () => {
|
||||||
|
console.log('focus')
|
||||||
|
}
|
||||||
|
|
||||||
|
const filterOption = (input, option) => {
|
||||||
|
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
<style></style>
|
<style></style>
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
|
|
|
@ -12,7 +12,10 @@
|
||||||
<div class="top">
|
<div class="top">
|
||||||
<div v-for="val in data" :key="val.id" class="item">
|
<div v-for="val in data" :key="val.id" class="item">
|
||||||
<div class="icon" :class="val.icon"></div>
|
<div class="icon" :class="val.icon"></div>
|
||||||
|
<a-tooltip>
|
||||||
|
<template #title>{{ val.title }}</template>
|
||||||
<div class="title">{{ val.title }}</div>
|
<div class="title">{{ val.title }}</div>
|
||||||
|
</a-tooltip>
|
||||||
<a-tooltip>
|
<a-tooltip>
|
||||||
<template #title>{{ val.text }}</template>
|
<template #title>{{ val.text }}</template>
|
||||||
<div class="text">{{ val.text }}</div>
|
<div class="text">{{ val.text }}</div>
|
||||||
|
@ -92,7 +95,7 @@
|
||||||
align-items: center;
|
align-items: center;
|
||||||
.item {
|
.item {
|
||||||
width: 424px;
|
width: 424px;
|
||||||
height:306px;
|
height: 306px;
|
||||||
padding: 35px;
|
padding: 35px;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
@ -119,7 +122,11 @@
|
||||||
.title {
|
.title {
|
||||||
font-size: 22px;
|
font-size: 22px;
|
||||||
margin-top: 25px;
|
margin-top: 25px;
|
||||||
|
width: 2.6rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
.text {
|
.text {
|
||||||
height: 78px;
|
height: 78px;
|
||||||
|
|
|
@ -12,9 +12,7 @@
|
||||||
<div class="content-content">{{ item.content }}</div>
|
<div class="content-content">{{ item.content }}</div>
|
||||||
</a-tooltip>
|
</a-tooltip>
|
||||||
<div class="content-footer">
|
<div class="content-footer">
|
||||||
<span>{{ item.unit }}</span>
|
|
||||||
<span>{{ item.value }}</span>
|
<span>{{ item.value }}</span>
|
||||||
<span>{{ item.time }}</span>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -40,44 +38,10 @@
|
||||||
// dataFrom.value = obj
|
// dataFrom.value = obj
|
||||||
obj.attrValue.map((item) => {
|
obj.attrValue.map((item) => {
|
||||||
let params = {}
|
let params = {}
|
||||||
switch (item.type) {
|
|
||||||
case '一次性买断':
|
|
||||||
params = {
|
params = {
|
||||||
title: item.type,
|
title: item.type,
|
||||||
content: item.desc,
|
content: item.desc,
|
||||||
value: item.price,
|
value: item.price,
|
||||||
time: '元',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
case '按调用次数':
|
|
||||||
params = {
|
|
||||||
title: item.type,
|
|
||||||
content: item.desc,
|
|
||||||
value: item.price,
|
|
||||||
time: '/次',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
|
|
||||||
case '按并发路数':
|
|
||||||
params = {
|
|
||||||
title: item.type,
|
|
||||||
content: item.desc,
|
|
||||||
value: item.price,
|
|
||||||
time: '/路',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
case '按年计费':
|
|
||||||
params = {
|
|
||||||
title: item.type,
|
|
||||||
content: item.desc,
|
|
||||||
value: item.price,
|
|
||||||
time: '/年',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
}
|
}
|
||||||
dataFrom.value.push(params)
|
dataFrom.value.push(params)
|
||||||
})
|
})
|
||||||
|
@ -97,44 +61,10 @@
|
||||||
// dataFrom.value = obj
|
// dataFrom.value = obj
|
||||||
obj.attrValue.map((item) => {
|
obj.attrValue.map((item) => {
|
||||||
let params = {}
|
let params = {}
|
||||||
switch (item.type) {
|
|
||||||
case '一次性买断':
|
|
||||||
params = {
|
params = {
|
||||||
title: item.type,
|
title: item.type,
|
||||||
content: item.desc,
|
content: item.desc,
|
||||||
value: item.price,
|
value: item.price,
|
||||||
time: '元',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
case '按调用次数':
|
|
||||||
params = {
|
|
||||||
title: item.type,
|
|
||||||
content: item.desc,
|
|
||||||
value: item.price,
|
|
||||||
time: '/次',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
|
|
||||||
case '按并发路数':
|
|
||||||
params = {
|
|
||||||
title: item.type,
|
|
||||||
content: item.desc,
|
|
||||||
value: item.price,
|
|
||||||
time: '/路',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
case '按年计费':
|
|
||||||
params = {
|
|
||||||
title: item.type,
|
|
||||||
content: item.desc,
|
|
||||||
value: item.price,
|
|
||||||
time: '/年',
|
|
||||||
unit: '¥',
|
|
||||||
}
|
|
||||||
break
|
|
||||||
}
|
}
|
||||||
dataFrom.value.push(params)
|
dataFrom.value.push(params)
|
||||||
})
|
})
|
||||||
|
@ -189,14 +119,6 @@
|
||||||
font-size: 22px;
|
font-size: 22px;
|
||||||
color: #ff8b55;
|
color: #ff8b55;
|
||||||
}
|
}
|
||||||
span:nth-child(2) {
|
|
||||||
font-size: 32px;
|
|
||||||
color: #ff8b55;
|
|
||||||
}
|
|
||||||
span:last-child {
|
|
||||||
font-size: 22px;
|
|
||||||
color: #999999;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.content-card:hover {
|
.content-card:hover {
|
||||||
|
|
|
@ -21,12 +21,18 @@
|
||||||
<span class="label" v-if="props.dataList.type">
|
<span class="label" v-if="props.dataList.type">
|
||||||
{{ props.dataList.type }}
|
{{ props.dataList.type }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="componentType">
|
||||||
|
{{ componentType }}
|
||||||
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareType">
|
<span class="label" v-if="props.dataList.shareType">
|
||||||
{{ props.dataList.shareType }}
|
{{ props.dataList.shareType }}
|
||||||
</span>
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareCondition">
|
<span class="label" v-if="props.dataList.shareCondition">
|
||||||
{{ props.dataList.shareCondition }}
|
{{ props.dataList.shareCondition }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="deploymentLocation">
|
||||||
|
{{ deploymentLocation }}
|
||||||
|
</span>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<!-- <span class="label">免费</span> -->
|
<!-- <span class="label">免费</span> -->
|
||||||
|
@ -71,6 +77,7 @@
|
||||||
})
|
})
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const applicationArea = ref('')
|
const applicationArea = ref('')
|
||||||
|
const deploymentLocation = ref('') //部署位置
|
||||||
//加入申购车
|
//加入申购车
|
||||||
const addShoppingCart = () => {
|
const addShoppingCart = () => {
|
||||||
console.log('加入申购车==================>', props.dataList)
|
console.log('加入申购车==================>', props.dataList)
|
||||||
|
@ -128,6 +135,13 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '组件类型'
|
(val) => val.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter((val) => val.attrType === '部署位置')[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -142,6 +156,15 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '组件类型'
|
(val) => val.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -189,8 +212,8 @@
|
||||||
}
|
}
|
||||||
.lable-father {
|
.lable-father {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
min-width: 3.5rem;
|
min-width: 5.5rem;
|
||||||
right: -3.5rem;
|
right: -5.5rem;
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
.label {
|
.label {
|
||||||
|
|
|
@ -68,11 +68,13 @@
|
||||||
item.attrType === '部署位置'
|
item.attrType === '部署位置'
|
||||||
) {
|
) {
|
||||||
dataFrom.value.content[0].childrenContent.push(item)
|
dataFrom.value.content[0].childrenContent.push(item)
|
||||||
} else if (
|
} else if (item.attrType === '等保定级') {
|
||||||
item.attrType === '是否等保备案' ||
|
|
||||||
item.attrType === '等保定级'
|
|
||||||
) {
|
|
||||||
dataFrom.value.content[1].childrenContent.push(item)
|
dataFrom.value.content[1].childrenContent.push(item)
|
||||||
|
let isAndNo = {
|
||||||
|
attrType: '是否等保备案',
|
||||||
|
attrValue: '是',
|
||||||
|
}
|
||||||
|
dataFrom.value.content[1].childrenContent.push(isAndNo)
|
||||||
} else if (item.attrType === '访问地址') {
|
} else if (item.attrType === '访问地址') {
|
||||||
let obj = {
|
let obj = {
|
||||||
attrType: '访问地址',
|
attrType: '访问地址',
|
||||||
|
@ -85,7 +87,7 @@
|
||||||
let data = [
|
let data = [
|
||||||
{
|
{
|
||||||
attrType: '是否等保备案',
|
attrType: '是否等保备案',
|
||||||
attrValue: '------',
|
attrValue: '否',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
attrType: '等保定级',
|
attrType: '等保定级',
|
||||||
|
@ -116,11 +118,13 @@
|
||||||
item.attrType === '部署位置'
|
item.attrType === '部署位置'
|
||||||
) {
|
) {
|
||||||
dataFrom.value.content[0].childrenContent.push(item)
|
dataFrom.value.content[0].childrenContent.push(item)
|
||||||
} else if (
|
} else if (item.attrType === '等保定级') {
|
||||||
item.attrType === '是否等保备案' ||
|
|
||||||
item.attrType === '等保定级'
|
|
||||||
) {
|
|
||||||
dataFrom.value.content[1].childrenContent.push(item)
|
dataFrom.value.content[1].childrenContent.push(item)
|
||||||
|
let isAndNo = {
|
||||||
|
attrType: '是否等保备案',
|
||||||
|
attrValue: '是',
|
||||||
|
}
|
||||||
|
dataFrom.value.content[1].childrenContent.push(isAndNo)
|
||||||
} else if (item.attrType === '访问地址') {
|
} else if (item.attrType === '访问地址') {
|
||||||
let obj = {
|
let obj = {
|
||||||
attrType: '访问地址',
|
attrType: '访问地址',
|
||||||
|
@ -130,10 +134,11 @@
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
if (dataFrom.value.content[1].childrenContent.length <= 0) {
|
if (dataFrom.value.content[1].childrenContent.length <= 0) {
|
||||||
|
debugger
|
||||||
let data = [
|
let data = [
|
||||||
{
|
{
|
||||||
attrType: '是否等保备案',
|
attrType: '是否等保备案',
|
||||||
attrValue: '------',
|
attrValue: '否',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
attrType: '等保定级',
|
attrType: '等保定级',
|
||||||
|
|
|
@ -21,12 +21,18 @@
|
||||||
<span class="label" v-if="props.dataList.type">
|
<span class="label" v-if="props.dataList.type">
|
||||||
{{ props.dataList.type }}
|
{{ props.dataList.type }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="componentType">
|
||||||
|
{{ componentType }}
|
||||||
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareType">
|
<span class="label" v-if="props.dataList.shareType">
|
||||||
{{ props.dataList.shareType }}
|
{{ props.dataList.shareType }}
|
||||||
</span>
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareCondition">
|
<span class="label" v-if="props.dataList.shareCondition">
|
||||||
{{ props.dataList.shareCondition }}
|
{{ props.dataList.shareCondition }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="deploymentLocation">
|
||||||
|
{{ deploymentLocation }}
|
||||||
|
</span>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<!-- <span class="label">免费</span> -->
|
<!-- <span class="label">免费</span> -->
|
||||||
|
@ -75,6 +81,8 @@
|
||||||
})
|
})
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const businessArea = ref('')
|
const businessArea = ref('')
|
||||||
|
const deploymentLocation = ref('') //部署位置
|
||||||
|
const componentType = ref('') //组件类型
|
||||||
// // 加入申购车
|
// // 加入申购车
|
||||||
const addShoppingCart = () => {
|
const addShoppingCart = () => {
|
||||||
console.log('加入申购车==================>', props.dataList)
|
console.log('加入申购车==================>', props.dataList)
|
||||||
|
@ -124,14 +132,17 @@
|
||||||
message.success('收藏成功')
|
message.success('收藏成功')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
const componentType = ref('')
|
|
||||||
if (props.dataList.infoList) {
|
if (props.dataList.infoList) {
|
||||||
businessArea.value = props.dataList.infoList.filter(
|
businessArea.value = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '应用领域'
|
(val) => val.attrType === '应用领域'
|
||||||
)[0].attrValue
|
)[0].attrValue
|
||||||
let obj = props.dataList.infoList.filter(
|
if (
|
||||||
(val) => val.attrType === '组件类型'
|
props.dataList.infoList.filter((val) => val.attrType === '部署位置')[0]
|
||||||
)[0]
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -146,6 +157,15 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '组件类型'
|
(val) => val.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -197,8 +217,8 @@
|
||||||
|
|
||||||
.lable-father {
|
.lable-father {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
min-width: 3.5rem;
|
min-width: 5.5rem;
|
||||||
right: -3.5rem;
|
right: -5.5rem;
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -138,10 +138,12 @@
|
||||||
flag.value = false
|
flag.value = false
|
||||||
} else {
|
} else {
|
||||||
// eslint-disable-next-line vue/no-setup-props-destructure
|
// eslint-disable-next-line vue/no-setup-props-destructure
|
||||||
dataFrom.value.content[0].link.value = props.dataList.apiUrl
|
dataFrom.value.content[0].link.value = props.dataList.apiUrl || '--'
|
||||||
dataFrom.value.content[0].facilitator.value = props.dataList.deptName
|
dataFrom.value.content[0].facilitator.value =
|
||||||
dataFrom.value.content[0].people.value = props.dataList.deptContacts
|
props.dataList.deptName || '--'
|
||||||
dataFrom.value.content[0].phone.value = props.dataList.deptPhone
|
dataFrom.value.content[0].people.value =
|
||||||
|
props.dataList.deptContacts || '--'
|
||||||
|
dataFrom.value.content[0].phone.value = props.dataList.deptPhone || '--'
|
||||||
console.log('dataList', props.dataList)
|
console.log('dataList', props.dataList)
|
||||||
props.dataList.infoList.map((item) => {
|
props.dataList.infoList.map((item) => {
|
||||||
if (item.attrType === '组件地址') {
|
if (item.attrType === '组件地址') {
|
||||||
|
@ -173,10 +175,10 @@
|
||||||
if (!obj) {
|
if (!obj) {
|
||||||
flag.value = false
|
flag.value = false
|
||||||
} else {
|
} else {
|
||||||
dataFrom.value.content[0].link.value = val.apiUrl
|
dataFrom.value.content[0].link.value = val.apiUrl || '--'
|
||||||
dataFrom.value.content[0].facilitator.value = val.deptName
|
dataFrom.value.content[0].facilitator.value = val.deptName || '--'
|
||||||
dataFrom.value.content[0].people.value = val.deptContacts
|
dataFrom.value.content[0].people.value = val.deptContacts || '--'
|
||||||
dataFrom.value.content[0].phone.value = val.deptPhone
|
dataFrom.value.content[0].phone.value = val.deptPhone || '--'
|
||||||
console.log('dataList', val)
|
console.log('dataList', val)
|
||||||
val.infoList.map((item) => {
|
val.infoList.map((item) => {
|
||||||
if (item.attrType === '组件地址') {
|
if (item.attrType === '组件地址') {
|
||||||
|
|
|
@ -102,24 +102,24 @@
|
||||||
if (!obj) {
|
if (!obj) {
|
||||||
flag.value = false
|
flag.value = false
|
||||||
} else {
|
} else {
|
||||||
dataFrom.value.content[0].childrenContent[0].attrValue =
|
|
||||||
props.dataList.deptContacts
|
|
||||||
dataFrom.value.content[0].childrenContent[1].attrValue =
|
dataFrom.value.content[0].childrenContent[1].attrValue =
|
||||||
props.dataList.deptPhone
|
props.dataList.deptContacts || '--'
|
||||||
dataFrom.value.content[0].childrenContent[2].attrValue =
|
dataFrom.value.content[0].childrenContent[2].attrValue =
|
||||||
props.dataList.deptName
|
props.dataList.deptPhone || '--'
|
||||||
|
dataFrom.value.content[0].childrenContent[0].attrValue =
|
||||||
|
props.dataList.deptName || '--'
|
||||||
props.dataList.infoList.map((item) => {
|
props.dataList.infoList.map((item) => {
|
||||||
if (item.attrType == '组件地址') {
|
if (item.attrType == '组件地址') {
|
||||||
dataFrom.value.link = item.attrValue
|
dataFrom.value.link = item.attrValue
|
||||||
} else if (item.attrType == '服务商联系人') {
|
} else if (item.attrType == '服务商联系人') {
|
||||||
dataFrom.value.content[1].childrenContent[0].attrValue =
|
|
||||||
item.attrValue
|
|
||||||
} else if (item.attrType == '服务商联系电话') {
|
|
||||||
dataFrom.value.content[1].childrenContent[1].attrValue =
|
dataFrom.value.content[1].childrenContent[1].attrValue =
|
||||||
item.attrValue
|
item.attrValue || '--'
|
||||||
} else if (item.attrType == '服务商' || item.attrType == '服务商名') {
|
} else if (item.attrType == '服务商联系电话') {
|
||||||
dataFrom.value.content[1].childrenContent[2].attrValue =
|
dataFrom.value.content[1].childrenContent[2].attrValue =
|
||||||
item.attrValue
|
item.attrValue || '--'
|
||||||
|
} else if (item.attrType == '服务商' || item.attrType == '服务商名') {
|
||||||
|
dataFrom.value.content[1].childrenContent[0].attrValue =
|
||||||
|
item.attrValue || '--'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -164,27 +164,27 @@
|
||||||
if (!obj) {
|
if (!obj) {
|
||||||
flag.value = false
|
flag.value = false
|
||||||
} else {
|
} else {
|
||||||
dataFrom.value.content[0].childrenContent[0].attrValue =
|
|
||||||
props.dataList.deptContacts
|
|
||||||
dataFrom.value.content[0].childrenContent[1].attrValue =
|
dataFrom.value.content[0].childrenContent[1].attrValue =
|
||||||
props.dataList.deptPhone
|
props.dataList.deptContacts || '--'
|
||||||
dataFrom.value.content[0].childrenContent[2].attrValue =
|
dataFrom.value.content[0].childrenContent[2].attrValue =
|
||||||
props.dataList.deptName
|
props.dataList.deptPhone || '--'
|
||||||
|
dataFrom.value.content[0].childrenContent[0].attrValue =
|
||||||
|
props.dataList.deptName || '--'
|
||||||
props.dataList.infoList.map((item) => {
|
props.dataList.infoList.map((item) => {
|
||||||
if (item.attrType == '组件地址') {
|
if (item.attrType == '组件地址') {
|
||||||
dataFrom.value.link = item.attrValue
|
dataFrom.value.link = item.attrValue
|
||||||
} else if (item.attrType == '服务商联系人') {
|
} else if (item.attrType == '服务商联系人') {
|
||||||
dataFrom.value.content[1].childrenContent[0].attrValue =
|
|
||||||
item.attrValue
|
|
||||||
} else if (item.attrType == '服务商联系电话') {
|
|
||||||
dataFrom.value.content[1].childrenContent[1].attrValue =
|
dataFrom.value.content[1].childrenContent[1].attrValue =
|
||||||
item.attrValue
|
item.attrValue || '--'
|
||||||
|
} else if (item.attrType == '服务商联系电话') {
|
||||||
|
dataFrom.value.content[1].childrenContent[2].attrValue =
|
||||||
|
item.attrValue || '--'
|
||||||
} else if (
|
} else if (
|
||||||
item.attrType == '服务商' ||
|
item.attrType == '服务商' ||
|
||||||
item.attrType == '服务商名'
|
item.attrType == '服务商名'
|
||||||
) {
|
) {
|
||||||
dataFrom.value.content[1].childrenContent[2].attrValue =
|
dataFrom.value.content[1].childrenContent[0].attrValue =
|
||||||
item.attrValue
|
item.attrValue || '--'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -204,11 +204,11 @@
|
||||||
}
|
}
|
||||||
.content {
|
.content {
|
||||||
display: flex;
|
display: flex;
|
||||||
width: 13rem;
|
width: 14rem;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
.content-card {
|
.content-card {
|
||||||
height: 1.8rem;
|
height: 1.8rem;
|
||||||
width: 6.2rem;
|
width: 6.6rem;
|
||||||
border-radius: 0.2rem;
|
border-radius: 0.2rem;
|
||||||
background: linear-gradient(
|
background: linear-gradient(
|
||||||
to right,
|
to right,
|
||||||
|
@ -242,11 +242,18 @@
|
||||||
max-width: 2.8rem;
|
max-width: 2.8rem;
|
||||||
div {
|
div {
|
||||||
max-width: 2.8rem;
|
max-width: 2.8rem;
|
||||||
|
// overflow: hidden;
|
||||||
|
// text-overflow: ellipsis;
|
||||||
|
// display: -webkit-box;
|
||||||
|
// -webkit-box-orient: vertical;
|
||||||
|
// -webkit-line-clamp: 1;
|
||||||
|
& > span:last-child {
|
||||||
|
display: inline-block;
|
||||||
|
width: 1.19rem;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
display: -webkit-box;
|
white-space: nowrap;
|
||||||
-webkit-box-orient: vertical;
|
}
|
||||||
-webkit-line-clamp: 1;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,12 +21,18 @@
|
||||||
<span class="label" v-if="props.dataList.type">
|
<span class="label" v-if="props.dataList.type">
|
||||||
{{ props.dataList.type }}
|
{{ props.dataList.type }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="componentType">
|
||||||
|
{{ componentType }}
|
||||||
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareType">
|
<span class="label" v-if="props.dataList.shareType">
|
||||||
{{ props.dataList.shareType }}
|
{{ props.dataList.shareType }}
|
||||||
</span>
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareCondition">
|
<span class="label" v-if="props.dataList.shareCondition">
|
||||||
{{ props.dataList.shareCondition }}
|
{{ props.dataList.shareCondition }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="deploymentLocation">
|
||||||
|
{{ deploymentLocation }}
|
||||||
|
</span>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<!-- <span class="label">免费</span> -->
|
<!-- <span class="label">免费</span> -->
|
||||||
|
@ -71,6 +77,7 @@
|
||||||
})
|
})
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const applicationArea = ref('')
|
const applicationArea = ref('')
|
||||||
|
const deploymentLocation = ref('') //部署位置
|
||||||
// 加入申购车
|
// 加入申购车
|
||||||
const addShoppingCart = () => {
|
const addShoppingCart = () => {
|
||||||
console.log('加入申购车==================>', props.dataList)
|
console.log('加入申购车==================>', props.dataList)
|
||||||
|
@ -128,6 +135,13 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '组件类型'
|
(val) => val.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter((val) => val.attrType === '部署位置')[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -142,6 +156,15 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '组件类型'
|
(val) => val.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -188,8 +211,8 @@
|
||||||
}
|
}
|
||||||
.lable-father {
|
.lable-father {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
min-width: 3.5rem;
|
min-width: 5.5rem;
|
||||||
right: -3.5rem;
|
right: -5.5rem;
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
.label {
|
.label {
|
||||||
|
|
|
@ -21,12 +21,18 @@
|
||||||
<span class="label" v-if="props.dataList.type">
|
<span class="label" v-if="props.dataList.type">
|
||||||
{{ props.dataList.type }}
|
{{ props.dataList.type }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="componentType">
|
||||||
|
{{ componentType }}
|
||||||
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareType">
|
<span class="label" v-if="props.dataList.shareType">
|
||||||
{{ props.dataList.shareType }}
|
{{ props.dataList.shareType }}
|
||||||
</span>
|
</span>
|
||||||
<span class="label" v-if="props.dataList.shareCondition">
|
<span class="label" v-if="props.dataList.shareCondition">
|
||||||
{{ props.dataList.shareCondition }}
|
{{ props.dataList.shareCondition }}
|
||||||
</span>
|
</span>
|
||||||
|
<span class="label" v-if="deploymentLocation">
|
||||||
|
{{ deploymentLocation }}
|
||||||
|
</span>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<!-- <span class="label">免费</span> -->
|
<!-- <span class="label">免费</span> -->
|
||||||
|
@ -71,6 +77,7 @@
|
||||||
})
|
})
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const businessArea = ref('')
|
const businessArea = ref('')
|
||||||
|
const deploymentLocation = ref('') //部署位置
|
||||||
// 加入申购车
|
// 加入申购车
|
||||||
const addShoppingCart = () => {
|
const addShoppingCart = () => {
|
||||||
console.log('加入申购车==================>', props.dataList)
|
console.log('加入申购车==================>', props.dataList)
|
||||||
|
@ -129,6 +136,13 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(val) => val.attrType === '组件类型'
|
(val) => val.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter((val) => val.attrType === '部署位置')[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -145,6 +159,15 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(item) => item.attrType === '组件类型'
|
(item) => item.attrType === '组件类型'
|
||||||
)[0]
|
)[0]
|
||||||
|
if (
|
||||||
|
props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0]
|
||||||
|
) {
|
||||||
|
deploymentLocation.value = props.dataList.infoList.filter(
|
||||||
|
(val) => val.attrType === '部署位置'
|
||||||
|
)[0].attrValue
|
||||||
|
}
|
||||||
if (obj) {
|
if (obj) {
|
||||||
componentType.value = obj.attrValue
|
componentType.value = obj.attrValue
|
||||||
}
|
}
|
||||||
|
@ -191,8 +214,8 @@
|
||||||
}
|
}
|
||||||
.lable-father {
|
.lable-father {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
min-width: 3.5rem;
|
min-width: 5.5rem;
|
||||||
right: -3.5rem;
|
right: -5.5rem;
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
.label {
|
.label {
|
||||||
|
|
|
@ -142,10 +142,12 @@
|
||||||
flag.value = false
|
flag.value = false
|
||||||
} else {
|
} else {
|
||||||
// eslint-disable-next-line vue/no-setup-props-destructure
|
// eslint-disable-next-line vue/no-setup-props-destructure
|
||||||
dataFrom.value.content[0].link.value = props.dataList.apiUrl
|
dataFrom.value.content[0].link.value = props.dataList.apiUrl || '--'
|
||||||
dataFrom.value.content[0].facilitator.value = props.dataList.deptName
|
dataFrom.value.content[0].facilitator.value =
|
||||||
dataFrom.value.content[0].people.value = props.dataList.deptContacts
|
props.dataList.deptName || '--'
|
||||||
dataFrom.value.content[0].phone.value = props.dataList.deptPhone
|
dataFrom.value.content[0].people.value =
|
||||||
|
props.dataList.deptContacts || '--'
|
||||||
|
dataFrom.value.content[0].phone.value = props.dataList.deptPhone || '--'
|
||||||
console.log('dataList', props.dataList)
|
console.log('dataList', props.dataList)
|
||||||
props.dataList.infoList.map((item) => {
|
props.dataList.infoList.map((item) => {
|
||||||
if (item.attrType === '服务地址') {
|
if (item.attrType === '服务地址') {
|
||||||
|
@ -179,10 +181,10 @@
|
||||||
if (!obj) {
|
if (!obj) {
|
||||||
flag.value = false
|
flag.value = false
|
||||||
} else {
|
} else {
|
||||||
dataFrom.value.content[0].link.value = val.apiUrl
|
dataFrom.value.content[0].link.value = val.apiUrl || '--'
|
||||||
dataFrom.value.content[0].facilitator.value = val.deptName
|
dataFrom.value.content[0].facilitator.value = val.deptName || '--'
|
||||||
dataFrom.value.content[0].people.value = val.deptContacts
|
dataFrom.value.content[0].people.value = val.deptContacts || '--'
|
||||||
dataFrom.value.content[0].phone.value = val.deptPhone
|
dataFrom.value.content[0].phone.value = val.deptPhone || '--'
|
||||||
console.log('dataList', val)
|
console.log('dataList', val)
|
||||||
val.infoList.map((item) => {
|
val.infoList.map((item) => {
|
||||||
if (item.attrType === '服务地址') {
|
if (item.attrType === '服务地址') {
|
||||||
|
|
|
@ -63,6 +63,10 @@
|
||||||
<div class="mynotice" v-show="mynoticeFlag">
|
<div class="mynotice" v-show="mynoticeFlag">
|
||||||
<a-list item-layout="horizontal" :data-source="mynoticeData">
|
<a-list item-layout="horizontal" :data-source="mynoticeData">
|
||||||
<template #renderItem="{ item }">
|
<template #renderItem="{ item }">
|
||||||
|
<a-tooltip placement="left">
|
||||||
|
<template #title>
|
||||||
|
<span>{{ item.content }}</span>
|
||||||
|
</template>
|
||||||
<a-list-item>
|
<a-list-item>
|
||||||
<a-list-item-meta :description="item.senderDate">
|
<a-list-item-meta :description="item.senderDate">
|
||||||
<template #title>
|
<template #title>
|
||||||
|
@ -70,6 +74,7 @@
|
||||||
</template>
|
</template>
|
||||||
</a-list-item-meta>
|
</a-list-item-meta>
|
||||||
</a-list-item>
|
</a-list-item>
|
||||||
|
</a-tooltip>
|
||||||
</template>
|
</template>
|
||||||
</a-list>
|
</a-list>
|
||||||
<div class="bottom" @click="goToView()">查看更多</div>
|
<div class="bottom" @click="goToView()">查看更多</div>
|
||||||
|
|
|
@ -414,12 +414,15 @@
|
||||||
// }
|
// }
|
||||||
const getCamera = () => {
|
const getCamera = () => {
|
||||||
console.log('初始化调用')
|
console.log('初始化调用')
|
||||||
|
console.log('不选左侧树的时候不调用接口', mapSearchParam.value)
|
||||||
|
if (mapSearchParam.value.parentId) {
|
||||||
getCameraByParentId(mapSearchParam.value).then((res) => {
|
getCameraByParentId(mapSearchParam.value).then((res) => {
|
||||||
console.log('RRRRRRRRRR', res.data.data)
|
console.log('RRRRRRRRRR', res.data.data)
|
||||||
dataSource.value = res.data.data
|
dataSource.value = res.data.data
|
||||||
pagination.value.total = res.data.count
|
pagination.value.total = res.data.count
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
}
|
||||||
//加入申购车
|
//加入申购车
|
||||||
const addShoppingCart = () => {
|
const addShoppingCart = () => {
|
||||||
if (selectedList.value.length > 0) {
|
if (selectedList.value.length > 0) {
|
||||||
|
|
Loading…
Reference in New Issue