| | |
| | | <el-dialog |
| | | :title="title" |
| | | :visible.sync="open" |
| | | width="1100px" |
| | | width="1500px" |
| | | append-to-body |
| | | :close-on-click-modal="false" |
| | | > |
| | | <el-form |
| | | ref="form" |
| | |
| | | style="width: 150px" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="体检类别" prop="tjCategory"> |
| | | <el-select |
| | | v-model="form.tjCategory" |
| | | placeholder="请选择是否上架" |
| | | style="width: 150px" |
| | | filterable |
| | | clearable |
| | | > |
| | | <el-option |
| | | v-for="dict in dict.type.dict_tjtype" |
| | | :key="dict.value" |
| | | :label="dict.label" |
| | | :value="dict.value" |
| | | ></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <div v-if="!isCollapsed" style="display: flex"> |
| | | <div> |
| | |
| | | </el-table> --> |
| | | |
| | | <el-row :gutter="20"> |
| | | <el-col :span="6"> |
| | | <el-col :span="7"> |
| | | <div |
| | | style="text-align: center; margin-bottom: 10px; margin-top: 10px" |
| | | > |
| | |
| | | :default-checked-keys="checkedkey" |
| | | :filter-node-method="filterNode" |
| | | ref="tree" |
| | | :render-content="renderContent" |
| | | > |
| | | </el-tree> |
| | | </div> |
| | |
| | | @check-change="handleCurrentChecked1" |
| | | :default-checked-keys="checkedListkey" |
| | | ref="trees" |
| | | :render-content="renderContent" |
| | | > |
| | | </el-tree> |
| | | </div> |
| | |
| | | > |
| | | <el-table-column prop="propinName" label="检查项目"> |
| | | </el-table-column> |
| | | <el-table-column prop="proName" label="明细项目" width="260px"> |
| | | </el-table-column> |
| | | <el-table-column prop="proPrice" label="原价" width="56px"> |
| | | </el-table-column> |
| | | <el-table-column prop="proName" label="明细项目" width="260px"> |
| | | </el-table-column> |
| | | |
| | | <!-- <el-table-column |
| | |
| | | </template> |
| | | </el-table-column>--> |
| | | </el-table> |
| | | <h3 style="font-weight: 600">合计:{{ pics }}元</h3> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | import { Message } from "element-ui"; |
| | | export default { |
| | | name: "Package", |
| | | dicts: ["sys_normal_disable", "sys_yes_no"], |
| | | dicts: ["sys_normal_disable", "sys_yes_no", "dict_tjtype"], |
| | | components: { Packages }, |
| | | data() { |
| | | let checkPhoneNum = (rule, value, callback) => { |
| | |
| | | } |
| | | }; |
| | | return { |
| | | pics: 0, |
| | | filterText: "", |
| | | DataList: [], |
| | | list1: true, |
| | |
| | | }, |
| | | filterNode(value, data) { |
| | | if (!value) return true; |
| | | return data.proName.indexOf(value) !== -1; |
| | | // return data.proName.indexOf(value) !== -1; |
| | | if(data.proName.indexOf(value) !== -1){ |
| | | return data.proName.indexOf(value) !== -1; |
| | | }else{ |
| | | return data.proEngName.indexOf(value) !== -1; |
| | | } |
| | | }, |
| | | /** 查询体检套餐列表 */ |
| | | getList() { |
| | |
| | | this.open = true; |
| | | this.title = "体检套餐信息维护"; |
| | | this.DataList = []; |
| | | this.checkedkey=[]; |
| | | this.checkedListkey=[]; |
| | | this.checkedkey = []; |
| | | this.checkedListkey = []; |
| | | this.getDataList(); |
| | | // getAllList().then((response) => { |
| | | // this.allList = response.data; |
| | |
| | | this.form.keywords = this.form.keywords.slice(0, -1); |
| | | this.form.keywords = this.form.keywords.split(","); |
| | | this.DataList = []; |
| | | // this.pics = 0; |
| | | this.checkedkey = []; |
| | | this.checkedListkey = []; |
| | | this.getDataList(); |
| | |
| | | } |
| | | } |
| | | }, |
| | | |
| | | renderContent(h, { node, data, store }) { |
| | | return ( |
| | | <span class="custom-tree-node"> |
| | | <span>{node.label}</span> |
| | | <span>({data.proPrice}元)</span> |
| | | </span> |
| | | ); |
| | | }, |
| | | getDataList() { |
| | | this.loading = true; |
| | | getProParentIdDxList().then((response) => { |
| | |
| | | item.propinPrice = item1.proPrice; |
| | | } |
| | | }); |
| | | this.pics = 0; |
| | | this.DataList.forEach((item) => { |
| | | this.pics += item.proPrice; |
| | | }); |
| | | } |
| | | }); |
| | | }); |
| | |
| | | }); |
| | | }); |
| | | } else { |
| | | console.log(this.checkedkey) |
| | | this.checkedkey.push(this.Treedata[0].proId); |
| | | let proId = this.Treedata[0].proId; |
| | | console.log(proId) |
| | | getProSonDxList(proId).then((res) => { |
| | | this.TreedataList = res.data.list; |
| | | this.TreedataList.forEach((item) => { |
| | |
| | | item.propinName = this.Treedata[0].proName; |
| | | item.propinPrice = this.Treedata[0].proPrice; |
| | | }); |
| | | this.pics = 0; |
| | | this.DataList.forEach((item) => { |
| | | this.pics += item.proPrice; |
| | | }); |
| | | }); |
| | | }); |
| | | } |
| | |
| | | }); |
| | | }, |
| | | handleCurrentChecked(data, checked, checkedNodes) { |
| | | console.log(data, checked) |
| | | this.dataObj = data; |
| | | this.checkedObj = checked; |
| | | if (checked == true) { |
| | |
| | | this.checkedListkey.push(item.proId); |
| | | this.DataList.push(item); |
| | | this.spliceData(); |
| | | this.pics = 0; |
| | | this.DataList.forEach((item1) => { |
| | | this.pics += item1.proPrice; |
| | | if (item1.proParentId == data.proId) { |
| | | item1.propinName = data.proName; |
| | | item1.propinPrice = this.dataObj.proPrice; |
| | |
| | | }); |
| | | }); |
| | | this.TotalPrice1 = 0; |
| | | this.pics = 0; |
| | | if (this.DataList.length != 0) { |
| | | this.list1 = false; |
| | | this.DataList.forEach((item) => { |
| | | this.TotalPrice1 = item.proPrice + this.TotalPrice1; |
| | | this.pics += item.proPrice; |
| | | }); |
| | | } |
| | | }); |
| | |
| | | if (item.proParentId == this.dataObj.proId) { |
| | | this.DataList.splice(index, this.TreedataList.length); |
| | | } |
| | | }); |
| | | this.pics = 0; |
| | | this.DataList.forEach((item, index) => { |
| | | this.pics += item.proPrice; |
| | | }); |
| | | }); |
| | | } |
| | |
| | | if (item.proId == data.proId) { |
| | | this.DataList.splice(index, 1); |
| | | this.TotalPrice1 = 0; |
| | | this.pics = 0; |
| | | this.DataList.forEach((item1) => { |
| | | this.TotalPrice1 = item1.proPrice + this.TotalPrice1; |
| | | this.pics += item1.proPrice; |
| | | // this.TotalPrice1 = item1.proPrice + this.TotalPrice1; |
| | | }); |
| | | } |
| | | }); |
| | | } else if (checked == true) { |
| | | this.DataList.push(data); |
| | | this.pics = 0; |
| | | this.DataList.forEach((item1) => { |
| | | this.pics += item1.proPrice; |
| | | if (item1.proParentId == this.dataObj.proId) { |
| | | item1.propinName = this.dataObj.proName; |
| | | item1.propinPrice = this.dataObj.proPrice; |
| | |
| | | }); |
| | | this.spliceData(); |
| | | this.TotalPrice1 = 0; |
| | | this.pics = 0; |
| | | this.DataList.forEach((item1) => { |
| | | this.TotalPrice1 = item1.proPrice + this.TotalPrice1; |
| | | // this.TotalPrice1 = item1.proPrice + this.TotalPrice1; |
| | | this.pics += item1.proPrice; |
| | | }); |
| | | } |
| | | }, |
| | |
| | | this.treeList = JSON.parse(JSON.stringify(this.DataList)); |
| | | for (var i = 0; i < this.treeList.length; i++) { |
| | | for (var j = i + 1; j < this.treeList.length; j++) { |
| | | if (this.treeList[i].proParentId == this.treeList[j].proParentId) { |
| | | if ( |
| | | this.treeList[i].proParentId == this.treeList[j].proParentId |
| | | ) { |
| | | this.treeList.splice(j, 1); |
| | | j--; |
| | | } |
| | | } |
| | | } |
| | | this.treeList.forEach((item) => { |
| | | this.treeList.forEach((item) => { |
| | | this.form.tjProjectList.push({ |
| | | // id: 0, |
| | | proName: item.propinName, |
| | |
| | | overflow-y: auto; |
| | | border: 1px solid #d9d9d9; |
| | | } |
| | | /* .custom-tree-node { |
| | | flex: 1; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | font-size: 14px; |
| | | padding-right: 8px; |
| | | } */ |
| | | </style> |