关键字提示搜索提示
This commit is contained in:
parent
7e44c1fa16
commit
7a7111cfa3
|
@ -120,6 +120,12 @@ export function getAbilityQuality(query) {
|
|||
params: query
|
||||
})
|
||||
}
|
||||
export function getQualityItem(id) {
|
||||
return request({
|
||||
url: `/ability/quali/${id}/`,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
export function getQualityMy(query) {
|
||||
return request({
|
||||
url: `/ability/quali/my/`,
|
||||
|
|
|
@ -64,28 +64,44 @@
|
|||
ref="filterTable"
|
||||
>
|
||||
<el-table-column type="index" width="45"/>
|
||||
<el-table-column label="名称" prop="name">
|
||||
<el-table-column label="名称">
|
||||
<template slot-scope="scope">
|
||||
<span v-html="showlight(scope.row.name)"></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="资质类型" prop="type">
|
||||
<el-table-column label="资质类型">
|
||||
<template slot-scope="scope">
|
||||
<span v-html="showlight(scope.row.name)"></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="等级">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.type==='OTHER'">{{scope.row.level}}</span>
|
||||
<span v-else>{{typeOptions[scope.row.grade]}}</span>
|
||||
<span v-if="scope.row.type==='OTHER'" v-html="showlight(scope.row.level)">{{scope.row.level}}</span>
|
||||
<span v-else v-html="showlight(typeOptions[scope.row.grade])">{{typeOptions[scope.row.grade]}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="备案城市" prop="citys">
|
||||
<!-- <template slot-scope="scope">
|
||||
<span v-if="scope.row.grade">{{ scope.row.grade}}</span>
|
||||
<span v-if="scope.row.level">、{{ scope.row.level}}</span>
|
||||
</template>-->
|
||||
<el-table-column label="备案城市">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.province_name" v-html="showlight(scope.row.province_name)"></span>
|
||||
<span v-if="scope.row.city_name" v-html="showlight(scope.row.city_name)"></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="所属单位" prop="org"></el-table-column>
|
||||
<el-table-column label="主要服务" prop="service">
|
||||
<el-table-column label="所属单位">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.org_" v-html="showlight(scope.row.org_.name)"></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="资质范围" prop="scope">
|
||||
<!-- <el-table-column label="主要服务" prop="service">
|
||||
</el-table-column>-->
|
||||
<el-table-column label="资质范围">
|
||||
<template slot-scope="scope">
|
||||
<span v-html="showlight(scope.row.scope)"></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="描述" prop="description">
|
||||
<el-table-column label="描述">
|
||||
<template slot-scope="scope">
|
||||
<span v-html="showlight(scope.row.description)"></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建日期">
|
||||
<template slot-scope="scope">{{scope.row.create_time.substring(0, 10)}}</template>
|
||||
|
@ -152,6 +168,20 @@
|
|||
this.getGroup();
|
||||
},
|
||||
methods: {
|
||||
showlight(val) {
|
||||
val = val + "";
|
||||
if (this.listQuery.search !== "") {
|
||||
let searchList = this.listQuery.search.split(" ");
|
||||
let reg = null;
|
||||
for (let i = 0; i < searchList.length; i++) {
|
||||
reg=new RegExp(searchList[i],"g");
|
||||
val = val.replace(reg, '<span style="color:red;font-weight:bold">' + searchList[i] + '</span>');
|
||||
}
|
||||
return val;
|
||||
} else {
|
||||
return val;
|
||||
}
|
||||
},
|
||||
checkPermission,
|
||||
getList() {
|
||||
this.listLoading = true;
|
||||
|
|
|
@ -47,7 +47,6 @@
|
|||
</el-col>
|
||||
</el-row>
|
||||
<div style="margin-top: 10px">
|
||||
<!-- <el-button type="primary" icon="el-icon-plus" @click="handleAdd" v-if="checkPermission(['cma_create'])">新增</el-button> -->
|
||||
<el-popover
|
||||
placement="top"
|
||||
width="160"
|
||||
|
@ -71,13 +70,9 @@
|
|||
>
|
||||
</el-upload>
|
||||
</div>
|
||||
|
||||
|
||||
<el-button slot="reference">导入分子公司能力</el-button>
|
||||
|
||||
</el-popover>
|
||||
<el-button @click="delAll()" v-if="checkPermission(['cma_deletes'])">批量删除</el-button>
|
||||
|
||||
</div>
|
||||
</el-card>
|
||||
<el-card style="margin-top: 10px">
|
||||
|
@ -135,14 +130,10 @@
|
|||
></template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建日期">
|
||||
<template slot-scope="scope">{{
|
||||
scope.row.create_time.substring(0, 10)
|
||||
}}</template>
|
||||
<template slot-scope="scope">{{scope.row.create_time.substring(0, 10)}}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="变更日期">
|
||||
<template slot-scope="scope">{{
|
||||
scope.row.update_time.substring(0, 10)
|
||||
}}</template>
|
||||
<template slot-scope="scope">{{scope.row.update_time.substring(0, 10)}}</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="关联资质"
|
||||
|
@ -183,7 +174,6 @@
|
|||
</template>
|
||||
</el-table-column> -->
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="cmaList.count > 0"
|
||||
:total="cmaList.count"
|
||||
|
@ -281,13 +271,10 @@ export default {
|
|||
val = val + "";
|
||||
if (this.listQuery.search != "") {
|
||||
let searchList = this.listQuery.search.split(" ");
|
||||
for (var i = 0; i < searchList.length; i++) {
|
||||
val = val.replace(
|
||||
searchList[i],
|
||||
'<span style="color:red;font-weight:bold">' +
|
||||
searchList[i] +
|
||||
"</span>"
|
||||
);
|
||||
let reg = null;
|
||||
for (let i = 0; i < searchList.length; i++) {
|
||||
reg=new RegExp(searchList[i],"g");
|
||||
val = val.replace(reg, '<span style="color:red;font-weight:bold">' + searchList[i] + '</span>');
|
||||
}
|
||||
return val;
|
||||
} else {
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="300"
|
||||
:height="topHeight"
|
||||
@row-click="clickRow"
|
||||
>
|
||||
<el-table-column type="index" width="50"/>
|
||||
|
@ -103,7 +103,7 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="400"
|
||||
:height="bottomHeight"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
|
||||
|
@ -124,13 +124,13 @@
|
|||
<el-tag type="danger" effect="plain" v-else>未确认</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="改动内容">
|
||||
<!-- <el-table-column label="改动内容">
|
||||
<template #default="scope">
|
||||
<span v-if="scope.row.value2.name">{{ scope.row.value2.name }}</span>
|
||||
<span v-else>{{ scope.row.value2 }}</span>
|
||||
<span v-else-if="typeof scope.row.value2=='String'">{{ scope.row.value2 }}</span>
|
||||
</template>
|
||||
|
||||
</el-table-column>
|
||||
</el-table-column>-->
|
||||
<el-table-column label="报送文件">
|
||||
<template slot-scope="scope" v-if="scope.row.files">
|
||||
<el-link
|
||||
|
@ -147,7 +147,9 @@
|
|||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作人">
|
||||
<template slot-scope="scope">{{ scope.row.content_name }}</template>
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.create_by_"> {{ scope.row.create_by_.name }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作时间">
|
||||
<template slot-scope="scope" >{{ scope.row.update_time.substring(0, 16) }}</template>
|
||||
|
@ -468,7 +470,7 @@
|
|||
v-model="qualiForm.province"
|
||||
placeholder="省份"
|
||||
clearable
|
||||
@change="getCites(qualiForm.province)"
|
||||
disabled
|
||||
>
|
||||
<el-option
|
||||
v-for="item in proviceOptions"
|
||||
|
@ -480,6 +482,7 @@
|
|||
<el-select
|
||||
v-model="qualiForm.city"
|
||||
placeholder="所在市"
|
||||
disabled
|
||||
>
|
||||
<el-option
|
||||
v-for="item in cityOptions"
|
||||
|
@ -495,7 +498,7 @@
|
|||
placeholder="省份"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
@change="getCites(qualiForm.province)"
|
||||
disabled
|
||||
>
|
||||
<el-option
|
||||
v-for="item in proviceOptions"
|
||||
|
@ -510,6 +513,7 @@
|
|||
style="width: 100%;"
|
||||
v-model="qualiForm.city"
|
||||
placeholder="所在市"
|
||||
disabled
|
||||
>
|
||||
<el-option
|
||||
v-for="item in cityOptions"
|
||||
|
@ -650,9 +654,15 @@
|
|||
filterOrgText: "",
|
||||
treeLoding: false,
|
||||
buttonsShow: false,
|
||||
topHeight:null,
|
||||
bottomHeight:null,
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
let height1 = document.getElementsByClassName('app-main')[0].clientHeight/2;
|
||||
let height2 = document.getElementsByClassName('pagination-container')[0].clientHeight;
|
||||
this.topHeight = height1-height2-95;
|
||||
this.bottomHeight = height1-height2-80;
|
||||
this.getTableList();
|
||||
this.getGroup();
|
||||
//领域类型
|
||||
|
@ -730,8 +740,6 @@
|
|||
|
||||
///////
|
||||
getList(){
|
||||
this.qtask = obj.qtask;
|
||||
this.listQuery.task = obj.qtask;
|
||||
qactionMy(this.listQuery).then((res)=>{
|
||||
this.recordList = res.data;
|
||||
})
|
||||
|
@ -742,13 +750,15 @@
|
|||
},
|
||||
//更新服务提交
|
||||
submitEditSever(form){
|
||||
let that = this;
|
||||
this.$refs[form].validate((valid) => {
|
||||
if (valid) {
|
||||
this.severForm.qtask = this.qtask;
|
||||
that.severForm.qtask = this.qtask;
|
||||
updateService(this.severForm).then((res) => {
|
||||
if (res.code >= 200) {
|
||||
this.dialogVisibleSever = false;
|
||||
this.$message.success("成功");
|
||||
that.getList();
|
||||
that.dialogVisibleSever = false;
|
||||
that.$message.success("成功");
|
||||
}
|
||||
});
|
||||
} else {
|
||||
|
@ -804,37 +814,38 @@
|
|||
},
|
||||
//提交资质
|
||||
async confirm(form) {
|
||||
this.$refs[form].validate((valid) => {
|
||||
let that = this;
|
||||
that.$refs[form].validate((valid) => {
|
||||
if (valid) {
|
||||
if(this.qualiForm.type==='OTHER'){
|
||||
let city = parseInt(this.qualiForm.city);
|
||||
let province = parseInt(this.qualiForm.province);
|
||||
this.qualiForm.citys.push(province);
|
||||
this.qualiForm.citys.push(city);
|
||||
if(that.qualiForm.type==='OTHER'){
|
||||
let city = parseInt(that.qualiForm.city);
|
||||
let province = parseInt(that.qualiForm.province);
|
||||
that.qualiForm.citys.push(province);
|
||||
that.qualiForm.citys.push(city);
|
||||
}else{}
|
||||
let obj = new Object();
|
||||
obj.qtask = this.qtask;
|
||||
obj.value2 = this.qualiForm;
|
||||
obj.qtask = that.qtask;
|
||||
obj.value2 = that.qualiForm;
|
||||
if(obj.value2.grade===''){
|
||||
obj.value2.grade=null
|
||||
}
|
||||
const isEdit = this.dialogType === "edit";
|
||||
const isEdit = that.dialogType === "edit";
|
||||
if (isEdit) {
|
||||
updateQuali(obj).then((res) => {
|
||||
if (res.code >= 200) {
|
||||
this.getTableList();
|
||||
this.dialogVisibleQuliEdit = false;
|
||||
this.$message.success("成功");
|
||||
if (res.code>=200&&res.code<400) {
|
||||
that.getList();
|
||||
that.dialogVisibleQuliEdit = false;
|
||||
that.$message.success("成功");
|
||||
}
|
||||
});
|
||||
} else {
|
||||
debugger;
|
||||
console.log(obj)
|
||||
console.log(obj);
|
||||
createQuali(obj).then((res) => {
|
||||
if (res.code >= 200) {
|
||||
this.getTableList();
|
||||
this.dialogVisible = false;
|
||||
this.$message.success("成功");
|
||||
if (res.code>=200&&res.code<400) {
|
||||
that.getList();
|
||||
that.dialogVisible = false;
|
||||
that.$message.success("成功");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -845,14 +856,15 @@
|
|||
},
|
||||
//提交服务更新
|
||||
async confirmAbility(form) {
|
||||
this.$refs[form].validate((valid) => {
|
||||
let that = this;
|
||||
that.$refs[form].validate((valid) => {
|
||||
if (valid) {
|
||||
this.abilityForm.qtask = this.qtask;
|
||||
createAbility(this.abilityForm).then((res) => {
|
||||
if (res.code >= 200) {
|
||||
this.getTableList();
|
||||
this.dialogVisibleAbility = false;
|
||||
this.$message.success("成功");
|
||||
that.abilityForm.qtask = that.qtask;
|
||||
createAbility(that.abilityForm).then((res) => {
|
||||
if (res.code>=200&&res.code<400) {
|
||||
that.getList();
|
||||
that.dialogVisibleAbility = false;
|
||||
that.$message.success("成功");
|
||||
}
|
||||
});
|
||||
} else {
|
||||
|
@ -862,11 +874,15 @@
|
|||
},
|
||||
//删除操作
|
||||
handleDelete(id){
|
||||
this.$confirm("确认删除该操作吗?", "提示")
|
||||
let that = this;
|
||||
that.$confirm("确认删除该操作吗?", "提示")
|
||||
.then(async () => {
|
||||
await qactionDelete(id);
|
||||
location.reload();
|
||||
this.$message.success("成功");
|
||||
await qactionDelete(id).then(res=>{
|
||||
if(res.code>=200&&res.code<400){
|
||||
that.getList();
|
||||
that.$message.success("成功");
|
||||
}
|
||||
});
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<el-card class="filterTop">
|
||||
<el-input
|
||||
v-model="pageForm.search"
|
||||
placeholder="任务名"
|
||||
|
@ -41,7 +41,7 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
:height="tableHeight"
|
||||
>
|
||||
<el-table-column type="index" width="50"/>
|
||||
<el-table-column label="任务名称" prop="name"></el-table-column>
|
||||
|
@ -65,12 +65,12 @@
|
|||
size="small"
|
||||
@click="handleClick(scope)"
|
||||
>执行</el-link>
|
||||
<el-link
|
||||
<!-- <el-link
|
||||
v-if="scope.row.state==='待发布'"
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="handleEdit(scope)"
|
||||
>编辑</el-link>
|
||||
>编辑</el-link>-->
|
||||
<el-link
|
||||
v-if="scope.row.state==='待发布'"
|
||||
type="warning"
|
||||
|
@ -173,9 +173,13 @@
|
|||
},
|
||||
filterOrgText: "",
|
||||
treeLoding: false,
|
||||
tableHeight: null,
|
||||
}
|
||||
},
|
||||
mounted(){
|
||||
let height1 = document.getElementsByClassName('app-main')[0].clientHeight;
|
||||
let height2 = document.getElementsByClassName('filterTop')[0].clientHeight;
|
||||
this.tableHeight = height1-height2-70;
|
||||
this.getOrgsList();
|
||||
this.getQtaskList();
|
||||
},
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<el-card class="filterTop">
|
||||
<div slot="header" class="clearfix">
|
||||
<span>任务详情</span>
|
||||
</div>
|
||||
|
@ -65,7 +65,7 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
height="300px"
|
||||
:height="tableHeight"
|
||||
@row-click="clickRow"
|
||||
>
|
||||
<el-table-column label="序号" type="index" align="center" width="55"/>
|
||||
|
@ -149,7 +149,7 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
height="300px"
|
||||
:height="tableHeight"
|
||||
style="margin-top:2px"
|
||||
@selection-change="handleSelectRecords"
|
||||
>
|
||||
|
@ -169,18 +169,13 @@
|
|||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作人">
|
||||
<template slot-scope="scope">{{ scope.row.content_name }}</template>
|
||||
<template slot-scope="scope">
|
||||
<span v-if=" scope.row.create_by_">{{ scope.row.create_by_.name }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作时间">
|
||||
<template slot-scope="scope">{{ scope.row.update_time }}</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="改动内容">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.value2.name">{{ scope.row.value2.name}}</span>
|
||||
<span v-else>{{ scope.row.value2}}</span>
|
||||
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="文件">
|
||||
<template slot-scope="scope">
|
||||
<el-link v-if="scope.row.file" :href="scope.row.file" target="_blank" type="primary">
|
||||
|
@ -225,12 +220,13 @@
|
|||
size="40%"
|
||||
>
|
||||
<div
|
||||
v-if="data.action==='service:update'"
|
||||
v-if="showData.type==='service:update'"
|
||||
style="padding: 10px 20px;position: relative"
|
||||
>
|
||||
<p style="font-size: 20px;font-weight: bold;">更新服务</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">原始内容:</span>{{data.value1}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">更新内容:</span>{{data.value2}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">原始内容:</span>{{showData.data.value1}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">更新内容:</span>{{showData.data.value2}}</p>
|
||||
<el-divider></el-divider>
|
||||
<el-button
|
||||
v-if="actionType==='confirm'"
|
||||
style="position: absolute;right:40px;margin-top: 20px"
|
||||
|
@ -241,14 +237,15 @@
|
|||
</el-button>
|
||||
</div>
|
||||
<div
|
||||
v-if="data.action==='ablity:create'"
|
||||
v-if="showData.type==='ablity:create'"
|
||||
style="padding: 10px 20px;position: relative"
|
||||
>
|
||||
<p style="font-size: 20px;font-weight: bold;">新增能力</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">能力类型 :</span>{{data.afield_name}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">能力领域:</span>{{data.afield_name}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">上传文件:</span>{{data.file}}</p>
|
||||
<el-link :href="data.file" target="_blank" type="primary">{{data.file}}</el-link>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">能力类型 :</span>{{showData.data.afield_name}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">能力领域:</span>{{showData.data.afield_name}}</p>
|
||||
<p><span style="display: inline-block;width: 100px;font-weight: bold;">上传文件:</span>{{showData.data.file}}</p>
|
||||
<el-link :href="showData.data.file" target="_blank" type="primary">{{showData.data.file}}</el-link>
|
||||
<el-divider></el-divider>
|
||||
<el-button
|
||||
v-if="actionType==='confirm'"
|
||||
style="position: absolute;right:40px;margin-top: 20px"
|
||||
|
@ -265,9 +262,10 @@
|
|||
@handleDo="handleDo"
|
||||
></quliShow>
|
||||
<quliShow
|
||||
v-if="drawer&&showData.type==='quli:update'"
|
||||
v-if="drawer&&showData.type==='quali:update'"
|
||||
ref="quliShow"
|
||||
:showData="showData"
|
||||
:fieldList2="fieldList2"
|
||||
@handleDo="handleDo"
|
||||
></quliShow>
|
||||
</el-drawer>
|
||||
|
@ -318,22 +316,29 @@
|
|||
qtask: {},
|
||||
detailItem: {},
|
||||
actionType: null,
|
||||
tableHeight: null,
|
||||
fieldList2: [],
|
||||
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.qtaskId = sessionStorage.getItem('qtaskId');
|
||||
},
|
||||
mounted() {
|
||||
debugger;
|
||||
let height1 = document.getElementsByClassName('app-main')[0].clientHeight;
|
||||
let height2 = document.getElementsByClassName('filterTop')[0].clientHeight;
|
||||
let computedHeight = height1-height2;
|
||||
this.tableHeight = computedHeight/2-54;
|
||||
this.qtaskId = sessionStorage.getItem('qtaskId');
|
||||
this.getQtaskDept();
|
||||
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
checkPermission,
|
||||
getQtaskDept() {
|
||||
debugger;
|
||||
qtaskDetail({qtask: this.qtaskId}).then((res) => {
|
||||
debugger;
|
||||
this.qtaskDepts = res.data.results;
|
||||
this.qtask = res.data.results[0].qtask_;
|
||||
});
|
||||
|
@ -351,28 +356,38 @@
|
|||
},
|
||||
//操作处理
|
||||
handleRecord(type, item) {
|
||||
debugger;
|
||||
if (item.action === 'quali:update' || item.action === 'quali:create') {
|
||||
this.data = item;
|
||||
// debugger;
|
||||
this.showData.data = item;
|
||||
this.showData.type = item.action;
|
||||
this.showData.action = type;
|
||||
} else {
|
||||
this.data = item;
|
||||
this.actionType = type;
|
||||
}
|
||||
this.drawer = true;
|
||||
qactionItem(item.id).then(res => {
|
||||
this.fieldList2 =[];
|
||||
qactionItem(item.id).then(res=>{
|
||||
if (res.code>=200) {
|
||||
debugger;
|
||||
let updateDetail = res.data.update_detail;//更改字段
|
||||
updateDetail.forEach(item=>{
|
||||
this.fieldList2.push(item.field);//所有字段
|
||||
})
|
||||
this.drawer = true;
|
||||
}
|
||||
debugger;
|
||||
console.log(this.fieldList2)
|
||||
})
|
||||
|
||||
qactionItem(item.id).then(res => {
|
||||
console.log(res)
|
||||
})
|
||||
},
|
||||
handleDelete(id) {
|
||||
this.$confirm("确认删除该操作吗?", "提示")
|
||||
.then(async () => {
|
||||
await qactionDelete(id);
|
||||
location.reload();
|
||||
await qactionDelete(id).then(res=>{
|
||||
if(res.code>=200&&res.code<400){
|
||||
this.getQactionList();
|
||||
this.$message.success("成功");
|
||||
}
|
||||
});
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err);
|
||||
|
@ -381,15 +396,14 @@
|
|||
//操作确认
|
||||
confirmClick() {
|
||||
qactionConfirm(this.data.id).then(res => {
|
||||
debugger;
|
||||
console.log(res)
|
||||
if (res.code === 200) {
|
||||
if (res.code>=200) {
|
||||
this.drawer = false;
|
||||
this.getQactionList();
|
||||
}
|
||||
})
|
||||
},
|
||||
handleDo(data) {
|
||||
console.log(data);
|
||||
this.drawer = data;
|
||||
this.getQactionList();
|
||||
},
|
||||
|
|
|
@ -1,29 +1,54 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<div class="ma">资质报送详情</div>
|
||||
<el-form label-width="100px" label-position="left">
|
||||
<p v-if="showData.type==='quali:create'" style="font-size: 20px;font-weight: bold;">新增资质</p>
|
||||
<p v-if="showData.type==='quali:update'" style="font-size: 20px;font-weight: bold;">编辑资质</p>
|
||||
<el-form
|
||||
v-if="showData.type==='quali:create'"
|
||||
label-width="100px"
|
||||
label-position="left"
|
||||
>
|
||||
<el-form-item label="资质名称">
|
||||
{{ data.value2.name }}
|
||||
</el-form-item>
|
||||
<el-form-item label="" v-if="data.value2.name1">
|
||||
<span style="color: #f56c6c;">{{data.value2.name1}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="资质类型">
|
||||
{{ data.value2.type }}
|
||||
</el-form-item>
|
||||
<el-form-item label="" v-if="data.value2.type1">
|
||||
<span style="color: #f56c6c;">{{data.value2.type1}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="资质等级" v-if="data.type!=='OTHER'">
|
||||
<span v-if="data.value2.grade===10">国家级</span>
|
||||
<span v-if="data.value2.grade===20">省级</span>
|
||||
<span v-if="data.value2.grade===30">市级</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="" v-if="data.value2.grade1">
|
||||
<span v-if="data.value2.grade1===10">国家级</span>
|
||||
<span v-if="data.value2.grade1===20">省级</span>
|
||||
<span v-if="data.value2.grade1===30">市级</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="二级等级" v-if="data.type==='OTHER'">
|
||||
{{ data.value2.level }}
|
||||
</el-form-item>
|
||||
<el-form-item label="" v-if="data.value2.level1">
|
||||
<span style="color: #f56c6c;">{{data.value2.level1}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="资质范围">
|
||||
{{data.value2.scope}}
|
||||
</el-form-item>
|
||||
<el-form-item label="" v-if="data.value2.scope1">
|
||||
<span style="color: #f56c6c;">{{data.value2.scope1}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="描述">
|
||||
{{data.value2.description}}
|
||||
</el-form-item>
|
||||
<el-form-item label="" v-if="data.value2.description1">
|
||||
<span style="color: #f56c6c;">{{data.value2.description1}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="备案城市" v-if="data.type==='OTHER'">
|
||||
{{ data.value2.name }}
|
||||
{{ data.value2.citys }}
|
||||
</el-form-item>
|
||||
<el-form-item label="所在省" v-if="data.type!=='OTHER'">
|
||||
{{ data.value2.province }}
|
||||
|
@ -35,10 +60,82 @@
|
|||
{{ data.value2.name }}
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div v-if="showData.type==='quali:update'">
|
||||
<el-form
|
||||
label-width="100px"
|
||||
label-position="left"
|
||||
>
|
||||
<el-form-item label="资质名称">
|
||||
{{ formData.name }}
|
||||
</el-form-item>
|
||||
<el-form-item label="资质类型">
|
||||
{{ formData.type }}
|
||||
</el-form-item>
|
||||
<el-form-item label="资质等级" v-if="formData.type!=='OTHER'">
|
||||
<span v-if="formData.grade===10">国家级</span>
|
||||
<span v-if="formData.grade===20">省级</span>
|
||||
<span v-if="formData.grade===30">市级</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="二级等级" v-if="formData.type==='OTHER'">
|
||||
{{ formData.level }}
|
||||
</el-form-item>
|
||||
<el-form-item label="资质范围">
|
||||
{{formData.scope}}
|
||||
</el-form-item>
|
||||
<el-form-item label="描述">
|
||||
{{formData.description}}
|
||||
</el-form-item>
|
||||
<el-form-item label="备案城市" v-if="formData.type==='OTHER'">
|
||||
{{ formData.province_name }}{{ formData.city_name }}
|
||||
</el-form-item>
|
||||
<el-form-item label="所在省" v-if="formData.grade===20">
|
||||
{{ formData.province_name }}
|
||||
</el-form-item>
|
||||
<el-form-item label="所在市" v-if="formData.grade===30">
|
||||
{{ formData.city_name }}
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-divider></el-divider>
|
||||
<el-form
|
||||
label-width="100px"
|
||||
label-position="left"
|
||||
>
|
||||
<el-form-item label="资质名称">
|
||||
<span :class="setClass('name')"> {{ formData2.name }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="资质类型">
|
||||
<span :class="setClass('type')"> {{ formData2.type }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="资质等级" v-if="formData2.type!=='OTHER'">
|
||||
<span v-if="formData2.grade===10" :class="setClass('grade')">国家级</span>
|
||||
<span v-if="formData2.grade===20" :class="setClass('grade')">省级</span>
|
||||
<span v-if="formData2.grade===30" :class="setClass('grade')">市级</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="二级等级" v-if="formData2.type==='OTHER'">
|
||||
<span :class="setClass('level')"> {{ formData2.level }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="资质范围">
|
||||
<span :class="setClass('scope')"> {{ formData2.scope }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="描述">
|
||||
<span :class="setClass('description')"> {{ formData2.description }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="备案城市" v-if="formData2.type==='OTHER'">
|
||||
<span :class="setClass('citys')"> {{ formData2.province_name}}{{ formData2.city_name }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="所在省" v-if="formData2.grade===20">
|
||||
<span :class="setClass('provice')"> {{ formData2.province_name}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="所在市" v-if="formData.grade===30">
|
||||
<span :class="setClass('city')"> {{ formData2.city_name }}</span>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
</div>
|
||||
<el-divider></el-divider>
|
||||
<div style="text-align: right">
|
||||
<el-button
|
||||
v-if="this.showData.action == 'confirm'"
|
||||
v-if="action === 'confirm'"
|
||||
@click="confirm()"
|
||||
type="primary"
|
||||
>
|
||||
|
@ -50,31 +147,71 @@
|
|||
|
||||
<script>
|
||||
import {upUrl, upHeaders} from "@/api/file";
|
||||
import {qactionConfirm} from "@/api/ability";
|
||||
import {qactionConfirm,qactionItem,getQualityItem,provinceLists,cityLists} from "@/api/ability";
|
||||
|
||||
export default {
|
||||
name: "quliShow",
|
||||
props: ["showData"],
|
||||
props:{
|
||||
showData:{
|
||||
type:Object,
|
||||
require:true //属性必要性:true表示属性必须进行传递
|
||||
},
|
||||
fieldList2:{
|
||||
type:Array,
|
||||
default:[]
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
data: null,
|
||||
action: null,
|
||||
fileList: [],
|
||||
formData: null,
|
||||
formData2: null,
|
||||
updateDetail: [],
|
||||
fieldList: [],
|
||||
};
|
||||
},
|
||||
created() {
|
||||
mounted() {
|
||||
this.initRecord();
|
||||
this.getProvince();
|
||||
},
|
||||
methods: {
|
||||
setClass(item){
|
||||
let obj = {};
|
||||
if(this.fieldList2.indexOf(item)>-1){
|
||||
obj = 'redFont';
|
||||
}
|
||||
return obj;
|
||||
},
|
||||
initRecord() {
|
||||
debugger;
|
||||
console.log(this.showData);
|
||||
//操作类型查看/确认
|
||||
this.action = this.showData.action;
|
||||
this.data = Object.assign({}, this.showData.data);
|
||||
qactionItem(this.data.id).then(res=>{
|
||||
if (res.code>=200) {
|
||||
this.formData =Object.assign({}, res.data.value1);
|
||||
this.formData2 = res.data.value1;
|
||||
debugger;
|
||||
console.log(this.formData);
|
||||
console.log(this.formData2);
|
||||
let fieldList = [];
|
||||
let updateDetail = res.data.update_detail;//更改字段
|
||||
for( let key in this.formData2 ){
|
||||
fieldList.push(key);//所有字段
|
||||
}
|
||||
updateDetail.forEach(item=>{
|
||||
if(fieldList.indexOf(item.field)>-1){
|
||||
this.formData2[item.field] = item.value2;
|
||||
}
|
||||
});
|
||||
}
|
||||
})
|
||||
},
|
||||
confirm() {
|
||||
qactionConfirm(this.data.id).then(res => {
|
||||
if (res.code === 200) {
|
||||
this.drawer = false;
|
||||
this.$emit("handleDo", true);
|
||||
if (res.code>=200) {
|
||||
this.$emit("handleDo", false);
|
||||
}
|
||||
})
|
||||
},
|
||||
|
@ -97,4 +234,7 @@
|
|||
cursor: pointer;
|
||||
color: #409eff;
|
||||
}
|
||||
.redFont{
|
||||
color: red;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -1,9 +1,30 @@
|
|||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<el-card class="filterTop">
|
||||
<el-button type="primary" icon="el-icon-plus" @click="handleAddVideo"
|
||||
>新增</el-button
|
||||
>
|
||||
<el-input
|
||||
v-model="listQuery.search"
|
||||
placeholder="关键字"
|
||||
style="width: 300px"
|
||||
class="filter-item"
|
||||
@keyup.enter.native="handleFilter"
|
||||
/>
|
||||
<el-button
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-search"
|
||||
@click="handleFilter"
|
||||
>搜索</el-button
|
||||
>
|
||||
<el-button
|
||||
class="filter-item"
|
||||
type="primary"
|
||||
icon="el-icon-refresh-left"
|
||||
@click="resetFilter"
|
||||
>重置</el-button
|
||||
>
|
||||
</el-card>
|
||||
<el-card style="margin-top: 10px">
|
||||
<el-table
|
||||
|
@ -20,7 +41,7 @@
|
|||
fit
|
||||
stripe
|
||||
highlight-current-row
|
||||
max-height="600"
|
||||
:height="tableHeight"
|
||||
>
|
||||
<el-table-column type="index" width="50" />
|
||||
<el-table-column label="名称" prop="name"></el-table-column>
|
||||
|
@ -36,13 +57,6 @@
|
|||
width="200px"
|
||||
fixed="right"
|
||||
>
|
||||
<template slot="header" slot-scope="scope">
|
||||
<el-input
|
||||
v-model="search"
|
||||
size="mini"
|
||||
placeholder="输入关键字搜索"
|
||||
/>
|
||||
</template>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
:disabled="!checkPermission(['video_update'])"
|
||||
|
@ -224,6 +238,7 @@ export default {
|
|||
|
||||
data() {
|
||||
return {
|
||||
tableHeight:null,
|
||||
dialogVisible: false,
|
||||
signature: "",
|
||||
treeLoding: false,
|
||||
|
@ -235,6 +250,7 @@ export default {
|
|||
listQuery: {
|
||||
page: 1,
|
||||
page_size: 20,
|
||||
search:''
|
||||
},
|
||||
search: "",
|
||||
VideoContent: defaultVideo,
|
||||
|
@ -256,7 +272,9 @@ export default {
|
|||
},
|
||||
computed: {},
|
||||
|
||||
created() {
|
||||
mounted() {
|
||||
let height1 = document.getElementsByClassName('app-main')[0].clientHeight;
|
||||
this.tableHeight = height1-120;
|
||||
this.getList();
|
||||
this.getTypeAll();
|
||||
},
|
||||
|
@ -287,7 +305,13 @@ export default {
|
|||
console.log(row)
|
||||
return row.category === value;
|
||||
},
|
||||
|
||||
handleFilter(){
|
||||
this.getList();
|
||||
},
|
||||
resetFilter(){
|
||||
this.listQuery.search = '';
|
||||
this.getList();
|
||||
},
|
||||
/*弹出弹窗 */
|
||||
handleAddVideo() {
|
||||
this.VideoContent = Object.assign({}, defaultVideo);
|
||||
|
|
Loading…
Reference in New Issue