pengjun 2 years ago
parent
commit
a53e7364ef
  1. 104
      src/views/fee-settings/Asbitem.vue
  2. 9
      src/views/fee-settings/Item.vue

104
src/views/fee-settings/Asbitem.vue

@ -84,7 +84,7 @@
</el-table-column>
</el-table>
<!-- table页 -->
<el-tabs v-model="activeName" size="small">
<el-tabs v-model="activeName">
<el-tab-pane label="项目明细" name="first">
<div>
<span style="margin-top: 10px; padding: 5px; margin-left: 11.7%"
@ -114,6 +114,7 @@
placeholder="请选择"
style="margin-top: 5px"
:filter-method="remoteMethods" default-first-option clearable
ref="quickAsbOCX"
>
<el-option
v-for="item in filetelists"
@ -137,7 +138,7 @@
>
<div>{{ item.displayName }}</div>
</div> -->
<el-table :data="leftdata" :height="window.pageHeight < 668 ? 200:(window.pageHeight - 115 - 358)" @row-dblclick="dbClickChoosedAsb" border @selection-change="handleSelectionChange" @row-click="chooseAsbItem" highlight-current-row>
<el-table :data="leftdata" :height="window.pageHeight < 668 ? 200:(window.pageHeight - 121 - 358)" @row-dblclick="dbClickChoosedAsb" border @selection-change="handleSelectionChange" @row-click="chooseAsbItem" highlight-current-row>
<el-table-column type="index" align="center" label="序号"/>
<el-table-column prop="displayName" label="未选项目" />
</el-table>
@ -187,7 +188,7 @@
>
<div>{{ item.displayName }}</div>
</div> -->
<el-table :data="rightdata" :height="window.pageHeight < 668 ? 200:(window.pageHeight - 115 - 358)" width="100%" @row-dblclick="removeAbs" border
<el-table :data="rightdata" :height="window.pageHeight < 668 ? 200:(window.pageHeight - 121 - 358)" width="100%" @row-dblclick="removeAbs" border
@selection-change="selecteditems" @row-click="removeAsbItem" highlight-current-row>
<el-table-column type="index" align="center" label="序号"/>
<el-table-column label="已选项目" prop="displayName" />
@ -198,7 +199,7 @@
<!-- 指引单信息 -->
<el-tab-pane label="指引信息" name="second">
<div style="display: flex; width: 100%">
<div style="width: 90%">
<div style="width: 95%">
<el-form ref="guidanceinformation" :rules="guidelinesRules" :model="formdata">
<el-table
:data="formdata.guidanceinformationdata"
@ -209,20 +210,21 @@
:height="window.pageHeight < 668 ? 200:(window.pageHeight - 70 - 358)"
ref="guidanceinformationdata"
class="guidelines"
border
>
<el-table-column label="体检中心" width="200">
<template slot-scope="scope">
<el-form-item :prop="'guidanceinformationdata.' + scope.$index + '.organizationUnitId'" :rules="guidelinesRules.organizationUnitId">
<el-select v-model="scope.row.organizationUnitId" size="small">
<el-select v-model="scope.row.organizationUnitId">
<el-option v-for="item in organizationUnitdata" :key="item.id" :label="item.displayName" :value="item.id" />
</el-select>
</el-form-item>
</template>
</el-table-column>
<el-table-column label="性别" width="200">
<el-table-column label="适用性别" width="200">
<template slot-scope="scope">
<el-form-item :prop="'guidanceinformationdata.' + scope.$index + '.forSexId'" :rules="guidelinesRules.forSexId">
<el-select v-model="scope.row.forSexId" size="small">
<el-select v-model="scope.row.forSexId">
<el-option v-for="item in forsexdata" :key="item.id" :label="item.displayName" :value="item.id" />
</el-select>
</el-form-item>
@ -231,7 +233,7 @@
<el-table-column label="指引信息">
<template slot-scope="scope">
<el-form-item :prop="'guidanceinformationdata.' + scope.$index + '.guide'" :rules="guidelinesRules.guide">
<el-input v-model="scope.row.guide" required size="small" />
<el-input v-model="scope.row.guide" required />
</el-form-item>
</template>
</el-table-column>
@ -1120,6 +1122,12 @@ export default {
this.tableData = res.data;
this.initTableData=[...res.data]
});
this.curRow=this.$options.data().curRow
this.leftdata=this.$options.data().leftdata
this.rightdata=this.$options.data().rightdata
this.formdata=this.$options.data().formdata
this.values=this.$options.data().values
this.flitvalues=this.$options.data().flitvalues
},
remoteMethodes(keyWords) {
if (keyWords) {
@ -1248,10 +1256,11 @@ export default {
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
let peisid=window.sessionStorage.getItem("peisid")
this.formdata.guidanceinformationdata.push({
organizationUnitId: "",
organizationUnitId: peisid,
asbitemId:this.curRow.id,
forSexId: "",
forSexId: "A",
guide: "",
});
}
@ -1310,26 +1319,29 @@ export default {
//
selectitem(v) {
if(v){
this.itemid = v.id;
// this.rightdata.forEach((item) => {
// if (v.id === item.id) {
// this.$message.warning("");
// } else {
// this.rightdata.push({ displayName: v.displayName,id:v.id });
// }
// });
if(this.rightdata.length<1){
this.rightdata.push({ displayName: v.displayName,id:v.id });
this.isdislob=false
}else{
for(let i=0;i<this.rightdata.length;i++){
if(v.id===this.rightdata[i].id){
return this.$message.warning("已有该项目");
}
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
this.itemid = v.id;
if(this.rightdata.length<1){
this.rightdata.push({ displayName: v.displayName,id:v.id });
this.isdislob=false
}else{
for(let i=0;i<this.rightdata.length;i++){
if(v.id===this.rightdata[i].id){
return this.$message.warning("已有该项目");
}
}
this.rightdata.push({ displayName: v.displayName,id:v.id });
this.isdislob=false
}
this.$nextTick(() => {
this.$refs['quickAsbOCX'].blur(); //total asbItemId
this.flitvalues = ''
this.filetelists = deepCopy(this.initfiletelists)
this.$refs['quickAsbOCX'].focus(); //total asbItemId
});
}
this.rightdata.push({ displayName: v.displayName,id:v.id });
this.isdislob=false
}
}else{
this.remoteMethods()
}
@ -1390,7 +1402,10 @@ export default {
this.ary1=val
},
addAbs(){
if(this.ary1.length<1){
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
if(this.ary1.length<1){
this.$message.warning('请选择要添加的项目')
}else{
let temporaryLeft=[]
@ -1401,6 +1416,7 @@ export default {
})
this.isdislob = false;
}
}
},
removeAbs(row){
let index = this.rightdata.findIndex((arr) => arr.id == row.id);
@ -1412,7 +1428,10 @@ export default {
this.ary2=val
},
delAbs(){
if(this.ary2.length<1){
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
if(this.ary2.length<1){
this.$message.warning('请选择要移除的项目')
}else{
let temporaryRight=[]
@ -1423,6 +1442,7 @@ export default {
})
this.isdislob = false;
}
}
},
//
rightdelite(item, index) {
@ -1457,7 +1477,10 @@ export default {
},
//q
allclear() {
if (this.rightdata.length > 0) {
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
if (this.rightdata.length > 0) {
this.rightdata.forEach(item=>{
this.leftdata.push(item);
})
@ -1466,10 +1489,14 @@ export default {
}else{
this.$message.warning('没有可移除的项目')
}
}
},
//
addall() {
if (this.leftdata.length > 0) {
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
if (this.leftdata.length > 0) {
this.leftdata.forEach(item=>{
this.rightdata.push(item);
})
@ -1478,6 +1505,7 @@ export default {
}else{
this.$message.warning('没有可添加的项目')
}
}
},
//
shuanji(item, index) {
@ -1522,11 +1550,15 @@ export default {
//
ischangs(v) {
if(v){
getapi(`/api/app/item/in-item-type/${v}`).then((res) => {
let bq=[]
if(this.curRow.id==undefined || this.curRow.id==""){
this.$message.warning("请先选择组合项目")
}else{
getapi(`/api/app/item/in-item-type/${v}`).then((res) => {
let bq=[]
bq = res.data.filter(item => !this.rightdata.some(ele=>ele.id === item.id));
this.leftdata = [...bq];
});
});
}
}else{
this.remoteMethod()
}

9
src/views/fee-settings/Item.vue

@ -2566,4 +2566,13 @@ export default {
background-color: blue!important;
color: #fff;
}
//checkBox
.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
background-color: #409EFF !important;
border-color: #409EFF !important;
}
.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after {
border-color: #fff !important;
}
</style>
Loading…
Cancel
Save