From f3425be7724211c186c0bfeea87aa164720dd85f Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期四, 13 十月 2022 17:02:05 +0800
Subject: [PATCH] 1.产能规划页面实现静态部分
---
src/views/scgl/cngh.vue | 603 ++++++++++++++++++++++++++++++++++--------------------
1 files changed, 382 insertions(+), 221 deletions(-)
diff --git a/src/views/scgl/cngh.vue b/src/views/scgl/cngh.vue
index 342b692..e68cff2 100644
--- a/src/views/scgl/cngh.vue
+++ b/src/views/scgl/cngh.vue
@@ -3,8 +3,6 @@
<div class="body" :style="{height:mainHeight+'px'}">
<div class="bodyTopButtonGroup" style="justify-content: space-between">
<el-button type="primary" icon="el-icon-setting" @click="setting('setting')">璁剧疆</el-button>
- <!-- <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>-->
- <!-- <el-button icon="el-icon-download" @click="upload">瀵煎叆</el-button>-->
</div>
<div class="bodyTopFormGroup">
@@ -17,9 +15,13 @@
>
<div class="elForm" style="justify-content: flex-start">
<el-form-item label-width="70px" label="鐢熶骇杞﹂棿" style=" display: flex;">
- <el-select v-model="form.OrgType" style="width: 200px" placeholder="璇烽�夋嫨">
+ <el-select
+ v-model="form.workshop"
+ style="width: 200px"
+ placeholder="璇烽�夋嫨"
+ >
<el-option
- v-for="item in OrgTypeArr"
+ v-for="item in workshopArr"
:key="item.code"
:label="item.name"
:value="item.code"
@@ -27,12 +29,23 @@
</el-select>
</el-form-item>
<el-form-item label="鐢熶骇鍗曞厓" style=" display: flex;">
- <el-input v-model="form.OrgName" placeholder="璇疯緭鍏�" style="width: 200px" />
+ <el-select
+ v-model="form.devicetype"
+ style="width: 200px"
+ placeholder="璇烽�夋嫨"
+ >
+ <el-option
+ v-for="item in devicetypeArr"
+ :key="item.code"
+ :label="item.name"
+ :value="item.code"
+ />
+ </el-select>
</el-form-item>
<el-form-item label="鏈夋晥鐘舵��" style=" display: flex;">
- <el-select v-model="form.OrgType" style="width: 200px" placeholder="璇烽�夋嫨">
+ <el-select v-model="form.stustype" style="width: 200px" placeholder="璇烽�夋嫨">
<el-option
- v-for="item in OrgTypeArr"
+ v-for="item in stustypeArr"
:key="item.code"
:label="item.name"
:value="item.code"
@@ -48,21 +61,7 @@
</el-form>
<div
class="bodyTopFormExpand"
- >
- <!-- <svg-icon-->
- <!-- v-show="mouseHoverType==='mouseout'"-->
- <!-- style="cursor: pointer"-->
- <!-- :icon-class="!isExpandForm?'doubleDown3':'doubleUp3'"-->
- <!-- @mouseenter="mouseHoverType=$event.type"-->
- <!-- />-->
- <!-- <svg-icon-->
- <!-- v-show="mouseHoverType==='mouseenter'"-->
- <!-- style="cursor: pointer"-->
- <!-- :icon-class="!isExpandForm?'doubleDown':'doubleUp'"-->
- <!-- @click="isExpandForm=!isExpandForm"-->
- <!-- @mouseout="mouseHoverType=$event.type"-->
- <!-- />-->
- </div>
+ />
</div>
<div class="elTableDiv">
@@ -80,33 +79,33 @@
@sort-change="sortChange"
>
<el-table-column
- prop="xh"
+ prop="RowNum"
width="50"
fixed
label="搴忓彿"
/>
<el-table-column
- prop="sccj"
+ prop="CaptPlanWorkShop"
label="鐢熶骇杞﹂棿"
sortable="custom"
width="160"
/>
<el-table-column
- prop="scdy"
+ prop="CaptPlanDeviceType"
label="鐢熶骇鍗曞厓"
width="160"
sortable="custom"
/>
<el-table-column
- prop="mrfa"
+ prop="CaptPlanWorkShift"
label="榛樿鏂规"
sortable="custom"
width="240"
>
<template slot-scope="{row}">
- <div style="display: flex;" @click="mrfaSearch(row)">
+ <div style="display: flex;" @click="mrfaSearch(row,'mrfaSearch')">
<el-input
- v-model="row.mrfa"
+ v-model="row.CaptPlanWorkShift"
readonly
/>
<el-button
@@ -118,60 +117,50 @@
</template>
</el-table-column>
<el-table-column
- prop="gzrl"
+ prop="CaptPlanShopCalendarList"
label="宸ヤ綔鏃ュ巻"
sortable="custom"
>
<template slot-scope="{row}">
- <!-- <div style="width: 100%;" @click="gzrlClick(row)">-->
- <!-- <el-input-->
- <!-- v-model="row.gzrl"-->
- <!-- readonly-->
- <!-- />-->
- <!-- </div>-->
- <!-- <div style="width: 100%;" @click="gzrlClick(row)">-->
- <!-- <el-date-picker-->
- <!-- :ref="'datePicker'+row.xh"-->
- <!-- v-model="row.gzrl"-->
- <!-- :class="'datePicker'+row.xh"-->
- <!-- style="width: 100%;"-->
- <!-- type="dates"-->
- <!-- placeholder="璇烽�夋嫨涓�涓垨澶氫釜鏃ユ湡"-->
- <!-- align="left"-->
- <!-- format="yyyy-MM-dd"-->
- <!-- value-format="yyyy-MM-dd"-->
- <!-- :clearable="false"-->
- <!-- :picker-options="pickerOptions"-->
- <!-- @focus="val=>datePickerFocus(val,row)"-->
- <!-- @blur="val=>datePickerBlur(val,row)"-->
- <!-- @change="val=>datePickerChange(val,row)"-->
- <!-- />-->
- <!-- </div>-->
- <!-- <date-picker v-model="row.gzrl"-->
- <!-- :rowData='row'-->
- <!-- :CapacityPlanningSearch='CapacityPlanningSearch'></date-picker>-->
-
+ <date-picker
+ v-model="row.CaptPlanShopCalendarList"
+ :row-data="row"
+ style="width: 100%;"
+ :capacity-planning-search="CapacityPlanningSearch"
+ />
</template>
</el-table-column>
<el-table-column
- prop="czry"
+ prop="CaptPlanUser"
label="鍒涘缓浜哄憳"
sortable="custom"
width="160"
/>
<el-table-column
- prop="czsj"
+ prop="CaptPlanDate"
width="160"
label="鍒涘缓鏃堕棿"
sortable="custom"
/>
<el-table-column
- prop="yxzt"
+ prop="CaptPlanStus"
width="160"
label="鏈夋晥鐘舵��"
sortable="custom"
- />
+ >
+ <template slot-scope="{row}">
+ <div v-if="row.CaptPlanStus==='Y'">
+ <svg-icon icon-class="circleYes" style="margin-right: 2px" />
+ 鏈夋晥
+ </div>
+ <div v-else-if="row.CaptPlanStus==='N'">
+ <svg-icon icon-class="circleNo" style="margin-right: 2px" />
+ 鏃犳晥
+ </div>
+ <div v-else>/</div>
+ </template>
+ </el-table-column>
<!-- <el-table-column-->
<!-- label="鎿嶄綔"-->
@@ -199,33 +188,181 @@
align="right"
layout="total,prev, pager, next,sizes"
popper-class="select_bottom"
- @pagination="getOrganizationSearch"
+ @pagination="getCapacityPlanningSearch"
/>
</div>
- <!-- :title="operation==='add'?'鏂板':'缂栬緫'"-->
<el-dialog
- title="璁剧疆"
+ :title="operation==='setting'?'璁剧疆':'榛樿鏂规'"
:visible.sync="dialogVisible"
- width="800px"
+ width="1280px"
:close-on-click-modal="false"
- top="15vh"
+ top="10vh"
@closed="handleClose"
@close="handleClose"
>
- <el-form ref="dialogForm" inline :rules="dialogFormRules" :model="dialogForm" label-width="80px">
- <el-form-item label="缁勭粐缂栫爜" prop="OrgCode">
- <el-input v-model="dialogForm.OrgCode" :disabled="operation!=='add'" style="width: 200px" />
- </el-form-item>
- <el-form-item label="缁勭粐鍚嶇О" prop="OrgName">
- <el-input v-model="dialogForm.OrgName" style="width: 200px" />
- </el-form-item>
+ <el-button v-if="operation==='setting'" type="primary" @click="addRow">鏂板</el-button>
+ <div class="elTableDiv">
+ <el-table
+ ref="tableDataDialogRef"
+ class="tableFixedDialog"
+ :data="tableDataDialog"
+ :style="{width: 100+'%',height:(tableHeight-200)+'px'}"
+ border
+ :height="(tableHeight-200)+'px'"
+ :row-class-name="tableRowClassName"
+ highlight-current-row
+ :header-cell-style="this.$headerCellStyle"
+ :cell-style="this.$cellStyle"
+ >
- </el-form>
+ <el-table-column
+ v-if="operation!=='setting'"
+ width="50"
+ fixed
+ >
+ <template slot-scope="{row}">
+ <el-radio
+ v-model="radioSelectedId"
+ :label="row.hx"
+ style="padding-left: 10px;"
+ @change.native="getCurrentRowSource(row.hx)"
+ />
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="famc"
+ label="鏂规鍚嶇О"
+ width="150"
+ fixed
+ show-tooltip-when-overflow
+ >
+ <template slot-scope="{row}">
+ <el-input v-model="row.famc" :disabled="row.isVisible===0" type="text" />
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="gzsc"
+ label="宸ヤ綔鏃堕暱"
+ width="100"
+ show-tooltip-when-overflow
+ />
+
+ <el-table-column
+ prop="time1"
+ label="宸ヤ綔鏃堕棿涓�"
+ >
+ <template slot-scope="{row}">
+ <el-time-picker
+ v-model="row.time1"
+ is-range
+ :disabled="row.isVisible===0"
+ :editable="false"
+ :clearable="false"
+ range-separator="~"
+ start-placeholder="寮�濮�"
+ end-placeholder="缁撴潫"
+ format="HH:mm"
+ @focus="val=>getTime(val,row,'time1')"
+ />
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="time2"
+ label="宸ヤ綔鏃堕棿浜�"
+ >
+ <template slot-scope="{row}">
+ <el-time-picker
+ v-model="row.time2"
+ is-range
+ :disabled="row.isVisible===0"
+ :editable="false"
+ :clearable="false"
+ range-separator="~"
+ start-placeholder="寮�濮�"
+ end-placeholder="缁撴潫"
+ format="HH:mm"
+ @focus="val=>getTime(val,row,'time2')"
+ />
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="time3"
+ label="宸ヤ綔鏃堕棿涓�"
+ >
+ <template slot-scope="{row}">
+ <el-time-picker
+ v-model="row.time3"
+ is-range
+ :editable="false"
+ :disabled="row.isVisible===0"
+ :clearable="false"
+ format="HH:mm"
+ range-separator="~"
+ start-placeholder="寮�濮�"
+ end-placeholder="缁撴潫"
+ @focus="val=>getTime(val,row,'time3')"
+ />
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="time4"
+ label="宸ヤ綔鏃堕棿鍥�"
+ >
+ <template slot-scope="{row}">
+ <el-time-picker
+ v-model="row.time4"
+ is-range
+ format="HH:mm"
+ :editable="false"
+ :disabled="row.isVisible===0"
+ :clearable="false"
+ range-separator="~"
+ start-placeholder="寮�濮�"
+ end-placeholder="缁撴潫"
+ @focus="val=>getTime(val,row,'time4')"
+ />
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="time5"
+ label="宸ヤ綔鏃堕棿浜�"
+ >
+ <template slot-scope="{row}">
+ <el-time-picker
+ v-model="row.time5"
+ :disabled="row.isVisible===0"
+ is-range
+ :editable="false"
+ format="HH:mm"
+ :clearable="false"
+ range-separator="~"
+ start-placeholder="寮�濮�"
+ end-placeholder="缁撴潫"
+ @focus="val=>getTime(val,row,'time5')"
+ />
+ </template>
+ </el-table-column>
+ <el-table-column
+ v-if="operation==='setting'"
+ width="100"
+ fixed="right"
+ label="鎿嶄綔"
+ >
+ <template slot-scope="{row}">
+ <div class="operationClass">
+ <el-button v-if="row.isVisible===0" type="text" @click="editRow(row)">缂栬緫</el-button>
+ <el-button v-if="row.isVisible===0" type="text" @click="delRow(row)">鍒犻櫎</el-button>
+ <el-button v-if="row.isVisible===1" type="text" @click="saveRow(row)">淇濆瓨</el-button>
+ </div>
+ </template>
+ </el-table-column>
+ </el-table>
+ </div>
<span slot="footer" class="dialog-footer">
<div class="footerButton">
- <el-button @click="dialogVisibleCancel">鍙� 娑�</el-button>
- <el-button type="primary" @click="dialogVisibleConfirm">纭� 瀹�</el-button>
+ <el-button @click="dialogVisibleCancel">杩� 鍥�</el-button>
+ <el-button v-if="operation!=='setting'" type="primary" @click="dialogVisibleConfirm">纭� 瀹�</el-button>
</div>
</span>
</el-dialog>
@@ -250,11 +387,14 @@
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
import $ from 'jquery'
+import DatePicker from '@/components/DatePicker'
+import { CapacityPlanningSearch } from '@/api/scgl'
+import { DeviceTypeSelect, WorkShopSelect } from '@/api/sbgl'
export default {
name: 'Zzjg',
components: {
- Pagination, ImportPicker
+ Pagination, ImportPicker, DatePicker
},
data() {
return {
@@ -263,73 +403,31 @@
mainHeight: 0,
tableHeight: 0,
form: {
- OrgCode: '', // 缁勭粐鏋舵瀯浠g爜
- OrgName: '', // 缁勭粐鏋舵瀯鍚嶇О
- OrgType: '', // 缁勭粐绫诲瀷
- UserName: '', // 鍒涘缓浜哄憳
- createdate: '',
- prop: 'lm_date', // 鎺掑簭瀛楁
+ workshop: '', // 杞﹂棿缂栫爜
+ devicetype: '', // 鐢熶骇鍗曞厓
+ stustype: '', // 鏈夋晥鐘舵��
+ prop: 'CaptPlanDate', // 鎺掑簭瀛楁
order: 'desc', // 鎺掑簭瀛楁
page: 1, // 绗嚑椤�
rows: 20 // 姣忛〉澶氬皯鏉�
},
- OrgTypeArr: [
- { label: '鏄�', value: 'Y' },
- { label: '鍚�', value: 'N' }
+ stustypeArr: [
+ { name: '鏈夋晥', code: 'Y' },
+ { name: '鏃犳晥', code: 'N' }
],
-
+ workshopArr: [],
+ devicetypeArr: [],
total: 10,
- tableData: [
- {
- xh: 1,
- sccj: '鏈哄姞001',
- scdy: '鏈哄姞浜х嚎C01-L01',
- mrfa: '',
- gzrl: '',
- czry: 'Admin',
- czsj: '2022-10-12 10:00:00',
- yxzt: '鏈夋晥'
- }, {
- xh: 2,
- sccj: '鏈哄姞001',
- scdy: '鏈哄姞浜х嚎C01-L01',
- mrfa: '',
- gzrl: '',
- czry: 'Admin',
- czsj: '2022-10-12 10:00:00',
- yxzt: '鏈夋晥'
- }, {
- xh: 3,
- sccj: '鏈哄姞001',
- scdy: '鏈哄姞浜х嚎C01-L01',
- mrfa: '',
- gzrl: '',
- czry: 'Admin',
- czsj: '2022-10-12 10:00:00',
- yxzt: '鏈夋晥'
- }
- ],
+ tableData: [],
+
dialogVisible: false,
dialogForm: {
- OrgType: '',
- OrgCode: '',
- OrgName: '',
- SupUnit: ''// 涓婄骇鍗曚綅
+ // OrgType: '',
+ // OrgCode: '',
+ // OrgName: '',
+ // SupUnit: ''// 涓婄骇鍗曚綅
},
operation: '',
- dialogFormRules: {
- OrgType: [
- { required: true, message: '璇疯緭鍏ラ�夋嫨绫诲瀷', trigger: ['blur', 'change'] }
- ],
- OrgCode: [
- { required: true, validator: validateCode, trigger: ['blur', 'change'] }
- ],
- OrgName: [
- { required: true, message: '璇疯緭鍏ュ悕绉�', trigger: ['blur', 'change'] }
- ]
-
- },
-
pickerOptions: {
disabledDate(time) {
// return time.getTime() > Date.now(); // 鍙�夊巻鍙插ぉ銆佸彲閫夊綋鍓嶅ぉ銆佷笉鍙�夋湭鏉ュぉ
@@ -339,6 +437,21 @@
}
},
popoverVisible: false,
+ available: null,
+ nextMonth: null,
+
+ tableDataDialog: [
+ // {
+ // famc: '鏂规涓�',
+ // gzsc: '8灏忔椂',
+ // time1: [new Date(2016, 9, 10, 8, 40), new Date(2016, 9, 10, 9, 40)],
+ // time2: '',
+ // time3: '',
+ // time4: '',
+ // time5: ''
+ // }
+ ],
+ radioSelectedId: '',
title_value: '鏁版嵁瀵煎叆 / 鐐规閮ㄤ綅',
code: '4',
@@ -349,84 +462,132 @@
watch: {
shows() {
if (!this.shows) {
- this.getOrganizationSearch()
+ this.getCapacityPlanningSearch()
}
}
},
created() {
- this.getOrganizationSearch()
+
},
mounted() {
window.addEventListener('resize', this.getHeight)
this.getHeight()
+
+ this.handleRequest()
+ // this.getDialogData()
},
methods: {
- async getOrganizationSearch() {
+ getCurrentRowSource() {
},
- mrfaSearch(row) {
+ getDialogData() {
+ let number = Math.random() * Math.random()// 浣滀负鍒犻櫎鏃剁殑鏍囪瘑绗�
+ number = number === 0 ? (10 + Math.random()) : number
+ this.tableDataDialog.push(
+ {
+ hx: 1,
+ famc: '鏂规涓�',
+ gzsc: '8灏忔椂',
+ time1: [],
+ time2: [],
+ time3: [],
+ time4: [],
+ time5: [],
+ number,
+ isVisible: 0
+ }
+ )
+ },
+ getTime(val, row, belong) {
+ const res = this.getDt()
+ if (belong === 'time1') {
+ // row.time1.push(new Date(res.yyyy, res.MM, res.dd, '00', '00'))
+ row.time1 = row.time1.length > 0 ? row.time1 : row.time1.push(new Date())
+ } else if (belong === 'time2') {
+ row.time2 = row.time2.length > 0 ? row.time2 : row.time2.push(new Date())
+ } else if (belong === 'time3') {
+ row.time3 = row.time3.length > 0 ? row.time3 : row.time3.push(new Date())
+ } else if (belong === 'time4') {
+ row.time4 = row.time4.length > 0 ? row.time4 : row.time4.push(new Date())
+ } else if (belong === 'time5') {
+ row.time5 = row.time5.length > 0 ? row.time5 : row.time5.push(new Date())
+ }
+ },
+ getDt() {
+ const dt = new Date()
+
+ const y = dt.getFullYear()
+ const m = (dt.getMonth() + 1 + '').padStart(2, '0')
+ const d = (dt.getDate() + '').padStart(2, '0')
+
+ const hh = (dt.getHours() + '').padStart(2, '0')
+ const mm = (dt.getMinutes() + '').padStart(2, '0')
+ const ss = (dt.getSeconds() + '').padStart(2, '0')
+
+ return { yyyy: y, MM: m, dd: d, hh, mm }
+ },
+ addRow() {
+ this.tableDataDialog.push(
+ {
+ hx: 2,
+ famc: '鏂规xxx',
+ gzsc: '8灏忔椂',
+ time1: [],
+ time2: [],
+ time3: [],
+ time4: [],
+ time5: [],
+ isVisible: 1
+ }
+ )
+ },
+ editRow(row) {
console.log(row)
- this.setting()
+ row.isVisible = 1
},
- gzrlClick(row) {
- console.log(row, 1)
- // console.log($('1'))
+ saveRow(row) {
+ row.isVisible = 0
},
- datePickerChange(val, row) {
- // console.log(this.$refs.datePicker, 8)
- // console.log(val, 2)
+ delRow(row) {
+
},
- datePickerFocus(val, row) {
- const that = this
- // console.log(val, 3)
- // console.log(this.$refs['datePicker' + row.xh], 3333)
- // console.log(val.pickerVisible, 3)
- this.$nextTick(() => {
- // console.log($('.el-date-table'), 9)
- // console.log($('.el-date-table')[0], 9)
- // console.log($('.el-date-table')[0].querySelectorAll('.available'), 9)
- // console.log($('.el-date-table')[0].querySelectorAll('.next-month'), 10)
+ CapacityPlanningSearch() {
- // console.log($('div').wrap($('.el-picker-panel')))
-
- const available = $('.el-date-table')[0].querySelectorAll('.available')
- const nextMonth = $('.el-date-table')[0].querySelectorAll('.next-month')
-
- available.forEach(item => {
- const date = item.querySelectorAll('div>span')[0].innerText
- $(item).bind('dblclick', { date }, function(event) {
- // 闃绘榛樿浜嬩欢
- event.preventDefault()
- // 闃绘浜嬩欢鍐掓场
- event.stopPropagation()
- console.log(event)
- console.log(event.data.date)
- console.log(that.$message.info('鍙屽嚮浜�'))
- // that.setting()
- }, {
- 'mouseenter': function() {
- },
- 'mouseleave': function() {
- }
- })
-
- // $(item).unbind('dblclick').dblclick(e => {
- // // console.log(i, 'i-index', index)
- // console.log(e, 1)
- // })
- })
-
- // this.$refs['datePicker' + row.xh]
- // console.log(this.$refs['datePicker' + row.xh].$children[0], 88)
- // console.log(this.$refs['datePicker' + row.xh].$children[0].nativeInputValue = '2022-10-20', 88)
- // console.log(this.$refs['datePicker' + row.xh].$children[0].nativeInputValue = '2022-10-20', 88)
- // console.log(this.$refs['datePicker' + row.xh].$children[0].value = '2022-10-20', 88)
+ },
+ handleRequest() {
+ this.getCapacityPlanningSearch().then(res => {
+ if (res.code === '200') {
+ this.getWorkShopSelect()
+ this.getDeviceTypeSelect()
+ }
})
},
- datePickerBlur(val, row) {
- console.log(val, 4)
- console.log(val.pickerVisible, 4)
- // val.pickerVisible = true
+ async getCapacityPlanningSearch() {
+ const res = await CapacityPlanningSearch(this.form)
+ this.total = res.count
+ this.tableData = res.data
+ this.tableData.forEach(item => {
+ item.CaptPlanShopCalendarList = item.CaiptPlanShopCalendarList ? item.CaptPlanShopCalendarList : []
+ })
+
+ return { code: res.code }
+ },
+ async getWorkShopSelect() {
+ const { data: res } = await WorkShopSelect()
+ this.workshopArr = res
+ },
+ async getDeviceTypeSelect() {
+ const { data: res } = await DeviceTypeSelect()
+ this.devicetypeArr = res
+ },
+ mrfaSearch(row, operation) {
+ console.log(row)
+ this.operation = operation
+ this.dialogVisible = true
+
+ this.$nextTick(() => {
+ this.$refs.tableDataDialogRef.doLayout()
+ })
},
// 鎺掑簭鏀瑰彉鏃�
sortChange({ column, prop, order }) {
@@ -439,11 +600,11 @@
}
this.form.order = order
this.form.prop = prop
- this.getOrganizationSearch()
+ this.getCapacityPlanningSearch()
},
// 鏌ヨ
search() {
- this.getOrganizationSearch()
+ this.getCapacityPlanningSearch()
},
// 瀵煎叆鎸夐挳
upload() {
@@ -455,15 +616,18 @@
},
// 閲嶇疆
reset() {
- this.form.OrgCode = ''
- this.form.OrgName = ''
- this.form.OrgType = ''
- this.form.UserName = ''
- this.getOrganizationSearch()
+ this.form.workshop = ''
+ this.form.devicetype = ''
+ this.form.stustype = ''
+ this.getCapacityPlanningSearch()
},
setting(operation) {
this.operation = operation
this.dialogVisible = true
+
+ this.$nextTick(() => {
+ this.$refs.tableDataDialogRef.doLayout()
+ })
},
// 鏂板鎸夐挳
add(operation) {
@@ -494,7 +658,7 @@
if (this.form.page > 1 && this.tableData.length === 1) {
this.form.page--
}
- this.getOrganizationSearch()
+ this.getCapacityPlanningSearch()
}
})
}).catch(() => {
@@ -515,25 +679,7 @@
},
// 瀵硅瘽妗嗙‘璁�
dialogVisibleConfirm() {
- this.$refs.dialogForm.validate(valid => {
- if (valid) {
- const data = {
- OrganCode: this.dialogForm.OrgCode,
- OrganName: this.dialogForm.OrgName,
- OperType: this.operation === 'add' ? 'Add' : 'Update',
- Operator: getCookie('admin')
- }
- AddUpdateOrganization(data).then(res => {
- if (res.code === '200') {
- this.$message.success(this.operation === 'add' ? '娣诲姞鎴愬姛锛�' : '淇敼鎴愬姛锛�')
- this.dialogVisible = false
- this.getOrganizationSearch()
- } else {
- this.$message.error(this.operation === 'add' ? '娣诲姞澶辫触锛�' : '淇敼澶辫触锛�')
- }
- })
- }
- })
+ this.dialogVisible = false
},
// 鑾峰彇椤甸潰楂樺害
getHeight() {
@@ -590,7 +736,8 @@
}
::v-deep .el-dialog__body {
- padding: 20px 100px !important;
+ //padding: 20px 100px !important;
+ padding: 20px !important;
}
::v-deep .dialogVisibleRoles .el-dialog__body {
@@ -666,6 +813,20 @@
}
}
+
+.tableFixedDialog {
+ ::v-deep .el-input__icon {
+ line-height: 27px;
+ }
+
+ ::v-deep .el-range-separator {
+ line-height: 27px;
+ }
+
+ ::v-deep .el-radio__label {
+ display: none;
+ }
+}
</style>
<style>
--
Gitblit v1.9.3