From 8319f67b9bec1d19c06eaa4216f0f34c67e3afb1 Mon Sep 17 00:00:00 2001 From: feige <feige@qq.com> Date: 星期日, 10 九月 2023 10:08:25 +0800 Subject: [PATCH] Merge branch 'master' of http://47.93.189.255:8099/r/zhangshi_app_web --- ruoyi-ui/src/views/self/memo.vue | 5 ruoyi-ui/src/views/travel/Info.vue | 270 ++++++ ruoyi-ui/src/views/collection/collectionInfo.vue | 12 ruoyi-ui/src/views/travel/index.vue | 797 +++++++++++++++++---- ruoyi-ui/src/views/self/memoInfo.vue | 5 ruoyi-ui/src/views/contacts/index.vue | 19 ruoyi-ui/src/views/index.vue | 15 ruoyi-ui/src/views/bignote/familyeventInfo.vue | 4 ruoyi-ui/src/views/clean/cleanInfo.vue | 3 ruoyi-ui/src/views/contacts/contactsInfo.vue | 5 ruoyi-ui/src/views/economy/index.vue | 4 ruoyi-ui/src/views/wish/index.vue | 5 ruoyi-ui/src/views/doctor/index.vue | 4 ruoyi-ui/src/views/honor/index.vue | 10 ruoyi-ui/src/views/mindMap/index.vue | 178 +--- ruoyi-ui/src/views/self/show.vue | 294 ++++--- ruoyi-ui/src/api/travel/index.js | 77 + ruoyi-ui/src/api/self/index.js | 9 ruoyi-ui/src/views/honor/honorInfo.vue | 10 ruoyi-ui/src/api/clean/index.js | 2 ruoyi-ui/src/router/index.js | 2 ruoyi-ui/src/assets/images/shouye.png | 0 ruoyi-ui/src/views/travel/travelInfo.vue | 179 ++-- ruoyi-ui/src/views/economy/economyInfo.vue | 3 ruoyi-ui/src/views/marry/index.vue | 168 ++- ruoyi-ui/src/views/components/superMindmap.vue | 14 ruoyi-ui/src/views/bignote/index.vue | 4 ruoyi-ui/src/views/collection/index.vue | 7 ruoyi-ui/src/views/wish/wishInfo.vue | 5 ruoyi-ui/src/views/device/equipmentInfo.vue | 3 ruoyi-ui/src/views/note/propertyInfo.vue | 3 ruoyi-ui/src/views/device/index.vue | 4 ruoyi-ui/src/views/clean/index.vue | 5 ruoyi-ui/src/views/note/index.vue | 19 34 files changed, 1,464 insertions(+), 680 deletions(-) diff --git a/ruoyi-ui/src/api/clean/index.js b/ruoyi-ui/src/api/clean/index.js index faa4bf8..2743567 100644 --- a/ruoyi-ui/src/api/clean/index.js +++ b/ruoyi-ui/src/api/clean/index.js @@ -28,7 +28,7 @@ // 鍒犻櫎璧勪骇淇℃伅 export function delClean(Ids) { return request({ - url: '/zfClean' + Ids, + url: '/zfClean/' + Ids, method: 'delete' }) } diff --git a/ruoyi-ui/src/api/self/index.js b/ruoyi-ui/src/api/self/index.js index fab5092..acb9597 100644 --- a/ruoyi-ui/src/api/self/index.js +++ b/ruoyi-ui/src/api/self/index.js @@ -140,7 +140,14 @@ method: 'delete', }) } - +//璇佷欢绫诲瀷鏁版嵁 +export function listType(query) { + return request({ + url: '/zCertificate/type', + method: 'get', + params: query + }) +} // 鏌ヨ鍑哄浗鎯呭喌 export function getAbroadList() { return request({ diff --git a/ruoyi-ui/src/api/travel/index.js b/ruoyi-ui/src/api/travel/index.js index c9b1d5a..0df8f4b 100644 --- a/ruoyi-ui/src/api/travel/index.js +++ b/ruoyi-ui/src/api/travel/index.js @@ -12,7 +12,7 @@ } -// 鏍规嵁id鏌ヨ鎵�鏈夋敹鏀彴璐︿俊鎭� +// 鏍规嵁id鏌ヨ export function getTravelPriceInfo(id) { return request({ url: '/zTravelPrice/' + id, @@ -75,37 +75,44 @@ // }) // } export function listTravelBase(query) { - return request({ - url: '/zTravelBase/all', - method: 'get', - params: query - }) - } - - - // 鏍规嵁id鏌ヨ鎵�鏈夋敹鏀彴璐︿俊鎭� - export function getTravelBaseInfo(id) { - return request({ - url: '/zTravelBase/' + id, - method: 'get', - - }) - } - - //鏂板鏀舵敮鍙拌处 - export function addTravelBase(data) - { - return request({ - url: '/zTravelBase', - method: 'post', - data: data - }) - } - - // 鍒犻櫎瀹跺涵璁惧 - export function delTravelBase(Ids) { - return request({ - url: '/zTravelBase/' + Ids, - method: 'delete' - }) - } \ No newline at end of file + return request({ + url: '/zTravelBase/all', + method: 'get', + params: query + }) +} + + +// 鏍规嵁id鏌ヨ鎵�鏈夋敹鏀彴璐︿俊鎭� +export function getTravelBaseInfo(id) { + return request({ + url: '/zTravelBase/' + id, + method: 'get', + + }) +} + +//鏂板鏀舵敮鍙拌处 +export function addTravelBase(data) +{ + return request({ + url: '/zTravelBase', + method: 'post', + data: data + }) +} +//淇敼瀹跺涵璁惧 +export function updateTravelBase(data) { + return request({ + url: '/zTravelBase', + method: 'put', + data: data + }) +} +// 鍒犻櫎瀹跺涵璁惧 +export function delTravelBase(Ids) { + return request({ + url: '/zTravelBase/' + Ids, + method: 'delete' + }) +} diff --git a/ruoyi-ui/src/assets/images/shouye.png b/ruoyi-ui/src/assets/images/shouye.png index 9d6baad..a3dca1c 100644 --- a/ruoyi-ui/src/assets/images/shouye.png +++ b/ruoyi-ui/src/assets/images/shouye.png Binary files differ diff --git a/ruoyi-ui/src/router/index.js b/ruoyi-ui/src/router/index.js index f453471..b4a48e2 100644 --- a/ruoyi-ui/src/router/index.js +++ b/ruoyi-ui/src/router/index.js @@ -439,7 +439,7 @@ hidden: true, children: [ { - path: 'edit/:id(\\d+)', + path: 'edit/:id', component: () => import('@/views/travel/edit'), name: 'edit', meta: { title: '缂栬緫',activeMenu: '/geren/Ztravel'} diff --git a/ruoyi-ui/src/views/bignote/familyeventInfo.vue b/ruoyi-ui/src/views/bignote/familyeventInfo.vue index bc4e875..0c086cb 100644 --- a/ruoyi-ui/src/views/bignote/familyeventInfo.vue +++ b/ruoyi-ui/src/views/bignote/familyeventInfo.vue @@ -28,6 +28,10 @@ <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> + <h4 class="form-header">鐩稿叧鍥剧墖 </h4> <el-upload action="#" diff --git a/ruoyi-ui/src/views/bignote/index.vue b/ruoyi-ui/src/views/bignote/index.vue index 42ae195..22a487f 100644 --- a/ruoyi-ui/src/views/bignote/index.vue +++ b/ruoyi-ui/src/views/bignote/index.vue @@ -154,7 +154,9 @@ <el-table-column label="浜虹墿" prop="people" sortable width="150px" /> <el-table-column label="鍦扮偣" prop="address" sortable width="150px" /> <el-table-column label="澶т簨鏍囬" prop="title" sortable :show-overflow-tooltip="true" width="150px" /> - + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <el-table-column label="澶囨敞" prop="remark" sortable width="150px" > <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '鈥斺�斺�斺��'}}</template> </el-table-column> diff --git a/ruoyi-ui/src/views/clean/cleanInfo.vue b/ruoyi-ui/src/views/clean/cleanInfo.vue index 29f76ea..105f0c1 100644 --- a/ruoyi-ui/src/views/clean/cleanInfo.vue +++ b/ruoyi-ui/src/views/clean/cleanInfo.vue @@ -39,6 +39,9 @@ <el-form-item label="澶囨敞" prop="remark"> <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> <h4 class="form-header">鐩稿叧鍥剧墖 </h4> diff --git a/ruoyi-ui/src/views/clean/index.vue b/ruoyi-ui/src/views/clean/index.vue index 3394499..ccaf984 100644 --- a/ruoyi-ui/src/views/clean/index.vue +++ b/ruoyi-ui/src/views/clean/index.vue @@ -132,6 +132,9 @@ <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '鈥斺�斺�斺��'}}</template> </el-table-column> <el-table-column label="澶囨敞" prop="remark" sortable width="100" /> + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <el-table-column label="鐢靛瓙鏂囦欢" prop="url" width="180" align="center"> <template slot-scope="scope" > @@ -647,7 +650,7 @@ /** 鍒犻櫎鎸夐挳鎿嶄綔 */ handleDelete(row) { const Ids = row.id || this.ids; - this.$modal.confirm('鏄惁纭鍒犻櫎璧勪骇缂栧彿涓�"' + Ids + '"鐨勬暟鎹」锛�').then(function() { + this.$modal.confirm('鏄惁纭鍒犻櫎鎵�閫夋暟鎹」锛�').then(function() { return delClean(Ids); }).then(() => { this.getList(); diff --git a/ruoyi-ui/src/views/collection/collectionInfo.vue b/ruoyi-ui/src/views/collection/collectionInfo.vue index 4e4439f..6145d2e 100644 --- a/ruoyi-ui/src/views/collection/collectionInfo.vue +++ b/ruoyi-ui/src/views/collection/collectionInfo.vue @@ -17,9 +17,9 @@ <el-row :span="12"> <el-cow > <el-form-item label="鑾峰緱鏃堕棿" prop="happenTime" label-width="70px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> - <el-input v-model="formData.happenTime" placeholder="璇疯緭鍏ヨ幏寰楁椂闂�" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> - + <el-date-picker v-model="formData.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> </el-cow> @@ -67,6 +67,12 @@ <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> </el-cow> + <el-cow > + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> + </el-cow> + </el-row> </el-container> <h4 class="form-header">鐩稿叧鍥剧墖 </h4> diff --git a/ruoyi-ui/src/views/collection/index.vue b/ruoyi-ui/src/views/collection/index.vue index 77dff43..0afe162 100644 --- a/ruoyi-ui/src/views/collection/index.vue +++ b/ruoyi-ui/src/views/collection/index.vue @@ -209,6 +209,9 @@ <el-table-column label="澶囨敞" prop="remark" sortable width="90" align="center"> <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '鈥斺�斺�斺��'}}</template> </el-table-column> + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <el-table-column label="鐢靛瓙鏂囦欢" prop="url" width="180" align="center"> <template slot-scope="scope" > @@ -281,7 +284,9 @@ <!-- <el-input v-model="formDat.happenTime" placeholder="璇疯緭鍏ヨ幏寰楁椂闂�" clearable :style="{width: '100%'}" ></el-input>--> <!-- </el-form-item>--> <el-form-item label="鑾峰緱鏃堕棿" prop="happenTime"> - <el-input v-model='formDat.happenTime' type='date' clearable placeholder='閫夋嫨鏃ユ湡'></el-input> + <el-date-picker v-model="formDat.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <el-form-item label="绫诲埆" prop="type"> <el-select v-model="formDat.type" placeholder="璇烽�夋嫨绫诲埆" clearable :style="{width: '100%'}" > diff --git a/ruoyi-ui/src/views/components/superMindmap.vue b/ruoyi-ui/src/views/components/superMindmap.vue index 8c30a33..6ce4c1b 100644 --- a/ruoyi-ui/src/views/components/superMindmap.vue +++ b/ruoyi-ui/src/views/components/superMindmap.vue @@ -3,7 +3,7 @@ </template> <script> import * as d3 from 'd3'; - + export default { props: { data: Object, @@ -281,7 +281,7 @@ }, }, } - + // 鑾峰彇鏍戠殑娣卞害 function getDepth(json) { var arr = []; @@ -306,7 +306,7 @@ } return depth; } - + // 鎻愬彇鏍戠殑瀛愯妭鐐癸紝鏈�缁堟墍鏈夋爲鐨勫瓙鑺傜偣閮戒細瀛樺叆浼犲叆鐨刲eafList鏁扮粍涓� function getTreeLeaf(treeData, leafList) { // 鍒ゆ柇鏄惁涓烘暟缁� @@ -326,13 +326,13 @@ } } } - + // 鑾峰彇鍖呭惈姹夊瓧鐨勫瓧绗︿覆鐨勯暱搴� function getStringSizeLength(string) { //鍏堟妸涓枃鏇挎崲鎴愪袱涓瓧鑺傜殑鑻辨枃锛屽啀璁$畻闀垮害 return string.replace(/[\u0391-\uFFE5]/g, "aa").length; } - + // 鐢熸垚闅忔満鐨勫瓧绗︿覆 function randomString(strLength) { strLength = strLength || 32; @@ -343,7 +343,7 @@ } return n } - + // 鑾峰彇瀛楃涓茬殑鍍忕礌瀹藉害 function getPXwidth(str, fontSize = "12px", fontFamily = "Microsoft YaHei") { var span = document.createElement("span"); @@ -365,4 +365,4 @@ // result.height = parseFloat(window.getComputedStyle(span).height) - result.height; return result.width; } -</script> \ No newline at end of file +</script> diff --git a/ruoyi-ui/src/views/contacts/contactsInfo.vue b/ruoyi-ui/src/views/contacts/contactsInfo.vue index a41d5cc..9263e66 100644 --- a/ruoyi-ui/src/views/contacts/contactsInfo.vue +++ b/ruoyi-ui/src/views/contacts/contactsInfo.vue @@ -67,6 +67,11 @@ <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> </el-cow> + <el-cow > + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> + </el-cow> </el-row> </el-container> <h4 class="form-header">鐢靛瓙鍚嶇墖 </h4> diff --git a/ruoyi-ui/src/views/contacts/index.vue b/ruoyi-ui/src/views/contacts/index.vue index 4675828..175ea01 100644 --- a/ruoyi-ui/src/views/contacts/index.vue +++ b/ruoyi-ui/src/views/contacts/index.vue @@ -177,6 +177,10 @@ <span v-if="scope.row.isAlways== null">鈥斺��</span> </template> </el-table-column> + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> + <el-table-column label="澶囨敞锛堟槸鍚﹀瓨鍦ㄩ噾閽卞叧绯伙級" prop="remark" sortable width="120" align="center"> <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '鈥斺�斺�斺��'}}</template> @@ -279,8 +283,10 @@ </el-input> </el-form-item> <el-form-item label="鏄惁甯歌仈绯�" prop="isAlways"> - <el-input v-model="formDat.isAlways" placeholder="鏄惁甯歌仈绯�" clearable :style="{width: '100%'}" > - </el-input> + <el-select v-model="formDat.isAlways" placeholder="璇烽�夋嫨鏄惁甯歌仈绯�" clearable :style="{width: '100%'}" > + <el-option v-for="(item, index) in typeOptions" :key="index" :label="item.label" :value="item.value" + ></el-option> + </el-select> </el-form-item> <el-form-item label="澶囨敞锛堟槸鍚﹀瓨鍦ㄩ噾閽卞叧绯伙級" prop="remark"> @@ -524,7 +530,14 @@ trigger: 'blur' }], }, - typeOptions: [], + typeOptions: [{ + value: '1', + label: '鏄�', + }, + { + value: '0', + label: '鍚�', + }], }; }, created() { diff --git a/ruoyi-ui/src/views/device/equipmentInfo.vue b/ruoyi-ui/src/views/device/equipmentInfo.vue index 44850ff..be92caf 100644 --- a/ruoyi-ui/src/views/device/equipmentInfo.vue +++ b/ruoyi-ui/src/views/device/equipmentInfo.vue @@ -51,6 +51,9 @@ <el-form-item label="澶囨敞" prop="remark"> <el-input v-model="formData.remark" placeholder="" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> <h4 class="form-header">鐩稿叧鍥剧墖 </h4> diff --git a/ruoyi-ui/src/views/device/index.vue b/ruoyi-ui/src/views/device/index.vue index f820765..e268174 100644 --- a/ruoyi-ui/src/views/device/index.vue +++ b/ruoyi-ui/src/views/device/index.vue @@ -144,7 +144,9 @@ <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '鈥斺�斺�斺��'}}</template> </el-table-column> - + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <el-table-column label="鐢靛瓙鏂囦欢" prop="url" width="120" align="center"> <template slot-scope="scope" > diff --git a/ruoyi-ui/src/views/doctor/index.vue b/ruoyi-ui/src/views/doctor/index.vue index 1647b81..a1c52bc 100644 --- a/ruoyi-ui/src/views/doctor/index.vue +++ b/ruoyi-ui/src/views/doctor/index.vue @@ -199,7 +199,9 @@ <el-table-column label="閫傜敤浜�" prop="suitable" sortable width="140" align="center" > <template slot-scope="scope">{{scope.row.suitable? scope.row.suitable: '鈥斺�斺�斺��'}}</template> </el-table-column> - + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <el-table-column label="澶囨敞" prop="remark" sortable width="120" align="center"> <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '鈥斺�斺�斺��'}}</template> </el-table-column> diff --git a/ruoyi-ui/src/views/economy/economyInfo.vue b/ruoyi-ui/src/views/economy/economyInfo.vue index 5aeebc4..9a75b2d 100644 --- a/ruoyi-ui/src/views/economy/economyInfo.vue +++ b/ruoyi-ui/src/views/economy/economyInfo.vue @@ -36,6 +36,9 @@ <el-form-item label="澶囨敞" prop="remark"> <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> <h4 class="form-header">鐩稿叧鍥剧墖 </h4> diff --git a/ruoyi-ui/src/views/economy/index.vue b/ruoyi-ui/src/views/economy/index.vue index 21d63ec..d1fed0e 100644 --- a/ruoyi-ui/src/views/economy/index.vue +++ b/ruoyi-ui/src/views/economy/index.vue @@ -117,7 +117,9 @@ <el-table-column label="鐜伴噾/鑷姩鎵e垝" prop="kind" sortable width="130" > <template slot-scope="scope">{{scope.row.kind? scope.row.kind: '鈥斺�斺�斺��'}}</template> </el-table-column> - + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <el-table-column label="鐢靛瓙鏂囦欢" prop="url" align="center" sortable width="110" > <template slot-scope="scope" > <div @click="handleCheck(scope.row)"> diff --git a/ruoyi-ui/src/views/honor/honorInfo.vue b/ruoyi-ui/src/views/honor/honorInfo.vue index d985170..7f88aea 100644 --- a/ruoyi-ui/src/views/honor/honorInfo.vue +++ b/ruoyi-ui/src/views/honor/honorInfo.vue @@ -60,14 +60,16 @@ <el-row> <el-cow :span="8"> <el-form-item label="鏈夋晥鏃堕棿" prop="validityDate" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> - <el-input v-model="formData.validityDate" type="date" placeholder="璇疯緭鍏ユ湁鏁堟椂闂�" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="formData.validityDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> </el-cow> <el-cow :span="8"> <el-form-item label="鑾峰緱鏃堕棿" prop="getDate" label-width="68px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> - <el-input v-model="formData.getDate" type="date" placeholder="璇疯緭鍏ヨ幏寰楁椂闂�" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="formData.getDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> </el-cow> <el-cow :span="8"> diff --git a/ruoyi-ui/src/views/honor/index.vue b/ruoyi-ui/src/views/honor/index.vue index 248acb8..f5d1839 100644 --- a/ruoyi-ui/src/views/honor/index.vue +++ b/ruoyi-ui/src/views/honor/index.vue @@ -237,13 +237,15 @@ </el-input> </el-form-item> <el-form-item label="鏈夋晥鏃堕棿" prop="validityDate"> - <el-input v-model="formDat.validityDate" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" > - </el-input> + <el-date-picker v-model="formDat.validityDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <el-form-item label="鑾峰緱鏃堕棿" prop="getDate"> - <el-input v-model="formDat.getDate" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" > - </el-input> + <el-date-picker v-model="formDat.getDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <el-form-item label="瀛樻斁浣嶇疆" prop="location"> <el-input v-model="formDat.location" placeholder="璇疯緭鍏ュ瓨鏀句綅缃�" clearable :style="{width: '100%'}" > diff --git a/ruoyi-ui/src/views/index.vue b/ruoyi-ui/src/views/index.vue index 5328088..965fe11 100644 --- a/ruoyi-ui/src/views/index.vue +++ b/ruoyi-ui/src/views/index.vue @@ -2,21 +2,6 @@ <div class="app-container"> <div class="image-container"> <img class="bottom-image" src="../assets/images/shouye.png" alt="Bottom Image"> - <el-input - class="text-box1" - type="textarea" :rows="6" resize="none" - placeholder=" 鍙傚ぉ澶ф爲蹇呮湁鍏舵牴锛屼竾閲屾睙娌充害鏈夊叾婧愩�� - 鏅ぉ涔嬩笅鐐庨粍瀛愬瓩锛岃剦鑴夌浉浼狅紝涓嶄箯鏈夎瘑涔嬪+锛屾爧姊佷箣鎵嶃�傚惥绛変笉鍙繕鍏跺厛浜猴紝浜︿笉鍙笉鐭ユ垜涔嬫湰婧愩�� - 寤鸿氨涔嬪ぇ浜嬶紝涓婂彲鍛婃叞绁栧厛鍦ㄥぉ涔嬬伒锛屼笅鍙娇瀛愬瓩鍚庝唬鏈夊鏍逛箣鏈�傚彾鑴変箣浜庤崏鏈ㄣ�佸瓙瀛欎箣浜庡墠鏍癸紝琛�绠′箣浜庝汉浣擄紝渚濇墭鎶�鏈緭閫佷簨浠讹紝渚涚粰缁忛獙锛岃氨鍐欐牴鏍圭浉浼犱竴璺蛋鏉ョ殑闈炲嚒銆�" - ></el-input> - <el-input - class="text-box2" - type="textarea" :rows="18" resize="none" - placeholder=" 瀹讹紝鏄垜浠敓鍛界殑椹跨珯銆佹紓娉婄殑褰掓墍銆� - 浼楁墍鍛ㄧ煡锛岃嚜浠庢湁浜嗚禆浠ョ敓瀛樼殑灏忓搴紝瀹跺涵鎴愬憳灏辨湁浜嗘垚闀跨殑杞ㄨ抗銆佸涔犵殑杞ㄨ抗銆佸伐浣滅殑杞ㄨ抗銆佺敓娲荤殑杞ㄨ抗銆傚搴腑姣忎竴浜烘瘡涓�鐗╅兘璋卞啓鐫�瀹跺涵鐨勮緣鐓岃建杩广�傝鎴戜滑鐢� 鈥滄湰閮介兘鈥� 鏉ユ敹钘忔瘡涓鏃忋�佹瘡涓搴�佹瘡涓汉鐢滆湝鏄ㄥぉ锛岃褰曞垢绂忎粖澶╋紝鎷ユ姳缇庡ソ鏄庡ぉ銆傝鎴戜滑鐪熸鎰熷彈鐢熷懡璇炵敓鐨勬澹扮瑧璇紝浜虹敓濂嬫枟鐨勯吀鐢滆嫤杈o紝鑶濅笅寮勫効鐨勫垢绂忔俯棣ㄣ�� - 娲诲湪褰撲笅锛屾灞ュ寙鍖嗐�傚綋鎮ㄥ湪澶栧湴婕傛硦鑰屾�ラ渶鏌愪簺蹇呴』鐨勮瘉鏄庢潗鏂欐椂锛涘綋鎮ㄥ湪浣跨敤鏌愪欢鐗╁搧闇�瑕佸府鍔╂椂锛涘綋鎮ㄨ韩蹇冪柌鍊︽椂锛涘綋鎮ㄦ�ヤ簬涓鸿嚜宸辨暣鐞嗗仴搴锋棩璁版椂锛涘綋鎮ㄥ湪鏌愪釜鐬棿鍙堝洖蹇嗚捣浜蹭汉鐨勭瑧璨屾椂.......鎮ㄤ笉濡ㄦ墦寮�韬竟鐨� 鈥滄湰閮介兘鈥� 锛岀粏缁嗗湴鍝佸懗鈥滄湰閮介兘鈥濊褰曠殑姣忎竴杞ㄨ抗绛旀锛氬師鏉ュ彲浠ュ湪 鈥滄湰閮介兘鈥� 鏀惰幏鏉愭枡璇佹槑锛涙挱鏀剧殑閭e凡缁忔硾榛勭殑鐓х墖銆佽瘉涔︼紝鍞よ捣浜嗗線鏃ユ棫鏃剁浉鐭ャ�佸浠婂凡婕傛硦澶╂动鐨勬寶鍙嬶紱涓�鏈偖绁ㄣ�佷竴娌撴爣鏈紝璁板綍鐨勬槸鎮ㄩ偅鍒牱鐨勭瓒o紱鎵嬫嬁鐫�瀛╁瓙鐨勫嚭鐢熻瘉鏄庯紝鏇存槸绂佷笉浣忔唱姘存墦婀跨溂鐪讹紝濡備粖浜嬩笟鏈夋垚鐨勫瓙濂充滑浼间箮鍙堝彉鍥為偅涓ぉ鐪熺儌婕殑瀛╁瓙锛涙偍鐨勬埧浜ц瘉銆佸湡鍦拌瘉銆佺粨濠氳瘉銆佸仴搴锋姤鍛娿�佺櫨骞村績鎰�...锛屾垨璁稿湪灏嗘潵鏌愪釜鏃堕棿鈥滄湰閮介兘鈥濊兘鎴愪负鎮ㄧ淮鎶ゆ潈鐩婄殑淇濋殰锛屾姂鎴栨槸鐣欑粰瀛愬コ鐨勪竴浠借储瀵屻�� - 甯屾湜 鈥滄湰閮介兘鈥� 鑳芥垚涓哄姪鎺ㄦ偍浜嬩笟鎴愬姛銆佸搴垢绂忋�佷汉鐢熺編婊$殑濂藉府鎵嬶紒" - ></el-input> </div> </div> diff --git a/ruoyi-ui/src/views/marry/index.vue b/ruoyi-ui/src/views/marry/index.vue index 972d91d..d7e8608 100644 --- a/ruoyi-ui/src/views/marry/index.vue +++ b/ruoyi-ui/src/views/marry/index.vue @@ -7,50 +7,44 @@ ></el-button> </el-backtop> <h2 style="font-size:30px;padding-top:0px">濠氬Щ鐘跺喌鐧昏琛�</h2> - <el-row :gutter="10" class="mb8"> - <el-col :span="1.5"> - <el-button - type="warning" - plain - icon="el-icon-download" - size="mini" - @click="handleExport" - v-hasPermi="['family:note:export']" - >瀵煎嚭</el-button> - </el-col> - <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> - </el-row> <el-divider /> <!-- 鍩烘湰淇℃伅--> <h2 style="font-size:21px">鍩烘湰鎯呭喌</h2> <el-container> - <div style="padding-left:0px" > + <div style="padding-left:0px;width: 28%;" > <el-container > <el-col > <el-form ref="elForm" :model="marryList" :rules="rules" size="medium" label-position="left" v-loading="loading" :data="marryList" @selection-change="handleSelectionChange" > <el-row :span="16"> - <el-form-item label="濮撳悕" prop="name" label-width="40px"> + <el-form-item label="濮撳悕" prop="name" label-width="50px"> <el-input v-model="marryList.name " placeholder="" clearable :style="{width: '100%'}" :disabled="dsb"> </el-input> </el-form-item> </el-row> <el-row :span="16"> - <el-form-item label="鍑虹敓鏃ユ湡" prop="birthday" label-width="70px"> - <el-input v-model="marryList.birthday" placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-form-item label="鍑虹敓鏃ユ湡" prop="birthday" label-width="75px"> + <!-- <el-input v-model="marryList.birthday" placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> --> + <el-date-picker v-model="marryList.birthday" + type="date" + placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" + :clearable="false" + :style="{width: '100%'}" + :disabled="dsb" value-format="yyyy-MM-dd"></el-date-picker> </el-form-item> </el-row> <el-row :span="16"> - <el-form-item label="韬唤璇佸彿鐮�" prop="id" label-width="85px"> + <el-form-item label="韬唤璇佸彿鐮�" prop="id" label-width="95px"> <el-input v-model="marryList.id" placeholder="" clearable :style="{width: '100%'}" :disabled="dsb"> </el-input> </el-form-item> </el-row> <el-row :span="16"> - <el-form-item label="濠氬Щ鐘跺喌" prop="marryStatus" label-width="70px"> + <el-form-item label="濠氬Щ鐘跺喌" prop="marryStatus" label-width="80px" > <template v-if="!isEditing"> <el-input v-if="marryList.marryStatus===0" placeholder="鏈" style="" :disabled="dsb"></el-input> <el-input v-if="marryList.marryStatus===1" placeholder="鍒濆" :disabled="dsb"></el-input> @@ -59,7 +53,7 @@ </template> <template v-else> - <el-select v-model="mrs" placeholder="璇烽�夋嫨濠氬Щ鐘舵��" clearable :style="{width: '100%'}"> + <el-select v-model="mrs" placeholder="璇烽�夋嫨濠氬Щ鐘舵��" clearable :style="{width: '100%'}" @change="handleMarryStatusChange"> <el-option label="鏈" value='0'></el-option> <el-option label="鍒濆" value='1'></el-option> <el-option label="绂诲" value='2'></el-option> @@ -82,7 +76,7 @@ </el-col> </el-container> </div> - <div style="padding-left:200px"> + <div style="width: 35%;padding-left: 100px;"> <el-container> <el-col v-loading="loading" :data="marryList" @selection-change="handleSelectionChange"> <el-form ref="elForm" :model="marryList" :rules="rules" size="medium" label-position="left"> @@ -114,8 +108,8 @@ </el-row> <el-row :span="16"> <el-form-item label="缁撳鏃堕棿" prop="marryTime" label-width="70px"> - <el-input v-model="marryList.marryTime" placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="marryList.marryTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> </el-row> </el-form> @@ -129,15 +123,27 @@ <el-container > - <el-row > - <el-button - type="primary" - @click="handleEdit()" - v-if="isShow" - v-hasPermi="['system:role:edit']" - >缂栬緫</el-button> - <el-button v-if="isShow_2" type="primary" @click="submitForm" :disabled="dsb">瀹屾垚</el-button> - <br> + <el-row :gutter="10" class="mb8"> + <el-col > + <el-button + plain + @click="handleEdit()" + style="width: 80px;height: 32px;background: #E0EEFE;" + v-if="isShow" + v-hasPermi="['system:role:edit']" + >缂栬緫</el-button> + <el-button v-if="isShow_2" style="width: 80px;height: 32px;background: #E0EEFE;" @click="submitForm" :disabled="dsb">瀹屾垚</el-button> + <br> + + </el-col> + + <el-col style="padding-top: 10px;"> + <el-button + plain + style="width: 80px;height: 32px;background: #D2F3E0;" + @click="handleExport" + v-hasPermi="['family:note:export']" + >瀵煎嚭</el-button></el-col> </el-row> @@ -147,7 +153,7 @@ </el-container> <h2 style="font-size:16px " >閰嶅伓鎯呭喌</h2> <el-container> - <div style="padding-top:15px" > + <div style="padding-top:15px;width: 28%;" > <el-container > <el-col > <el-form ref="elForm" :model="marryList" :rules="rules" size="medium" label-position="left" @@ -160,8 +166,8 @@ </el-row> <el-row :span="16"> <el-form-item label="鍑虹敓鏃ユ湡" prop="spouseBirthday" label-width="70px"> - <el-input v-model="marryList.spouseBirthday" placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="marryList.spouseBirthday" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> </el-row> <el-row :span="16"> @@ -202,7 +208,7 @@ </el-col> </el-container> </div> - <div style="padding-left:200px;padding-top:15px"> + <div style="padding-left:100px;padding-top:15px;width: 30%;"> <el-container> <el-col v-loading="loading" :data="marryList" @selection-change="handleSelectionChange"> <el-form ref="elForm" :model="marryList" :rules="rules" size="medium" label-position="left"> @@ -235,8 +241,8 @@ </el-row> <el-row :span="16"> <el-form-item label="缁撳鏃堕棿" prop="spouseMarryTime" label-width="70px"> - <el-input v-model="marryList.spouseMarryTime" placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="marryList.spouseMarryTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> </el-row> </el-form> @@ -256,7 +262,7 @@ <!-- </el-dialog> self:user:export--> </el-container> - <div> + <div v-if="showOldSpouse"> <el-collapse v-model="activeNames" @change="handleChange"> <el-collapse-item name="1" > @@ -296,8 +302,8 @@ <el-table-column label="鍑虹敓鏃ユ湡" prop="birthday" sortable width="150" align="center" > <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.birthday }}</template> - <template v-else><el-input v-model="scope.row.birthday" type="date" placeholder="閫夋嫨鏃ユ湡"> - </el-input></template> + <template v-else><el-date-picker v-model="scope.row.birthday" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd"> + </el-date-picker></template> </template> </el-table-column> <el-table-column label="鎴风睄鍦板潃" prop="address" sortable width="180" align="center" > @@ -340,8 +346,8 @@ <el-table-column label="缁撳鏃堕棿" prop="marryTime" sortable width="150" align="center" > <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.marryTime }}</template> - <template v-else><el-input v-model="scope.row.marryTime" type="date" placeholder="閫夋嫨鏃ユ湡"> - </el-input></template> + <template v-else><el-date-picker v-model="scope.row.marryTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd"> + </el-date-picker></template> </template> </el-table-column> <!-- 鎿嶄綔 --> @@ -431,14 +437,14 @@ <el-row :span="16" > <el-form-item label="棰嗚瘉鏃堕棿" prop="handbookTime" label-width="70px"> - <el-input v-model="marryList.handbookTime " placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="marryList.handbookTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> </el-row> <el-row :span="16"> <el-form-item label="棰嗚瘉鏃堕棿" prop="oneBornTime" label-width="70px"> - <el-input v-model="marryList.oneBornTime" placeholder="" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="marryList.oneBornTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> </el-row> @@ -478,11 +484,8 @@ </el-select> </el-form-item> <el-form-item label="鍑虹敓鏃ユ湡" prop="birthday"> - <el-input - v-model='formDat.birthday' - type='date' - placeholder='閫夋嫨鏃ユ湡' - ></el-input> + <el-date-picker v-model="formDat.birthday" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> <el-form-item label="姘戞棌" prop="nation"> <el-input v-model="formDat.nation" placeholder="璇疯緭鍏ユ皯鏃�" clearable :style="{width: '100%'}" > @@ -506,11 +509,8 @@ </el-select> </el-form-item> <el-form-item label="缁撳鏃堕棿" prop="marryTime"> - <el-input - v-model='formDat.marryTime' - type='date' - placeholder='閫夋嫨鏃ユ湡' - ></el-input> + <el-date-picker v-model="formDat.marryTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd"> + </el-date-picker> </el-form-item> @@ -539,6 +539,7 @@ data() { return { + showOldSpouse:false,//鏄剧ず鍓嶄换淇℃伅 // 閬僵灞� disabled: false, isEditing:false, @@ -590,7 +591,6 @@ }, fit:['fill'], - oldSpouseList:{}, //涓嬫媺瀹炵幇 activeNames:['1'], // 寮瑰嚭灞傛爣棰� @@ -621,7 +621,6 @@ btn:false, isShow:true, isShow_2:false, - oldSpouseList:undefined, oldSpouseList:{ name:undefined, sex:undefined, @@ -661,10 +660,33 @@ }, // 琛ㄥ崟鏍¢獙 rules: { - + id: [{ + required: true, + message: '璇疯緭鍏ヨ韩浠借瘉鍙风爜', + trigger: 'blur' + }], + name: [{ + required: true, + message: '璇疯緭鍏ュ鍚�', + trigger: 'blur' + }], + birthday: [{ + // required: true, + message: '璇烽�夋嫨鏃ユ湡', + trigger: 'change' + }], + marryStatus: [{ + required: true, + message: '璇烽�夋嫨濠氬Щ鐘跺喌', + trigger: 'change' + }], + marryTime: [{ + // required: true, + message: '璇烽�夋嫨缁撳鏃堕棿', + trigger: 'change' + }], }, - typeOptions: [], typeOptions: [ { value: '濂�', label: '濂�', @@ -695,6 +717,17 @@ this.getList() }, methods: { + + handleMarryStatusChange() { + // 鍒ゆ柇褰撳墠閫変腑鐨勫濮荤姸鎬佹槸鍚︿负鍐嶅 + if (this.mrs === '3') { + this.showOldSpouse = true; + } else { + this.showOldSpouse = false; + } + + }, + //鎬у埆 getSrc1(sex) { if (sex === '濂�') { @@ -734,9 +767,16 @@ else{ this.marryList = response.data; this.oldSpouseList = this.marryList.oldSpouseList; - this.loading = false; console.log(111) - console.log(this.oldSpouseList) + console.log("淇℃伅") + console.log(this.marryList.marryStatus); + if(this.marryList.marryStatus===3){ + this.showOldSpouse = true; + } else{ + this.showOldSpouse = false; + } + this.loading = false; + } } diff --git a/ruoyi-ui/src/views/mindMap/index.vue b/ruoyi-ui/src/views/mindMap/index.vue index 970362a..5f1fd1a 100644 --- a/ruoyi-ui/src/views/mindMap/index.vue +++ b/ruoyi-ui/src/views/mindMap/index.vue @@ -1,12 +1,11 @@ <template> <div class="app-container"> - <h1 style="font-size: 21px;">{{ greeting +'锛�' + user.userName }}</h1> + <div class="text" > + <h1 style="font-size: 21px;margin-left: 0">{{ greeting +'锛�' + user.userName }}</h1></div> <div class="image-container"> <img class="top-image" src="../../assets/images/zhang.png" alt="Top Image"> </div> - - - <superMindmap v-if="showMindMap" :active='active' :data="mapData" @activeChange="activeChange"/> + <superMindmap v-if="showMindMap" :active='active' :data="mapData" @activeChange="activeChange" class="mind-map-container "/> </div> </template> @@ -15,10 +14,10 @@ import { getUserProfile } from "@/api/system/user"; import { listRootAll ,listRoot} from "@/api/root/index"; import * as d3 from 'd3'; - // 瀵煎叆鎬濈淮瀵煎浘鏁版嵁 - import MapData from '../components/MapData.js' - // 瀵煎叆鎬濈淮瀵煎浘缁勪欢 - import superMindmap from '../components/superMindmap.vue' +// 瀵煎叆鎬濈淮瀵煎浘鏁版嵁 +import MapData from '../components/MapData.js' +// 瀵煎叆鎬濈淮瀵煎浘缁勪欢 +import superMindmap from '../components/superMindmap.vue' export default { components:{superMindmap}, @@ -42,25 +41,21 @@ // console.log('sssssssssssssssssss') }, - - - methods: { // 鐐瑰嚮鎬濈淮瀵煎浘鑺傜偣鍚庯紝瑙﹀彂鍙橀噺鏇存柊 - activeChange(newLabel) { - this.active = newLabel - this.reloadMindMap() - }, - // 閲嶈浇鎬濈淮瀵煎浘 - reloadMindMap() { - this.showMindMap = false - this.$nextTick( - () => { - this.showMindMap = true - } - ) - }, - + activeChange(newLabel) { + this.active = newLabel + this.reloadMindMap() + }, + // 閲嶈浇鎬濈淮瀵煎浘 + reloadMindMap() { + this.showMindMap = false + this.$nextTick( + () => { + this.showMindMap = true + } + ) + }, setGreeting() { const currentTime = new Date(); @@ -86,127 +81,77 @@ const mindMapData = this.rootList[0]; - // console.log(this.drawData(mindMapData)) this.mapData = this.drawData(mindMapData) this.showMindMap = true }) }, - drawData(mpdata) - { - if(mpdata==null) - return null + drawData(mpdata) { + if (mpdata == null) + return null; var data = { - "label": mpdata['nickName'], + "label": mpdata['spouse'] != null ? eval(mpdata['spouse']).nickName : '', "prop": mpdata['nickName'], "url": '', - "link": '', - "children":[] - } - if(eval(mpdata['spouse'])!=null) - data['link'] = eval(mpdata['spouse']).nickName - if(mpdata['childList']!=null){ - for(var i = 0; i < mpdata['childList'].length; i++) - { - var dt = { - "label": mpdata['childList'][i]['nickName'], - "prop": mpdata['childList'][i]['nickName'], - "url": '', - "link": "", - "children":[] + "link": mpdata['nickName'], + "children": [] + }; + + if (mpdata['childList'] != null) { + for (var i = 0; i < mpdata['childList'].length; i++) { + var dt = { + "label": mpdata['childList'][i]['spouse'] != null ? eval(mpdata['childList'][i]['spouse']).nickName : '', + "prop": mpdata['childList'][i]['nickName'], + "url": '', + "link": mpdata['childList'][i]['nickName'], + "children": [] + }; + if (mpdata['childList'][i]['childList'] != null) { + for (var j = 0; j < mpdata['childList'][i]['childList'].length; j++) { + dt['children'].push(this.drawData(mpdata['childList'][i]['childList'][j])); + } + } + data['children'].push(dt); } - if(eval(mpdata['childList'][i]['spouse'])!=null) - dt['link'] = eval(mpdata['childList'][i]['spouse']).nickName - if(mpdata['childList'][i]['childList']!=null) - { - for(var j = 0; j < mpdata['childList'][i]['childList'].length;j++) - dt['children'].push(this.drawData(mpdata['childList'][i]['childList'][j])) - } - data['children'].push(dt) - } } return data; }, - drawMindMap() { - const mindMapData = this.rootList[0]; // 浠巖ootList涓幏鍙栨暟鎹� - console.log(mindMapData) - // 娓呴櫎鐜版湁鐨凷VG鍏冪礌 - // d3.select("#mind-map svg").remove(); - - // // 鍒涘缓涓�涓柊鐨� div 鍏冪礌浣滀负鍖呰9鎬濈淮瀵煎浘鐨勫鍣� - // const mindMapContainer = document.createElement("div"); - // mindMapContainer.setAttribute("id", "mind-map-container"); - // mindMapContainer.style.position = "absolute"; - // mindMapContainer.style.top = "0"; - // mindMapContainer.style.left = "0"; - // mindMapContainer.style.width = "100%"; - // mindMapContainer.style.height = "100%"; - // mindMapContainer.style.zIndex = "1"; - - // // 灏嗘�濈淮瀵煎浘瀹瑰櫒鎻掑叆鍒� image-container 涓� - // document.querySelector(".image-container").appendChild(mindMapContainer); - - // // 鍒涘缓SVG鍏冪礌锛岃缃搴﹀拰楂樺害 - // const svg = d3.select("#mind-map-container") - // .append("svg") - // .attr("class", "svg-container") // 娣诲姞 className - // .attr("width", "100%") - // .attr("height", "100%"); - - // // 鍒涘缓鏍硅妭鐐� - // const root = d3.hierarchy(mindMapData); - // const treeLayout = d3.tree().size([500, 400]); // 璁剧疆鏍戠姸甯冨眬鐨勫昂瀵� - // treeLayout(root); - - // // 鍒涘缓閾炬帴绾� - // svg.selectAll(".link") - // .data(root.descendants().slice(1)) - // .enter() - // .append("path") - // .attr("class", "link") - // .attr("d", d => { - // return "M" + d.x + "," + d.y + "C" + (d.x + d.parent.x) / 2 + "," + d.y + " " + - // (d.x + d.parent.x) / 2 + "," + d.parent.y + " " + d.parent.x + "," + d.parent.y; - // }); - - // // 鍒涘缓鑺傜偣 - // const nodes = svg.selectAll(".node") - // .data(root.descendants()) - // .enter() - // .append("g") - // .attr("class", "node") - // .attr("transform", d => "translate(" + d.x + "," + d.y + ")"); - - // nodes.append("circle") - // .attr("r", 10); - - // nodes.append("text") - // .attr("dx", 12) - // .attr("dy", 5) - // .text(d => d.data.nickName); - } } }; </script> <style scoped> .app-container{ - background-color: #FEF7FC; position: relative; + /*background-color: transparent;*/ + /*padding-left: -20px;*/ } +.text{ + background-color: #FEF7FC; + opacity: 0.75; + margin-top: -20px; + padding: 20px; +} .image-container { - position: absolute; + /*position: absolute;*/ + position: fixed; + top: 50px; + left: 50px; width: 100%; height: 100%; z-index: -1; } .mind-map-container{ + position: fixed; z-index: 2; - opacity: 0.5; + opacity: 0.8; + margin-top: 50px; + margin-left: 50px; + background-color: transparent; } .top-image { width: 100%; @@ -215,7 +160,4 @@ position: static; opacity: 0.8; } - - - </style> diff --git a/ruoyi-ui/src/views/note/index.vue b/ruoyi-ui/src/views/note/index.vue index 64e0fb7..f4fefc4 100644 --- a/ruoyi-ui/src/views/note/index.vue +++ b/ruoyi-ui/src/views/note/index.vue @@ -141,6 +141,9 @@ <el-table-column label="澶囨敞" prop="remark" sortable width="130" > <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '鈥斺�斺�斺��'}}</template> </el-table-column> + <el-table-column label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData" sortable width="150px" > + <template slot-scope="scope">{{scope.row.ownData === 0 ? '鍚�': '鏄�'}}</template> + </el-table-column> <!-- <el-table-column label="瀹跺涵鍙�" prop="familyId" sortable width="100" /> --> <el-table-column label="鍙戠敓鏃堕棿" prop="happenTime" sortable width="150" align="center"> <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '鈥斺�斺�斺��'}}</template> @@ -649,11 +652,21 @@ this.$modal.msgSuccess("鍒犻櫎鎴愬姛"); }).catch(() => {}); }, + /** 瀵煎嚭鎸夐挳鎿嶄綔 */ handleExport() { - this.download('family/property/export', { - ...this.queryParams - }, `property_${new Date().getTime()}.xlsx`) + const Ids = this.ids; + + if(Ids.length==0) + { + this.download('family/property/export', { + ...this.queryParams + }, `property_${new Date().getTime()}.xlsx`) + } + else{ + this.download('family/property/export1/'+Ids, { + }, `property_${new Date().getTime()}.xlsx`) + } }, /** 瀵煎叆鎿嶄綔*/ handleEnport(params){ diff --git a/ruoyi-ui/src/views/note/propertyInfo.vue b/ruoyi-ui/src/views/note/propertyInfo.vue index af1442a..52645e3 100644 --- a/ruoyi-ui/src/views/note/propertyInfo.vue +++ b/ruoyi-ui/src/views/note/propertyInfo.vue @@ -46,6 +46,9 @@ <el-form-item label="澶囨敞" prop="remark"> <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> </el-form-item> + <el-form-item label="鏄惁鏄湰瀹跺涵璁板綍" prop="ownData"> + <el-input v-model="formData.ownData=== 1 ? '鏄�':'鍚�'" placeholder=" " clearable :style="{width: '100%'}" :disabled=true></el-input> + </el-form-item> <h4 class="form-header">鐩稿叧鍥剧墖 </h4> <el-upload diff --git a/ruoyi-ui/src/views/self/memo.vue b/ruoyi-ui/src/views/self/memo.vue index b9fb6c7..c9ca71b 100644 --- a/ruoyi-ui/src/views/self/memo.vue +++ b/ruoyi-ui/src/views/self/memo.vue @@ -222,8 +222,9 @@ <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px"> <el-form-item label="鏃堕棿" prop="happenTime"> - <el-input v-model="formDat.happenTime" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> - </el-form-item> + <el-date-picker v-model="formDat.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></el-form-item> <el-form-item label="浜虹墿" prop="people"> <el-input v-model="formDat.people" placeholder="璇疯緭鍏ヤ汉鐗�" clearable :style="{width: '100%'}" > </el-input> diff --git a/ruoyi-ui/src/views/self/memoInfo.vue b/ruoyi-ui/src/views/self/memoInfo.vue index 4a3404d..a739a96 100644 --- a/ruoyi-ui/src/views/self/memoInfo.vue +++ b/ruoyi-ui/src/views/self/memoInfo.vue @@ -13,8 +13,9 @@ <el-row> <el-cow :span="8"> <el-form-item label="鏃堕棿" prop="happenTime" label-width="50px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> - <el-input v-model="formData.happenTime" placeholder="璇疯緭鍏ユ椂闂�" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="formData.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> </el-cow> <el-cow :span="8"> diff --git a/ruoyi-ui/src/views/self/show.vue b/ruoyi-ui/src/views/self/show.vue index e44fbb8..2889f83 100644 --- a/ruoyi-ui/src/views/self/show.vue +++ b/ruoyi-ui/src/views/self/show.vue @@ -8,11 +8,39 @@ class="el-icon-top" ></el-button> </el-backtop> - <h1 style="font-size:21px;padding-top:30px;display: flex;justify-content: space-between;align-items: center;"> + <h1 style="font-size:21px;padding-top:30px;display: flex;"> <span>涓汉绠�鍘�</span> + <div class="button-container" > + <el-button + size="mini" + style="background: #E0EEFE; + border-radius: 7px 7px 7px 7px;opacity: 1; margin-left: 20px;" + @click="handleEdit()" + v-if="isShow" + v-hasPermi="['system:role:edit']" + >缂栬緫</el-button> + <el-button v-if="isShow_2" size="mini" + style=" width: 67px;height: 27px;background:#E0EEFE; + border-radius: 7px 7px 7px 7px;opacity: 1;margin-left: 20px; "@click="submitForm" :disabled="dsb">瀹屾垚</el-button> + + <el-button + size="mini" + style=" width: 67px;height: 27px;background: #D2F3E0; + border-radius: 7px 7px 7px 7px;opacity: 1;margin-left: 20px; " + @click="handleExport" + v-hasPermi="['family:note:export']" + >瀵煎嚭</el-button> + + <el-button + size="mini" + style=" width: 67px;height: 27px;background: #FFDDE3; + border-radius: 7px 7px 7px 7px;opacity: 1; margin-left: 20px;" + v-hasPermi="['family:note:export']" + >鎵撳嵃</el-button> + </div> <div style="display: flex; align-items: center;"> - <el-button size="mini" type="text" @click="toMemo" v-hasPermi="['person:information:memo']"> - <div class="form" ><el-icon style="padding-right:110px;"></el-icon> + <el-button size="mini" type="text" @click="toMemo" v-hasPermi="['person:information:memo']" style="margin-left: 20px"> + <div class="form" ><el-icon style="padding-right:100px;"></el-icon> <span class="text" style="width: 69px;height: 26px;font-size: 16px; font-family: Microsoft YaHei-Regular, Microsoft YaHei; color: #EBA4AA;">涓汉璁颁簨鏈�</span></div> </el-button> @@ -27,19 +55,19 @@ <el-col > <el-form ref="elForm" :model="individualList" :rules="rules" size="medium" label-position="left" v-loading="loading" :data="individualList" @selection-change="handleSelectionChange" > - <el-row :span="5"> + <el-row :span="6"> <el-form-item label="濮撳悕" prop="nickName" label-width="40px"> <el-input v-model="individualList.nickName" placeholder="" clearable :style="{width: '100%'}" :disabled="dsb"> </el-input> </el-form-item> </el-row> - <el-row :span="5"> + <el-row :span="6"> <el-form-item label="鏇剧敤鍚�" prop="oldName" label-width="60px"> <el-input v-model="individualList.oldName" placeholder="" clearable :style="{width: '100%'}" :disabled="dsb"> </el-input> </el-form-item> </el-row> - <el-row :span="5"> + <el-row :span="6"> <el-form-item label="韬唤璇佸彿" prop="idNum" label-width="70px"> <el-input v-model="individualList.idNum" placeholder="" clearable :style="{width: '100%'}" :disabled="dsb"> </el-input> @@ -49,7 +77,7 @@ </el-col> </el-container> </div> - <div style="padding-left:30px"> + <div style="padding-left:60px"> <el-container> <el-col v-loading="loading" :data="individualList" @selection-change="handleSelectionChange"> <el-form ref="elForm" :model="individualList" :rules="rules" size="medium" label-position="left"> @@ -84,7 +112,7 @@ </el-col> </el-container> </div> - <div style="padding-left:30px"> + <div style="padding-left:60px"> <el-container> <el-col v-loading="loading" :data="individualList" @selection-change="handleSelectionChange"> <el-form ref="elForm" :model="individualList" :rules="rules" size="medium" label-position="left":disabled="dsb"> @@ -116,7 +144,7 @@ </el-col> </el-container> </div> - <div style="padding-left:30px;padding-top:30px"> + <div style="padding-left:100px;padding-top:30px"> <el-col :span="6" :data="individualList"> <div class="block" :model="individualList"> <div v-if="!isEditing"> @@ -167,29 +195,7 @@ </div> <div style="padding-left:30px;padding-top:30px" > - <el-container > - <el-row > - <el-button - type="primary" - @click="handleEdit()" - v-if="isShow" - v-hasPermi="['system:role:edit']" - >缂栬緫</el-button> - <el-button v-if="isShow_2" type="primary" @click="submitForm" :disabled="dsb">瀹屾垚</el-button> - <br> - <el-button - type="primary" - @click="handleExport" - v-hasPermi="['family:note:export']" - >瀵煎嚭</el-button> - <br> - <el-button - type="primary" - v-hasPermi="['family:note:export']" - >鎵撳嵃</el-button> - </el-row> - </el-container> </div> <!-- </el-dialog> self:user:export--> </el-container> @@ -221,7 +227,7 @@ </el-col> </el-container> </div> - <div style="padding-left:30px"> + <div style="padding-left:60px"> <el-container> <el-col v-loading="loading" :data="individualList" @selection-change="handleSelectionChange"> <el-form ref="elForm" :model="individualList" :rules="rules" size="medium" label-position="left"> @@ -291,13 +297,18 @@ <el-table-column label="寮�濮嬫棩鏈�" prop="startDate" sortable width="250" align="center" > <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.startDate }}</template> - <template v-else><el-input v-model="scope.row.startDate" type="date" placeholder="閫夋嫨鏃ユ湡"></el-input></template> + <template v-else> + <el-date-picker v-model="scope.row.startDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></template> </template> </el-table-column> <el-table-column label="缁撴潫鏃ユ湡" prop="endDate" sortable width="250" align="center" > <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.endDate }}</template> - <template v-else><el-input v-model="scope.row.endDate" type="date" placeholder="閫夋嫨鏃ユ湡"></el-input></template> + <template v-else><el-date-picker v-model="scope.row.endDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></template> </template> </el-table-column> <el-table-column label="涓昏瀛︿範缁忓巻銆佸伐浣滃崟浣嶅強浠昏亴鎯呭喌" prop="content" sortable width="350" align="center" > @@ -332,7 +343,8 @@ 瀹跺涵鎴愬憳鍙婁富瑕佺ぞ浼氬叧绯绘儏鍐� <div> <el-button class="button2" size="mini" type="text" @click="showDialog('relation1')"> - <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn></el-button></div> + <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn></el-button> + </div> </div> </template> <el-table v-loading="loading" :data="relationList" @selection-change="handleSelectionChange" @@ -383,7 +395,7 @@ <el-collapse-item name="4"> <template v-slot:title> <div class="title-wrapper"> - 鎸佹湁鍑哄叆澧冭瘉浠舵儏鍐� + 鎸佹湁璇佷欢鎯呭喌 <el-button class="button4" size="mini" type="text" @click="showDialog('certificate')"> <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn></el-button> </div> @@ -417,13 +429,19 @@ <el-table-column label="寮�濮嬫椂闂�" prop="startTime" sortable width="230" align="center"> <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.startTime }}</template> - <template v-else><el-input v-model="scope.row.startTime" type="date" placeholder="閫夋嫨鏃ユ湡"></el-input></template> + <template v-else> + <el-date-picker v-model="scope.row.startTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></template> </template> </el-table-column> <el-table-column label="缁撴潫鏃堕棿" prop="endTime" sortable width="230" align="center"> <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.endTime }}</template> - <template v-else><el-input v-model="scope.row.endTime" type="date" placeholder="閫夋嫨鏃ユ湡"></el-input></template> + <template v-else> + <el-date-picker v-model="scope.row.endTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></template> </template> </el-table-column> <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width"> @@ -452,13 +470,19 @@ <el-table-column label="寮�濮嬫椂闂�" prop="startTime" sortable width="200" align="center"> <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.startTime }}</template> - <template v-else><el-input v-model="scope.row.startTime" type="date" placeholder="閫夋嫨鏃ユ湡"></el-input></template> + <template v-else> + <el-date-picker v-model="scope.row.startTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></template> </template> </el-table-column> <el-table-column label="缁撴潫鏃堕棿" prop="endTime" sortable width="200" align="center"> <template slot-scope="scope"> <template v-if="!scope.row.isEdit">{{ scope.row.endTime }}</template> - <template v-else><el-input v-model="scope.row.endTime" type="date" placeholder="閫夋嫨鏃ユ湡"></el-input></template> + <template v-else> + <el-date-picker v-model="scope.row.endTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></template> </template> </el-table-column> <el-table-column label="鎵�鍒板浗瀹舵垨鑰呭湴鍖�" prop="destination" sortable width="300" align="center" > @@ -485,39 +509,45 @@ </el-table-column> </el-table> </el-collapse-item> + <!-- 鑷紶--> + <el-collapse-item name="6"> + <template v-slot:title> + <div class="title-wrapper"> + 鑷紶 + <div> + <el-button size='mini' type="text" class="btn_autobiography" @click="showDialog('autobiography')" > + <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn> + </el-button> + </div> + </div> + </template> + <el-contain> + <div> + <el-tabs type="border-card" v-model="activeName" @tab-click="handleClick" + v-loading="loading" :data="AutobiographyList" > + <el-tab-pane v-for="(item, index) in AutobiographyList" + :key='item.id' :label="item.ageBegin+'~'+item.ageEnd+'宀�'+'('+item.term+')'"> + <div v-if="item.term === '濠村効'"> {{item.content}}</div> + <div v-if="item.term === '骞煎効'"> {{item.content}}</div> + <div v-if="item.term === '灏忓'"> {{item.content}}</div> + <div v-if="item.term === '鍒濅腑'"> {{item.content}}</div> + <div v-if="item.term === '楂樹腑'"> {{item.content}}</div> + <div v-if="item.term === '澶у'"> {{item.content}}</div> + <div v-if="item.term === '鐮旂┒鐢�'"> {{item.content}}</div> + <div v-if="item.term === '宸ヤ綔'"> {{item.content}}</div> + <div v-if="item.term === '缁撳鍚�'"> {{item.content}}</div> + <el-button size='mini' type="text" class="btn_edit" @click="editData(item)" style='position: absolute;right:10px;top:5px;'> + <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn> + </el-button> + </el-tab-pane> + </el-tabs></div> + </el-contain> + </el-collapse-item> + </el-collapse> - <!-- 鑷紶--> - <div style="padding-top:30px"> - <el-container> - <div style="width:100%"><h2 style="font-size:15px" >鑷紶</h2></div> - </el-container> - <div style='position: relative;'> - <el-tabs type="border-card" v-model="activeName" @tab-click="handleClick" - v-loading="loading" :data="AutobiographyList" > - <el-tab-pane v-for="(item, index) in AutobiographyList" - :key='item.id' :label="item.ageBegin+'~'+item.ageEnd+'宀�'+'('+item.term+')'"> - <div v-if="item.term === '濠村効'"> {{item.content}}</div> - <div v-if="item.term === '骞煎効'"> {{item.content}}</div> - <div v-if="item.term === '灏忓'"> {{item.content}}</div> - <div v-if="item.term === '鍒濅腑'"> {{item.content}}</div> - <div v-if="item.term === '楂樹腑'"> {{item.content}}</div> - <div v-if="item.term === '澶у'"> {{item.content}}</div> - <div v-if="item.term === '鐮旂┒鐢�'"> {{item.content}}</div> - <div v-if="item.term === '宸ヤ綔'"> {{item.content}}</div> - <div v-if="item.term === '缁撳鍚�'"> {{item.content}}</div> - <el-button size='mini' type="text" class="btn_edit" @click="editData(item)" style='position: absolute;right:10px;top:5px;'> - <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn> - </el-button> - </el-tab-pane> - </el-tabs> - <el-button size='mini' type="text" class="btn_autobiography" @click="showDialog('autobiography')" style='position: absolute;right:10px;top:5px;'> - <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn> - </el-button> - </div> - </div> <pagination v-show="total>0" @@ -528,13 +558,17 @@ /> <!-- 鏂板涓昏缁忓巻淇℃伅閰嶇疆瀵硅瘽妗� --> - <el-dialog :title="title" :visible.sync="dialogVisible.open" width="900px" append-to-body> + <el-dialog title="鏂板涓昏缁忓巻淇℃伅" :visible.sync="dialogVisible.open" width="900px" append-to-body> <el-form ref="elForm1" :model="formDat" :rules="rules" size="medium" label-width="140px"> <el-form-item label="寮�濮嬫棩鏈�" prop="startDate"> - <el-input v-model="formDat.startDate" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> + <el-date-picker v-model="formDat.startDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <el-form-item label="缁撴潫鏃ユ湡" prop="endDate"> - <el-input v-model="formDat.endDate" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> + <el-date-picker v-model="formDat.endDate" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <el-form-item label="涓昏瀛︿範缁忓巻銆佸伐浣滃崟浣嶅強浠昏亴鎯呭喌" prop="content"> <el-input v-model="formDat.content" type="textarea" :rows="5" placeholder="璇疯緭鍏ヤ富瑕佸涔犵粡鍘嗐�佸伐浣滃崟浣嶅強浠昏亴鎯呭喌" clearable :style="{width: '100%'}" > @@ -554,7 +588,7 @@ </div> </el-dialog> <!-- 鏂板瀹跺涵鎴愬憳鍙婁富瑕佺ぞ浼氬叧绯绘儏鍐典俊鎭厤缃璇濇 --> - <el-dialog :title="title" :visible.sync="dialogVisible.relation1" width="900px" append-to-body> + <el-dialog title="鏂板瀹跺涵鎴愬憳鍙婁富瑕佺ぞ浼氬叧绯绘儏鍐�" :visible.sync="dialogVisible.relation1" width="900px" append-to-body> <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="140px"> <el-form-item label="涓庢湰浜哄叧绯�" prop="relation"> <el-input v-model="formDat.relation" placeholder="璇疯緭鍏ヤ笌鏈汉鍏崇郴" clearable :style="{width: '100%'}" ></el-input> @@ -584,18 +618,20 @@ <el-button @click="cancelData">鍙� 娑�</el-button> </div> </el-dialog> - <!-- 鏂板鎸佹湁鍑哄叆澧冭瘉浠舵儏鍐典俊鎭厤缃璇濇 --> - <el-dialog :title="title" :visible.sync="dialogVisible.certificate" width="900px" append-to-body> + <!-- 鏂板鎸佹湁璇佷欢鎯呭喌淇℃伅閰嶇疆瀵硅瘽妗� --> + <el-dialog title="鏂板鎸佹湁璇佷欢鎯呭喌" :visible.sync="dialogVisible.certificate" width="900px" append-to-body> <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="140px"> <el-form-item label="璇佷欢鍚嶇О" prop="cerName"> <el-input v-model="formDat.cerName" placeholder="璇疯緭鍏ヨ瘉浠跺悕绉�" clearable :style="{width: '100%'}" > </el-input> </el-form-item> <el-form-item label="璇佷欢绫诲瀷" prop="type"> - <el-select v-model="formDat.type" placeholder="璇烽�夋嫨绫诲瀷" clearable :style="{width: '100%'}" > + <el-select v-model="formDat.type" placeholder="璇烽�夋嫨璇佷欢绫诲瀷" clearable :style="{width: '100%'}" > <el-option v-for="(item, index) in typeOption" :key="index" :label="item.label" :value="item.value" ></el-option> </el-select> + <el-input v-model="newOption" v-if="showInput" placeholder="鑻ユ湭鍦ㄤ笂杩伴�夐」涓壘鍒板搴旂被鍨嬶紝璇峰湪姝よ緭鍏ユ柊鐨勮瘉浠剁被鍨�" @change="addNewOption"></el-input> + </el-form-item> <el-form-item label="鎸佹湁鎯呭喌" prop="ownStatus"> <el-input v-model="formDat.ownStatus" placeholder="璇疯緭鍏ユ寔鏈夋儏鍐�" clearable :style="{width: '100%'}" > @@ -606,11 +642,14 @@ </el-input> </el-form-item> <el-form-item label="寮�濮嬫棩鏈�" prop="startTime"> - <el-input v-model="formDat.startTime" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> - </el-form-item> + <el-date-picker v-model="formDat.startTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> + </el-form-item> <el-form-item label="缁撴潫鏃ユ湡" prop="endTime"> - <el-input v-model="formDat.endTime" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> - </el-form-item> + <el-date-picker v-model="formDat.endTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></el-form-item> </el-form> <h4 class="form-header"> </h4> @@ -620,14 +659,16 @@ </div> </el-dialog> <!-- 鏂板鍑哄浗锛堝锛夋儏鍐典俊鎭厤缃璇濇 --> - <el-dialog :title="title" :visible.sync="dialogVisible.abroad" width="900px" append-to-body> + <el-dialog title="鏂板鍑哄浗锛堝锛夋儏鍐典俊鎭�" :visible.sync="dialogVisible.abroad" width="900px" append-to-body> <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="140px"> <el-form-item label="寮�濮嬫棩鏈�" prop="startTime"> - <el-input v-model="formDat.startTime" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> - </el-form-item> + <el-date-picker v-model="formDat.startTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></el-form-item> <el-form-item label="缁撴潫鏃ユ湡" prop="endTime"> - <el-input v-model="formDat.endTime" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" > - </el-input> + <el-date-picker v-model="formDat.endTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <el-form-item label="鎵�鍒板浗瀹舵垨鑰呭湴鍖�" prop="destination"> <el-input v-model="formDat.destination" type="textarea" :rows="5" placeholder="璇疯緭鍏ユ墍鍒板浗瀹舵垨鑰呭湴鍖�" clearable :style="{width: '100%'}" > @@ -695,12 +736,11 @@ import axios from 'axios'; //鍦╯ystem/note/index.js涓鍏ユ帴鍙e嚱鏁� --鎺ュソ浜� -import { - getIndividualList, addIndividual, updateIndividual, delIndividual, +import {getIndividualList, addIndividual, updateIndividual, delIndividual, listExperience, addExperience, updateExperience, delExperience, getIndividualRelation, addRelation, updateRelation, delRelation, getCertificateList, addCertificate, updateCertificate, delCertificate, - getAbroadList, addAbroad, updateAbroad, delAbroad, + getAbroadList, addAbroad, updateAbroad, delAbroad,listType, getAutobiographyList, getAutobiographyTermList, addAutobiography,updateAutobiography, getCategory, } from "@/api/self/index"; @@ -752,6 +792,7 @@ relationList:[], //鍑哄叆澧冭瘉浠舵儏鍐� certificateList:[], + typeList:[], //鍑哄浗鎯呭喌 AbroadList:[], @@ -783,8 +824,6 @@ }, // 寮瑰嚭灞傛爣棰� title: "", - // 鏄惁鏄剧ず寮瑰嚭灞� - open: false, // open:true, // 鏄惁鏄剧ず寮瑰嚭灞傦紙鏁版嵁鏉冮檺锛� @@ -979,16 +1018,9 @@ }, selectedOption:'', typeOptions:[], - typeOption: [{ - value:'鎶ょ収', - label:'鎶ょ収' - },{ - value:'閫氳璇�', - label:'閫氳璇�' - },{ - value:'韬唤璇�', - label:'韬唤璇�' - }], + typeOption:[], + newOption: undefined, + showInput: true }; }, created() { @@ -1018,7 +1050,7 @@ //涓嬫媺 handleChange(activeNames) { - // console.log(val); + // console.log(activeNames); this.reset(); }, showDialog(dialogName) { @@ -1064,7 +1096,14 @@ return '鈥斺�斺�斺�斺�斺��' } }, - +//绫诲埆 + addNewOption() { + const newOption = this.newOption.trim(); + if (newOption && !this.typeOption.includes(newOption)) { + this.typeOption.push(newOption); + this.$set(this.formDat, 'type', newOption); // 鏇存柊formDat.type鐨勫�间负鏂扮殑閫夐」 + } + }, /** 鏌ヨ瑙掕壊鍒楄〃 */ getList() { this.loading = true; @@ -1132,6 +1171,32 @@ // this.total = response.data.total; // this.loading = false; // }); + listType(this.queryParams).then(response => { + this.typeList = response.data; + this.total = response.data.total; + // console.log( this.typeList ) + // 鍦ㄥ洖璋冨嚱鏁颁腑璋冪敤 getTypeOptions() + this.getTypeOptions(); + this.loading = false; + } + ); + }, + getTypeOptions() { + const filteredOptions = this.typeList.filter(item => typeof item === 'string' && item !== ''); + // 鍒涘缓涓�涓┖瀵硅薄鐢ㄤ簬瀛樺偍鍞竴鐨勫瓧绗︿覆閫夐」 + const uniqueOptions = {}; + // 鏋勫缓涓嬫媺閫夐」鍒楄〃 + this.typeOption = filteredOptions.reduce((options, option) => { + if (!uniqueOptions[option]) { + uniqueOptions[option] = true; + options.push({ + label: option, + value: option + }); + } + return options; + }, []); + }, //鍥剧墖鐨勪笂浼犲強涓婁紶鎸夐挳闅愯棌 @@ -1212,12 +1277,6 @@ }); }, - handleRemoveFile(file) { - alert(23) - }, - handleRemove(file) { - alert("323") - }, handlePictureCardPreview(file) { this.dialogImageUrl = file.url; this.dialogVisible = true; @@ -1273,11 +1332,6 @@ }); }); - // if(AutobiographyList.ageEnd==null){ - // this.AgeEnd='?' - // }else{ - // this.AgeEnd=this.ageEnd - // } }, /** 鎻愪氦鎸夐挳锛堟暟鎹潈闄愶級 */ @@ -1667,9 +1721,7 @@ background: #FFEFF2; } -/*.co-item{*/ -/* background-color: #EBAFB4;*/ -/*}*/ + .el-collapse-item__header { background-color:#FEF7FC; } @@ -1679,11 +1731,19 @@ } .btn_autobiography{ background:center no-repeat url('../../assets/icons/add1.png') ; + margin-left: 76vw; } .btn_edit{ background:center no-repeat url('../../assets/icons/edit.png') ; } +.button-container { + text-align: right; + display: flex; + justify-content: flex-end; + align-items: center; + flex-grow: 1; +} .button { background:center no-repeat url('../../assets/icons/add1.png') ; margin-left: 69.5vw; @@ -1695,7 +1755,7 @@ } .button4 { background: center no-repeat url('../../assets/icons/add1.png') ; - margin-left: 69.5vw; + margin-left: 71.5vw; } .button5 { background:center no-repeat url('../../assets/icons/add1.png') ; diff --git a/ruoyi-ui/src/views/travel/Info.vue b/ruoyi-ui/src/views/travel/Info.vue index f3538b3..14ae47f 100644 --- a/ruoyi-ui/src/views/travel/Info.vue +++ b/ruoyi-ui/src/views/travel/Info.vue @@ -162,46 +162,45 @@ <!-- 娣诲姞鎴栦慨鏀硅祫浜т俊鎭厤缃璇濇 --> - <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body> + <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body> <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px"> - + <h4 class="form-header">琛岀▼鍐呭 </h4> + <el-form-item label="鏍囬" prop="title"> + <el-input v-model="formDat.title" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> <el-form-item label="鏃堕棿" prop="happenTime"> - <el-date-picker + <el-input v-model='formDat.happenTime' type='date' placeholder='閫夋嫨鏃ユ湡' - ></el-date-picker> + ></el-input> </el-form-item> <el-form-item label="鍦扮偣" prop="address"> <el-input v-model="formDat.address" placeholder="璇疯緭鍏ュ湴鐐�" clearable :style="{width: '100%'}" > </el-input> </el-form-item> - <!-- <el-form-item label="鍦扮偣" prop="price"> - <el-select v-model="formDat.price" placeholder="璇烽�夋嫨鏀跺叆/鏀嚭" clearable :style="{width: '100%'}" > - <el-option v-for="(item, index) in typeOptions" :key="index" :label="item.label" :value="item.value" - ></el-option> - </el-select> - </el-form-item> --> <el-form-item label="浜虹墿" prop="people"> <el-input v-model="formDat.people" placeholder="璇疯緭鍏ヤ汉鐗�" clearable :style="{width: '100%'}" > </el-input> </el-form-item> - <el-form-item label="鏍囬" prop="title"> - <el-input v-model="formDat.title" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" > - </el-input> - </el-form-item> <el-form-item label="鏃呮湡" prop="travelPeriod"> - <el-input v-model="formDat.travelPeriod" placeholder="璇疯緭鍏ヤ娇鐢ㄤ汉" clearable :style="{width: '100%'}" > + <el-input v-model="formDat.travelPeriod" placeholder="璇疯緭鍏ユ梾鏈�" clearable :style="{width: '100%'}" > </el-input> </el-form-item> <el-form-item label="鎸佽瘉鏃呮父" prop="certificate"> - <el-input v-model="formDat.certificate" placeholder="璇疯緭鍏ヨ瘉浠�" clearable :style="{width: '100%'}" > - </el-input> + <el-select v-model="formDat.certificate" placeholder="璇烽�夋嫨璇佷欢" clearable :style="{width: '80%'}" > + <el-option label="灞呮皯韬唤璇�" value="灞呮皯韬唤璇�"></el-option> + <el-option label="涓存椂韬唤璇�" value="涓存椂韬唤璇�"></el-option> + <el-option label="鎴峰彛鏈�" value="鎴峰彛鏈�"></el-option> + <el-option label="鎶ょ収" value="鎶ょ収"></el-option> + <el-option label="瀛︾敓璇�" value="瀛︾敓璇�"></el-option> + </el-select> </el-form-item> - <el-form-item label="璐圭敤" prop="totalPrice"> + <!-- <el-form-item label="璐圭敤" prop="totalPrice"> <el-input v-model="formDat.totalPrice" placeholder="璇疯緭鍏ユ�诲叡璐圭敤" clearable :style="{width: '100%'}" > </el-input> - </el-form-item> + </el-form-item> --> <el-form-item label="鍏垂/鑷垂" prop="self"> <el-select v-model="formDat.self" placeholder="璇烽�夋嫨鑷垂/鍏垂" clearable :style="{width: '100%'}" > <el-option v-for="(item, index) in typeOptions" :key="index" :label="item.label" :value="item.value" @@ -211,6 +210,7 @@ <el-form-item label="澶囨敞" prop="remark"> <el-input v-model="formDat.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" ></el-input> </el-form-item> + <h4 class="form-header">鐩稿叧鍥剧墖 </h4> <el-upload @@ -269,6 +269,34 @@ </el-upload> </el-form> + <el-form ref="elForm1" :model="formDat1" :rules="rules1" size="medium" label-width="100px"> + <h4 class="form-header">璐圭敤鏄庣粏 </h4> + <el-form-item label="鍐呭" prop="content"> + <el-input v-model="formDat1.content" placeholder="璇疯緭鍏ュ唴瀹�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="浣忓璐圭敤" prop="stay"> + <el-input v-model="formDat1.stay" placeholder="璇疯緭鍏ヤ綇瀹胯垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="浜ら�氳垂鐢�" prop="traffic"> + <el-input v-model="formDat1.traffic" placeholder="璇疯緭鍏ヤ氦閫氳垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="椁愯垂" prop="eat"> + <el-input v-model="formDat1.eat" placeholder="璇疯緭鍏ラ璐圭敤" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="璐墿璐圭敤" prop="shopping"> + <el-input v-model="formDat1.shopping" placeholder="璇疯緭鍏ヨ喘鐗╄垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="闂ㄧエ璐圭敤" prop="entrance"> + <el-input v-model="formDat1.entrance" placeholder="璇疯緭鍏ラ棬绁ㄨ垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + + </el-form> <h4 class="form-header"> </h4> <div slot="footer" class="dialog-footer"> @@ -292,7 +320,7 @@ //鍦╯ystem/note/index.js涓鍏ユ帴鍙e嚱鏁� --鎺ュソ浜� -import {addTravelBase,listTravelBase,enload,delTravelBase, uploadPic} from "@/api/travel/index"; +import {addTravelBase,listTravelPrice,getTravelBaseInfo,listTravelBase,enload,delTravelBase, uploadPic,updateTravelPrice} from "@/api/travel/index"; export default { name: "Role", @@ -315,6 +343,7 @@ total: 0, // 瀹跺ぇ浜嬭琛ㄦ牸鏁版嵁 travelBase: [], + detailList:[], // 寮瑰嚭灞傛爣棰� title: "", // 鏄惁鏄剧ず寮瑰嚭灞� @@ -347,6 +376,18 @@ self: undefined, remark: undefined, url: undefined, + }, + formDat1: { + eat: undefined, + stay: undefined, + traffic: undefined, + entrance: undefined, + shopping:undefined, + content: undefined, + }, + formDat2: { + id: undefined, + detailList: undefined, }, // 鑿滃崟鍒楄〃 menuOptions: [], @@ -413,6 +454,40 @@ }], }, + rules1: { + stay: [{ + required: true, + message: '璇疯緭鍏ヤ汉鐗�', + trigger: 'blur' + }], + + content: [{ + required: true, + message: '璇疯緭鍏ュ湴鐐�', + trigger: 'blur' + }], + traffic: [{ + required: true, + message: '璇疯緭鍏ユ爣棰�', + trigger: 'blur' + }], + entrance: [{ + required: true, + message: '璇疯緭鍏ユ梾鏈�', + trigger: 'blur' + }], + eat: [{ + required: true, + message: '璇疯緭鍏ヨ瘉浠�', + trigger: 'blur' + }], + shopping: [{ + required: true, + message: '璇烽�夋嫨鏃ユ湡閫夋嫨', + trigger: 'change' + }], + + }, typeOptions: [ { value: '0', @@ -436,8 +511,9 @@ }, created() { - const id = this.$route.params && this.$route.params.id; + const id = this.$route.params && this.$route.params.id; + this.getList1(); this.getList(id); }, @@ -491,11 +567,30 @@ // alert(123) // console.log(response.data) this.travelBase = response.data.data; - console.log(this.travelBase) + // console.log(this.travelBase) this.total = response.data.total; this.loading = false; } ); + + }, + getList1() { + this.loading = true; + const id = this.$route.params && this.$route.params.id; + return new Promise((resolve, reject) => { + listTravelPrice(this.queryParams).then(response => { + // console.log(response.data.data); + const filteredData = response.data.data.find(item => item.id === id); + this.total = response.data.total; + this.loading = false; + const detailList = filteredData.detailList; + // console.log(detailList); + resolve(detailList); + }).catch(error => { + console.error("璇锋眰閿欒:", error); + reject(error); + }); + }); }, handleRemove(file) { for(let i = 0; i < this.fileListOther.length; i++) @@ -593,7 +688,14 @@ this.dialogVisible = true; }, /** 鎻愪氦鎸夐挳锛堟暟鎹潈闄愶級 */ - submitDataScope: function() { + submitDataScope: async function() { + this.formDat2.detailList = []; + console.log("璋冭瘯"); + console.log(this.formDat2.detailList); + await this.getList1().then(detailList => { + this.formDat2.detailList = detailList; + console.log(this.formDat2.detailList); + }); let ul = this.fileList.map(function (elem){ return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"") @@ -602,6 +704,24 @@ return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"") }).join(",") this.formDat.url = ul+","+uls + const fid = this.$route.params && this.$route.params.id; + this.formDat.feeId = this.$route.params && this.$route.params.id; + this.formDat1.happenTime = this.formDat.happenTime; + this.formDat2.detailList.push(this.formDat1); + this.formDat2.id = this.$route.params && this.$route.params.id; + const stay = parseFloat(this.formDat1.stay); + const traffic = parseFloat(this.formDat1.traffic); + const eat = parseFloat(this.formDat1.eat); + const shopping = parseFloat(this.formDat1.shopping); + const entrance = parseFloat(this.formDat1.entrance); + + const totalPrice = stay + traffic + eat + shopping + entrance; + console.log("鎬昏垂鐢�"); + console.log(totalPrice); + this.formDat.totalPrice=totalPrice; + console.log("111"); + console.log(this.formDat2) + this.$refs["elForm"].validate(valid => { if (valid) { @@ -610,6 +730,18 @@ this.open = false; this.getList(fid); }); + + } + }); + this.$refs["elForm1"].validate(valid => { + if (valid) { + + + updateTravelPrice(this.formDat2).then(response => { + this.$modal.msgSuccess("璐圭敤鏂板鎴愬姛"); + this.open = false; + }); + } }); }, @@ -637,15 +769,95 @@ }, /** 鍒犻櫎鎸夐挳鎿嶄綔 */ - handleDelete(row) { + async handleDelete(row) { const Ids = row.id || this.ids; - this.$modal.confirm('鏄惁纭鍒犻櫎鎵�閫夋暟鎹」锛�').then(function() { - return delTravelBase(Ids); - }).then(() => { - this.getList(); + const id = row.id || this.ids; + + try { + const response = await getTravelBaseInfo(id); + const baseDate = response.data.totalPrice; + console.log("112"); + console.log(baseDate); + + const detailList = await this.getList1(); + this.detailList = detailList; + console.log(this.detailList); + + const targetTotalCost = baseDate; // 鐩爣 totalCost 鍊� + let targetId = null; // 鐩爣鏁版嵁鐨� id + + for (const detail of this.detailList) { + if (detail.totalCost === targetTotalCost) { + targetId = detail.id; + console.log(targetId); + break; + } + } + + const detailList2 = this.detailList.filter((detail) => detail.id !== targetId); + console.log(detailList2); + const formDat3 = {} + formDat3.detailList = detailList2 + const id2 = this.$route.params && this.$route.params.id; + console.log(id2); + formDat3.id = id2; + console.log(formDat3); + await updateTravelPrice(formDat3); + this.open = false; + + await delTravelBase(Ids); + const fid = this.queryParams.fid + this.getList(fid); this.$modal.msgSuccess("鍒犻櫎鎴愬姛"); - }).catch(() => {}); + } catch (error) { + console.error(error); + } }, +// async handleDelete(row) { +// const Ids = row.id || this.ids; +// const id = row.id ||this.ids +// await getTravelBaseInfo(id).then(async (response) => { +// const baseDate = response.data.totalPrice; +// console.log("112"); +// console.log(baseDate); + +// // 鑾峰彇璇︾粏鍒楄〃 +// await this.getList1().then((detailList) => { +// this.detailList = detailList; +// console.log(this.detailList); + +// const targetTotalCost = baseDate; // 鐩爣 totalCost 鍊� +// let targetId = null; // 鐩爣鏁版嵁鐨� id + +// for (const detail of this.detailList) { +// if (detail.totalCost === targetTotalCost) { +// targetId = detail.id; +// console.log(targetId); +// break; +// } +// } +// const detailList2 = [...this.detailList].filter((detail) => { +// return detail.id !== targetId; +// }); +// console.log(detailList2); +// const id2 = this.$route.params && this.$route.params.id; +// console.log(id2); +// detailList2.id = id2 +// console.log(typeof detailList2); +// debugger +// updateTravelPrice(detailList2).then(response => { +// this.open = false; +// }); +// }); +// }); +// this.$modal.confirm('鏄惁纭鍒犻櫎鎵�閫夋暟鎹」锛�').then(function() { +// return delTravelBase(Ids); + +// }).then(() => { +// this.getList(fid); +// this.$modal.msgSuccess("鍒犻櫎鎴愬姛"); +// }).catch(() => {}); +// }, /** 瀵煎嚭鎸夐挳鎿嶄綔 */ handleExport() { const Ids = this.ids; diff --git a/ruoyi-ui/src/views/travel/index.vue b/ruoyi-ui/src/views/travel/index.vue index 8dd1d80..75d4464 100644 --- a/ruoyi-ui/src/views/travel/index.vue +++ b/ruoyi-ui/src/views/travel/index.vue @@ -2,7 +2,7 @@ <div class="app-container" style="opacity: 1;"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"> <h1 style="font-size:21px">瀹岀編鏃呴��</h1> - <el-form-item label="鏃堕棿" prop="startTime"> + <el-form-item label="鏃堕棿" prop="startTime" > <el-date-picker v-model="dateRange" style="width: 240px;" @@ -52,122 +52,187 @@ v-hasPermi="['system:role:remove']" >鍒犻櫎</el-button> </el-col> - <el-col :span="1.5"> - <el-button - type="warning" - plain - icon="el-icon-download" - size="mini" - @click="handleExport" - v-hasPermi="['family:note:export']" - >瀵煎嚭</el-button> - </el-col> - <el-col :span="1.5"> - <el-button - type="warning" - plain - icon="el-icon-download" - size="mini" - @click="handleExportTemplate" - v-hasPermi="['family:note:export']" - >瀵煎叆妯℃澘涓嬭浇</el-button> - </el-col> - <el-col :span="1.2"> - <el-upload - action="" - class="upload-demo" - :show-file-list="false" - :http-request="handleEnport" - > - <el-button size="mini" type="primary" - plain - icon="el-icon-plus" >瀵煎叆</el-button> - </el-upload> - </el-col> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> </el-row> <!-- 搴忓彿銆佸熀閲�/鍙拌处銆佹椂闂淬�佹敹鍏�/鏀嚭銆佺敤閫斻�佷娇鐢ㄤ汉銆佺幇閲�/鑷姩鎵e垝銆佷綑棰濄�佺數瀛愭枃浠躲�佸娉� 鎿嶄綔--> <!-- 杩欓噷鏈変釜familyList鏁扮粍 鏄湪data()涓畾涔夌殑 --> - <el-table v-loading="loading" :data="travelpriceList" @selection-change="handleSelectionChange" @row-click="handleShow" :row-class-name="tableRowClassName" style="background: #FFEFF2; border-radius: 14px 14px 14px 14px;"> - <el-table-column type="selection" width="55" align="center" /> - <el-table-column fixed label="搴忓彿" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="40"/> - <el-table-column label="鏃呮父鍚嶇О" prop="tableName" sortable width="100" /> - <el-table-column label="鏍囬" prop="title" sortable width="100" /> - <el-table-column label="鍘诲悜" prop="destination" sortable width="50" /> + <el-table v-loading="loading" :data="travelpriceList" @row-click="getRowId" @selection-change="handleSelectionChange" :row-class-name="tableRowClassName" style="background: #FFEFF2; border-radius: 14px 14px 14px 14px;"> + <el-table-column type="expand" :cell-class-name="expandRowClassName"> + <template slot-scope="props"> + <div > + <el-table :header-row-class-name="tableHeaderRowClassName" v-loading="loading" :data="travelBase[props.row.id]" style="background: #FFEFF2; border-radius: 14px 14px 14px 14px;" :row-class-name="tableRowClassName1" > + <el-table-column label="搴忓彿" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="50px"/> + + <el-table-column label="鏃堕棿" prop="happenTime" sortable width="100" align="center" > + <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '鈥斺�斺�斺��'}}</template> + </el-table-column> + + <el-table-column label="鍦扮偣" prop="address" sortable width="100" /> + <el-table-column label="浜虹墿" prop="people" sortable width="100" /> + + <el-table-column label="鏍囬" prop="title" sortable width="100" /> + <!-- <el-table-column label="鏃呮湡" prop="travelPeriod" sortable width="100" /> --> + <el-table-column label="鎸佽瘉鏃呮父" prop="certificate" sortable width="100" /> + <el-table-column label="鎬昏垂鐢�" prop="totalPrice" sortable width="100" /> + <el-table-column label="鍏垂/鑷垂" prop="self" sortable width="100" > + <template slot-scope="scope">{{scope.row.self==0?'鍏垂':'鑷垂'}}</template> + </el-table-column> + <el-table-column label="椁愯垂" prop="eat" sortable width="70px" /> + <el-table-column label="浣忓" prop="stay" sortable width="70px" /> + <el-table-column label="浜ら��" prop="traffic" sortable width="70px" /> + <el-table-column label="闂ㄧエ" prop="entrance" sortable width="70px" /> + <el-table-column label="璐墿" prop="shopping" sortable width="70px" /> + <el-table-column label="鐢靛瓙鏂囦欢" prop="url" width="160" > + <template slot-scope="scope" > + <img + class="el-upload-list__item-thumbnail" + src="../../assets/images/deviceLis.png" + alt="" + style="width: 35px; height: 35px;" + fit="cover" + v-if="scope.row.url !== null" + > + <img + class="el-upload-list__item-thumbnail" + src="../../assets/images/deviceA.png" + alt="" + style="width: 35px; height: 35px;" + fit="cover" + v-if="scope.row.url === null" + > + </template> + </el-table-column> + <el-table-column label="澶囨敞" prop="remark" sortable width="100" /> + + + <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width"> + <template slot-scope="scope" v-if="scope.row.roleId !== 1"> + <el-button + size="mini" + type="text" + icon="el-icon-edit" + @click="handleUpdate1(scope.row)" + v-hasPermi="['familymodel:economy:info']" + >淇敼</el-button> + <el-button + size="mini" + type="text" + icon="el-icon-delete" + @click="handleDelete(scope.row)" + v-hasPermi="['system:role:remove']" + >鍒犻櫎</el-button> + <el-button size="mini" type="text" icon="el-icon-d-arrow-right" @click="handleCheck1(scope.row)">鏌ョ湅璇︽儏</el-button> + + </template> + </el-table-column> + </el-table> + </div> + + + </template> + </el-table-column> + <!-- <el-table-column type="selection" width="55" align="center" /> --> + <el-table-column fixed label="搴忓彿" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="60px"/> <el-table-column label="璧�" prop="startTime" sortable width="100" align="center"> <template slot-scope="scope">{{scope.row.startTime? scope.row.startTime: '鈥斺�斺�斺��'}}</template> </el-table-column> <el-table-column label="姝�" prop="endTime" sortable width="100" align="center"> <template slot-scope="scope">{{scope.row.endTime? scope.row.endTime: '鈥斺�斺�斺��'}}</template> </el-table-column> - <el-table-column label="鎬诲ぉ鏁�" prop="totalDay" sortable width="100" /> - + <el-table-column label="鎬诲ぉ鏁�" prop="totalDay" sortable width="85px" /> + <el-table-column label="鏃呮父鍚嶇О" prop="tableName" sortable width="100" /> + <el-table-column label="鏍囬" prop="title" sortable width="130px" /> + <el-table-column label="鍘诲悜" prop="destination" sortable width="70px" /> <el-table-column label="鏃呮父鎬ц川" prop="property" sortable width="100" /> <el-table-column label="鏃呮父鏂瑰紡" prop="type" sortable width="100" /> <el-table-column label="鎬婚噾棰�" prop="totalCost" sortable width="100" /> - <el-table-column label="椁愯垂" prop="eat" sortable width="100" /> - <el-table-column label="浣忓" prop="stay" sortable width="100" /> - <el-table-column label="浜ら��" prop="traffic" sortable width="100" /> - <el-table-column label="闂ㄧエ" prop="entrance" sortable width="100" /> - <el-table-column label="璐墿" prop="shopping" sortable width="80" /> + <el-table-column label="椁愯垂" prop="eat" sortable width="70px" /> + <el-table-column label="浣忓" prop="stay" sortable width="70px" /> + <el-table-column label="浜ら��" prop="traffic" sortable width="70px" /> + <el-table-column label="闂ㄧエ" prop="entrance" sortable width="70px" /> + <el-table-column label="璐墿" prop="shopping" sortable width="70px" /> - <el-table-column label="鎿嶄綔" align="center" sortable width="200" > + <el-table-column fixed label="鎿嶄綔" align="center" sortable width="180" > <template slot-scope="scope" v-if="scope.row.roleId !== 1"> - <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" - v-hasPermi="['familymodel:economy:info']" + v-hasPermi="['person:travel:edit']" >淇敼</el-button> <el-button size="mini" type="text" - class="button_delete" + icon="el-icon-circle-plus" + @click="handleAdd1(scope.row)" + + v-hasPermi="['person:travel:edit']" + >鏂板</el-button> + <el-button + size="mini" + type="text" + icon="el-icon-delete" + @click="handleDelete(scope.row)" v-hasPermi="['system:role:remove']" - > <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn></el-button> - <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['familymodel:economy:info']"> + > 鍒犻櫎</el-button> + <!-- <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['familymodel:economy:info']"> <el-button size="mini" type="text" icon="el-icon-d-arrow-right" @click="handleCheck(scope.row)">鏌ョ湅璇︽儏</el-button> - </el-dropdown> - <el-button class="button" size="mini" type="text" @click="handleShow" v-hasPermi="['system:role:add']"> - <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn> </el-button> + </el-dropdown> --> + <!-- <el-button class="button" size="mini" type="text" @click="handleShow" v-hasPermi="['system:role:add']"> + <sapn v-html="'\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0'"></sapn> </el-button> --> + </template> + </el-table-column> </el-table> + <div style="background-color: #FEF7FC;"> + <el-dialog :title="title" :visible.sync="openDataScope" width="1300px" append-to-body > + <div style="background-color: #FEF7FC;"> + <el-table v-loading="loading" :data="detailList" @selection-change="handleSelectionChange" :row-class-name="tableRowClassName" > + <el-table-column type="selection" width="50" align="center" /> + <el-table-column label="搴忓彿" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="80px"/> + <el-table-column label="鏃堕棿" prop="happenTime" sortable width="150" align="center"> + <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '鈥斺�斺�斺��'}}</template> + </el-table-column> + <el-table-column label="鍐呭" prop="content" sortable :show-overflow-tooltip="true" width="100px" /> + <el-table-column label="鎬婚噾棰�" prop="totalCost" sortable :show-overflow-tooltip="true" width="100px" /> + <el-table-column label="椁愯垂" prop="eat" sortable :show-overflow-tooltip="true" width="100px" /> + <el-table-column label="浣忓" prop="stay" sortable :show-overflow-tooltip="true" width="100px" /> + <el-table-column label="浜ら��" prop="traffic" sortable :show-overflow-tooltip="true" width="100px" /> + <el-table-column label="闂ㄧエ" prop="entrance" sortable :show-overflow-tooltip="true" width="100px" /> + <el-table-column label="璐墿" prop="shopping" sortable :show-overflow-tooltip="true" width="100px" /> - <el-dialog :title="title" :visible.sync="openDataScope" width="1500px" append-to-body > - <div style="background-color: #FEF7FC;"> - <el-table v-loading="loading" :data="detailList" @selection-change="handleSelectionChange" :row-class-name="tableRowClassName" > - <el-table-column type="selection" width="50" align="center" /> - <el-table-column label="搴忓彿" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="150"/> - <el-table-column label="鏃堕棿" prop="happenTime" sortable width="150" align="center"> - <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '鈥斺�斺�斺��'}}</template> - </el-table-column> - <el-table-column label="鍐呭" prop="content" sortable :show-overflow-tooltip="true" width="160" /> - <el-table-column label="鎬婚噾棰�" prop="totalCost" sortable :show-overflow-tooltip="true" width="160" /> - <el-table-column label="椁愯垂" prop="eat" sortable :show-overflow-tooltip="true" width="160" /> - <el-table-column label="浣忓" prop="stay" sortable :show-overflow-tooltip="true" width="160" /> - <el-table-column label="浜ら��" prop="traffic" sortable :show-overflow-tooltip="true" width="150" /> - <el-table-column label="闂ㄧエ" prop="entrance" sortable :show-overflow-tooltip="true" width="150" /> - <el-table-column label="璐墿" prop="shopping" sortable :show-overflow-tooltip="true" width="150" /> + <el-table-column label="鎿嶄綔" align="center" sortable class-name="small-padding fixed-width"> + <template slot-scope="scope" v-if="scope.row.roleId !== 1"> - </el-table> - <pagination - v-show="total>0" - :total="total" - :page.sync="queryParams.pageNum" - :limit.sync="queryParams.pageSize" - @pagination="getList" - style="background: #FEF7FC;" - /> - </div> + <el-button + size="mini" + type="text" + icon="el-icon-edit" + @click="handleUpdate1(scope.row)" + v-hasPermi="['familymodel:economy:info']" + >淇敼</el-button> - </el-dialog> + </template> + </el-table-column> + </el-table> + <pagination + v-show="total>0" + :total="total" + :page.sync="queryParams.pageNum" + :limit.sync="queryParams.pageSize" + @pagination="getList" + style="background: #FEF7FC;" + /> + </div> + + </el-dialog> + </div> <pagination v-show="total>0" :total="total" @@ -179,12 +244,59 @@ <!-- 娣诲姞鎴栦慨鏀硅祫浜т俊鎭厤缃璇濇 --> - <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body> - <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px"> - <el-form-item label="鍙拌处" prop="type"> - <el-input v-model="formDat.type" placeholder="璇疯緭鍏ュ唴瀹�" clearable :style="{width: '100%'}" ></el-input> + <el-dialog :title="title" :visible.sync="dialog1Visible" width="800px" append-to-body> + <el-form ref="elForm2" :model="formDat4" :rules="rules2" size="medium" label-width="100px"> + + <el-form-item label="鏍囬" prop="title"> + <el-input v-model="formDat4.title" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '80%'}" > + </el-input> + </el-form-item> + <el-form-item label="璧峰鏃堕棿" prop="startTime"> + <el-input type="date" v-model="formDat4.startTime" placeholder="璇烽�夋嫨璧峰鏃堕棿" style="width: 80%;"></el-input> + </el-form-item> + <el-form-item label="缁撴潫鏃堕棿" prop="endTime"> + <el-input type="date" v-model="formDat4.endTime" placeholder="璇烽�夋嫨缁撴潫鏃堕棿" style="width: 80%;"></el-input> + </el-form-item> + <el-form-item label="鍘诲悜" prop="destination"> + <el-select v-model="formDat4.destination" placeholder="璇烽�夋嫨鍘诲悜" clearable :style="{width: '80%'}" > + <el-option label="鍥藉唴" value="鍥藉唴"></el-option> + <el-option label="鍥藉" value="鍥藉"></el-option> + </el-select> + </el-form-item> + <el-form-item label="鏃呮父鍚嶇О" prop="tableName"> + <el-input v-model="formDat4.tableName" placeholder="璇疯緭鍏ユ梾娓稿悕绉�" clearable :style="{width: '80%'}" > + </el-input> + </el-form-item> + <el-form-item label="鏃呮父鎬ц川" prop="property"> + <el-select v-model="formDat4.property" placeholder="璇烽�夋嫨鎬ц川" clearable :style="{width: '80%'}" > + <el-option label="鑷垂" value="鑷垂"></el-option> + <el-option label="鍏垂" value="鍏垂"></el-option> + </el-select> + </el-form-item> + <el-form-item label="鏃呮父鏂瑰紡" prop="type"> + <el-select v-model="formDat4.type" placeholder="璇烽�夋嫨鏃呮父鏂瑰紡" clearable :style="{width: '80%'}" > + <el-option label="鑷┚娓�" value="鑷┚娓�"></el-option> + <el-option label="璺熷洟娓�" value="璺熷洟娓�"></el-option> + <el-option label="鑷姪娓�" value="鑷姪娓�"></el-option> + </el-select> </el-form-item> + </el-form> + <h4 class="form-header"> </h4> + + <div slot="footer" class="dialog-footer"> + <el-button type="primary" @click="submitDataScope">纭� 瀹�</el-button> + <el-button @click="cancelData">鍙� 娑�</el-button> + </div> + </el-dialog> + + <el-dialog title="娣诲姞姣忔棩琛岀▼鍐呭" :visible.sync="centerDialogVisible" width="60%" center append-to-body> + <el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px"> + <h4 class="form-header">琛岀▼鍐呭 </h4> + <el-form-item label="鏍囬" prop="title"> + <el-input v-model="formDat.title" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> <el-form-item label="鏃堕棿" prop="happenTime"> <el-input v-model='formDat.happenTime' @@ -192,31 +304,41 @@ placeholder='閫夋嫨鏃ユ湡' ></el-input> </el-form-item> - <el-form-item label="鏀跺叆/鏀嚭" prop="price"> - <el-select v-model="formDat.price" placeholder="璇烽�夋嫨鏀跺叆/鏀嚭" clearable :style="{width: '100%'}" > + <el-form-item label="鍦扮偣" prop="address"> + <el-input v-model="formDat.address" placeholder="璇疯緭鍏ュ湴鐐�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="浜虹墿" prop="people"> + <el-input v-model="formDat.people" placeholder="璇疯緭鍏ヤ汉鐗�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="鏃呮湡" prop="travelPeriod"> + <el-input v-model="formDat.travelPeriod" placeholder="璇疯緭鍏ユ梾鏈�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="鎸佽瘉鏃呮父" prop="certificate"> + <el-select v-model="formDat.certificate" placeholder="璇烽�夋嫨璇佷欢" clearable :style="{width: '80%'}" > + <el-option label="灞呮皯韬唤璇�" value="灞呮皯韬唤璇�"></el-option> + <el-option label="涓存椂韬唤璇�" value="涓存椂韬唤璇�"></el-option> + <el-option label="鎴峰彛鏈�" value="鎴峰彛鏈�"></el-option> + <el-option label="鎶ょ収" value="鎶ょ収"></el-option> + <el-option label="瀛︾敓璇�" value="瀛︾敓璇�"></el-option> + </el-select> + </el-form-item> + <!-- <el-form-item label="璐圭敤" prop="totalPrice"> + <el-input v-model="formDat.totalPrice" placeholder="璇疯緭鍏ユ�诲叡璐圭敤" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> --> + <el-form-item label="鍏垂/鑷垂" prop="self"> + <el-select v-model="formDat.self" placeholder="璇烽�夋嫨鑷垂/鍏垂" clearable :style="{width: '100%'}" > <el-option v-for="(item, index) in typeOptions" :key="index" :label="item.label" :value="item.value" ></el-option> </el-select> </el-form-item> - <el-form-item label="閲戦" prop="balance"> - <el-input v-model="formDat.balance" placeholder="璇疯緭鍏ヤ綑棰�" clearable :style="{width: '100%'}" > - </el-input> - </el-form-item> - <el-form-item label="鐢ㄩ��" prop="useFor"> - <el-input v-model="formDat.useFor" placeholder="璇疯緭鍏ョ敤閫�" clearable :style="{width: '100%'}" > - </el-input> - </el-form-item> - <el-form-item label="浣跨敤浜�" prop="usePeople"> - <el-input v-model="formDat.usePeople" placeholder="璇疯緭鍏ヤ娇鐢ㄤ汉" clearable :style="{width: '100%'}" > - </el-input> - </el-form-item> - <el-form-item label="鏀粯鏂瑰紡" prop="kind"> - <el-input v-model="formDat.kind" placeholder="璇疯緭鍏ユ敮浠樻柟寮�" clearable :style="{width: '100%'}" > - </el-input> - </el-form-item> <el-form-item label="澶囨敞" prop="remark"> <el-input v-model="formDat.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" ></el-input> </el-form-item> + <h4 class="form-header">鐩稿叧鍥剧墖 </h4> <el-upload @@ -275,14 +397,41 @@ </el-upload> </el-form> + <el-form ref="elForm1" :model="formDat1" :rules="rules1" size="medium" label-width="100px"> + <h4 class="form-header">璐圭敤鏄庣粏 </h4> + <el-form-item label="鍐呭" prop="content"> + <el-input v-model="formDat1.content" placeholder="璇疯緭鍏ュ唴瀹�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="浣忓璐圭敤" prop="stay"> + <el-input v-model="formDat1.stay" placeholder="璇疯緭鍏ヤ綇瀹胯垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="浜ら�氳垂鐢�" prop="traffic"> + <el-input v-model="formDat1.traffic" placeholder="璇疯緭鍏ヤ氦閫氳垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="椁愯垂" prop="eat"> + <el-input v-model="formDat1.eat" placeholder="璇疯緭鍏ラ璐圭敤" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="璐墿璐圭敤" prop="shopping"> + <el-input v-model="formDat1.shopping" placeholder="璇疯緭鍏ヨ喘鐗╄垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + <el-form-item label="闂ㄧエ璐圭敤" prop="entrance"> + <el-input v-model="formDat1.entrance" placeholder="璇疯緭鍏ラ棬绁ㄨ垂鐢�" clearable :style="{width: '100%'}" > + </el-input> + </el-form-item> + + </el-form> <h4 class="form-header"> </h4> <div slot="footer" class="dialog-footer"> - <el-button type="primary" @click="submitDataScope">纭� 瀹�</el-button> - <el-button @click="cancelData">鍙� 娑�</el-button> + <el-button type="primary" @click="submitDataScope1">纭� 瀹�</el-button> + <el-button @click="centerDialogVisible = false">鍙� 娑�</el-button> </div> </el-dialog> - </div> </template> @@ -294,7 +443,7 @@ //鍦╯ystem/note/index.js涓鍏ユ帴鍙e嚱鏁� --鎺ュソ浜� -import {listTravelPrice,enload,getTravelPriceInfo,delTravelPrice, addTravelPrice, uploadPic} from "@/api/travel/index"; +import {listTravelPrice,enload,listTravelBase,delTravelPrice, addTravelPrice, uploadPic,updateTravelPrice,addTravelBase} from "@/api/travel/index"; export default { name: "Role", @@ -305,7 +454,6 @@ disabled: false, loading: true, formData:[], - detailList:[], // 閫変腑鏁扮粍 ids: [], // 闈炲崟涓鐢� @@ -316,12 +464,19 @@ showSearch: true, // 鎬绘潯鏁� total: 0, - // 瀹跺ぇ浜嬭琛ㄦ牸鏁版嵁 + // travelpriceList: [], + travelBase:[], + baseData:[], + detailList:[], // 寮瑰嚭灞傛爣棰� title: "", + title1:"", // 鏄惁鏄剧ず寮瑰嚭灞� open: false, + centerDialogVisible: false, + dialog1Visible: false, + dialog2Visible: false, // 鏄惁鏄剧ず寮瑰嚭灞傦紙鏁版嵁鏉冮檺锛� openDataScope: false, menuExpand: false, @@ -340,13 +495,37 @@ dsb:true, btn:false, formDat: { - type: undefined, - createTime: undefined, - useFor: undefined, - usePeople: undefined, - kind:undefined, + people: undefined, + address: undefined, + happenTime: undefined, + title: undefined, + travelPeriod:undefined, + certificate: undefined, + totalPrice: undefined, + self: undefined, remark: undefined, url: undefined, + }, + formDat1: { + eat: undefined, + stay: undefined, + traffic: undefined, + entrance: undefined, + shopping:undefined, + content: undefined, + }, + formDat2: { + id: undefined, + detailList: undefined, + }, + formDat4: { + type: undefined, + startTime: undefined, + title: undefined, + endTime: undefined, + property:undefined, + tableName: undefined, + destination: undefined, detailList:undefined, }, // 鑿滃崟鍒楄〃 @@ -369,53 +548,131 @@ children: "children", label: "label" }, - // 琛ㄥ崟鏍¢獙 + //琛ㄥ崟鏍¢獙 rules: { - usePeople: [{ + people: [{ required: true, - message: '璇疯緭鍏ヤ娇鐢ㄤ汉', + message: '璇疯緭鍏ヤ汉鐗�', trigger: 'blur' }], - useFor: [{ + address: [{ required: true, - message: '璇疯緭鍏ョ敤閫�', + message: '璇疯緭鍏ュ湴鐐�', trigger: 'blur' }], - type: [{ + title: [{ required: true, - message: '璇疯緭鍏ュ彴璐﹀唴瀹�', + message: '璇疯緭鍏ユ爣棰�', trigger: 'blur' }], - balance: [{ + travelPeriod: [{ required: true, - message: '璇疯緭鍏ラ噾棰�', + message: '璇疯緭鍏ユ梾鏈�', trigger: 'blur' }], - kind: [{ - // required: true, - message: '璇疯緭鍏ユ敮浠樻柟寮�', + certificate: [{ + required: true, + message: '璇疯緭鍏ヨ瘉浠�', trigger: 'blur' }], - createTime: [{ + happenTime: [{ required: true, message: '璇烽�夋嫨鏃ユ湡閫夋嫨', trigger: 'change' }], - price: [{ + totalPrice: [{ required: true, - message: '璇烽�夋嫨浜嬮」鍐呭', + message: '璇烽�夋嫨璐圭敤', + trigger: 'blur' + }], + self: [{ + required: true, + message: '璇烽�夋嫨鍏垂/鑷垂', + trigger: 'change' + }], + + }, + rules1: { + stay: [{ + required: true, + message: '璇疯緭鍏ヤ汉鐗�', + trigger: 'blur' + }], + + content: [{ + required: true, + message: '璇疯緭鍏ュ湴鐐�', + trigger: 'blur' + }], + traffic: [{ + required: true, + message: '璇疯緭鍏ユ爣棰�', + trigger: 'blur' + }], + entrance: [{ + required: true, + message: '璇疯緭鍏ユ梾鏈�', + trigger: 'blur' + }], + eat: [{ + required: true, + message: '璇疯緭鍏ヨ瘉浠�', + trigger: 'blur' + }], + shopping: [{ + required: true, + message: '璇烽�夋嫨鏃ユ湡閫夋嫨', + trigger: 'change' + }], + + }, + rules2: { + type: [{ + required: true, + message: '璇疯緭鍏ユ梾娓告柟寮�', + trigger: 'blur' + }], + property: [{ + required: true, + message: '璇疯緭鍏ユ梾娓告�ц川', + trigger: 'change' + }], + destination: [{ + required: true, + message: '璇烽�夋嫨鍘诲悜', + trigger: 'change' + }], + tableName: [{ + required: true, + message: '璇疯緭鍏ユ梾娓稿悕绉�', + trigger: 'blur' + }], + startTime: [{ + required: true, + message: '璇烽�夋嫨鏃ユ湡', + trigger: 'change' + }], + endTime: [{ + required: true, + message: '璇烽�夋嫨鏃ユ湡', + trigger: 'change' + }], + title: [{ + required: true, + message: '璇烽�夋嫨鏍囬', trigger: 'blur' }], }, + typeOptions: [ { - value: '鏀跺叆', - label: '鏀跺叆', + value: '0', + label: '鑷垂', }, { - value: '鏀嚭', - label: '鏀嚭', + value: '1', + label: '鍏垂', }], typeOptions1: [ { @@ -431,27 +688,20 @@ }, created() { this.getList(); - }, methods: { - - //鍩洪噾/鍙拌处鐨勯�夋嫨 - getSrc1(type) { - if (type === 0) { - return '鍩洪噾' - }else { - return '鍙拌处' - } + //灞曞紑琛� + expandRowClassName({ row, rowIndex }) { + // 杩斿洖瀵瑰簲琛岀殑鏍峰紡閰嶇疆瀵硅薄 + return { + 'expand-row': true, // 娣诲姞鑷畾涔夋牱寮忕被鍚� + 'expand-row-height': '40px' // 璁剧疆灞曞紑琛岀殑楂樺害 + }; }, - - getSrc2(kind) { - if (kind == 0) { - return '鐜伴噾' - }else { - return '鑷姩鎵e垝' - } + //棣栬鏍峰紡 + tableHeaderRowClassName() { + return 'custom-header-row'; }, - // 鍙栨秷鎸夐挳 cancelData() { this.open = false; @@ -466,7 +716,14 @@ return "statistics-warning-row"; } }, - + //闅旇鍙樿壊 + tableRowClassName1({ row, rowIndex }) { + if (rowIndex % 2 == 0) { + return "statistics-warning-row3"; + } else { + return "statistics-warning-row2"; + } + }, /** 鏌ヨ瑙掕壊鍒楄〃 */ //鍒楄〃鏄剧ず瀹跺ぇ浜嬭 @@ -478,16 +735,67 @@ // console.log(this.queryParams) // listProperty(this.addDateRange(this.queryParams, this.dateRange)).then(response => { - listTravelPrice(this.queryParams).then(response => { + listTravelPrice(this.queryParams).then(async response => { // alert(123) // console.log(response.data) this.travelpriceList = response.data.data; - console.log(this.travelpriceList[0]) + // const targetId = row.id + // const detailList = filteredData.detailList; + // console.log("detailList" ); + // console.log(detailList); + // resolve(detailList); + // console.log(this.detailList) + // console.log(this.travelpriceList); this.total = response.data.total; + + for (let item of this.travelpriceList) { + this.queryParams.fid = item.id + this.queryParams.happenStartTime = this.dateRange.length > 0 && this.dateRange[0] + this.queryParams.happenEndTime = this.dateRange.length > 0 && this.dateRange[1] + const baseResponse = await listTravelBase(this.queryParams); + const baseData = baseResponse.data.data; + this.$set(this.travelBase, item.id, baseData); + // debugger + this.total = response.data.total; + + for(let item1 of item.detailList){ + console.log(item1); + + const targetDate = item1.happenTime; // 瑕佹煡鎵剧殑鐩爣鏃ユ湡 + // console.log("targetDate" + targetDate); + const keys = Object.keys(baseData); + for (let i = 0; i < keys.length; i++) { + const key = keys[i]; + const baseItem = baseData[key]; + // console.log("baseItem" + baseItem); + if (baseItem.happenTime === targetDate) { + // 鎵惧埌浜嗙鍚堟潯浠剁殑鏁版嵁 + const baseItem = baseData[key]; + delete item1.id; + const mergedItem = { ...baseItem, ...item1 }; + + this.$set(baseData, key, mergedItem); + // console.log(baseData); + + break; + + } + + } + + } + + + } + + // console.log("鎵撳嵃瀹屾瘯"); + this.loading = false; } ); + }, + handleRemove(file) { for(let i = 0; i < this.fileListOther.length; i++) { @@ -504,6 +812,7 @@ getRowId(row) { return row.id + }, // 鍙栨秷鎸夐挳锛堟暟鎹潈闄愶級 cancelDataScope() { @@ -555,20 +864,134 @@ /** 鏂板鎸夐挳鎿嶄綔 */ handleAdd() { this.reset(); - this.open = true; - this.title = "娣诲姞瀹跺涵鏀舵敮鍙拌处"; + this.dialog1Visible = true; + this.dialog2Visible = false; + this.title = "娣诲姞鏃呮父鍐呭"; + }, + /** 鏂板鎸夐挳鎿嶄綔 */ + handleAdd1(row) { + const id = row.id + this.row = row; + this.reset(); + this.centerDialogVisible = true; + this.title1 = "娣诲姞姣忔棩琛岀▼鍐呭"; + }, + /** 鎻愪氦鎸夐挳锛堟暟鎹潈闄愶級 */ + submitDataScope1: async function() { + const id = this.row.id + + this.formDat2.detailList = []; + console.log("璋冭瘯"); + // console.log(this.formDat2.detailList); + // await this.getList().then(detailList => { + // this.formDat2.detailList = detailList; + // console.log(this.formDat2.detailList); + // }); + + // async function getData() { + + // listTravelPrice(this.queryParams).then(async response => { + + // this.travelpriceList = response.data.data; + + // const filteredData = this.travelpriceList.filter(item => item.id === id); + // this.total = response.data.total; + // console.log( filteredData[0].detailList); + + + // // this.formDat2.detailList =filteredData[0].detailList + // this.formDat2.detailList = filteredData[0].detailList; + // // console.log(this.formDat2.detailList ); + // // console.log(this.formDat2.detailList); + // return this.formDat2 + // }).catch(error => { + // console.error("璇锋眰閿欒:", error); + // }); + // } + + async function getData() { + try { + const response = await listTravelPrice(this.queryParams); + this.travelpriceList = response.data.data; + + const filteredData = this.travelpriceList.filter(item => item.id === id); + console.log(filteredData[0].detailList); + this.total = response.data.total; + + return filteredData[0].detailList; + } catch (error) { + console.error("璇锋眰閿欒:", error); + } + } + this.formDat2.detailList = await getData(); // 璋冪敤async鍑芥暟鏉ヨ幏鍙栨暟鎹苟璧嬪�肩粰detailList + + console.log(" this.formDat2.detailList"); + console.log( this.formDat2.detailList); + + + let ul = this.fileList.map(function (elem){ + return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"") + }).join(",") + let uls = this.fileListOther.map(function (elem){ + return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"") + }).join(",") + this.formDat.url = ul+","+uls + // const fid = this.$route.params && this.$route.params.id; + // this.formDat.feeId = this.$route.params && this.$route.params.id; + this.formDat.feeId = id; + this.formDat1.happenTime = this.formDat.happenTime; + this.formDat2.detailList.push(this.formDat1); + this.formDat2.id = id; + const stay = parseFloat(this.formDat1.stay); + const traffic = parseFloat(this.formDat1.traffic); + const eat = parseFloat(this.formDat1.eat); + const shopping = parseFloat(this.formDat1.shopping); + const entrance = parseFloat(this.formDat1.entrance); + + const totalPrice = stay + traffic + eat + shopping + entrance; + console.log("鎬昏垂鐢�"); + console.log(totalPrice); + this.formDat.totalPrice=totalPrice; + + console.log(this.formDat2) + console.log(this.formDat); + + this.$refs["elForm"].validate(valid => { + if (valid) { + + addTravelBase(this.formDat).then(response => { + this.$modal.msgSuccess("鏂板鎴愬姛"); + this.centerDialogVisible = false; + this.getList(); + }); + + } + }); + this.$refs["elForm1"].validate(valid => { + if (valid) { + + + updateTravelPrice(this.formDat2).then(response => { + // this.$modal.msgSuccess("璐圭敤鏂板鎴愬姛"); + this.centerDialogVisible = false; + }); + + } + }); + }, // 寮圭獥 handleShow(row){ const id = row.id; + this.openDataScope = true // this.getList() //alert(123) this.detailList = row.detailList // alert(row.index) - this.title = "灞曠ず璇︽儏"; - + this.title = "姣忔棩璐圭敤璇︽儏"; + this.getList1() }, /** 鏌ョ湅璇︾粏淇℃伅 */ @@ -578,18 +1001,29 @@ // alert(row.fee_id) this.$router.push("/self/travel/Info/" + id); }, + handleCheck1(row){ + const id = row.id; + this.$router.push("/self/travel/travelInfo/" + id); + }, /** 淇敼鎸夐挳鎿嶄綔 */ handleUpdate(row) { - const id = row.id; - // let jd = true - // this.$router.push({ - // path:"/self/travel/edit/" + id, - // query:{ - // detail:jd - // } - // }); + const id = row.id; + // console.log(id); this.$router.push("/self/travel/edit/" + id); + + }, + /** 淇敼鎸夐挳鎿嶄綔 */ + handleUpdate1(row) { + const id = row.id; + let jd = true + + this.$router.push({ + path:"/self/travel/travelInfo/" + id, + query:{ + detail:jd + } + }); }, @@ -600,21 +1034,22 @@ /** 鎻愪氦鎸夐挳锛堟暟鎹潈闄愶級 */ submitDataScope: function() { - let ul = this.fileList.map(function (elem){ - return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"") - }).join(",") - let uls = this.fileListOther.map(function (elem){ - return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"") - }).join(",") - this.formDat.url = ul+","+uls - this.$refs["elForm"].validate(valid => { + this.formDat4.detailList = []; + this.$refs["elForm2"].validate(valid => { if (valid) { - - addEconomy(this.formDat).then(response => { + console.log(this.formDat4); + addTravelPrice(this.formDat4).then(response => { this.$modal.msgSuccess("鏂板鎴愬姛"); - this.open = false; + + this.dialog1Visible = false; this.getList(); }); + // 娓呯┖formDat瀵硅薄鐨勬暟鎹� + Object.keys(this.formDat4).forEach(key => { + this.formDat4[key] = ''; + }); + this.handleRemove(this.fileList[0]); + this.handleRemoveFile(this.fileListOther[0]); } }); }, @@ -702,7 +1137,13 @@ } .el-table__row.statistics-warning-row1 { background: #FFEFF2; +} +.el-table__row.statistics-warning-row2 { + background: #EBFFF2; +} +.el-table__row.statistics-warning-row3 { + background: #f8f8dc; } .button { background: center no-repeat url('../../assets/images/寮圭獥 1.png') ; @@ -713,4 +1154,8 @@ /* margin-left: 66vw; */ } +.custom-header-row { + background-color: #EBAFB4 /* 鏇存敼涓轰綘鎯宠鐨勮儗鏅鑹� */ + /* color: #FFF; 鏇存敼涓轰綘鎯宠鐨勬枃瀛楅鑹� */ +} </style> diff --git a/ruoyi-ui/src/views/travel/travelInfo.vue b/ruoyi-ui/src/views/travel/travelInfo.vue index b5e6904..2b38dcd 100644 --- a/ruoyi-ui/src/views/travel/travelInfo.vue +++ b/ruoyi-ui/src/views/travel/travelInfo.vue @@ -4,61 +4,71 @@ <h4 class="dt h4">鏃呮父缁忓巻璇︾粏淇℃伅 </h4> </div> + <div > + <el-form ref="elForm" :model="formData" :rules="rules" size="medium" label-width="100px" style="width: 60%;"> + <el-form-item label="鍙戠敓鏃堕棿" prop="happenTime"> + <el-input v-model="formData.happenTime" placeholder="璇疯緭鍏ュ彂鐢熸椂闂�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + <el-form-item label="鍦扮偣" prop="address"> + <el-input v-model="formData.address" placeholder="璇疯緭鍏ュ湴鐐�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + <el-form-item label="浜虹墿" prop="people"> + <el-input v-model="formData.people" placeholder="璇疯緭鍏ヤ汉鐗�" clearable :style="{width: '100%'}" :disabled="dsb"> + </el-input> + </el-form-item> + <el-form-item label="鏍囬" prop="title"> + <el-input v-model="formData.title" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> + </el-form-item> + <el-form-item label="鏃呮湡" prop="travelPeriod"> + <el-input v-model="formData.travelPeriod" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> + </el-form-item> + <el-form-item label="鎸佽瘉鏃呮父" prop="certificate"> + <el-select v-model="formData.certificate" placeholder="璇烽�夋嫨璇佷欢" clearable :style="{width: '100%'}" :disabled="dsb"> + <el-option label="灞呮皯韬唤璇�" value="灞呮皯韬唤璇�"></el-option> + <el-option label="涓存椂韬唤璇�" value="涓存椂韬唤璇�"></el-option> + <el-option label="鎴峰彛鏈�" value="鎴峰彛鏈�"></el-option> + <el-option label="鎶ょ収" value="鎶ょ収"></el-option> + <el-option label="瀛︾敓璇�" value="瀛︾敓璇�"></el-option> + </el-select> + </el-form-item> + <el-form-item label="璐圭敤" prop="totalPrice"> + <el-input v-model="formData.totalPrice" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="true"></el-input> + </el-form-item> - <el-form ref="elForm" :model="formData" :rules="rules" size="medium" label-width="100px"> - <el-form-item label="鍙戠敓鏃堕棿" prop="happenTime"> - <el-input v-model="formData.happenTime" placeholder="璇疯緭鍏ュ彂鐢熸椂闂�" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> - </el-form-item> - <el-form-item label="鍦扮偣" prop="address"> - <el-input v-model="formData.address" placeholder="璇疯緭鍏ュ湴鐐�" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> - </el-form-item> - <el-form-item label="浜虹墿" prop="people"> - <el-input v-model="formData.people" placeholder="璇疯緭鍏ヤ汉鐗�" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> - </el-form-item> - <el-form-item label="鏍囬" prop="title"> - <el-input v-model="formData.title" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> - </el-form-item> - <el-form-item label="鏃呮湡" prop="travelPeriod"> - <el-input v-model="formData.travelPeriod" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> - </el-form-item> - <el-form-item label="鎸佽瘉鏃呮父" prop="certificate"> - <el-input v-model="formData.certificate" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> - </el-form-item> - <el-form-item label="璐圭敤" prop="totalPrice"> - <el-input v-model="formData.totalPrice" placeholder="璇疯緭鍏ユ爣棰�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> - </el-form-item> + <el-form-item label="鏄惁鍏垂鏃呮父" prop="self"> + <el-select v-model="formData.self" placeholder="璇烽�夋嫨鏄惁" clearable :style="{width: '100%'}" :disabled="dsb"> + <el-option label="鏄�" value="1"></el-option> + <el-option label="鍚�" value="0"></el-option> + </el-select> + </el-form-item> - <el-form-item label="鏄惁鍏垂鏃呮父" prop="self"> - <el-select v-model="formData.self=== 1 ? '鑷垂':'鍏垂'" placeholder="璇烽�夋嫨淇濇磥/鏀剁撼" clearable :style="{width: '100%'}" :disabled="dsb" ></el-select> - </el-form-item> + <el-form-item label="澶囨敞" prop="remark"> + <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> + </el-form-item> - <el-form-item label="澶囨敞" prop="remark"> - <el-input v-model="formData.remark" placeholder="璇疯緭鍏ュ娉�" clearable :style="{width: '100%'}" :disabled="dsb"></el-input> - </el-form-item> - <h4 class="form-header">鐢靛瓙鏂囦欢 </h4> - <el-upload - action="#" - list-type="picture-card" - multiple - :http-request="requestUpload" - :file-list="fileList" - > - <div v-if="uploading" class="upload-status">姝e湪涓婁紶...</div> - <i v-if="!uploading" slot="default" class="el-icon-plus"></i> - <div slot="file" slot-scope="{file}"> - <img - class="el-upload-list__item-thumbnail" - :src="file.url" - alt="" - style="width: 147px; height: 147px" - fit="cover" - :preview-src-list="[file.url]" - > - <span class="el-upload-list__item-actions"> + <h4 class="form-header">鐢靛瓙鏂囦欢 </h4> + <el-upload + action="#" + list-type="picture-card" + multiple + :http-request="requestUpload" + :file-list="fileList" + > + <div v-if="uploading" class="upload-status">姝e湪涓婁紶...</div> + <i v-if="!uploading" slot="default" class="el-icon-plus"></i> + <div slot="file" slot-scope="{file}"> + <img + class="el-upload-list__item-thumbnail" + :src="file.url" + alt="" + style="width: 147px; height: 147px" + fit="cover" + :preview-src-list="[file.url]" + > + <span class="el-upload-list__item-actions"> <span class="el-upload-list__item-preview" @@ -83,32 +93,32 @@ </span> - </div> - </el-upload> + </div> + </el-upload> - <h4 class="form-header">鍏朵粬闄勪欢 </h4> - <el-upload - action="" - :file-list="fileListOther" - class="upload-demo" - multiple - list-type="picture-card" - :on-preview="handleFileCardPreview" - :on-remove="handleRemoveFile" - :http-request="requestUpload" - :show-file-list="true" - > - <div v-if="uploading" class="upload-status">姝e湪涓婁紶...</div> - <i v-if="!uploading" slot="default" class="el-icon-plus"></i> - <div slot="file" slot-scope="{file}"> - <img - class="el-upload-list__item-thumbnail" - src="../../assets/401_images/401.gif" - alt="" - style="width: 147px; height: 147px" - fit="cover" - > - <span class="el-upload-list__item-actions"> + <h4 class="form-header">鍏朵粬闄勪欢 </h4> + <el-upload + action="" + :file-list="fileListOther" + class="upload-demo" + multiple + list-type="picture-card" + :on-preview="handleFileCardPreview" + :on-remove="handleRemoveFile" + :http-request="requestUpload" + :show-file-list="true" + > + <div v-if="uploading" class="upload-status">姝e湪涓婁紶...</div> + <i v-if="!uploading" slot="default" class="el-icon-plus"></i> + <div slot="file" slot-scope="{file}"> + <img + class="el-upload-list__item-thumbnail" + src="../../assets/401_images/401.gif" + alt="" + style="width: 147px; height: 147px" + fit="cover" + > + <span class="el-upload-list__item-actions"> <span class="el-upload-list__item-preview" @@ -133,16 +143,16 @@ </span> - </div> + </div> - </el-upload> + </el-upload> - <el-form-item size="large"> - <el-button v-if="isShow" type="primary" @click="submitForm" :disabled="dsb">淇敼</el-button> - </el-form-item> - </el-form> - + <el-form-item size="large"> + <el-button v-if="isShow" type="primary" @click="submitForm" :disabled="dsb">淇敼</el-button> + </el-form-item> + </el-form> + </div> <el-dialog :visible.sync="dialogVisible"> <img w-full :src="dialogImageUrl" style="width: 700px; height: 700px" alt="Preview Image" /> </el-dialog> @@ -261,8 +271,6 @@ } this.loading = false; }); - this.getCateInfor() - } }, mounted() {}, @@ -283,6 +291,7 @@ if (valid) { if (this.formData.id != undefined) { updateTravelBase(this.formData).then(response => { + console.log(this.formData); this.$modal.msgSuccess("淇敼鎴愬姛"); // this.open = false; this.btn=false diff --git a/ruoyi-ui/src/views/wish/index.vue b/ruoyi-ui/src/views/wish/index.vue index 66586d9..56627f4 100644 --- a/ruoyi-ui/src/views/wish/index.vue +++ b/ruoyi-ui/src/views/wish/index.vue @@ -290,8 +290,9 @@ <!-- <el-input v-model="formDat.happenTime" placeholder="璇疯緭鍏ヨ幏寰楁椂闂�" clearable :style="{width: '100%'}" ></el-input>--> <!-- </el-form-item>--> <el-form-item label="鏃堕棿" prop="happenTime"> - <el-input v-model="formDat.happenTime" type='date' placeholder='閫夋嫨鏃ユ湡' clearable :style="{width: '100%'}" ></el-input> - </el-form-item> + <el-date-picker v-model="formDat.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" + ></el-date-picker></el-form-item> <el-form-item label="鐞嗘兂鏍囬/鐧惧勾蹇冩効" prop="title"> <el-input v-model="formDat.title" placeholder="璇疯緭鍏ョ悊鎯虫爣棰�/鐧惧勾蹇冩効" clearable :style="{width: '100%'}" > </el-input> diff --git a/ruoyi-ui/src/views/wish/wishInfo.vue b/ruoyi-ui/src/views/wish/wishInfo.vue index 9cbd3f8..95fa711 100644 --- a/ruoyi-ui/src/views/wish/wishInfo.vue +++ b/ruoyi-ui/src/views/wish/wishInfo.vue @@ -17,8 +17,9 @@ <el-row :span="12"> <el-cow > <el-form-item label="鏃堕棿" prop="happenTime" label-width="70px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;"> - <el-input v-model="formData.happenTime" placeholder="璇疯緭鍏ユ椂闂�" type="date" clearable :style="{width: '100%'}" :disabled="dsb"> - </el-input> + <el-date-picker v-model="formData.happenTime" type="date" placeholder="璇烽�夋嫨鏃ユ湡" + :editable="false" :clearable="false" :style="{width: '100%'}" :disabled="dsb" value-format="yyyy-MM-dd" + ></el-date-picker> </el-form-item> <!-- <el-form-item label="鑾峰緱鏃堕棿" prop="happenTime" label-width="78px" style="background: #FAD1E0;border-radius: 7px 7px 7px 7px;opacity: 1;">--> -- Gitblit v1.9.1