From 487730ee293c50201858dad719d2b30bce758ce8 Mon Sep 17 00:00:00 2001 From: qinxianzhangyao <11053546+qinxianzhangyao@user.noreply.gitee.com> Date: 星期四, 26 十月 2023 14:27:24 +0800 Subject: [PATCH] tjqx --- src/views/reservation/reservations/index.vue | 76 +++++++++++++++++++------------------- 1 files changed, 38 insertions(+), 38 deletions(-) diff --git a/src/views/reservation/reservations/index.vue b/src/views/reservation/reservations/index.vue index a4eebcb..9518226 100644 --- a/src/views/reservation/reservations/index.vue +++ b/src/views/reservation/reservations/index.vue @@ -67,7 +67,11 @@ <span>{{ parseTime(scope.row.reservationTime, "{y}-{m}-{d}") }}</span> </template> </el-table-column> - <el-table-column label="浣撴绫诲瀷" align="center" prop="tjType" width="80px" :show-overflow-tooltip="true" /> + <el-table-column label="浣撴绫诲瀷" align="center" prop="tjType" width="80px" :show-overflow-tooltip="true" > + <template slot-scope="scope"> + <dict-tag :options="dict.type.dict_team" :value="scope.row.tjType" /> + </template> + </el-table-column> <el-table-column label="濠氬Щ" align="center" prop="marriage" width="60px" :show-overflow-tooltip="true"> <template slot-scope="scope"> <dict-tag :options="dict.type.dict_user_marry" :value="scope.row.marriage" /> @@ -241,9 +245,12 @@ <el-tab-pane label="鍗曢」"> <div class="tab3"> <div class="tab2"> - <el-tree :data="data" show-checkbox node-key="proId" :props="defaultProps" - @check-change="handleCurrentChecked"> - </el-tree> + <v-tree-transfer :treeData="treedataList" + :defaultProps="{ children: 'tjProjectList', label: 'proName' }" :defaultKeys="defaultKeys" + @changeKeys="changeCategoryKeys" :key="datekey"></v-tree-transfer> + <!-- <el-tree :data="data" show-checkbox node-key="proId" :props="defaultProps" + @check-change="handleCurrentChecked"> + </el-tree>--> </div> </div> </el-tab-pane> @@ -515,7 +522,7 @@ <el-form-item label="鍗″彿" prop="indexCard"> <el-input v-model="formIn.indexCard" placeholder="璇疯緭鍏ュ崱鍙�" style="width: 190px" /> </el-form-item> - <el-button type="primary" @click="taocan = true" size="mini">閫夋嫨濂楅</el-button> + <el-button type="primary" @click="Package" size="mini">閫夋嫨濂楅</el-button> </el-form> </div> @@ -731,7 +738,11 @@ import { deptTreeSelect, projectGetList, getPackageListName, getaddtTransition, getTransitionList, } from "@/api/system/tijian"; import { getCompany, queryCompany } from "@/api/team/tuanti"; import user from "@/store/modules/user"; +import VTreeTransfer from '../../system/tijian/TreeTransfer.vue' export default { + components: { + VTreeTransfer + }, name: "Reservation", dicts: ["dict_user_national", "dict_user_national", "dict_user_marry", "sys_yes_no", "sys_user_sex", "dict_team", "tj_time_region", "dict_tjtype", "dict_job", @@ -750,6 +761,7 @@ }, }, taocan: false, + defaultKeys: [], value1: "", pacName: "", hides: false, @@ -769,6 +781,8 @@ thisCancas: null, thisContext: null, thisVideo: null, + datekey: Date.now(), + treedataList: [], list: [], activeName: "1", // 閬僵灞� @@ -972,30 +986,6 @@ // response.rows.forEach((item, index) => // {item.newID =(this.queryParams.pageNum - 1) * this.queryParams.pageSize +index +1; // }); - this.reservationList.forEach((item) => { - if (item.tjType === "2") { - item.tjType = "涓汉"; - } else { - item.tjType = "鍥㈤槦"; - } - if (item.tjCategory === "01") { - item.tjCategory = "鍋ュ悍浣撴"; - } else if (item.tjCategory === "02") { - item.tjCategory = "鑱屼笟鐥呬綋妫�"; - } else if (item.tjCategory === "03") { - item.tjCategory = "鍏崼浣撴"; - } else if (item.tjCategory === "04") { - item.tjCategory = "鍏ヨ亴浣撴"; - } else if (item.tjCategory === "05") { - item.tjCategory = "鍏姟鍛樹綋妫�"; - } else if (item.tjCategory === "06") { - item.tjCategory = "鍖讳繚浣撴"; - } else if (item.tjCategory === "07") { - item.tjCategory = "濠氭"; - } else if (item.tjCategory === "09") { - item.tjCategory = "鍑哄叆澧冧綋妫�"; - } - }); this.total = response.total; this.loading = false; }); @@ -1070,8 +1060,8 @@ }, // 澶氶�夋閫変腑鏁版嵁 handleSelectionChange(selection) { - selection.forEach(item =>{ - this.fmobj = item + selection.forEach(item => { + this.fmobj = item }) console.log(this.fmobj) this.ids = selection.map((item) => item.id); @@ -1090,6 +1080,7 @@ handleUpdate(row) { this.title = "淇敼浣撴棰勭害"; this.formIn = row; + this.form.tjType= this.formIn.tjType if (this.formIn.timeRegion === 0) { this.formIn.timeRegion = "8:00-9:00"; } @@ -1173,13 +1164,17 @@ /** 鏌ヨ閮ㄩ棬涓嬫媺鏍戠粨鏋� */ projectGetList().then((response) => { - this.data = response.data; - this.dXData = response.data; + this.treedataList = response.data.list; + this.dXData = response.data.list; return; }); } else { this.$message.warning("宸茶繃鏈熻閲嶆柊棰勭害"); } + }, + changeCategoryKeys(val) { + this.proIds = []; + this.proIds = val }, /** 淇敼璇︾粏鎸夐挳鎿嶄綔 */ handleUpdate1(row) { @@ -1272,8 +1267,8 @@ /** 鏌ヨ閮ㄩ棬涓嬫媺鏍戠粨鏋� */ projectGetList().then((response) => { - this.data = response.data; - this.dXData = response.data; + this.treedataList = response.data.list; + this.dXData = response.data.list; return; }); }, @@ -1282,6 +1277,11 @@ numberChange(currentValue, oldValue) { this.discount = currentValue; this.TotalPrice = (this.TotalPrice1 * (this.discount / 10)).toFixed(2); + }, + + Package() { + this.taocan = true; + this.datekey = Date.now() }, /** 鎼滅储鎿嶄綔 */ @@ -1312,9 +1312,9 @@ this.multiple = !selection.length; if (selection[0]) { this.DataList = []; - this.data = JSON.parse(JSON.stringify(this.dXData)); + this.treedataList = JSON.parse(JSON.stringify(this.dXData)); selection[0].tjProjectList.forEach((selectionitem) => { - this.data.forEach((item) => { + this.treedataList.forEach((item) => { if (selectionitem.proName == item.proName) { item.disabled = true; item.tjProjectList = []; @@ -1338,7 +1338,7 @@ }); }); } else { - this.data = JSON.parse(JSON.stringify(this.dXData)); + this.treedataList = JSON.parse(JSON.stringify(this.dXData)); return; } }, -- Gitblit v1.8.0