From 3072da92f3c3f08b2ee0ca03ee4e74b12f545b0e Mon Sep 17 00:00:00 2001 From: yangdelong <828900aaa> Date: 星期三, 26 五月 2021 21:31:55 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/develop' into develop --- src/components/base-page/enterprise-emergency/PositionChange.vue | 275 +++++++++++++++++++++++++++++++++++++++++++----------- 1 files changed, 217 insertions(+), 58 deletions(-) diff --git a/src/components/base-page/enterprise-emergency/PositionChange.vue b/src/components/base-page/enterprise-emergency/PositionChange.vue index 87943b0..e45dd7d 100644 --- a/src/components/base-page/enterprise-emergency/PositionChange.vue +++ b/src/components/base-page/enterprise-emergency/PositionChange.vue @@ -1,6 +1,6 @@ <template> <div class="side-box map-background" v-show="location"> - <el-tabs v-model="activeName" @tab-click="handleClick"> + <el-tabs v-model="activeName"> <el-tab-pane label="鐐瑰嚮瀹氫綅" name="first"> <div class="click-location"> <el-input v-model="clickLocation"></el-input> @@ -8,41 +8,93 @@ </div> </el-tab-pane> <el-tab-pane label="绠℃瀹氫綅" name="second"> - <div class="line-pos"> - <div class="line-pos-form"> - <el-form :model="linePos" label-width="90px"> - <el-form-item label="绠$嚎鍚嶇О:"> - <el-input v-model="linePos.lineName"></el-input> - </el-form-item> - <el-form-item label="闄勫睘璁炬柦:"> - <el-select v-model="linePos.affFac" placeholder="璇烽�夋嫨娲诲姩鍖哄煙"> - <el-option label="鍖哄煙涓�" value="shanghai"></el-option> - <el-option label="鍖哄煙浜�" value="beijing"></el-option> - </el-select> - </el-form-item> - </el-form> - <el-button type="primary" size="mini">鎼滅储</el-button> - </div> - <el-button type="primary" @click="confirm">纭</el-button> + <div class="place"> + <div class="place-top"> + <!-- <div class="place-left">--> + <el-form :model="linePos" label-width="90px"> + <el-row class="elrow"> + <el-col :span="16"> + <el-form-item label="绠$嚎鍚嶇О:"> + <el-input v-model="linePos.lineName"></el-input> + </el-form-item> + </el-col> + <el-col :span="8" style="vertical-align: middle !important;"> + <el-button type="primary" size="mini" @click="fileChoose">...</el-button> + <el-button type="primary" size="mini" @click="tableAccod">鎼滅储</el-button> + </el-col> + </el-row> + <el-form-item label="闄勫睘璁炬柦:"> + <el-select v-model="linePos.affFac"> + <el-option + v-for="item in linePos.affFacList" + :key="item.value" + :label="item.label" + :value="item.value"> + </el-option> + </el-select> + </el-form-item> + </el-form> + </div> + <div class="place-bottom"> + <el-button type="primary" @click="confirm">纭</el-button> + </div> </div> </el-tab-pane> <el-tab-pane label="缁忕含搴﹀畾浣�" name="third"> - <div class="latlng-location"> - <div class="latlng-location-chose"> - <el-form :model="LongLatPos" label-width="90px"> - <el-form-item label="缁忓害:"> - <el-input v-model="LongLatPos.longPos"></el-input> - </el-form-item> - <el-form-item label="绾害:"> - <el-input v-model="LongLatPos.latPos"></el-input> - </el-form-item> - </el-form> - <el-button type="primary" size="mini">瀹氫綅</el-button> + <div class="place"> + <div class="place-top"> + <div class="place-left"> + <el-form :model="LongLatPos" label-width="90px"> + <el-form-item label="缁忓害:"> + <el-input v-model="LongLatPos.longPos"></el-input> + </el-form-item> + <el-form-item label="绾害:"> + <el-input v-model="LongLatPos.latPos"></el-input> + </el-form-item> + </el-form> + </div> + <div class="place-right"> + <el-button type="primary" size="small">鎼滅储</el-button> + </div> </div> - <el-button type="primary" @click="confirm">纭</el-button> + <div class="place-bottom"> + <el-button type="primary" @click="confirm">纭</el-button> + </div> </div> </el-tab-pane> </el-tabs> + <div class="pipe-table" v-show="pipeTable"> + <el-table + :data="tableData.slice((currentPage-1)*pageSize,currentPage*pageSize)" + border + style="width: 100%"> + <el-table-column + prop="number" + label="搴忓彿"> + </el-table-column> + <el-table-column + prop="seares" + label="鎼滅储缁撴灉"> + </el-table-column> + <el-table-column + prop="restype" + label="缁撴灉绫诲瀷"> + </el-table-column> + </el-table> +<!-- <el-card class="footer-page" v-if="total >= 0">--> + <el-pagination + mini + @size-change="handleSizeChange" + @current-change="handlePage" + :page-size=pageSize + :current-page="currentPage" + layout="prev, pager, next" + :total=total + class="warnPagination" + > + </el-pagination> +<!-- </el-card>--> + </div> </div> </template> @@ -54,8 +106,17 @@ props: ['location'], data () { return { + // 鎺ユ敹鏁版嵁 鎺у埗椤甸潰灞曠ず/闅愯棌 pipelineFile: false, + // active tab鍒囨崲 activeName: 'first', + // 绠℃鏌ヨtable + pipeTable: false, + // 鍒嗛〉鍔熻兘 + pageSize: 3, + total: 0, + currentPage: 1, + // 鐐瑰嚮瀹氫綅缁戝畾鏁版嵁 clickLocation: '', // 缁忕含搴﹀畾浣� LongLatPos: { @@ -65,9 +126,47 @@ // 绠℃瀹氫綅 linePos: { lineName: '', - affFac: '' + affFac: '', + affFacList: [ + { + label: '闃�闂ˋ', + value: '1' + }, + { + label: '闃�闂˙', + value: '2' + } + ] }, - tabLabel: '' + fileChoChange: false, + tableData: [ + { + number: 1, + seares: '20璺洦姘寸绾�', + restype: '绠$嚎鍚嶇О' + }, { + number: 2, + seares: '20璺洦姘寸绾�', + restype: '绠$嚎鍚嶇О' + }, { + number: 3, + seares: '100020', + restype: '绠℃缂栫爜' + }, + { + number: 4, + seares: '20璺洦姘寸绾�', + restype: '绠$嚎鍚嶇О' + }, { + number: 5, + seares: '20璺洦姘寸绾�', + restype: '绠$嚎鍚嶇О' + }, { + number: 6, + seares: '100020', + restype: '绠℃缂栫爜' + } + ] } }, mounted () { @@ -77,16 +176,20 @@ }) }, methods: { - // tab 鍒囨崲鐢ㄤ簬鍒ゆ柇 - handleClick (tab) { - // 鎺у埗绗笁灞傞〉闈� 绠$嚎鍚嶇О/绠℃浠g爜閫夋嫨椤甸潰 - if (tab.label === '绠℃瀹氫綅') { - // 濡傛灉 鏄绾垮畾浣� 鏄剧ず涓夌骇闄勫睘妗� 杩涜閫夋嫨鏂囦欢鎿嶄綔 - eventBus.$emit('pipelineFile-choose', true) - } else { - // eles 涓嶈繘琛屾樉绀� - eventBus.$emit('pipelineFile-choose', false) - } + // 鍒嗛〉鍔熻兘 currentPage 鏀瑰彉鏃朵細瑙﹀彂 + handlePage (val) { + // console.log(val) + this.currentPage = val + }, + // 鍒嗛〉鍔熻兘 pageSize 鏀瑰彉鏃朵細瑙﹀彂 + handleSizeChange (val) { + // console.log(val) + this.pageSize = val + }, + // 鐐瑰嚮鏂囦欢閫夋嫨 鏄剧ず绗笁绾ч〉闈� 杩涜绠$嚎/娈甸�夋嫨 + fileChoose () { + this.fileChoChange = !this.fileChoChange + eventBus.$emit('pipelineFile-choose', this.fileChoChange) }, // 鐐瑰嚮纭鎸夐挳浜嬩欢 confirm () { @@ -94,23 +197,82 @@ this.$emit('localCation', false) // 閫氳繃bus 鎺у埗涓夌骇闄勫睘寮规鐨勯殣钘� eventBus.$emit('pipelineFile-choose', false) + }, + // 绠℃鏌ヨ琛ㄦ牸灞曠ず + tableAccod () { + this.pipeTable = !this.pipeTable } } } </script> <style lang="less" scoped> + /deep/ + .warnPagination { + .btn-quicknext, .btn-quickprev { + color: #e4e8f1 !important; + background-color: transparent; + // border: 1px solid #25AECD; + border-left: 1px solid #25AECD; + border-bottom: 1px solid #25AECD; + border-top: 1px solid #25AECD; + color: #e4e8f1; + } + + .el-pager li { + color: #e4e8f1; + background: transparent; + // border: 1px solid #25AECD; + border-left: 1px solid #25AECD; + border-bottom: 1px solid #25AECD; + border-top: 1px solid #25AECD; + } + + .el-pager li.active { + border-color: #25AECD; + background-color: rgba(38, 222, 253, 0.3); + color: #e4e8f1; + } + + .el-pager li:hover { + border-color: #25AECD; + background-color: rgba(38, 222, 253, 0.3); + color: #34e0ff; + } + + .btn-prev { + background-color: transparent; + // border: 1px solid #25AECD; + border-left: 1px solid #25AECD; + border-bottom: 1px solid #25AECD; + border-top: 1px solid #25AECD; + color: #e4e8f1; + } + + .btn-next { + background-color: transparent; + border: 1px solid #25AECD; + color: #e4e8f1; + } + } + + .elrow { + display: flex; + align-items: center; + justify-content: space-around; + } .side-box { min-width: 1.94532rem; - max-height: 1.343213rem; + max-width: 1.94532rem; } + .click-location { margin: 0 auto; text-align: center; .el-input { - width: 90%; + width: 80%; margin: 15px auto; } @@ -119,28 +281,25 @@ } } - .line-pos { - text-align: center; - .el-input { - width: 85%; - } - .line-pos-form { - display: flex; - } - } - - .latlng-location { + .place { text-align: center; - .latlng-location-chose { + .place-top { display: flex; - align-content: center; + align-items: center; justify-content: space-around; + .place-right { + .el-button { + margin: 15px; + } + } } - .el-input { - width: 85%; + .place-bottom { + .el-button { + margin: 15px; + } } } </style> -- Gitblit v1.8.0