From 55dee1e07a1569f57b38655e175dbda49a0699a8 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期一, 12 八月 2024 11:42:12 +0800
Subject: [PATCH] 样式调整
---
src/views/system/point/index.vue | 49 +++++++++++++++++++++++++++++++++++++++++++------
1 files changed, 43 insertions(+), 6 deletions(-)
diff --git a/src/views/system/point/index.vue b/src/views/system/point/index.vue
index 83c25d0..e39645e 100644
--- a/src/views/system/point/index.vue
+++ b/src/views/system/point/index.vue
@@ -34,13 +34,21 @@
</el-col>
<el-col :span="1.5">
<el-popover>
+ <p>瀵煎叆鐐逛綅鍙仛鏇存柊鎿嶄綔</p>
<div class="bottom_">
- <el-select v-model="importUnitId" size="small" placeholder="杩愮淮鍗曚綅">
+ <el-select @change="getUnitContractTime" v-model="importUnitId" size="small" placeholder="杩愮淮鍗曚綅">
<el-option v-for="unit in unitList" :key="unit.id" :label="unit.value" :value="unit.id"></el-option>
</el-select>
</div>
<div class="bottom_">
+ <el-select @change="showTimeRange" v-model="contractId" size="small" placeholder="杩愮淮鍚堝悓" :disabled="! importUnitId">
+ <el-option v-for="(time, index) in timeList" :key="index" :label="time.name" :value="time.id"></el-option>
+ </el-select>
+ <span style="margin-left: 10px;color: #8a8989" v-show="importUnitId">璇ュ崟浣嶆湁{{timeList.length}}涓悎鍚�</span>
+ </div>
+ <div class="bottom_">
<el-date-picker
+ :disabled="! contractId"
size="small"
v-model="ywTimes"
type="daterange"
@@ -48,6 +56,11 @@
start-placeholder="杩愮淮寮�濮嬫椂闂�"
end-placeholder="杩愮淮缁撴潫鏃堕棿">
</el-date-picker>
+ </div>
+ <div class="bottom_">
+ <el-checkbox v-model="provinceTag">閲嶇偣鐐逛綅</el-checkbox>
+ <el-checkbox v-model="importantTag">鐪佸巺</el-checkbox>
+ <el-checkbox v-model="importantCommandImageTag">閲嶇偣鎸囨尌鍥惧儚</el-checkbox>
</div>
<div class="bottom_">
<el-upload
@@ -70,10 +83,10 @@
<el-button type="primary" size="mini" plain icon="el-icon-top" slot="reference">瀵煎叆鐐逛綅</el-button>
</el-popover>
</el-col>
- <el-col :span="1.5">
- <el-button type="danger" plain icon="el-icon-receiving" size="mini" @click="handleEditBatch"
- v-hasPermi="['point:edit']">鎵归噺淇敼</el-button>
- </el-col>
+<!-- <el-col :span="1.5">-->
+<!-- <el-button type="danger" plain icon="el-icon-receiving" size="mini" @click="handleEditBatch"-->
+<!-- v-hasPermi="['point:edit']">鎵归噺淇敼</el-button>-->
+<!-- </el-col>-->
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
@@ -198,7 +211,7 @@
</template>
<script>
-import { listPoint, getPoint, delPoint, addPoint, batchEdit, updatePoint, exportData, importData } from "@/api/platform/point";
+import { listPoint, getPoint, delPoint, addPoint, batchEdit, updatePoint, exportData, importData, timeRange } from "@/api/platform/point";
import { unitSelect } from "@/api/platform/unit";
import { getCascader } from '@/api/platform/region'
import { cascader } from '@/api/system/dept'
@@ -208,12 +221,17 @@
dicts: ['point_tag'],
data() {
return {
+ importantTag: false,
+ provinceTag: false,
+ importantCommandImageTag: false,
+ timeList: [],
timezone: [],
ywTimes: [],
fileList: [],
importFile: null,
importUrl: '',
importUnitId: null,
+ contractId: null,
download: false,
upload: false,
deptOptions: [],
@@ -287,6 +305,22 @@
this.getDeptCascader();
},
methods: {
+ getUnitContractTime(unitId) {
+ this.ywTimes = []
+ this.contractId = null;
+ timeRange(unitId).then(res => {
+ this.timeList = res.data;
+ })
+ },
+ showTimeRange(contractId) {
+ let a = this.timeList.filter(item => item.id === contractId)
+ if (a.length < 1) {
+ this.ywTimes = []
+ return
+ }
+ let target = a[0]
+ this.ywTimes = [target.startTime, target.endTime]
+ },
beforeUpload(file) {
this.importFile = file
this.fileList = [file]
@@ -303,6 +337,9 @@
formData.append("file", this.importFile)
formData.append("startTime", this.ywTimes[0])
formData.append("endTime", this.ywTimes[1])
+ formData.append("provinceTag", this.provinceTag)
+ formData.append("importantTag", this.importantTag)
+ formData.append("importantCommandImageTag", this.importantCommandImageTag)
importData(formData, this.importUnitId).then(res => {
this.$message.success("瀵煎叆鎴愬姛")
this.upload = false
--
Gitblit v1.8.0