|
@@ -18,16 +18,16 @@
|
|
<el-form-item label="同义词:">
|
|
<el-form-item label="同义词:">
|
|
<el-input size="mini" v-model="filter.libName" placeholder="输入同义词"></el-input>
|
|
<el-input size="mini" v-model="filter.libName" placeholder="输入同义词"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="状态:">
|
|
|
|
- <el-select v-model="filter.isState" clearable placeholder="请选择" size="mini">
|
|
|
|
- <el-option
|
|
|
|
- v-for="item in stateSelect"
|
|
|
|
- :key="item.id"
|
|
|
|
- :label="item.name"
|
|
|
|
- :value="item.id">
|
|
|
|
- </el-option>
|
|
|
|
- </el-select>
|
|
|
|
- </el-form-item>
|
|
|
|
|
|
+ <el-form-item label="状态:">
|
|
|
|
+ <el-select v-model="filter.isState" clearable placeholder="请选择" size="mini">
|
|
|
|
+ <el-option
|
|
|
|
+ v-for="item in stateSelect"
|
|
|
|
+ :key="item.id"
|
|
|
|
+ :label="item.name"
|
|
|
|
+ :value="item.id"
|
|
|
|
+ ></el-option>
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
<el-form-item>
|
|
<el-form-item>
|
|
<el-button size="mini" @click="filterDatas">确认</el-button>
|
|
<el-button size="mini" @click="filterDatas">确认</el-button>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
@@ -35,10 +35,7 @@
|
|
<el-form class="secLine">
|
|
<el-form class="secLine">
|
|
<el-form-item>
|
|
<el-form-item>
|
|
<el-button size="mini" type="warning" @click="addMedicalName" style="margin:0 10px">+ 新增术语</el-button>
|
|
<el-button size="mini" type="warning" @click="addMedicalName" style="margin:0 10px">+ 新增术语</el-button>
|
|
- <el-button
|
|
|
|
- size="mini"
|
|
|
|
- @click="reloadLib"
|
|
|
|
- >更新数据</el-button>
|
|
|
|
|
|
+ <el-button size="mini" @click="reloadLib">更新数据</el-button>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
</crumbs>
|
|
</crumbs>
|
|
@@ -57,17 +54,9 @@
|
|
<el-table-column prop="gmtModified" label="操作时间" :show-overflow-tooltip="true"></el-table-column>
|
|
<el-table-column prop="gmtModified" label="操作时间" :show-overflow-tooltip="true"></el-table-column>
|
|
<el-table-column label="操作" width="160">
|
|
<el-table-column label="操作" width="160">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <el-button
|
|
|
|
- type="text"
|
|
|
|
- size="small"
|
|
|
|
- @click="toEditProduct(scope.row)"
|
|
|
|
- >修改</el-button>
|
|
|
|
|
|
+ <el-button type="text" size="small" @click="toEditProduct(scope.row)">修改</el-button>
|
|
<span style="margin:0 3px;">|</span>
|
|
<span style="margin:0 3px;">|</span>
|
|
- <el-button
|
|
|
|
- type="text"
|
|
|
|
- size="small"
|
|
|
|
- @click="toEditProduct(scope.row,true)"
|
|
|
|
- >复制</el-button>
|
|
|
|
|
|
+ <el-button type="text" size="small" @click="toEditProduct(scope.row,true)">复制</el-button>
|
|
<span style="margin:0 3px;">|</span>
|
|
<span style="margin:0 3px;">|</span>
|
|
<el-button
|
|
<el-button
|
|
type="text"
|
|
type="text"
|
|
@@ -102,9 +91,9 @@ export default {
|
|
data: function() {
|
|
data: function() {
|
|
return {
|
|
return {
|
|
list: [],
|
|
list: [],
|
|
- stateSelect:[
|
|
|
|
- {id:'N',name:'启用'},
|
|
|
|
- {id:'Y',name:'禁用'},
|
|
|
|
|
|
+ stateSelect: [
|
|
|
|
+ { id: 'N', name: '启用' },
|
|
|
|
+ { id: 'Y', name: '禁用' }
|
|
],
|
|
],
|
|
// isState:'',
|
|
// isState:'',
|
|
cacheData: {}, //因为删除和恢复要及时更新,所以不做缓存
|
|
cacheData: {}, //因为删除和恢复要及时更新,所以不做缓存
|
|
@@ -117,7 +106,7 @@ export default {
|
|
filter: {
|
|
filter: {
|
|
term: '',
|
|
term: '',
|
|
type: '',
|
|
type: '',
|
|
- libName: '',
|
|
|
|
|
|
+ libName: ''
|
|
},
|
|
},
|
|
typeList: [],
|
|
typeList: [],
|
|
reloadFlag: true
|
|
reloadFlag: true
|
|
@@ -125,18 +114,18 @@ export default {
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
const param = this.$route.params;
|
|
const param = this.$route.params;
|
|
- if(param.currentPage){
|
|
|
|
- this.inCurrentPage = param.currentPage
|
|
|
|
|
|
+ if (param.currentPage) {
|
|
|
|
+ this.inCurrentPage = param.currentPage;
|
|
}
|
|
}
|
|
- if(param.filter){
|
|
|
|
- this.filter = param.filter
|
|
|
|
|
|
+ if (param.filter) {
|
|
|
|
+ this.filter = param.filter;
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
this.getTypeList();
|
|
this.getTypeList();
|
|
//返回时避免参数未赋值就获取列表
|
|
//返回时避免参数未赋值就获取列表
|
|
- this.$nextTick(()=>{
|
|
|
|
|
|
+ this.$nextTick(() => {
|
|
this.getDataList();
|
|
this.getDataList();
|
|
- })
|
|
|
|
|
|
+ });
|
|
},
|
|
},
|
|
watch: {
|
|
watch: {
|
|
filter: {
|
|
filter: {
|
|
@@ -176,9 +165,9 @@ export default {
|
|
this.getDataList();
|
|
this.getDataList();
|
|
if (res.data.code == 0) {
|
|
if (res.data.code == 0) {
|
|
this.reloadFlag = true;
|
|
this.reloadFlag = true;
|
|
- this.warning('更新成功','success');
|
|
|
|
- }else{
|
|
|
|
- this.warning(res.data.msg||'更新失败,请重试');
|
|
|
|
|
|
+ this.warning('更新成功', 'success');
|
|
|
|
+ } else {
|
|
|
|
+ this.warning(res.data.msg || '更新失败,请重试');
|
|
}
|
|
}
|
|
});
|
|
});
|
|
}
|
|
}
|
|
@@ -204,7 +193,7 @@ export default {
|
|
this.$router.push({
|
|
this.$router.push({
|
|
name: 'AddTerm',
|
|
name: 'AddTerm',
|
|
// params: {info:row}
|
|
// params: {info:row}
|
|
- params: Object.assign(pam, { id: row.conceptId, copy: copy })
|
|
|
|
|
|
+ params: Object.assign(pam, { id: row.conceptId,libType:row.libType, copy: copy })
|
|
});
|
|
});
|
|
},
|
|
},
|
|
filterDatas() {
|
|
filterDatas() {
|
|
@@ -220,14 +209,15 @@ export default {
|
|
spinner: 'el-icon-loading',
|
|
spinner: 'el-icon-loading',
|
|
background: 'rgba(0, 0, 0, 0.7)'
|
|
background: 'rgba(0, 0, 0, 0.7)'
|
|
});
|
|
});
|
|
- api.getBaseConceptInfoPage(param)
|
|
|
|
|
|
+ api
|
|
|
|
+ .getBaseConceptInfoPage(param)
|
|
.then(res => {
|
|
.then(res => {
|
|
loading.close();
|
|
loading.close();
|
|
if (res.data.code == '0') {
|
|
if (res.data.code == '0') {
|
|
const data = res.data.data;
|
|
const data = res.data.data;
|
|
const templis = data.records;
|
|
const templis = data.records;
|
|
- for(let i = 0;i < templis.length;i++){
|
|
|
|
- templis[i].isDeleted = templis[i].status=='1'?'N':'Y'
|
|
|
|
|
|
+ for (let i = 0; i < templis.length; i++) {
|
|
|
|
+ templis[i].isDeleted = templis[i].status == '1' ? 'N' : 'Y';
|
|
}
|
|
}
|
|
this.list = templis;
|
|
this.list = templis;
|
|
// this.cacheData[param.current] = data.records;
|
|
// this.cacheData[param.current] = data.records;
|
|
@@ -244,11 +234,11 @@ export default {
|
|
},
|
|
},
|
|
getTypeList() {
|
|
getTypeList() {
|
|
api
|
|
api
|
|
- .baseTypeGetPage({ name: '',size: 1000 })
|
|
|
|
|
|
+ .baseTypeGetPage({ name: '', size: 1000 })
|
|
.then(res => {
|
|
.then(res => {
|
|
const data = res.data;
|
|
const data = res.data;
|
|
if (data.code == 0) {
|
|
if (data.code == 0) {
|
|
- this.typeList = data.data.records||[];
|
|
|
|
|
|
+ this.typeList = data.data.records || [];
|
|
} else {
|
|
} else {
|
|
console.log(res.msg);
|
|
console.log(res.msg);
|
|
}
|
|
}
|
|
@@ -266,10 +256,15 @@ export default {
|
|
this.clearFilter();
|
|
this.clearFilter();
|
|
}
|
|
}
|
|
const param = {
|
|
const param = {
|
|
- "libName": this.filter.term.trim(),
|
|
|
|
- "libType": this.filter.type,
|
|
|
|
- "status": this.filter.isState=='N'?'1':this.filter.isState=='Y'?'0':'',
|
|
|
|
- "synonymName": this.filter.libName.trim(),
|
|
|
|
|
|
+ libName: this.filter.term.trim(),
|
|
|
|
+ libType: this.filter.type,
|
|
|
|
+ status:
|
|
|
|
+ this.filter.isState == 'N'
|
|
|
|
+ ? '1'
|
|
|
|
+ : this.filter.isState == 'Y'
|
|
|
|
+ ? '0'
|
|
|
|
+ : '',
|
|
|
|
+ synonymName: this.filter.libName.trim(),
|
|
current: this.inCurrentPage || this.currentPage,
|
|
current: this.inCurrentPage || this.currentPage,
|
|
size: this.pageSize,
|
|
size: this.pageSize,
|
|
isDeleted: this.filter.isState
|
|
isDeleted: this.filter.isState
|
|
@@ -313,7 +308,7 @@ export default {
|
|
const param = {
|
|
const param = {
|
|
conceptId: item.conceptId
|
|
conceptId: item.conceptId
|
|
};
|
|
};
|
|
- let url = item.isDeleted === 'N'?'disableConcept':'startConcept'
|
|
|
|
|
|
+ let url = item.isDeleted === 'N' ? 'disableConcept' : 'startConcept';
|
|
let waringTxt =
|
|
let waringTxt =
|
|
item.isDeleted === 'N'
|
|
item.isDeleted === 'N'
|
|
? '是否禁用该标准术语?'
|
|
? '是否禁用该标准术语?'
|
|
@@ -332,7 +327,8 @@ export default {
|
|
} else {
|
|
} else {
|
|
if (this.filter.isState !== '' && this.list.length === 1) {
|
|
if (this.filter.isState !== '' && this.list.length === 1) {
|
|
//有启用状态筛选条件且当前页只有最后一条数据删除时,删除成功后跳转到前一页
|
|
//有启用状态筛选条件且当前页只有最后一条数据删除时,删除成功后跳转到前一页
|
|
- this.currentPage = this.currentPage === 1 ? 1 : this.currentPage - 1;
|
|
|
|
|
|
+ this.currentPage =
|
|
|
|
+ this.currentPage === 1 ? 1 : this.currentPage - 1;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
this.warning(res.data.msg || '操作成功', 'success');
|
|
this.warning(res.data.msg || '操作成功', 'success');
|