loulijun2021
2022-09-07 ef9633e0d1689fd8869170f3aa0af6c90c2e5e7f
1.优化项目2.搜索栏多行的变为一行可展开
已添加1个文件
已修改32个文件
4072 ■■■■ 文件已修改
src/api/dzkb.js 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/scgl.js 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/styles/global.css 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/global.js 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/jcsz/jsqd.vue 18 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/jcsz/wldw.vue 16 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/jcsz/yhqd.vue 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/jcsz/zzjg.vue 29 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/kb/bzcj.vue 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/kb/dccj.vue 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/kb/zhkb.vue 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/kb/zpcj.vue 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/sbgl/bybw.vue 29 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/sbgl/bybz.vue 40 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/sbgl/djbw.vue 17 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/sbgl/djbz.vue 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/sbgl/sbqd.vue 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/scgl/gd.vue 255 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/scgl/gd_back.vue 2579 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/scgl/gdplgb.vue 523 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/scgl/scdd.vue 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/template.vue 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/wlgl/ckdy.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/wlgl/kwdy.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/xtsz/cjgg.vue 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zlgl/gxjybz.vue 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zlgl/gxjyjl.vue 43 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zlgl/gxjyxm.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zlgl/qxdy.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zzmx/chda.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zzmx/gxdy.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zzmx/gylx.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/zzmx/jpgj.vue 69 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/dzkb.js
@@ -114,3 +114,11 @@
    method: 'get'
  })
}
// è½¦é—´çœ‹æ¿å…¬å‘Š
export function WkspReportNotice(data) {
  return request({
    url: 'KanBanManagerent/WkspReportNotice',
    method: 'post',
    params: data
  })
}
src/api/scgl.js
@@ -227,3 +227,28 @@
    data
  })
}
// MES工单查询
export function MesOrderBitchClosedSearch(data) {
  return request({
    url: 'ProductionManagement/MesOrderBitchClosedSearch',
    method: 'get',
    params: data
  })
}
// MES工单批量关闭提交
export function MesOrderBitchClosedSeave(data) {
  return request({
    url: 'ProductionManagement/MesOrderBitchClosedSeave',
    method: 'post',
    data
  })
}
// MES工单批量反关闭
export function MesOrderBitchAntiClosedSeave(data) {
  return request({
    url: 'ProductionManagement/MesOrderBitchAntiClosedSeave',
    method: 'post',
    data
  })
}
src/styles/global.css
@@ -24,7 +24,7 @@
}
/*头部按钮组样式*/
.bodyTopButtonGroup{
.bodyTopButtonGroup {
  /*padding-left: 10px;*/
  display: flex;
  background-color: #f8f8fa;
@@ -34,9 +34,17 @@
}
/*头部表单组样式*/
.bodyTopFormGroup{
.bodyTopFormGroup {
  background-color: #f8f8fa;
  padding: 10px;
}
.bodyTopFormExpand {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #eee;
  cursor: pointer;
}
.elForm {
@@ -69,10 +77,11 @@
  justify-content: end;
}
.ellipsis{
  text-overflow    :ellipsis;overflow:hidden;white-space:nowrap;
.ellipsis {
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}
/*
src/utils/global.js
@@ -76,5 +76,18 @@
  }
  return items
}
export default clearAllChildren
// æ­£åˆ™è¡¨è¾¾å¼  ç¼–码不能含有中文或特殊字符
const SER_HZ = /^[a-zA-Z0-9_\-;,.<>() ]{0,}$/
export const validateCode = (rule, value, callback) => {
  if (!value) {
    return callback(new Error('请输入编码'))
  } else {
    if (!SER_HZ.test(value)) {
      return callback(new Error('编码不能含有中文或特殊字符'))
    } else {
      callback()
    }
  }
}
src/views/jcsz/jsqd.vue
@@ -277,7 +277,7 @@
          sortable="custom"
        >
          <template slot-scope="{row}">
            <el-input v-if="row.isVisible===1" v-model="row.roletype_code" placeholder="请输入" />
            <el-input v-if="row.isVisible===1" v-model="row.roletype_code" oninput="value=value.replace(/[^0-9a-zA-Z]/g,'')" placeholder="请输入" />
            <div v-else> {{ row.roletype_code }}</div>
          </template>
        </el-table-column>
@@ -581,26 +581,14 @@
} from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import $ from 'jquery'
import clearAllChildren from '@/utils/global'
import clearAllChildren, { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'JSQD',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -637,7 +625,7 @@
      operation: '',
      dialogFormRules: {
        RoleCode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        RoleName: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/jcsz/wldw.vue
@@ -259,25 +259,13 @@
} from '@/api/jcsz'
import { SeaveSearchPartner } from '@/api/ErpSyncMes'
import ImportPicker from '@/components/ImportPicker'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
import { validateCode } from '@/utils/global'
export default {
  name: 'WLDW',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateMobile = (rule, value, callback) => {
      if (!value) {
        callback()
@@ -332,7 +320,7 @@
      operation: '',
      dialogFormRules: {
        unitcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        unitname: [
          { required: true, message: '请输入供方名称', trigger: ['blur', 'change'] }
src/views/jcsz/yhqd.vue
@@ -458,7 +458,7 @@
          sortable="custom"
        >
          <template slot-scope="{row}">
            <el-input v-if="row.isVisible===1" v-model="row.group_code" placeholder="请输入" />
            <el-input v-if="row.isVisible===1" v-model="row.group_code" oninput="value=value.replace(/[^0-9a-zA-Z]/g,'')" placeholder="请输入" />
            <div v-else> {{ row.group_code }}</div>
          </template>
        </el-table-column>
@@ -534,27 +534,15 @@
} from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import $ from 'jquery'
import clearAllChildren from '@/utils/global'
import clearAllChildren, { validateCode } from '@/utils/global'
import { MesOrderStepReportSelectUserGroup } from '@/api/scgl'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'YYQD',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateMobile = (rule, value, callback) => {
      if (!value) {
        callback()
@@ -584,7 +572,6 @@
        }
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -637,7 +624,7 @@
      operation: '',
      dialogFormRules: {
        UserCode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        UserName: [
          { required: true, message: '请输入用户名称', trigger: ['blur', 'change'] }
src/views/jcsz/zzjg.vue
@@ -204,25 +204,27 @@
import Pagination from '@/components/Pagination'
import { AddUpdateOrganization, DeleteOrganization, OrganizationSearch, PrentOrganization } from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
// const SER_HZ = /^[\u4e00-\u9fa5]+$/
// const SER_HZ = /^[a-zA-Z0-9_;,.<>() ]{0,}$/
export default {
  name: 'ZZJG',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    // const validateName = (rule, value, callback) => {
    //   if (!value) {
    //     return callback(new Error('请输入编码'))
    //   } else {
    //     if (!this.$SER_HZ.test(value)) {
    //       return callback(new Error('编码不能含有中文或特殊字符'))
    //     } else {
    //       callback()
    //     }
    //   }
    // }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
@@ -270,7 +272,8 @@
          { required: true, message: '请输入选择类型', trigger: ['blur', 'change'] }
        ],
        OrgCode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          // { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        OrgName: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/kb/bzcj.vue
@@ -287,7 +287,7 @@
  LineSearchBottomRightData,
  LineSearchTopLeftData,
  LineSearchTopRightData, ShopSearch,
  ShopSearchLine
  ShopSearchLine, WkspReportNotice
} from '@/api/dzkb'
import MarqueeTips from 'vue-marquee-tips'
@@ -334,10 +334,25 @@
    },
    // èŽ·å–å…¬å‘Š
    getMarqueeTipsContent() {
      this.MarqueeTipsContent = '各位员工们:根据上级的通知,结合我企实际情况,现将20xx年的元旦放假通知如下:一、1月1日至1月3日放假调休,共3天。1月4日正式上班。二、节假日期间,各班组要严格落实上级的重要指示精神,按照上级的具体要求,认真抓好落实节日期间值班备勤工作,确保节日期间企业各项工作正常运转。xx企业20xxå¹´12月28日'
      const spance = ' '.padStart(this.MarqueeTipsContent.length * 2, ' ')
      this.MarqueeTipsContent = this.MarqueeTipsContent + spance
      this.speed = this.MarqueeTipsContent.length / 10
      WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res => {
        let contentAll = ''
        res.data.forEach(item => {
          contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
        })
        this.MarqueeTipsContent = contentAll
        this.speed = this.MarqueeTipsContent.length / 10
        setInterval(() => {
          WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res1 => {
            let contentAll = ''
            res1.data.forEach(item => {
              contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
            })
            this.MarqueeTipsContent = contentAll
            this.speed = this.MarqueeTipsContent.length / 10
          })
        }, this.speed * 1000)
      })
    },
    // èŽ·å–è½¦é—´ç¼–ç 
    async  getShopSearch() {
src/views/kb/dccj.vue
@@ -287,7 +287,7 @@
  LineSearchBottomRightData,
  LineSearchTopLeftData,
  LineSearchTopRightData, ShopSearch,
  ShopSearchLine
  ShopSearchLine, WkspReportNotice
} from '@/api/dzkb'
import MarqueeTips from 'vue-marquee-tips'
@@ -334,10 +334,25 @@
    },
    // èŽ·å–å…¬å‘Š
    getMarqueeTipsContent() {
      this.MarqueeTipsContent = '各位员工们:根据上级的通知,结合我企实际情况,现将20xx年的元旦放假通知如下:一、1月1日至1月3日放假调休,共3天。1月4日正式上班。二、节假日期间,各班组要严格落实上级的重要指示精神,按照上级的具体要求,认真抓好落实节日期间值班备勤工作,确保节日期间企业各项工作正常运转。xx企业20xxå¹´12月28日'
      const spance = ' '.padStart(this.MarqueeTipsContent.length * 2, ' ')
      this.MarqueeTipsContent = this.MarqueeTipsContent + spance
      this.speed = this.MarqueeTipsContent.length / 10
      WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res => {
        let contentAll = ''
        res.data.forEach(item => {
          contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
        })
        this.MarqueeTipsContent = contentAll
        this.speed = this.MarqueeTipsContent.length / 10
        setInterval(() => {
          WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res1 => {
            let contentAll = ''
            res1.data.forEach(item => {
              contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
            })
            this.MarqueeTipsContent = contentAll
            this.speed = this.MarqueeTipsContent.length / 10
          })
        }, this.speed * 1000)
      })
    },
    // èŽ·å–è½¦é—´ç¼–ç 
    async  getShopSearch() {
src/views/kb/zhkb.vue
@@ -287,7 +287,7 @@
  LineSearchBottomRightData,
  LineSearchTopLeftData,
  LineSearchTopRightData, ShopSearch,
  ShopSearchLine
  ShopSearchLine, WkspReportNotice
} from '@/api/dzkb'
import MarqueeTips from 'vue-marquee-tips'
@@ -331,13 +331,29 @@
      await this.getTableDataRoll()
      await this.getTableDataRankRoll()
      await this.getMarqueeTipsContent()
      await this.getMarqueeTipsContent()
    },
    // èŽ·å–å…¬å‘Š
    getMarqueeTipsContent() {
      this.MarqueeTipsContent = '各位员工们:根据上级的通知,结合我企实际情况,现将20xx年的元旦放假通知如下:一、1月1日至1月3日放假调休,共3天。1月4日正式上班。二、节假日期间,各班组要严格落实上级的重要指示精神,按照上级的具体要求,认真抓好落实节日期间值班备勤工作,确保节日期间企业各项工作正常运转。xx企业20xxå¹´12月28日'
      const spance = ' '.padStart(this.MarqueeTipsContent.length * 2, ' ')
      this.MarqueeTipsContent = this.MarqueeTipsContent + spance
      this.speed = this.MarqueeTipsContent.length / 10
      WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res => {
        let contentAll = ''
        res.data.forEach(item => {
          contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
        })
        this.MarqueeTipsContent = contentAll
        this.speed = this.MarqueeTipsContent.length / 10
        setInterval(() => {
          WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res1 => {
            let contentAll = ''
            res1.data.forEach(item => {
              contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
            })
            this.MarqueeTipsContent = contentAll
            this.speed = this.MarqueeTipsContent.length / 10
          })
        }, this.speed * 1000)
      })
    },
    // èŽ·å–è½¦é—´ç¼–ç 
    async  getShopSearch() {
src/views/kb/zpcj.vue
@@ -287,7 +287,7 @@
  LineSearchBottomRightData,
  LineSearchTopLeftData,
  LineSearchTopRightData, ShopSearch,
  ShopSearchLine
  ShopSearchLine, WkspReportNotice
} from '@/api/dzkb'
import MarqueeTips from 'vue-marquee-tips'
@@ -334,10 +334,25 @@
    },
    // èŽ·å–å…¬å‘Š
    getMarqueeTipsContent() {
      this.MarqueeTipsContent = '各位员工们:根据上级的通知,结合我企实际情况,现将20xx年的元旦放假通知如下:一、1月1日至1月3日放假调休,共3天。1月4日正式上班。二、节假日期间,各班组要严格落实上级的重要指示精神,按照上级的具体要求,认真抓好落实节日期间值班备勤工作,确保节日期间企业各项工作正常运转。xx企业20xxå¹´12月28日'
      const spance = ' '.padStart(this.MarqueeTipsContent.length * 2, ' ')
      this.MarqueeTipsContent = this.MarqueeTipsContent + spance
      this.speed = this.MarqueeTipsContent.length / 10
      WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res => {
        let contentAll = ''
        res.data.forEach(item => {
          contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
        })
        this.MarqueeTipsContent = contentAll
        this.speed = this.MarqueeTipsContent.length / 10
        setInterval(() => {
          WkspReportNotice({ shopcode: this.ShopArr.join(',') }).then(res1 => {
            let contentAll = ''
            res1.data.forEach(item => {
              contentAll += item.contents + ' '.padStart(item.contents.toString().length * 2, ' ')
            })
            this.MarqueeTipsContent = contentAll
            this.speed = this.MarqueeTipsContent.length / 10
          })
        }, this.speed * 1000)
      })
    },
    // èŽ·å–è½¦é—´ç¼–ç 
    async  getShopSearch() {
src/views/sbgl/bybw.vue
@@ -195,36 +195,17 @@
<script>
import Pagination from '@/components/Pagination'
import { AddUpdateOrganization, DeleteOrganization, OrganizationSearch, PrentOrganization } from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import { AddUpdateDeviceMaiItem, DeleteDeviceMaiItem, DeviceCheckItemSearch, DeviceMaiItemSearch } from '@/api/sbgl'
import ImportPicker from '@/components/ImportPicker'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
import { AddUpdateDeviceMaiItem, DeleteDeviceMaiItem, DeviceMaiItemSearch } from '@/api/sbgl'
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -257,7 +238,7 @@
      operation: '',
      dialogFormRules: {
        maiitemcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        maiitemname: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/sbgl/bybz.vue
@@ -387,46 +387,26 @@
<script>
import Pagination from '@/components/Pagination'
import { AddUpdateOrganization, DeleteOrganization, OrganizationSearch, PrentOrganization } from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import ImportPicker from '@/components/ImportPicker'
import {
  AddUpdateDeviceCheckStandArd, AddUpdateDeviceRepairStandArd,
  DeleteDeviceCheckStaned, DeleteDeviceRepairStaned,
  DeviceCheckItemSelect,
  DeviceCheckStandArdSearch,
  DeviceCheckStanedAssociationEqp, DeviceRepairItemSelect,
  DeviceRepairStandArdSearch, DeviceRepairStanedAssociationEqp,
  SaveDeviceCheckStanedAssociationEqp, SaveDeviceRepairStanedAssociationEqp,
  ViewDeviceCheckStanedSearch, ViewDeviceRepairStanedSearch
  AddUpdateDeviceRepairStandArd,
  DeleteDeviceRepairStaned,
  DeviceRepairItemSelect,
  DeviceRepairStandArdSearch,
  DeviceRepairStanedAssociationEqp,
  SaveDeviceRepairStanedAssociationEqp,
  ViewDeviceRepairStanedSearch
} from '@/api/sbgl'
import $ from 'jquery'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -462,7 +442,7 @@
      dialogFormRules: {
        code: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        name: [
          { required: true, message: '请输入标准名称', trigger: ['blur', 'change'] }
src/views/sbgl/djbw.vue
@@ -234,29 +234,16 @@
<script>
import Pagination from '@/components/Pagination'
import { AddUpdateOrganization, DeleteOrganization, OrganizationSearch, PrentOrganization } from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import { AddUpdateDeviceCheckItem, DeleteDeviceCheckItem, DeviceCheckItemSearch } from '@/api/sbgl'
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -294,7 +281,7 @@
      operation: '',
      dialogFormRules: {
        checkitemcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        checkitemname: [
          { required: true, message: '请输入部位名称', trigger: ['blur', 'change'] }
src/views/sbgl/djbz.vue
@@ -429,32 +429,14 @@
  ViewDeviceCheckStanedSearch
} from '@/api/sbgl'
import $ from 'jquery'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -487,7 +469,7 @@
      dialogFormRules: {
        code: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        name: [
          { required: true, message: '请输入标准名称', trigger: ['blur', 'change'] }
src/views/sbgl/sbqd.vue
@@ -67,7 +67,6 @@
                style="width: 200px"
                filterable
                placeholder="请选择"
                @change="deviceTypeChange"
              >
                <!--                @focus="getDeviceTypeSelect"-->
@@ -79,7 +78,7 @@
                />
              </el-select>
            </el-form-item>
            <el-form-item label="设备组" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="设备组" style=" display: flex;">
              <el-select
                v-model="form.DeviceGroup"
                filterable
@@ -103,15 +102,22 @@
          </div>
        </el-form>
      </div>
      <div class="elTableDiv">
      <div
        class="bodyTopFormExpand"
        @click="isExpandForm=!isExpandForm"
      >
        <i
          :class="!isExpandForm?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <div class="elTableDiv" style="margin-top: 0;">
        <el-table
          :data="tableData"
          border
          :height="tableHeight+'px'"
          :height="isExpandForm?tableHeight:(tableHeight+40)+'px'"
          highlight-current-row
          :row-class-name="tableRowClassName"
          :style="{width: 100+'%',height:(tableHeight-50)+'px'}"
          :style="{width: 100+'%',height:isExpandForm?tableHeight:(tableHeight+40)+'px',}"
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
          @sort-change="sortChange"
@@ -397,7 +403,7 @@
          sortable="custom"
        >
          <template slot-scope="{row}">
            <el-input v-if="row.isVisible===1" v-model="row.code" placeholder="请输入" />
            <el-input v-if="row.isVisible===1" v-model="row.code" oninput="value=value.replace(/[^0-9a-zA-Z]/g,'')" placeholder="请输入" />
            <div v-else> {{ row.code }}</div>
          </template>
        </el-table-column>
@@ -487,7 +493,7 @@
          sortable="custom"
        >
          <template slot-scope="{row}">
            <el-input v-if="row.isVisible===1" v-model="row.code" placeholder="请输入" />
            <el-input v-if="row.isVisible===1"v-model="row.code" oninput="value=value.replace(/[^0-9a-zA-Z]/g,'')" placeholder="请输入" />
            <div v-else> {{ row.code }}</div>
          </template>
        </el-table-column>
@@ -580,27 +586,16 @@
  DeviceTypeSelectGroup,
  WorkShopSelect, WorkShopSelectLine
} from '@/api/sbgl'
import { handleDatetime } from '@/utils/global'
import { handleDatetime, validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'SBQD',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      isExpandForm: false,
      mainHeight: 0,
      tableHeight: 0,
      form: {
@@ -642,7 +637,7 @@
      operation: '',
      dialogFormRules: {
        devicecode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        devicename: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
@@ -870,7 +865,7 @@
    getHeight() {
      this.$nextTick(() => {
        this.mainHeight = window.innerHeight - 85
        this.tableHeight = this.mainHeight - 240
        this.tableHeight = this.mainHeight - 250
        // if (window.innerHeight < 769) {
        //   this.tableHeight = this.tableHeight - 50
        // }
src/views/scgl/gd.vue
@@ -57,28 +57,21 @@
                  :label="item.name"
                  :value="item.code"
                />
              </el-select>            </el-form-item>
              </el-select>
            </el-form-item>
            <el-form-item label="产品编码" style=" display: flex;">
              <!--              <el-select v-model="form.partcode" :popper-append-to-body="false" style="width: 200px" placeholder="请选择">-->
              <!--                <el-option-->
              <!--                  v-for="item in OrgTypeArr"-->
              <!--                  :key="item.code"-->
              <!--                  :label="item.name"-->
              <!--                  :value="item.code"-->
              <!--                />-->
              <!--              </el-select>-->
              <el-input v-model="form.partcode" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="产品名称" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="产品名称" style=" display: flex;">
              <el-input v-model="form.partname" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="产品规格" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="产品规格" style=" display: flex;">
              <el-input v-model="form.partspec" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="创建人员" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="创建人员" style=" display: flex;">
              <el-input v-model="form.creatuser" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="创建时间" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="创建时间" style=" display: flex;">
              <!--              <el-date-picker-->
              <!--                v-model="form.createdate"-->
              <!--                type="daterange"-->
@@ -99,7 +92,7 @@
              />
            </el-form-item>
          </div>
          <div style="min-height: 100px">
          <div>
            <div style="display: flex;align-items: start;justify-content:end;margin-top: 5px;z-index: 2">
              <el-button type="primary" icon="el-icon-search" @click="search">查询</el-button>
              <el-button type="info" icon="el-icon-refresh" @click="reset">重置</el-button>
@@ -121,17 +114,27 @@
        </el-form>
      </div>
      <div class="elTableDiv">
      <div
        class="bodyTopFormExpand"
        @click="isExpandForm=!isExpandForm"
      >
        <i
          :class="!isExpandForm?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <div class="elTableDiv" style="margin-top: 0">
        <el-table
          :data="tableData"
          :height="tableHeight+'px'"
          :height="isExpandForm?tableHeight:(tableHeight+40)+'px'"
          border
          :row-class-name="tableRowClassName"
          :style="{width: 100+'%',height:tableHeight+'px',}"
          :style="{width: 100+'%',height:isExpandForm?tableHeight:(tableHeight+40)+'px'}"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
          @sort-change="sortChange"
          @row-click="rowClick"
        >
          <!--          <el-table-column-->
          <!--            type="selection"-->
@@ -240,7 +243,7 @@
            label="工艺路线"
            show-tooltip-when-overflow
            sortable="custom"
            min-width="140"
            width="180"
          >
            <template slot-scope="{row}">
              <div v-if="row.route_name">{{ row.route_name }}</div>
@@ -311,11 +314,16 @@
          >
            <template slot-scope="{row}">
              <div class="operationClass">
                <el-tooltip class="item" effect="dark" content="工序任务" placement="top">
                <el-tooltip class="item" effect="dark" content="打印工单" placement="top">
                  <!--                  <i-->
                  <!--                    class="el-icon-tickets"-->
                  <!--                    style="cursor: pointer;color: #42b983;margin-right: 15px"-->
                  <!--                    @click="check(row)"-->
                  <!--                  />-->
                  <i
                    class="el-icon-tickets"
                    style="cursor: pointer;color: #42b983;margin-right: 15px"
                    @click="check(row)"
                    @click="handlePrint(row.wo_code)"
                  />
                </el-tooltip>
                <el-tooltip v-del-tab-index class="item" effect="dark" content="删除" placement="top">
@@ -336,6 +344,81 @@
        popper-class="select_bottom"
        @pagination="getMesOrderSearch"
      />
      <div class="elTableDiv">
        <el-table
          :data="tableDataDetail"
          border
          height="161px"
          :row-class-name="tableRowClassName"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
        >
          <!--          <el-table-column-->
          <!--            width="50"-->
          <!--            type="index"-->
          <!--            prop="序号"-->
          <!--            fixed-->
          <!--          />   -->
          <el-table-column
            width="50"
            prop="seq"
            label="序号"
            fixed
          />
          <el-table-column
            prop="wo_code"
            label="工单编号"
          />
          <el-table-column
            prop="partcode"
            label="产品编码"
          />
          <el-table-column
            prop="partname"
            label="产品名称"
          />
          <el-table-column
            label="工序编码"
            prop="partcode"
          />
          <el-table-column
            label="工序名称"
            prop="partname"
          />
          <el-table-column
            label="任务数量"
            prop="plan_qty"
          />
          <el-table-column
            label="合格数量"
            prop="good_qty"
          />
          <el-table-column
            label="不良数量"
            prop="ng_qty"
          />
          <el-table-column
            label="操作"
            width="120"
          >
            <template slot-scope="{row}">
              <div class="operationClass">
                <el-tooltip class="item" effect="dark" content="打印工序" placement="top">
                  <i
                    class="el-icon-tickets"
                    style="cursor: pointer;color: #42b983;margin-right: 15px"
                    @click="supplementSmallClick(row)"
                  />
                </el-tooltip>
              </div>
            </template>
          </el-table-column>
        </el-table>
      </div>
    </div>
    <!--新增派发对话框-->
    <el-dialog
@@ -759,20 +842,20 @@
                />
              </el-select>
            </el-form-item>
            <el-form-item v-show="isExpand" label="订单编号" style=" display: flex;">
            <el-form-item v-show="isExpandDialog" label="订单编号" style=" display: flex;">
              <el-input v-model="sourceForm.erpordercode" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item v-show="isExpand" label="产品编码" style=" display: flex;">
            <el-form-item v-show="isExpandDialog" label="产品编码" style=" display: flex;">
              <el-input v-model="sourceForm.partcode" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpand" label="产品名称" style=" display: flex;">
            <el-form-item v-show="isExpandDialog" label="产品名称" style=" display: flex;">
              <el-input v-model="sourceForm.partname" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpand" label="产品规格" style=" display: flex;">
            <el-form-item v-show="isExpandDialog" label="产品规格" style=" display: flex;">
              <el-input v-model="sourceForm.partspec" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpand" label="创建人员" style=" display: flex;">
            <el-form-item v-show="isExpandDialog" label="创建人员" style=" display: flex;">
              <el-input v-model="sourceForm.creatuser" style="width: 200px" placeholder="请输入" />
            </el-form-item>
@@ -785,14 +868,14 @@
          </div>
        </el-form>
      </div>
      <!--      <el-tooltip  :content="!isExpand?'点击展示更多':'收起'" placement="bottom">-->
      <!--      <el-tooltip  :content="!isExpandDialog?'点击展示更多':'收起'" placement="bottom">-->
      <div
        style="display:flex;justify-content: center;
          align-items:center;background-color:#eee;cursor: pointer"
        @click="isExpand=!isExpand"
        @click="isExpandDialog=!isExpandDialog"
      >
        <i
          :class="!isExpand?'el-icon-arrow-down':'el-icon-arrow-up'"
          :class="!isExpandDialog?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <!--      </el-tooltip>-->
@@ -997,36 +1080,36 @@
            <el-form
              ref="formApprove"
              :model="formApprove"
              label-width="100px"
              label-width="80px"
              inline
              style="display: flex;justify-content: space-between"
            >
              <div class="elForm">
                <el-form-item label="工单编号:" class="formContent">
                <el-form-item label="工单编号:" class="formContent">
                  {{ formApprove.mesordercode }}
                </el-form-item>
                <el-form-item label="源单单号:" class="formContent">
                <el-form-item label="源单单号:" class="formContent">
                  {{ formApprove.m_po }}
                </el-form-item>
                <el-form-item label="产品编码:" class="formContent">
                <el-form-item label="产品编码:" class="formContent">
                  {{ formApprove.partcode }}
                </el-form-item>
                <el-form-item label="产品名称:" class="formContent">
                <el-form-item label="产品名称:" class="formContent">
                  {{ formApprove.partname }}
                </el-form-item>
                <el-form-item label="产品规格:" class="formContent">
                <el-form-item label="产品规格:" class="formContent">
                  {{ formApprove.partspec }}
                </el-form-item>
                <el-form-item label="工单数量:" class="formContent">
                <el-form-item label="工单数量:" class="formContent">
                  {{ formApprove.plan_qty }}
                </el-form-item>
                <el-form-item label="工艺路线:" class="formContent">
                <el-form-item label="工艺路线:" class="formContent">
                  {{ formApprove.routename }}
                </el-form-item>
                <el-form-item label="打印人员:" class="formContent">
                <el-form-item label="打印人员:" class="formContent">
                  {{ username }}
                </el-form-item>
                <el-form-item label="打印时间:" class="formContent">
                <el-form-item label="打印时间:" class="formContent">
                  {{ formApprove.lm_date }}
                </el-form-item>
              </div>
@@ -1295,8 +1378,14 @@
            fixed="right"
          >
            <template slot-scope="{row}">
              <div v-if="row.enable==='Y'"><svg-icon icon-class="circleYes" style="margin-right: 2px" />是</div>
              <div v-if="row.enable==='N'"><svg-icon icon-class="circleNo" style="margin-right: 2px" />否</div>
              <div v-if="row.enable==='Y'">
                <svg-icon icon-class="circleYes" style="margin-right: 2px" />
                æ˜¯
              </div>
              <div v-if="row.enable==='N'">
                <svg-icon icon-class="circleNo" style="margin-right: 2px" />
                å¦
              </div>
            </template>
          </el-table-column>
        </el-table>
@@ -1322,31 +1411,19 @@
  SelectRouteStep
} from '@/api/scgl'
import { InventoryFileAssociationRoute, PartSelect, SaveInventoryFile } from '@/api/zzmx'
import { handleDatetime, handleDatetime2 } from '@/utils/global'
import { handleDatetime, handleDatetime2, validateCode } from '@/utils/global'
import { getCookie } from '@/utils/auth'
import { MesOrderPrintSearch1, PrintOrder } from '@/api/utils'
import { urlAddRandomNo, webapp_ws_ajax_run, webapp_ws_autoupdate } from '@/utils/grwebapp'
import QRCode from 'qrcodejs2'
import $ from 'jquery'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'GD',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -1422,7 +1499,7 @@
          { required: true, message: '请选择产品信息', trigger: ['blur', 'change'] }
        ],
        mesordercode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        mesqty: [
          { required: true, message: '请输入工单数量', trigger: ['blur', 'change'] }
@@ -1535,7 +1612,7 @@
      },
      sourceFormTotal: 10,
      radioSelectedId: '',
      isExpand: false, // æ˜¯å¦å¼ å¼€ï¼Œé»˜è®¤ä¸å±•å¼€
      isExpandDialog: false, // å¯¹è¯æ¡†è¡¨å•是否展开,默认不展开
      dialogVisibleRoute: false,
      dialogFormRoute: {
        projectName: '', // äº§å“åç§°
@@ -1544,7 +1621,9 @@
      },
      defaultroute_code: '', // é»˜è®¤å·¥è‰ºè·¯çº¿é€‰ä¸­å€¼
      defaultroute_codeArr: '', // é»˜è®¤å·¥è‰ºè·¯çº¿æ•°ç»„
      projectTableData: []// è®¾å¤‡åˆ—表
      projectTableData: [], // è®¾å¤‡åˆ—表
      isExpandForm: false, // è¡¨å•是否展开,默认不展开
      tableDataDetail: []// ç‚¹å‡»å·¥å•表的行 æ˜¾ç¤ºè¯¦ç»†ä¿¡æ¯
    }
  },
  created() {
@@ -1910,7 +1989,8 @@
    getHeight() {
      this.$nextTick(() => {
        this.mainHeight = window.innerHeight - 85
        this.tableHeight = this.mainHeight - 260
        // this.tableHeight = this.mainHeight - 250
        this.tableHeight = this.mainHeight - 420
        if (window.innerHeight < 769) {
          this.tableHeight = this.tableHeight - 20
        }
@@ -1930,14 +2010,14 @@
      this.dialogVisibleSearch = false
    },
    // å¤„理打印
    handlePrint() {
    handlePrint(wo_code) {
      // const number = Math.random() * Math.random()
      // this.number = number === 0 ? (10 + Math.random()) : number
      // console.log(number)
      const data2 = {
        username: getCookie('admin'),
        mesordercode: this.dialogForm.mesordercode
        mesordercode: wo_code || this.dialogForm.mesordercode
      }
      MesOrderPrintSearch1(data2).then(res2 => {
        if (res2.code === '200') {
@@ -2043,17 +2123,21 @@
    // è¡¥æ‰“小标签
    supplementSmallClick(row) {
      // let obj = {}
      this.taskTableData.forEach((item, index) => {
      console.log(row, 21)
      // this.taskTableData.forEach((item, index) => {
      this.tableDataDetail.forEach((item, index) => {
        if (item.seq === row.seq) {
          console.log(item)
          this.qrForm = {
            qrvalue: item.seq === this.taskTableData.length ? item.wo_code + ';' + item.stepcode : item.wo_code + ';' + this.taskTableData[item.seq].stepcode,
            startqty: item.seq === this.taskTableData.length ? item.plan_qty : this.taskTableData[item.seq].plan_qty,
            // qrvalue: item.seq === this.taskTableData.length ? item.wo_code + ';' + item.stepcode : item.wo_code + ';' + this.taskTableData[item.seq].stepcode,
            qrvalue: item.seq === this.tableDataDetail.length ? item.wo_code + ';' + item.stepcode : item.wo_code + ';' + this.tableDataDetail[item.seq].stepcode,
            // startqty: item.seq === this.taskTableData.length ? item.plan_qty : this.taskTableData[item.seq].plan_qty,
            startqty: item.seq === this.tableDataDetail.length ? item.plan_qty : this.tableDataDetail[item.seq].plan_qty,
            wo_code: item.wo_code,
            partcode: item.partcode,
            partname: item.partname,
            nextstepname: item.seq === this.taskTableData.length ? item.stepname : this.taskTableData[item.seq].stepname,
            // nextstepname: item.seq === this.taskTableData.length ? item.stepname : this.taskTableData[item.seq].stepname,
            nextstepname: item.seq === this.tableDataDetail.length ? item.stepname : this.tableDataDetail[item.seq].stepname,
            operator: getCookie('username'),
            operatorTime: handleDatetime2(new Date())
          }
@@ -2100,7 +2184,7 @@
      this.dialogVisibleSource = true
    },
    async   getErpOrderSearch() {
    async getErpOrderSearch() {
      let tempDate2 = this.sourceForm.paystartdate
      if (tempDate2.length > 0) {
        tempDate2 = handleDatetime(tempDate2[0]) + '~' + handleDatetime(tempDate2[1])
@@ -2164,7 +2248,7 @@
      this.sourceForm.creatuser = ''
      this.sourceForm.createdate = ''
      this.isExpand = false
      this.isExpandDialog = false
      this.sourceTableData = []
    },
    dialogVisibleSourceBack() {
@@ -2273,6 +2357,17 @@
        this.defaultroute_code = ''
      }
      this.defaultroute_codeArr = this.dialogFormRoute.routeOperationArr.filter(item => item.isSelected2)
    },
    //  è¡Œç‚¹å‡»äº‹ä»¶
    async   rowClick(row, event, column) {
      console.log(row, event, column)
      console.log(row.wo_code, event, column)
      const { data: res } = await SearchWorkStep({ wo_code: row.wo_code })
      this.tableDataDetail = res
    },
    // æ‰“印工单
    printOrder() {
    }
  }
}
@@ -2339,17 +2434,20 @@
    }
  }
}
.dialogVisibleRoute {
  ::v-deep .el-dialog__body {
    padding: 20px 20px !important;
  }
}
.defaultroute_code ::v-deep .el-input__suffix-inner{
.defaultroute_code ::v-deep .el-input__suffix-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -3px;
}
.el-date-editor {
  font-size: 14px;
}
@@ -2396,9 +2494,10 @@
}
//.elTableDiv {
  ::v-deep .el-radio__label {
    display: none;
  }
::v-deep .el-radio__label {
  display: none;
}
//}
.el-table::before {
@@ -2439,19 +2538,23 @@
<style lang="scss" scoped>
$main_color: #42b983;
::v-deep  .el-range-input{
::v-deep .el-range-input {
  font-size: 14px !important;
}
::v-deep .el-range__icon{
::v-deep .el-range__icon {
  line-height: 28px !important;
}
::v-deep .el-range-separator{
::v-deep .el-range-separator {
  line-height: 28px !important;
}
::v-deep .el-range-input{
  font-size: 14px ;
::v-deep .el-range-input {
  font-size: 14px;
}
::v-deep .el-range-separator{
::v-deep .el-range-separator {
  display: flex;
  justify-content: center;
  align-items: center;
src/views/scgl/gd_back.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,2579 @@
<template>
  <div>
    <div class="body" :style="{height:mainHeight+'px'}">
      <div class="bodyTopButtonGroup" style="justify-content: space-between">
        <div style="display: flex">
          <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">新增</el-button>
          <el-button type="primary" icon="el-icon-connection" @click="send('send')">派发</el-button>
        </div>
        <el-button icon="el-icon-switch-button" @click="orderClose">关闭工单</el-button>
      </div>
      <div class="bodyTopFormGroup">
        <el-form
          ref="form"
          :model="form"
          label-width="80px"
          inline
          style="display: flex;justify-content: space-between"
        >
          <div class="elForm">
            <el-form-item label="订单状态" style=" display: flex;">
              <el-select
                v-model="form.mesorderstus"
                :popper-append-to-body="false"
                style="width: 200px"
                placeholder="请选择"
                filterable
                @change="erporderstusChange"
              >
                <el-option
                  v-for="item in erporderstusArr"
                  :key="item.code"
                  :label="item.name"
                  :value="item.code"
                />
              </el-select>
            </el-form-item>
            <el-form-item label="订单编号" style=" display: flex;">
              <el-input v-model="form.mesordercode" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item label="源单单号" style="display: flex;">
              <el-input v-model="form.sourceorder" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="单据类型" style=" display: flex;">
              <el-select
                v-model="form.ordertype"
                :popper-append-to-body="false"
                style="width: 200px"
                placeholder="请选择"
              >
                <!--            @change="mesordertypeChange"-->
                <el-option
                  v-for="item in ordertypeArr"
                  :key="item.code"
                  :label="item.name"
                  :value="item.code"
                />
              </el-select>
            </el-form-item>
            <el-form-item label="产品编码" style=" display: flex;">
              <el-input v-model="form.partcode" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandForm" label="产品名称" style=" display: flex;">
              <el-input v-model="form.partname" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandForm" label="产品规格" style=" display: flex;">
              <el-input v-model="form.partspec" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandForm" label="创建人员" style=" display: flex;">
              <el-input v-model="form.creatuser" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandForm" label="创建时间" style=" display: flex;">
              <!--              <el-date-picker-->
              <!--                v-model="form.createdate"-->
              <!--                type="daterange"-->
              <!--                :clearable="false"-->
              <!--                range-separator="~"-->
              <!--                start-placeholder="开始日期"-->
              <!--                end-placeholder="结束日期"-->
              <!--                size="mini"-->
              <!--              />-->
              <el-date-picker
                v-model="form.createdate"
                type="date"
                size="mini"
                :clearable="false"
                class="dateMini"
                format="yyyy-MM-dd"
                placeholder="选择日期"
              />
            </el-form-item>
          </div>
          <div>
            <div style="display: flex;align-items: start;justify-content:end;margin-top: 5px;z-index: 2">
              <el-button type="primary" icon="el-icon-search" @click="search">查询</el-button>
              <el-button type="info" icon="el-icon-refresh" @click="reset">重置</el-button>
            </div>
            <!--            <div v-if="!isIpad" style="display: flex;align-items: start; margin-top: 15px;z-index: 2">-->
            <!--              <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">新增</el-button>-->
            <!--              <el-button type="primary" icon="el-icon-connection" @click="send('send')">派发</el-button>-->
            <!--              <el-button type="primary" icon="el-icon-switch-button">订单关闭</el-button>-->
            <!--            </div>-->
            <!--            <div v-if="isIpad" style="display: flex;flex-direction: column;align-items: end">-->
            <!--              <div style="display: flex;margin: 10px 0">-->
            <!--                <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">新增</el-button>-->
            <!--                <el-button type="primary" icon="el-icon-connection" @click="send('send')">派发</el-button>-->
            <!--              </div>-->
            <!--              <el-button type="primary" icon="el-icon-switch-button">订单关闭</el-button>-->
            <!--            </div>-->
          </div>
        </el-form>
      </div>
      <div
        class="bodyTopFormExpand"
        @click="isExpandForm=!isExpandForm"
      >
        <i
          :class="!isExpandForm?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <div class="elTableDiv" style="margin-top: 0">
        <el-table
          :data="tableData"
          :height="isExpandForm?tableHeight:(tableHeight+40)+'px'"
          border
          :row-class-name="tableRowClassName"
          :style="{width: 100+'%',height:isExpandForm?tableHeight:(tableHeight+40)+'px',}"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
          @sort-change="sortChange"
        >
          <!--          <el-table-column-->
          <!--            type="selection"-->
          <!--            width="50"-->
          <!--          />-->
          <el-table-column
            width="50"
            fixed
          >
            <template slot-scope="{row}">
              <el-radio
                v-model="radioSelected"
                :label="row.wo_code"
                style="color: transparent;padding-left: 10px;"
                @change.native="getCurrentRow(row.wo_code)"
              />
            </template>
          </el-table-column>
          <el-table-column
            prop="RowNum"
            width="50"
            label="序号"
            fixed
          />
          <el-table-column
            prop="status"
            label="订单状态"
            sortable="custom"
            width="110"
          >
            <template slot-scope="{row}">
              <div v-if="row.status==='NEW'">新工单</div>
              <!--              <div v-if="row.status==='CREATING'">执行中</div>-->
              <!--              <div v-if="row.status==='CREATED'">已关闭</div>-->
              <div v-if="row.status==='ALLO'">已派发</div>
              <div v-if="row.status==='START'">开工</div>
              <div v-if="row.status==='CLOSED'">完工</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="wo_code"
            label="工单编号"
            sortable="custom"
            min-width="160"
          />
          <el-table-column
            prop="m_po"
            label="源单单号"
            sortable="custom"
            min-width="160"
          />
          <el-table-column
            prop="wotype"
            label="单据类型"
            sortable="custom"
            min-width="120"
          >
            <template slot-scope="{row}">
              <div v-if="row.wotype==='PO'">标准工单</div>
              <div v-else-if="row.wotype==='FO'">报废补单</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="partcode"
            label="产品编码"
            sortable="custom"
            min-width="120"
          />
          <el-table-column
            prop="partname"
            min-width="150"
            label="产品名称"
            sortable="custom"
          />
          <el-table-column
            prop="partspec"
            label="产品规格"
            sortable="custom"
            width="110"
          >
            <template slot-scope="{row}">
              <div v-if="row.partspec">{{ row.partspec }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="plan_qty"
            label="工单数"
            sortable="custom"
            width="100"
          />
          <el-table-column
            prop="wkshp_name"
            label="生产车间"
            sortable="custom"
            width="120"
          >
            <template slot-scope="{row}">
              <div v-if="row.wkshp_name">{{ row.wkshp_name }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="route_name"
            label="工艺路线"
            show-tooltip-when-overflow
            sortable="custom"
            width="180"
          >
            <template slot-scope="{row}">
              <div v-if="row.route_name">{{ row.route_name }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <!--          <el-table-column-->
          <!--            prop="route_name"-->
          <!--            label="关联工艺路线"-->
          <!--            min-width="110"-->
          <!--          >-->
          <!--            <template slot-scope="{row}">-->
          <!--              <i v-if="row.route_name" class="el-icon-share" @click="routeClick(row)" />-->
          <!--              <i v-else style="color:rgb(180 ,181, 185)" class="el-icon-share" @click="routeClick(row)" />-->
          <!--            </template>-->
          <!--          </el-table-column>-->
          <el-table-column
            prop="plan_startdate"
            label="计划开始时间"
            sortable="custom"
            width="160"
          >
            <template slot-scope="{row}">
              <div v-if="row.plan_startdate">{{ row.plan_startdate }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="plan_enddate"
            label="计划结束时间"
            sortable="custom"
            width="160"
          >
            <template slot-scope="{row}">
              <div v-if="row.plan_enddate">{{ row.plan_enddate }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="piroque"
            label="工单等级"
            sortable="custom"
            width="120"
          >
            <template slot-scope="{row}">
              <div v-if="row.piroque==='1'">特级</div>
              <div v-if="row.piroque==='2'">紧急</div>
              <div v-if="row.piroque==='3'">正常</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="lm_user"
            label="创建人员"
            sortable="custom"
            width="120"
          />
          <el-table-column
            prop="lm_date"
            label="创建时间"
            width="160"
            sortable="custom"
          />
          <el-table-column
            label="操作"
            width="120"
            fixed="right"
          >
            <template slot-scope="{row}">
              <div class="operationClass">
                <el-tooltip class="item" effect="dark" content="工序任务" placement="top">
                  <i
                    class="el-icon-tickets"
                    style="cursor: pointer;color: #42b983;margin-right: 15px"
                    @click="check(row)"
                  />
                </el-tooltip>
                <el-tooltip v-del-tab-index class="item" effect="dark" content="删除" placement="top">
                  <i class="el-icon-delete" @click="del(row)" />
                </el-tooltip>
              </div>
            </template>
          </el-table-column>
        </el-table>
      </div>
      <!--分页-->
      <pagination
        :total="total"
        :page.sync="form.page"
        :limit.sync="form.rows"
        align="right"
        layout="total,prev, pager, next,sizes"
        popper-class="select_bottom"
        @pagination="getMesOrderSearch"
      />
    </div>
    <!--新增派发对话框-->
    <el-dialog
      :title="operation==='add'?'新增':'派发'"
      :visible.sync="dialogVisible"
      width="840px"
      top="15vh"
      :close-on-click-modal="false"
      @closed="handleClose"
      @close="handleClose"
    >
      <el-form
        ref="dialogForm"
        inline
        :rules="dialogFormRules"
        :model="dialogForm"
        label-width="110px"
      >
        <el-form-item
          label="订单状态"
          prop="mesorderstus"
        >
          <el-select
            v-model="dialogForm.mesorderstus"
            disabled
            filterable
            :popper-append-to-body="false"
            style="width: 200px"
            placeholder="请选择"
          >
            <el-option
              v-for="item in erporderstusArr"
              :key="item.code"
              :label="item.name"
              :value="item.code"
            />
          </el-select>
        </el-form-item>
        <el-form-item label="工单编号" prop="mesordercode">
          <el-input v-model="dialogForm.mesordercode" :disabled="operation!=='add'" style="width: 200px" />
        </el-form-item>
        <div style="display: flex">
          <el-form-item label="工单类型" prop="mesorderstus">
            <el-select
              v-model="dialogForm.ordertype"
              :popper-append-to-body="false"
              style="width: 200px"
              :disabled="operation!=='add'"
              placeholder="请选择"
              @change="mesordertypeChange"
            >
              <el-option
                v-for="item in ordertypeArr"
                :key="item.code"
                :label="item.name"
                :value="item.code"
              />
            </el-select>
          </el-form-item>
          <div style="display: flex;flex-wrap: nowrap">
            <el-form-item label="源单单号">
              <el-input
                v-model="dialogForm.sourceorder"
                :disabled="dialogForm.ordertype==='PO'"
                style="width: 172px"
              />
            </el-form-item>
            <el-button
              type="primary"
              style="padding: 0 10px;margin-left: -8px;margin-top: 3px"
              class="el-icon-search"
              :disabled="operation!=='add'||dialogForm.ordertype==='PO'"
              @click="mesordertsourcesearchclick"
            />
          </div>
        </div>
        <el-form-item label="工单数量" prop="mesqty">
          <el-input
            v-model="dialogForm.mesqty"
            oninput="value=value.replace(/[^0-9.]/g,'')"
            :disabled="operation!=='add'"
            style="width: 200px"
          />
        </el-form-item>
        <el-form-item
          v-if="operation==='add'"
          label="产品名称"
          prop="partcode"
        >
          <el-select
            v-model="dialogForm.partcode"
            filterable
            :disabled="operation!=='add'"
            :popper-append-to-body="false"
            style="width: 200px"
            placeholder="请选择"
            @change="partcodeChangeDialog"
          >
            <el-option
              v-for="item in partArr"
              :key="item.partcode"
              :label="item.partname"
              :value="item.partcode"
            />
          </el-select>
        </el-form-item>
        <el-form-item v-if="operation!=='add'" label="产品名称" prop="partname">
          <el-input v-model="dialogForm.partname" disabled style="width: 200px" />
        </el-form-item>
        <el-form-item label="产品编码">
          <el-input v-model="dialogForm.partcode" disabled style="width: 200px" />
        </el-form-item>
        <el-form-item label="产品规格" prop="partspec">
          <el-input v-model="dialogForm.partspec" disabled style="width: 200px" />
        </el-form-item>
        <div style="display: flex">
          <div style="display: flex;flex-wrap: nowrap">
            <el-form-item label="工艺路线" prop="routecode">
              <el-select
                v-model="dialogForm.routecode"
                filterable
                :disabled="dialogForm.partcode===''"
                :popper-append-to-body="false"
                style="width: 172px"
                placeholder="请选择"
                @change="routecodeChange"
              >
                <el-option
                  v-for="item in routeArr"
                  :key="item.code"
                  :label="item.name"
                  :value="item.code"
                />
              </el-select>
            </el-form-item>
            <el-button
              type="primary"
              style="padding: 0 10px;margin-left: -8px;margin-top:3px"
              class="el-icon-search"
              @click="searchClick"
            />
            <!--            :disabled="dialogForm.routecode===''"-->
          </div>
          <el-form-item label="生产车间" prop="wkshopcode">
            <el-select
              v-model="dialogForm.wkshopcode"
              filterable
              :popper-append-to-body="false"
              style="width: 200px;"
              placeholder="请选择"
              :disabled="dialogForm.routecode===''"
            >
              <el-option
                v-for="item in wkshopArr"
                :key="item.org_code"
                :label="item.org_name"
                :value="item.org_code"
              />
            </el-select>
          </el-form-item>
        </div>
        <el-form-item label="计划开始时间" prop="planstartdate">
          <el-date-picker
            v-model="dialogForm.planstartdate"
            type="date"
            :clearable="false"
            value-format="yyyy-MM-dd"
            style="width: 200px"
            placeholder="选择日期"
          />
        </el-form-item>
        <el-form-item label="计划完成时间" prop="planenddate">
          <el-date-picker
            v-model="dialogForm.planenddate"
            type="date"
            :clearable="false"
            value-format="yyyy-MM-dd"
            style="width: 200px"
            placeholder="选择日期"
          />
        </el-form-item>
        <el-form-item label="工单等级" prop="orderlev">
          <el-select
            v-model="dialogForm.orderlev"
            filterable
            :popper-append-to-body="false"
            style="width: 200px"
            placeholder="请选择"
          >
            <el-option
              v-for="item in orderlevArr"
              :key="item.code"
              :label="item.name"
              :value="item.code"
            />
          </el-select>
        </el-form-item>
      </el-form>
      <!--        å·¥è‰ºè·¯çº¿æ”¾å¤§é•œå¯¹è¯æ¡†-->
      <el-dialog
        title="工艺路线"
        :visible.sync="dialogVisibleSearch"
        width="840px"
        top="20vh"
        class="dialogVisibleSearch"
        append-to-body
        :close-on-click-modal="false"
      >
        <el-table
          :data="searchTableData"
          border
          :row-class-name="tableRowClassName"
          height="300"
          style="width: 100%;"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
        >
          <el-table-column
            prop="seq"
            label="序号"
            width="50"
            fixed
          />
          <el-table-column
            prop="stepcode"
            label="工序编码"
          />
          <el-table-column
            prop="stepname"
            label="工序名称"
          />
          <el-table-column
            prop="flwtype"
            label="工序类型"
          >
            <template slot-scope="{row}">
              <div v-if="row.flwtype==='W'">外协</div>
              <div v-if="row.flwtype==='Z'">自制</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="descr"
            label="工序描述"
            fixed="right"
          />
        </el-table>
      </el-dialog>
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="dialogVisibleCancel">取 æ¶ˆ</el-button>
          <!--          <el-button v-if="operation==='add'" type="primary" @click="dialogVisibleConfirmPreview('add')">预览</el-button>-->
          <el-button type="primary" @click="dialogVisibleConfirm">ç¡® å®š</el-button>
        </div>
      </span>
    </el-dialog>
    <!-- å·¥åºä»»åŠ¡å¯¹è¯æ¡†-->
    <el-dialog
      title="工序任务"
      :visible.sync="dialogVisibleTask"
      width="840px"
      top="15vh"
      class="dialogVisibleSearch"
      :close-on-click-modal="false"
      @close="dialogVisibleTaskClose"
    >
      <el-button
        style="margin-bottom: 15px"
        type="primary"
        @click="supplementClick"
      >补打
      </el-button>
      <el-table
        :data="taskTableData"
        border
        :row-class-name="tableRowClassName"
        height="300"
        style="width: 100%;"
        highlight-current-row
        :header-cell-style="this.$headerCellStyle"
        :cell-style="this.$cellStyle"
      >
        <el-table-column
          prop="seq"
          width="50"
          label="序号"
          fixed
        />
        <el-table-column
          prop="wo_code"
          label="工单编号"
          width="200"
        />
        <el-table-column
          prop="stepcode"
          label="工序编码"
        />
        <el-table-column
          prop="stepname"
          label="工序名称"
        />
        <!--        <el-table-column-->
        <!--          prop="flwtype"-->
        <!--          label="工序类型"-->
        <!--        >-->
        <!--          <template slot-scope="{row}">-->
        <!--            <div v-if="row.flwtype==='W'">外协</div>-->
        <!--            <div v-if="row.flwtype==='Z'">自制</div>-->
        <!--          </template>-->
        <!--        </el-table-column>-->
        <!--        <el-table-column-->
        <!--          prop="descr"-->
        <!--          label="工序描述"-->
        <!--        />-->
        <el-table-column
          prop="plan_qty"
          label="任务数量"
        />
        <el-table-column
          prop="good_qty"
          label="合格数量"
        />
        <el-table-column
          prop="ng_qty"
          label="不良数量"
        />
        <el-table-column
          label="操作"
          fixed="right"
        >
          <template slot-scope="{row}">
            <el-button type="text" style="padding: 0;" @click="supplementSmallClick(row)">补打</el-button>
          </template>
        </el-table-column>
      </el-table>
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="dialogVisibleBack">返 å›ž</el-button>
          <!--          <el-button type="primary" @click="dialogVisibleConfirm">ç¡® å®š</el-button>-->
        </div>
      </span>
    </el-dialog>
    <!-- æºå•单号对话框-->
    <el-dialog
      title="源单单号"
      :visible.sync="dialogVisibleSource"
      width="1200px"
      top="5vh"
      class="dialogVisibleSearch"
      :close-on-click-modal="false"
      @close="dialogVisibleSourceClose"
    >
      <div class="bodyTopFormGroup" style="animation: move 1s linear">
        <el-form
          ref="sourceForm"
          :model="sourceForm"
          label-width="100px"
          inline
          style="display: flex;justify-content: space-between"
        >
          <div class="elForm">
            <el-form-item
              label="预计开工时间"
              label-width="100px"
              style=" display: flex;font-size: 14px;margin-top: 3px"
            >
              <el-date-picker
                v-model="sourceForm.paystartdate"
                type="daterange"
                range-separator="~"
                class="timeMini"
                size="mini"
                style="width: 200px;display: flex;line-height: 34px;height: 34px;font-size: 14px!important;"
                :clearable="false"
                start-placeholder="开始日期"
                end-placeholder="结束日期"
              />
              <!--              :picker-options="expireTimeOption"-->
            </el-form-item>
            <el-form-item
              label="预计完工时间"
              label-width="100px"
              style=" display: flex;font-size: 14px;margin-top: 3px"
            >
              <el-date-picker
                v-model="sourceForm.payenddate"
                type="daterange"
                :clearable="false"
                class="timeMini"
                range-separator="~"
                start-placeholder="开始日期"
                style="width: 200px;display: flex;line-height: 34px ;height: 34px ;font-size: 14px !important;"
                end-placeholder="结束日期"
                size="mini"
              />
            </el-form-item>
            <el-form-item label="订单状态" style=" display: flex;">
              <el-select
                v-model="sourceForm.erporderstus"
                filterable
                :popper-append-to-body="false"
                style="width: 200px"
                placeholder="请选择"
              >
                <el-option
                  v-for="item in erporderstusArr"
                  :key="item.code"
                  :label="item.name"
                  :value="item.code"
                />
              </el-select>
            </el-form-item>
            <el-form-item v-show="isExpandDialog" label="订单编号" style=" display: flex;">
              <el-input v-model="sourceForm.erpordercode" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item v-show="isExpandDialog" label="产品编码" style=" display: flex;">
              <el-input v-model="sourceForm.partcode" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandDialog" label="产品名称" style=" display: flex;">
              <el-input v-model="sourceForm.partname" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandDialog" label="产品规格" style=" display: flex;">
              <el-input v-model="sourceForm.partspec" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item v-show="isExpandDialog" label="创建人员" style=" display: flex;">
              <el-input v-model="sourceForm.creatuser" style="width: 200px" placeholder="请输入" />
            </el-form-item>
          </div>
          <div>
            <div style="display: flex;align-items: start;margin-top: 5px;z-index: 2;justify-content: end">
              <el-button type="primary" icon="el-icon-search" @click="sourceSearch">查询</el-button>
              <el-button type="info" icon="el-icon-refresh" @click="sourceReset">重置</el-button>
            </div>
          </div>
        </el-form>
      </div>
      <!--      <el-tooltip  :content="!isExpandDialog?'点击展示更多':'收起'" placement="bottom">-->
      <div
        style="display:flex;justify-content: center;
          align-items:center;background-color:#eee;cursor: pointer"
        @click="isExpandDialog=!isExpandDialog"
      >
        <i
          :class="!isExpandDialog?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <!--      </el-tooltip>-->
      <div class="elTableDiv">
        <el-table
          :data="sourceTableData"
          :height="(tableHeight-100)+'px'"
          border
          :row-class-name="tableRowClassName"
          :style="{width: 100+'%',height:(tableHeight-100)+'px',}"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
          @sort-change="sourceSortChange"
        >
          <!--          <el-table-column-->
          <!--            type="selection"-->
          <!--            width="50"-->
          <!--          />-->
          <el-table-column
            width="50"
            fixed
          >
            <template slot-scope="{row}">
              <el-radio
                v-model="radioSelectedId"
                :label="row.id"
                style="color: transparent;padding-left: 10px;"
                @change.native="getCurrentRowSource(row.id)"
              />
            </template>
          </el-table-column>
          <el-table-column
            prop="RowNum"
            width="50"
            fixed
            label="序号"
          />
          <el-table-column
            prop="status"
            label="订单状态"
            sortable="custom"
            width="110"
          >
            <template slot-scope="{row}">
              <div v-if="row.status==='NEW'">新订单</div>
              <div v-if="row.status==='CREATING'">部分下达</div>
              <div v-if="row.status==='CREATED'">全部下达</div>
              <div v-if="row.status==='CLOSED'">已关闭</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="wo"
            label="订单编号"
            sortable="custom"
            min-width="150"
          />
          <el-table-column
            prop="partcode"
            label="产品编码"
            sortable="custom"
            min-width="150"
          />
          <el-table-column
            prop="partname"
            label="产品名称"
            sortable="custom"
            min-width="150"
          />
          <el-table-column
            prop="partspec"
            label="产品规格"
            sortable="custom"
            min-width="110"
          >
            <template slot-scope="{row}">
              <div v-if="row.partspec">{{ row.partspec }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="qty"
            label="订单数量"
            width="150"
            sortable="custom"
          />
          <el-table-column
            prop="relse_qty"
            label="已下单数量"
            width="150"
            sortable="custom"
          />
          <el-table-column
            prop="wkshp_name"
            label="生产车间"
            sortable="custom"
            width="150"
          >
            <template slot-scope="{row}">
              <div v-if="row.wkshp_name">{{ row.wkshp_name }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="planstartdate"
            label="预计开工时间"
            sortable="custom"
            width="130"
          >
            <template slot-scope="{row}">
              <div v-if="row.planstartdate">{{ row.planstartdate.substring(0, 11) }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="planenddate"
            label="预计完工时间"
            sortable="custom"
            width="130"
          >
            <template slot-scope="{row}">
              <div v-if="row.planenddate">{{ row.planenddate.substring(0, 11) }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="createuser"
            label="创建人员"
            sortable="custom"
            width="150"
          >
            <template slot-scope="{row}">
              <div v-if="row.createuser">{{ row.createuser }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="createdate"
            label="创建时间"
            width="130"
            sortable="custom"
          >
            <template slot-scope="{row}">
              <div v-if="row.createdate">{{ row.createdate.substring(0, 11) }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <!--          <el-table-column-->
          <!--            label="操作"-->
          <!--            fixed="right"-->
          <!--            width="80"-->
          <!--          >-->
          <!--            <template slot-scope="{row}">-->
          <!--              <div class="operationClass">-->
          <!--                <el-tooltip class="item" effect="dark" content="下达" placement="top">-->
          <!--                  &lt;!&ndash;                <el-button type="text" @click="edit('edit',row)">下达</el-button>&ndash;&gt;-->
          <!--                  <i-->
          <!--                    class="el-icon-bottom"-->
          <!--                    style="color:#42b983;cursor: pointer;margin-left: 5px"-->
          <!--                    @click="edit('edit',row)"-->
          <!--                  />-->
          <!--                </el-tooltip>-->
          <!--              </div>-->
          <!--            </template>-->
          <!--          </el-table-column>-->
        </el-table>
      </div>
      <!--分页-->
      <pagination
        :total="sourceFormTotal"
        :page.sync="sourceForm.page"
        :limit.sync="sourceForm.rows"
        align="right"
        layout="total,prev, pager, next,sizes"
        popper-class="select_bottom"
        @pagination="getErpOrderSearch"
      />
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="dialogVisibleSourceBack">返 å›ž</el-button>
          <el-button type="primary" @click="dialogVisibleSourceConfirm">ç¡® å®š</el-button>
        </div>
      </span>
    </el-dialog>
    <!--打印预览对话框  å¤§æ ‡ç­¾-->
    <el-dialog
      title=""
      :visible.sync="dialogVisibleApprove"
      width="812px"
      class="dialogVisibleConfirmClass"
      append-to-body
      :close-on-click-modal="false"
      @close="dialogVisibleConfirmClose"
    >
      <!-- è¦æ‰“印的区域 -->
      <div id="printMe" style="padding: 30px">
        <div style="font-size: 26px; text-align: center">流程单</div>
        <div style="display: flex;justify-content: space-around;margin-top: 20px; position: relative;">
          <div style="width: 78%">
            <el-form
              ref="formApprove"
              :model="formApprove"
              label-width="100px"
              inline
              style="display: flex;justify-content: space-between"
            >
              <div class="elForm">
                <el-form-item label="工单编号:" class="formContent">
                  {{ formApprove.mesordercode }}
                </el-form-item>
                <el-form-item label="源单单号:" class="formContent">
                  {{ formApprove.m_po }}
                </el-form-item>
                <el-form-item label="产品编码:" class="formContent">
                  {{ formApprove.partcode }}
                </el-form-item>
                <el-form-item label="产品名称:" class="formContent">
                  {{ formApprove.partname }}
                </el-form-item>
                <el-form-item label="产品规格:" class="formContent">
                  {{ formApprove.partspec }}
                </el-form-item>
                <el-form-item label="工单数量:" class="formContent">
                  {{ formApprove.plan_qty }}
                </el-form-item>
                <el-form-item label="工艺路线:" class="formContent">
                  {{ formApprove.routename }}
                </el-form-item>
                <el-form-item label="打印人员:" class="formContent">
                  {{ username }}
                </el-form-item>
                <el-form-item label="打印时间:" class="formContent">
                  {{ formApprove.lm_date }}
                </el-form-item>
              </div>
            </el-form>
          </div>
          <div
            id="qrCode"
            style="width: 22%;height:97px;
            margin-top: 20px;
            overflow-y: scroll;display: flex;
            justify-content: center;
            position: relative;"
          >
            <!--            <div id="qrCode0" ref="qrCodeDiv0" />-->
          </div>
          <div style="background-color: #fff;width: 20px;height:120px; position: absolute;right: 0" />
          <div
            style="z-index: 10;background-color:transparent;width: 120px;height:120px; position: absolute;right: 21px"
          />
        </div>
        <!--          <div style="width:100%;height: 30px;border-bottom: 1px solid #eee;margin-bottom: 20px" />-->
        <el-table
          id="table"
          :data="tableDataPrint"
          border
          class="tableDataPrint"
          :header-cell-style="{ background: '#c0c0c0',textAlign:'center',color:'#000',borderColor:'#000'}"
          :cell-style="{textAlign: 'center',color:'#000',borderColor:'#000'}"
          style="width: 100%;margin-top: 20px;text-align: center;border-color: #000"
        >
          <el-table-column
            id="column0"
            prop="seq"
            label="工序号"
            width="70"
            align="center"
          />
          <el-table-column
            id="column1"
            prop="stepqrcode"
            label="工序二维码"
            width="100"
            align="center"
          >
            <template slot-scope="{row}">
              <div :id="'qrCode'+row.seq" :ref="'qrCodeDiv'+row.seq" class="tableColumn" />
            </template>
          </el-table-column>
          <el-table-column
            id="column2"
            prop="stepname"
            label="工序"
            width="120"
            align="center"
          />
          <el-table-column
            id="column3"
            prop="plan_qty"
            label="加工数量"
            width="100"
            align="center"
          />
          <el-table-column
            id="column4"
            prop="good_qty"
            width="100"
            align="center"
            label="合格数量"
          />
          <el-table-column
            id="column5"
            width="100"
            prop="ng_qty"
            align="center"
            label="不良数量"
          />
          <el-table-column
            id="column6"
            prop="desc"
            align="center"
            width="120"
            label="备注"
          />
        </el-table>
      </div>
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="dialogVisibleBackPreview">返 å›ž</el-button>
          <!--            <el-button v-if="operation==='add'" type="primary" @click="dialogVisibleConfirm">ç¡® å®š</el-button>-->
          <!--            <el-button type="primary" @click="dialogVisibleConfirm">ç¡® å®š/打 å°</el-button>-->
          <el-button v-print="printObj" type="primary">打 å°</el-button>
        </div>
      </span>
    </el-dialog>
    <!--打印预览页面  å°æ ‡ç­¾-->
    <el-dialog
      title="预览"
      :visible.sync="dialogVisible2"
      width="1140"
      top="10vh"
      :close-on-click-modal="false"
      @close="dialogVisible2Close"
    >
      <!-- è¦æ‰“印的区域 -->
      <div id="printMe2" style="padding: 30px;">
        <div
          style="display: flex;width: 280px;height: 150px;border: 1px solid #000;text-align: center;font-size: 10px;"
        >
          <div style="width: 90px;display: flex;flex-direction: column;border-right: 1px solid #000">
            <div
              style="display: flex;height: 90px;border-bottom:1px solid #000;
              justify-content: center;align-items: center;position: relative"
            >
              <div id="qrCode2" ref="qrCodeDiv2" style="overflow-y: hidden;height:60px;position: absolute;left: 14px;" />
            </div>
            <div
              style="display: flex;height: 30px;justify-content: flex-start;border-bottom:1px solid #000;align-items: center"
            >
              <div style="margin-left: 5px;width: 28px">数量:</div>
              {{ qrForm.startqty }}
            </div>
            <div style="display: flex;height: 30px;justify-content: flex-start;align-items: center">
              <div style="margin-left: 5px;width: 42px">处理人:</div>
              {{ qrForm.operator }}
            </div>
          </div>
          <div style="width:190px;display: flex;flex-direction: column">
            <div
              style="display: flex;height: 20%;border-bottom:1px solid #000;justify-content: flex-start;align-items: center;text-align: left"
            >
              <div style="width: 60px;margin-left: 5px;">工单编号:</div>
              <div>{{ qrForm.wo_code }}</div>
            </div>
            <div
              style="display: flex;height: 20%;border-bottom:1px solid #000;justify-content: flex-start;align-items: center ;text-align: left"
            >
              <div style="width: 60px;margin-left: 5px;">产品编码:</div>
              <div>{{ qrForm.partcode }}</div>
            </div>
            <div
              style="display: flex;height: 20%;border-bottom:1px solid #000 ;justify-content: flex-start;align-items: center;text-align: left"
            >
              <div style="width:60px;margin-left: 5px;">产品名称:</div>
              <div>{{ qrForm.partname }}</div>
            </div>
            <div
              style="display: flex;height: 20%;border-bottom:1px solid #000 ;justify-content: flex-start;align-items: center;text-align: left"
            >
              <div style="width:60px;margin-left: 5px;">下道工序:</div>
              <div>{{ qrForm.nextstepname }}</div>
            </div>
            <div style="display: flex;height: 20%;justify-content: flex-start;align-items: center;text-align: left">
              <div style="width: 60px;margin-left: 5px;">处理时间:</div>
              <div>{{ qrForm.operatorTime }}</div>
            </div>
          </div>
        </div>
      </div>
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="dialogVisible2 = false">取 æ¶ˆ</el-button>
          <el-button v-print="printObj2" type="primary">ç¡® å®š</el-button>
        </div>
      </span>
    </el-dialog>
    <!--    å·¥è‰ºè·¯çº¿å¯¹è¯æ¡†-->
    <el-dialog
      :close-on-click-modal="false"
      title="关联工艺路线"
      :visible.sync="dialogVisibleRoute"
      width="800px"
      top="10vh"
      :fullscreen="isIpad"
      class="dialogVisibleRoute"
      @closed="handleCloseRoute"
      @close="handleCloseRoute"
    >
      <div>
        <i class="el-icon-s-comment" style="color:#42b983;" /> äº§å“åç§°ï¼š{{ dialogFormRoute.projectName }}
      </div>
      <el-divider />
      <div style="margin-bottom: 10px">
        <i class="el-icon-s-operation" style="color:#42b983;" /> å·¥è‰ºè·¯çº¿é›†åˆ
      </div>
      <div class="myCheckboxGroup">
        <div
          v-for="item in dialogFormRoute.routeOperationArr"
          :key="item.code"
          :style="{border:item.isSelected1?'1px solid #42b983':'1px solid #eee'}"
          class="myCheckbox"
          @click="myCheckboxClick(item)"
        >
          <input
            class="myCheckboxInput"
            type="checkbox"
            :value="item.code"
            :name="item.name"
            :style="{color:item.isSelected2?'#42b983':'#fff'}"
            @click="myCheckboxInputClick(item)"
          >{{ item.name }}
          <!--            çˆ¶å­ç‚¹å‡»äº‹ä»¶ä¸å½±å“-->
          <!--            onClick="event.cancelBubble = true"-->
        </div>
      </div>
      <el-divider />
      <div>
        <i class="el-icon-s-operation" style="color:#42b983;" /> é»˜è®¤å·¥è‰ºè·¯çº¿
      </div>
      <div style="margin-top: 20px">
        <el-select
          v-model="defaultroute_code"
          filterable
          style="width: 200px;"
          placeholder="请选择"
          class="defaultroute_code"
        >
          <el-option
            v-for="item in defaultroute_codeArr"
            :key="item.code"
            :label="item.name"
            :value="item.code"
          />
        </el-select>
      </div>
      <el-divider />
      <div style="margin-bottom: 10px">
        <i class="el-icon-s-operation" style="color:#42b983;" /> å·¥åºåˆ—表
      </div>
      <div style="overflow-y: scroll">
        <el-table
          ref="projectTableData"
          :data="projectTableData"
          border
          height="280"
          :row-class-name="tableRowClassName"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
        >
          <el-table-column
            prop="seq"
            width="100"
            label="工序序号"
            fixed
          />
          <el-table-column
            prop="stepcode"
            label="工序编码"
          />
          <el-table-column
            prop="stepname"
            label="工序名称"
          />
          <el-table-column
            prop="enable"
            label="启用状态"
            fixed="right"
          >
            <template slot-scope="{row}">
              <div v-if="row.enable==='Y'">
                <svg-icon icon-class="circleYes" style="margin-right: 2px" />
                æ˜¯
              </div>
              <div v-if="row.enable==='N'">
                <svg-icon icon-class="circleNo" style="margin-right: 2px" />
                å¦
              </div>
            </template>
          </el-table-column>
        </el-table>
      </div>
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="routeDialogVisibleCancel">取 æ¶ˆ</el-button>
          <el-button type="primary" @click="routeDialogVisibleConfirm">ç¡® å®š</el-button>
        </div>
      </span>
    </el-dialog>
  </div>
</template>
<script>
import Pagination from '@/components/Pagination'
import {
  AddUpdateMesOrder,
  ClosedMesOrder,
  DeleteMesOrder, ErpOrderSearch,
  MesOrderSearch, PartSelectRoute, RouteSelectWkshop, SearchWorkStep,
  SelectRouteStep
} from '@/api/scgl'
import { InventoryFileAssociationRoute, PartSelect, SaveInventoryFile } from '@/api/zzmx'
import { handleDatetime, handleDatetime2, validateCode } from '@/utils/global'
import { getCookie } from '@/utils/auth'
import { MesOrderPrintSearch1, PrintOrder } from '@/api/utils'
import { urlAddRandomNo, webapp_ws_ajax_run, webapp_ws_autoupdate } from '@/utils/grwebapp'
import QRCode from 'qrcodejs2'
import $ from 'jquery'
export default {
  name: 'GD',
  components: {
    Pagination
  },
  data() {
    return {
      isIpad: false,
      mainHeight: 0,
      tableHeight: 0,
      username: '',
      form: {
        mesorderstus: '', // å·¥å•状态码
        mesordercode: '', // å·¥å•编号
        partcode: '', // äº§å“ç¼–码
        ordertype: '', // ordertype
        sourceorder: '', // æºå•单号
        partname: '', // äº§å“åç§°
        partspec: '', // äº§å“è§„æ ¼
        creatuser: '', // åˆ›å»ºäººå‘˜
        createdate: '', // åˆ›å»ºæ—¶é—´
        prop: 'lm_date', // æŽ’序字段
        order: 'desc', // æŽ’序字段
        page: 1, // ç¬¬å‡ é¡µ
        rows: 20 // æ¯é¡µå¤šå°‘条
      },
      erporderstusArr: [
        { code: 'NEW', name: '新工单' },
        // { code: 'CREATING', name: '执行中' },
        // { code: 'CREATED', name: '已关闭' }
        { code: 'ALLO', name: '已派发' },
        { code: 'START', name: '开工' },
        { code: 'CLOSED', name: '完工' }
      ],
      total: 10,
      radioSelected: '',
      tableData: [],
      dialogVisible: false,
      dialogForm: {
        partname: '', // äº§å“åç§°
        partspec: '', // äº§å“è§„æ ¼
        wkshopname: '', // ç”Ÿäº§è½¦é—´åç§°
        routename: '', // å·¥è‰ºè·¯çº¿åç§°
        mesorderstus: 'NEW', // å·¥å•状态码
        mesordercode: '', // å·¥å•编号
        partcode: '', // äº§å“ç¼–码
        ordertype: 'PO', // å·¥å•类型
        sourceorder: '', // æºå•单号
        mesqty: '', // å·¥å•数量
        routecode: '', // å·¥è‰ºè·¯çº¿ç¼–码
        wkshopcode: '', // ç”Ÿäº§è½¦é—´ç¼–码
        planstartdate: '', // è®¡åˆ’开始时间
        planenddate: '', // è®¡åˆ’完成时间
        orderlev: '', // å·¥å•等级
        OperType: '' // æ“ä½œç±»åž‹
      },
      ordertypeArr: [// å·¥å•类型
        { code: 'PO', name: '标准工单' },
        { code: 'FO', name: '报废补单' }
      ],
      partArr: [], // äº§å“ä¿¡æ¯
      wkshopArr: [], // ç”Ÿäº§è½¦é—´æ•°ç»„
      routeArr: [], // å·¥è‰ºè·¯çº¿æ•°ç»„
      orderlevArr: [
        { code: 1, name: '特级' },
        { code: 2, name: '紧急' },
        { code: 3, name: '正常' }
      ], // å·¥å•等级数组
      operation: '',
      dialogFormRules: {
        mesorderstus: [
          { required: true, message: '请选择订单状态', trigger: ['blur', 'change'] }
        ],
        partcode: [
          { required: true, message: '请选择产品信息', trigger: ['blur', 'change'] }
        ],
        mesordercode: [
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        mesqty: [
          { required: true, message: '请输入工单数量', trigger: ['blur', 'change'] }
        ],
        wkshopcode: [
          { required: true, message: '请选择生产车间', trigger: ['blur', 'change'] }
        ],
        routecode: [
          { required: true, message: '请选择工艺路线', trigger: ['blur', 'change'] }
        ],
        planstartdate: [
          { required: true, message: '请选择开始时间', trigger: ['blur', 'change'] }
        ],
        planenddate: [
          { required: true, message: '请选择结束时间', trigger: ['blur', 'change'] }
        ],
        orderlev: [
          { required: true, message: '请选择工单等级', trigger: ['blur', 'change'] }
        ]
      },
      dialogVisibleTask: false,
      taskTableData: [],
      dialogVisibleSearch: false,
      searchTableData: [],
      dialogVisibleApprove: false,
      tableDataPrint: [], // æ‰“印页面内容
      printObj: {
        id: 'printMe',
        popTitle: '打印模板',
        preview: false,
        extraHead: '<meta http-equiv="Content-Language" content="zh-cn"/>',
        closeCallback(vue) { // å…³é—­æ‰“印的回调事件(无法确定点击的是确认还是取消)
          console.log('11212', vue)
          // vue.dialogVisible = false
          vue.dialogVisibleApprove = false
        },
        beforeOpenCallback(vue) {
          vue.printLoading = true
          console.log('打开之前')
          console.log()
        },
        openCallback(vue) {
          vue.printLoading = false
          console.log('执行了打印')
        }
      },
      formApprove: {
        m_po: '', // æºå•单号
        mesordercode: '',
        partcode: '',
        partname: '',
        partspec: '',
        plan_qty: '',
        routename: '',
        lm_date: ''
      },
      number: '',
      dialogVisible2: false,
      printObj2: {
        id: 'printMe2',
        popTitle: '打印模板',
        preview: false,
        extraHead: '<meta http-equiv="Content-Language" content="zh-cn"/>',
        closeCallback(vue) { // å…³é—­æ‰“印的回调事件(无法确定点击的是确认还是取消)
          console.log('11212', vue)
          // vue.dialogVisible = false
          vue.dialogVisible2 = false
          // vue.dialogVisible = false
        },
        beforeOpenCallback(vue) {
          vue.printLoading = true
          console.log('打开之前')
          console.log()
        },
        openCallback(vue) {
          vue.printLoading = false
          console.log('执行了打印')
        }
      },
      qrForm: {
        qrvalue: '',
        startqty: '',
        wo_code: '',
        partcode: '',
        partname: '',
        nextstepname: '',
        operator: '', // æ“ä½œäºº
        operatorTime: ''// æ“ä½œæ—¶é—´
      },
      dialogVisibleSource: false,
      sourceTableData: [],
      sourceForm: {
        erporderstus: '', // è®¢å•状态码
        erpordercode: '', // è®¢å•编号
        partcode: '', // äº§å“ç¼–码
        partname: '', // äº§å“åç§°
        partspec: '', // äº§å“è§„æ ¼
        creatuser: '', // åˆ›å»ºäººå‘˜
        // paystartdate: '', // äº¤ä»˜æ—¶é—´
        paystartdate: '', // é¢„计开工时间
        payenddate: '', // é¢„计完工时间
        createdate: '', // åˆ›å»ºæ—¶é—´
        prop: 'createdate', // æŽ’序字段
        order: 'desc', // æŽ’序字段
        page: 1, // ç¬¬å‡ é¡µ
        rows: 20 // æ¯é¡µå¤šå°‘条
      },
      sourceFormTotal: 10,
      radioSelectedId: '',
      isExpandDialog: false, // å¯¹è¯æ¡†è¡¨å•是否展开,默认不展开
      dialogVisibleRoute: false,
      dialogFormRoute: {
        projectName: '', // äº§å“åç§°
        projectCode: '', // äº§å“ä»£ç 
        routeOperationArr: [] // å·¥è‰ºè·¯çº¿é›†åˆ
      },
      defaultroute_code: '', // é»˜è®¤å·¥è‰ºè·¯çº¿é€‰ä¸­å€¼
      defaultroute_codeArr: '', // é»˜è®¤å·¥è‰ºè·¯çº¿æ•°ç»„
      projectTableData: [], // è®¾å¤‡åˆ—表
      isExpandForm: false// è¡¨å•是否展开,默认不展开
    }
  },
  created() {
    this.handleRequest()
  },
  mounted() {
    window.addEventListener('resize', this.getHeight)
    this.getHeight()
    // webapp_urlprotocol_startup()
    // webapp_ws_autoupdate(true)
    this.username = getCookie('username')
  },
  methods: {
    tableRowClassName({ row, rowIndex }) {
      return 'custom-row'
    },
    handleRequest() {
      this.getMesOrderSearch().then(res => {
        if (res.code === '200') {
          this.getSelect()
        }
      })
    },
    async getMesOrderSearch() {
      // let tempDate = this.form.createdate
      // if (tempDate.length > 0) {
      //   tempDate = handleDatetime(tempDate[0]) + '~' + handleDatetime(tempDate[1])
      // }
      const data = {
        mesorderstus: this.form.mesorderstus, // å·¥å•状态码
        mesordercode: this.form.mesordercode, // å·¥å•编号
        partcode: this.form.partcode, // äº§å“ç¼–码
        partname: this.form.partname, // äº§å“åç§°
        partspec: this.form.partspec, // äº§å“è§„æ ¼
        creatuser: this.form.creatuser, // åˆ›å»ºäººå‘˜
        sourceorder: this.form.sourceorder, // æºå•单号
        ordertype: this.form.ordertype, // å•据类型
        createdate: this.form.createdate.toString().length > 0 ? handleDatetime(this.form.createdate) : '', // åˆ›å»ºæ—¶é—´
        prop: this.form.prop, // æŽ’序字段
        order: this.form.order, // æŽ’序字段
        page: this.form.page, // ç¬¬å‡ é¡µ
        rows: this.form.rows // æ¯é¡µå¤šå°‘条
      }
      const res = await MesOrderSearch(data)
      this.tableData = res.data
      this.total = res.count
      // this.form.createdate = tempDate
      return { code: res.code }
    },
    async getSelect() {
      // èŽ·å–äº§å“ä¿¡æ¯
      const { data: res1 } = await PartSelect()
      this.partArr = res1
    },
    // è®¢å•状态改变时
    erporderstusChange(val) {
      this.form.mesorderstus = val
    },
    // æŽ’序改变时
    sortChange({ column, prop, order }) {
      if (order === 'descending') {
        order = 'desc'
      } else if (order === 'ascending') {
        order = 'asc'
      } else {
        order = 'desc'
      }
      this.form.order = order
      this.form.prop = prop
      this.getMesOrderSearch()
    },
    sourceSortChange({ column, prop, order }) {
      if (order === 'descending') {
        order = 'desc'
      } else if (order === 'ascending') {
        order = 'asc'
      } else {
        order = 'desc'
      }
      this.sourceForm.order = order
      this.sourceForm.prop = prop
      this.getErpOrderSearch()
    },
    // æŸ¥è¯¢
    search() {
      this.getMesOrderSearch()
    },
    // é‡ç½®
    reset(val) {
      this.form.mesorderstus = ''
      this.form.mesordercode = ''
      this.form.partcode = ''
      this.form.partname = ''
      this.form.partspec = ''
      this.form.paydate = ''
      this.form.creatuser = ''
      this.form.sourceorder = ''
      this.form.creatuser = ''
      this.form.ordertype = ''
      this.getMesOrderSearch()
    },
    // å•选框选中获取当前行信息
    getCurrentRow(wo_code) {
      this.radioSelected = wo_code
    },
    // æ–°å¢žæŒ‰é’®
    async add(operation) {
      this.operation = operation
      this.dialogVisible = true
      this.dialogForm.planstartdate = handleDatetime(new Date())
      this.dialogForm.planenddate = handleDatetime(new Date())
      this.dialogForm.orderlev = 3
    },
    // äº§å“ä¿¡æ¯å€¼æ”¹å˜
    async partcodeChange(val) {
      console.log(val, 22)
      const { data: res } = await PartSelectRoute({ partcode: val })
      this.routeArr = res
      let flag = false
      this.routeArr.forEach(item => {
        if (item.code === item.default_route) {
          this.dialogForm.routecode = item.code
          this.routecodeChange(this.dialogForm.routecode)
          flag = true
        }
      })
      if (!flag) {
        this.dialogForm.routecode = ''
      }
      this.dialogForm.wkshopcode = ''
    },
    // å·¥è‰ºè·¯çº¿å€¼æ”¹å˜
    async routecodeChange(val) {
      const data = {
        partcode: this.dialogForm.partcode,
        routecode: this.dialogForm.routecode
      }
      // èŽ·å–ç”Ÿäº§è½¦é—´æ•°ç»„
      const { data: res2 } = await RouteSelectWkshop(data)
      this.wkshopArr = res2
      this.dialogForm.wkshopcode = ''
    },
    // å·¥åºä»»åŠ¡
    async check(row) {
      const { data: res } = await SearchWorkStep({ wo_code: row.wo_code })
      this.taskTableData = res
      if (this.taskTableData.length === 0) {
        return this.$message.info('无生产任务数据!')
      }
      this.dialogForm.mesordercode = res[0].wo_code
      this.dialogVisibleTask = true
    },
    dialogVisibleBack() {
      this.dialogVisibleTask = false
    },
    // æ´¾å‘
    send(operation) {
      if (this.radioSelected.length < 1) {
        return this.$message.info('请先选择工单!')
      }
      const row = this.tableData.find(item => item.wo_code === this.radioSelected)
      if (row.status !== 'NEW') {
        return this.$message.info('此工单为非新工单状态,不可派发!')
      }
      this.operation = operation
      this.dialogVisible = true
      this.$nextTick(() => {
        this.dialogForm.mesorderstus = row.status
        this.dialogForm.mesordercode = row.wo_code
        this.dialogForm.partcode = row.partcode
        this.partcodeChange(row.partcode)
        this.dialogForm.partname = row.partname
        this.dialogForm.mesqty = row.plan_qty
        this.dialogForm.partspec = row.partspec
        this.dialogForm.sourceorder = row.m_po
        this.dialogForm.ordertype = row.wotype
        // this.routecodeChange(this.dialogForm.routecode)
        this.dialogForm.planstartdate = row.plan_startdate !== null ? row.plan_startdate : handleDatetime(new Date())
        this.dialogForm.planenddate = row.plan_enddate !== null ? row.plan_enddate : handleDatetime(new Date())
        this.dialogForm.orderlev = row.piroque !== null ? row.piroque : 3 // ç­‰çº§
      })
    },
    // åˆ é™¤æŒ‰é’®
    async del(row) {
      if (row.status === 'START' || row.status === 'CLOSED') {
        return this.$message.info('此工单不可删除!')
      }
      this.$confirm('是否确认删除?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        console.log(row, 1)
        const data = {
          souceid: row.sourceid,
          wocode: row.wo_code,
          m_po: row.m_po,
          orderqty: row.plan_qty
        }
        DeleteMesOrder(data).then(res => {
          if (res.code === '200') {
            this.$message.success('删除成功!')
            if (this.form.page > 1 && this.tableData.length === 1) {
              this.form.page--
            }
            this.getMesOrderSearch()
          }
        })
      }).catch(() => {
        this.$message.info('已取消删除')
      })
    },
    // å·¥å•关闭事件
    orderClose() {
      if (this.radioSelected.length < 1) {
        return this.$message.info('请先选择工单!')
      }
      console.log('工单关闭事件')
      this.tableData.forEach(item => {
        if (item.wo_code === this.radioSelected) {
          if (item.status === 'START') {
            return this.$message.info('当前工单未完工,无法关闭!')
          } else if (item.status === 'CLOSED') {
            return this.$message.info('工单已关闭,无需再关闭!')
          } else {
            this.$confirm('是否确认关闭工单?', '提示', {
              confirmButtonText: '确定',
              cancelButtonText: '取消',
              type: 'warning'
            }).then(() => {
              const data = {
                wocode: item.wo_code,
                m_po: item.m_po
              }
              ClosedMesOrder(data).then(res => {
                if (res.code === '200') {
                  this.$message.success('工单关闭成功!')
                  this.getMesOrderSearch()
                  // this.radioSelected = ''
                }
              })
            }).catch(() => {
              this.$message.info('已取消关闭!')
            })
          }
        }
      })
    },
    // å¯¹è¯æ¡†äº§å“ä¿¡æ¯å€¼æ”¹å˜
    partcodeChangeDialog(val) {
      console.log(val)
      this.dialogForm.partname = this.partArr.find(item => item.partcode === val).partname
      this.dialogForm.partcode = this.partArr.find(item => item.partcode === val).partcode
      this.dialogForm.partspec = this.partArr.find(item => item.partcode === val).partspec
      // const { data: res } = await PartSelectRpute({ partcode: val })
      // this.routeArr = res
      // this.dialogForm.routecode = ''
      this.partcodeChange(val)
    },
    // å¯¹è¯æ¡†å…³é—­äº‹ä»¶
    handleClose() {
      this.dialogForm.partname = '' // äº§å“åç§°
      this.dialogForm.partspec = '' // äº§å“è§„æ ¼
      this.dialogForm.wkshopname = '' // ç”Ÿäº§è½¦é—´åç§°
      this.dialogForm.routename = '' // å·¥è‰ºè·¯çº¿åç§°
      this.dialogForm.mesorderstus = 'NEW' // å·¥å•状态码
      this.dialogForm.mesordercode = '' // å·¥å•编号
      this.dialogForm.partcode = '' // äº§å“ç¼–码
      this.dialogForm.mesqty = '' // å·¥å•数量
      this.dialogForm.ordertype = 'PO' // å·¥å•类型
      this.dialogForm.sourceorder = '' // æºå•单号
      this.dialogForm.routecode = '' // å·¥è‰ºè·¯çº¿ç¼–码
      this.dialogForm.wkshopcode = '' // ç”Ÿäº§è½¦é—´ç¼–码
      this.dialogForm.planstartdate = '' // è®¡åˆ’开始时间
      this.dialogForm.planenddate = '' // è®¡åˆ’完成时间
      this.dialogForm.orderlev = '' // å·¥å•等级
      this.$refs.dialogForm.clearValidate()
    },
    // å¯¹è¯æ¡†å–消
    dialogVisibleCancel() {
      this.dialogVisible = false
    },
    // å¯¹è¯æ¡†ç¡®è®¤
    dialogVisibleConfirm() {
      this.$refs.dialogForm.validate(valid => {
        if (valid) {
          if (this.dialogForm.ordertype === 'FO' && this.dialogForm.sourceorder.toString().trim().length <= 0) {
            return this.$message.info('源单单号不能为空!')
          }
          const data = {
            // partname: this.dialogForm.partname, // äº§å“åç§°
            // partspec: this.dialogForm.partspec, // äº§å“è§„æ ¼
            // wkshopname: this.dialogForm.wkshopname, // ç”Ÿäº§è½¦é—´åç§°
            // routename: this.dialogForm.routename, // å·¥è‰ºè·¯çº¿åç§°
            mesorderstus: this.dialogForm.mesorderstus, // å·¥å•状态码
            mesordercode: this.dialogForm.mesordercode, // å·¥å•编号
            partcode: this.dialogForm.partcode, // äº§å“ç¼–码
            mesqty: this.dialogForm.mesqty, // å·¥å•数量
            ordertype: this.dialogForm.ordertype, // å•据类型
            sourceorder: this.dialogForm.sourceorder, // æºå•单号
            routecode: this.dialogForm.routecode, // å·¥è‰ºè·¯çº¿ç¼–码
            wkshopcode: this.dialogForm.wkshopcode, // ç”Ÿäº§è½¦é—´ç¼–码
            planstartdate: this.dialogForm.planstartdate, // è®¡åˆ’开始时间
            planenddate: this.dialogForm.planenddate, // è®¡åˆ’完成时间
            orderlev: this.dialogForm.orderlev, // å·¥å•等级
            OperType: this.operation === 'add' ? 'Add' : 'Update'
          }
          AddUpdateMesOrder(data).then(res => {
            if (res.code === '200') {
              this.dialogVisible = false
              this.handlePrint()
              this.$message.success(this.operation === 'add' ? '添加成功!' : '派发成功!')
              // this.dialogVisible = false
              this.getMesOrderSearch()
            } else {
              this.$message.error(this.operation === 'add' ? '添加失败!' : '派发失败!')
            }
          })
        }
      })
    },
    // æ´¾å‘打印
    async sendPrint() {
      const data = {
        username: getCookie('admin'),
        // username: getCookie('username'),
        mesordercode: this.dialogForm.mesordercode
      }
      const res = await MesOrderPrintSearch1(data)
      // const res = await PrintOrder(data)
      if (res.code === '200') {
        // å‚数具体说明请参考帮助文档中的“WEB报表(B/S报表)->WEB报表客户端->启动参数说明”部分
        var args = {
          type: 'print', // preview  print
          showOptionDlg: false, // å¦‚果不显示打印对话框而直接打印,将此行注释去掉即可
          report: urlAddRandomNo('./static/grf/产品流传单A4.grf'),
          data: res.data
        }
        webapp_ws_ajax_run(args)
      }
    },
    // èŽ·å–é¡µé¢é«˜åº¦
    getHeight() {
      this.$nextTick(() => {
        this.mainHeight = window.innerHeight - 85
        this.tableHeight = this.mainHeight - 250
        if (window.innerHeight < 769) {
          this.tableHeight = this.tableHeight - 20
        }
        this.isIpad = window.innerHeight < 769 && window.innerWidth < 1367
      })
    },
    // å·¥è‰ºè·¯çº¿æ”¾å¤§é•œç‚¹å‡»
    async searchClick() {
      if (this.dialogForm.routecode === '') {
        return this.$message.info('请先选择工艺路线!')
      }
      this.dialogVisibleSearch = true
      const { data: res } = await SelectRouteStep({ routecode: this.dialogForm.routecode })
      this.searchTableData = res
    },
    dialogVisibleSearchBack() {
      this.dialogVisibleSearch = false
    },
    // å¤„理打印
    handlePrint() {
      // const number = Math.random() * Math.random()
      // this.number = number === 0 ? (10 + Math.random()) : number
      // console.log(number)
      const data2 = {
        username: getCookie('admin'),
        mesordercode: this.dialogForm.mesordercode
      }
      MesOrderPrintSearch1(data2).then(res2 => {
        if (res2.code === '200') {
          const res3 = res2.data.recordset
          this.tableDataPrint = res3
          this.formApprove.mesordercode = res3[0].wo_code
          this.formApprove.m_po = res3[0].m_po
          this.formApprove.partcode = res3[0].partcode
          this.formApprove.partname = res3[0].partname
          this.formApprove.partspec = res3[0].partspec
          this.formApprove.plan_qty = res3[0].plan_qty
          this.formApprove.routename = res3[0].routename
          this.formApprove.lm_date = res3[0].lm_date
          this.$nextTick(() => {
            res3.forEach(i => {
              this.bindQRCode(i.seq, i.stepqrcode, 'small')
            })
            // this.bindQRCode('0', this.formApprove.mesordercode, 'big')
            const div = document.getElementById('qrCode')
            // è¿™ä¹ˆå¤šä»£ç åªéœ€è¦è¿™ä¸€å¥å®žçŽ°æˆ‘ä»¬æ‰€éœ€è¦çš„åŠŸèƒ½ï¼Œå®šä½div滚动条位置在底部,scrollHeight计算出div的高度,再scrollTop è®¾ç½®æ»šåŠ¨æ¡çš„é«˜åº¦ä¸ºå¤šå°‘
            // div.scrollTop = div.scrollHeight // æ»šåŠ¨æ¡ä½äºŽæœ€åº•éƒ¨
            div.scrollTop = 0 // æ»šåŠ¨æ¡ä½äºŽæœ€é¡¶éƒ¨
          })
        }
      })
      this.dialogVisibleApprove = true
    },
    dialogVisibleTaskClose() {
      this.dialogForm.mesordercode = ''
    },
    /*
  * æ‰‹åŠ¨ç‚¹å‡»æ‰“å°
  * */
    // è¿”回按钮
    dialogVisibleBackPreview() {
      this.dialogVisibleApprove = false
    },
    // dialogVisibleConfirmPreview(param) {
    //   this.$refs.dialogForm.validate(valid => {
    //     if (valid) {
    //       const data = {
    //         username: getCookie('admin'),
    //         mesordercode: this.dialogForm.mesordercode
    //       }
    //       MesOrderPrintSearch1(data).then(res => {
    //         if (res.code === '200') {
    //           this.dialogVisibleApprove = true
    //           console.log(res, 11)
    //         }
    //       })
    //     }
    //   })
    // },
    // ç”ŸæˆäºŒç»´ç 
    bindQRCode(seq, text, size) {
      if (size === 'big') {
        console.log(text, 1)
        new QRCode(this.$refs.qrCodeDiv0, {
          text: text,
          width: size === 'big' ? 90 : 60,
          height: size === 'big' ? 90 : 60,
          // colorDark: '#333333', // äºŒç»´ç é¢œè‰²
          colorDark: '#000', // äºŒç»´ç é¢œè‰²
          colorLight: '#ffffff', // äºŒç»´ç èƒŒæ™¯è‰²
          correctLevel: QRCode.CorrectLevel.L// å®¹é”™çŽ‡ï¼ŒL/M/H
        })
      } else {
        new QRCode(this.$refs['qrCodeDiv' + seq], {
          text: text,
          width: size === 'big' ? 90 : 60,
          height: size === 'big' ? 90 : 60,
          // colorDark: '#333333', // äºŒç»´ç é¢œè‰²
          colorDark: '#000', // äºŒç»´ç é¢œè‰²
          colorLight: '#ffffff', // äºŒç»´ç èƒŒæ™¯è‰²
          correctLevel: QRCode.CorrectLevel.L// å®¹é”™çŽ‡ï¼ŒL/M/H
        })
      }
    },
    dialogVisibleConfirmClose() {
      // this.dialogForm.mesordercode = ''
      this.formApprove.mesordercode = ''
      this.formApprove.m_po = ''
      this.formApprove.partcode = ''
      this.formApprove.partname = ''
      this.formApprove.partspec = ''
      this.formApprove.plan_qty = ''
      this.formApprove.routename = ''
      this.formApprove.lm_date = ''
      // this.$refs.qrCodeDiv0.title = ''
      this.tableDataPrint = []
    },
    // è¡¥æ‰“按钮
    supplementClick() {
      this.dialogVisibleTask = false
      this.handlePrint()
    },
    // è¡¥æ‰“小标签
    supplementSmallClick(row) {
      // let obj = {}
      this.taskTableData.forEach((item, index) => {
        if (item.seq === row.seq) {
          console.log(item)
          this.qrForm = {
            qrvalue: item.seq === this.taskTableData.length ? item.wo_code + ';' + item.stepcode : item.wo_code + ';' + this.taskTableData[item.seq].stepcode,
            startqty: item.seq === this.taskTableData.length ? item.plan_qty : this.taskTableData[item.seq].plan_qty,
            wo_code: item.wo_code,
            partcode: item.partcode,
            partname: item.partname,
            nextstepname: item.seq === this.taskTableData.length ? item.stepname : this.taskTableData[item.seq].stepname,
            operator: getCookie('username'),
            operatorTime: handleDatetime2(new Date())
          }
          this.$nextTick(() => {
            console.log(this.qrForm.qrvalue, 3333)
            this.bindQRCode2(this.qrForm.qrvalue)
          })
        }
      })
      // this.dialogVisibleTask = false
      this.dialogVisible2 = true
      console.log(this.qrForm, 1111)
    },
    dialogVisible2Close() {
      this.qrForm.qrvalue = ''
      this.qrForm.startqty = ''
      this.qrForm.wo_code = ''
      this.qrForm.partcode = ''
      this.qrForm.partname = ''
      this.qrForm.nextstepname = ''
      this.qrForm.operator = ''
      this.qrForm.operatorTime = ''
      // this.$refs.qrCodeDiv2 = ''
    },
    // ç”ŸæˆäºŒç»´ç 
    bindQRCode2(text) {
      new QRCode(this.$refs.qrCodeDiv2, {
        text: text,
        width: 60,
        height: 60,
        colorDark: '#000', // äºŒç»´ç é¢œè‰²
        colorLight: '#ffffff', // äºŒç»´ç èƒŒæ™¯è‰²
        correctLevel: QRCode.CorrectLevel.L// å®¹é”™çŽ‡ï¼ŒL/M/H
      })
    },
    // æŠ¥åºŸè¡¥å•情况下可点击选择
    mesordertsourcesearchclick() {
      if (this.dialogForm.ordertype === 'PO') {
        return this.$message.info('工单类型为报废补单情况下可选择!')
      }
      this.getErpOrderSearch()
      this.dialogVisibleSource = true
    },
    async getErpOrderSearch() {
      let tempDate2 = this.sourceForm.paystartdate
      if (tempDate2.length > 0) {
        tempDate2 = handleDatetime(tempDate2[0]) + '~' + handleDatetime(tempDate2[1])
      }
      let tempDate = this.sourceForm.payenddate
      if (tempDate.length > 0) {
        tempDate = handleDatetime(tempDate[0]) + '~' + handleDatetime(tempDate[1])
      }
      const data = {
        erporderstus: this.sourceForm.erporderstus, // è®¢å•状态码
        erpordercode: this.sourceForm.erpordercode, // è®¢å•编号
        partcode: this.sourceForm.partcode, // äº§å“ç¼–码
        partname: this.sourceForm.partname, // äº§å“åç§°
        partspec: this.sourceForm.partspec, // äº§å“è§„æ ¼
        paystartdate: tempDate2, // äº¤ä»˜æ—¶é—´
        payenddate: tempDate, // äº¤ä»˜æ—¶é—´
        creatuser: this.sourceForm.creatuser, // åˆ›å»ºäººå‘˜
        prop: this.sourceForm.prop, // æŽ’序字段
        order: this.sourceForm.order, // æŽ’序字段
        page: this.sourceForm.page, // ç¬¬å‡ é¡µ
        rows: this.sourceForm.rows // æ¯é¡µå¤šå°‘条
      }
      const res = await ErpOrderSearch(data)
      this.sourceTableData = res.data.filter(item => item.status !== 'NEW')
      this.sourceFormTotal = res.count
    },
    // å•选框选中获取当前行信息
    getCurrentRowSource(id) {
      this.radioSelectedId = id
    },
    sourceSearch() {
      this.getErpOrderSearch()
    },
    sourceReset() {
      this.sourceForm.erporderstus = ''
      this.sourceForm.erpordercode = ''
      this.sourceForm.partcode = ''
      this.sourceForm.partname = ''
      this.sourceForm.partspec = ''
      this.sourceForm.paystartdate = ''
      this.sourceForm.payenddate = ''
      this.sourceForm.creatuser = ''
      this.sourceForm.createdate = ''
      this.getErpOrderSearch()
    },
    dialogVisibleSourceClose() {
      this.radioSelectedId = ''
      this.sourceForm.erporderstus = ''
      this.sourceForm.erpordercode = ''
      this.sourceForm.partcode = ''
      this.sourceForm.partname = ''
      this.sourceForm.partspec = ''
      this.sourceForm.paystartdate = ''
      this.sourceForm.payenddate = ''
      this.sourceForm.creatuser = ''
      this.sourceForm.createdate = ''
      this.isExpandDialog = false
      this.sourceTableData = []
    },
    dialogVisibleSourceBack() {
      this.dialogVisibleSource = false
    },
    dialogVisibleSourceConfirm() {
      console.log(this.radioSelectedId)
      this.sourceTableData.forEach(item => {
        if (item.id === this.radioSelectedId) {
          this.dialogForm.sourceorder = item.wo
          this.dialogForm.partcode = item.partcode
          this.dialogForm.partspec = item.partspec
        }
      })
      this.dialogVisibleSource = false
      this.partcodeChange(this.dialogForm.partcode)
    },
    mesordertypeChange(val) {
      if (val === 'PO') {
        this.dialogForm.sourceorder = ''
        this.dialogForm.partcode = ''
        this.dialogForm.partspec = ''
      }
    },
    /* å…³è”工艺路线模块*/
    // å…³è”工艺路线
    async routeClick(row) {
      console.log(row)
      // this.defaultroute_code = row.default_route
      this.dialogFormRoute.projectCode = row.partcode
      this.dialogFormRoute.projectName = row.partname
      this.dialogVisibleRoute = true
      const { data: res } = await InventoryFileAssociationRoute({ partcode: this.dialogFormRoute.projectCode })
      this.dialogFormRoute.routeOperationArr = res
      this.dialogFormRoute.routeOperationArr.forEach((item, index) => {
        item.isSelected1 = false
        item.isSelected2 = false
        if (index === 0) {
          item.isSelected1 = true
          this.projectTableData = item.Data
        }
        if (item.flag === 'Y') {
          item.isSelected2 = true
          this.$nextTick(() => {
            $('input:checkbox').eq(index).prop('checked', true)
          })
        }
      })
      this.defaultroute_codeArr = this.dialogFormRoute.routeOperationArr.filter(item => item.flag === 'Y')
    },
    // å¯¹è¯æ¡†å…³é—­
    handleCloseRoute() {
      this.dialogFormRoute.routeOperationArr = []
      this.defaultroute_codeArr = []
      this.defaultroute_code = ''
      this.projectTableData = []
    },
    // å–消
    routeDialogVisibleCancel() {
      this.dialogVisibleRoute = false
    },
    // ç¡®å®š
    async routeDialogVisibleConfirm() {
      const temp = this.dialogFormRoute.routeOperationArr.filter(item => item.isSelected2)
      if (this.defaultroute_code === '' && temp.length > 0) {
        return this.$message.info('默认工艺路线不能为空!')
      }
      // æäº¤æ ¼å¼
      const data = []
      this.dialogFormRoute.routeOperationArr.forEach(item => {
        if (item.isSelected2) {
          data.push({ code: item.code, name: item.name })
        }
      })
      const res = await SaveInventoryFile(this.dialogFormRoute.projectCode, this.defaultroute_code, data)
      if (res.code === '200') {
        this.$message.success('保存成功!')
        await this.getMesOrderSearch()
        this.dialogVisibleRoute = false
      }
    },
    // å¤§ç›’子点击事件
    myCheckboxClick(val) {
      console.log(val, 1)
      this.dialogFormRoute.routeOperationArr.forEach(item => {
        item.isSelected1 = val.code === item.code
      })
      this.projectTableData = val.Data
    },
    // å°ç›’子点击事件
    myCheckboxInputClick(val) {
      console.log(val, 2)
      val.isSelected2 = !val.isSelected2
      this.dialogFormRoute.routeOperationArr.forEach((item, index) => {
        if (val.code === item.code) {
          item.flag = !item.flag
        }
      })
      if (val.code === this.defaultroute_code) {
        this.defaultroute_code = ''
      }
      this.defaultroute_codeArr = this.dialogFormRoute.routeOperationArr.filter(item => item.isSelected2)
    }
  }
}
</script>
<style lang="scss" scoped>
$main_color: #42b983;
.dialogVisibleRoute {
  .myCheckboxGroup {
    display: flex;
    flex-wrap: wrap;
    .myCheckbox {
      //border: 1px solid $main_color;
      border: 1px solid #eee;
      display: flex;
      min-width: 100px;
      padding: 10px;
      margin: 10px 30px 0 0;
      border-radius: 5px;
      cursor: default;
      .myCheckboxInput {
        margin: 1px 5px 0 0;
        cursor: pointer;
      }
    }
    //.myCheckbox{
    //  border: 1px solid $main_color;
    //}
    input[type=checkbox] {
      cursor: pointer;
      position: relative;
      width: 14px;
      height: 14px;
      font-size: 14px;
    }
    input[type=checkbox]::after {
      position: absolute;
      top: 0;
      //color: rgb(130, 35, 35);
      color: $main_color;
      width: 14px;
      height: 14px;
      display: inline-block;
      visibility: visible;
      padding-left: 0px;
      text-align: center;
      content: ' ';
      border-radius: 3px
    }
    input[type=checkbox]:checked::after {
      //content: "✓";
      content: "√";
      color: #fff;
      font-size: 12px;
      font-weight: bold;
      background-color: $main_color;
    }
  }
}
.dialogVisibleRoute {
  ::v-deep .el-dialog__body {
    padding: 20px 20px !important;
  }
}
.defaultroute_code ::v-deep .el-input__suffix-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -3px;
}
.el-date-editor {
  font-size: 14px;
}
::v-deep .el-dialog__body {
  padding: 20px 100px !important;
}
.dialogVisibleSearch ::v-deep .el-dialog__body {
  padding: 20px 20px !important;
}
.dialogVisibleConfirmClass ::v-deep .el-dialog__body {
  padding: 20px 20px !important;
}
::v-deep .el-table .caret-wrapper {
  transform: scale(0.8);
}
::v-deep .el-button--text {
  color: $main_color;
  font-size: 14px;
  cursor: pointer;
}
.operationClass {
  height: 23px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
::v-deep .el-radio.is-bordered + .el-radio.is-bordered {
  margin: 10px 30px 0px 0;
}
.body ::v-deep .el-form-item {
  margin-bottom: 0;
}
.elForm ::v-deep .el-form-item {
  margin-bottom: 0;
}
//.elTableDiv {
::v-deep .el-radio__label {
  display: none;
}
//}
.el-table::before {
  height: 0;
}
//.dialogVisibleConfirmClass >>>.el-table--border, .el-table--fit {
//  border-bottom: 2px solid #000 ;
//  //outline: #000 solid 2px !important;
//}
.tableDataPrint ::v-deep div.cell {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}
.formContent {
  width: 240px;
}
</style>
<style media="print">
/*@media print {*/
@page {
  size: auto;
  margin: 3mm;
}
</style>
<style>
.formContent .el-form-item__label {
  color: #000 !important;
}
</style>
<!--公共页面样式-->
<style lang="scss" scoped>
$main_color: #42b983;
::v-deep .el-range-input {
  font-size: 14px !important;
}
::v-deep .el-range__icon {
  line-height: 28px !important;
}
::v-deep .el-range-separator {
  line-height: 28px !important;
}
::v-deep .el-range-input {
  font-size: 14px;
}
::v-deep .el-range-separator {
  display: flex;
  justify-content: center;
  align-items: center;
}
.el-icon-share, .el-icon-delete, .el-icon-edit-outline {
  color: $main_color;
  cursor: pointer;
}
.el-icon-edit-outline {
  margin-right: 15px;
}
::v-deep .el-button--primary, .el-button--default, .el-button--info {
  height: 34px;
  display: flex;
  align-items: center;
  padding: 0 15px;
}
::v-deep .el-button--primary {
  //background-color: $main_color !important;
}
::v-deep .el-button--default {
  background-color: #f8f8fa;
  border: none;
}
::v-deep .el-input__inner {
  height: 34px;
  line-height: 34px;
  //color: #a7a7a7;
}
::v-deep .el-dialog__body {
  padding: 20px 100px !important;
}
::v-deep .dialogVisibleRoles .el-dialog__body {
  padding: 20px 20px !important;
}
::v-deep .importPickerClass .el-dialog__body {
  padding: 20px 20px !important;
}
::v-deep .el-dialog__footer {
  display: flex;
  justify-content: flex-end;
}
::v-deep .el-table .caret-wrapper {
  transform: scale(0.8);
}
::v-deep .cell {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
::v-deep .el-table::before {
  height: 0;
}
::v-deep .el-table__body-wrapper {
  background-color: #f8f8fa;
}
::v-deep .el-table__body .el-table__row.hover-row td {
  background-color: #eaecef;
}
::v-deep .el-form--inline .el-form-item__label {
  color: #a7a7a7;
}
.body ::v-deep .el-divider {
  border: 1px solid #eee;
  width: 99%;
  margin: 10px auto;
}
.body ::v-deep .el-form-item {
  margin-bottom: 0;
}
.userDialogVisible ::v-deep .el-form-item {
  margin-bottom: 0;
}
.dateMini {
  ::v-deep .el-input__inner {
    line-height: 34px;
    height: 34px;
    width: 200px;
    display: flex;
    font-size: 14px !important;
    align-items: center !important;
  }
  ::v-deep .el-input__prefix {
    margin-top: -3px;
  }
  //::v-deep .el-range__icon{
  //  line-height: 28px;
  //}
}
</style>
<style>
.el-table .custom-row {
  background: #f8f8fa;
}
</style>
src/views/scgl/gdplgb.vue
@@ -1,9 +1,12 @@
<template>
  <div>
    <div class="body" :style="{height:mainHeight+'px'}">
      <div class="bodyTopButtonGroup">
        <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 class="bodyTopButtonGroup" style="justify-content: space-between">
        <!--        <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>-->
        <el-button icon="el-icon-switch-button" @click="handleClose('close')">批量关单</el-button>
        <el-button icon="el-icon-switch-button" @click="handleClose('noClose')">批量反关单</el-button>
      </div>
      <div class="bodyTopFormGroup">
@@ -15,24 +18,39 @@
          style="display: flex;justify-content: space-between"
        >
          <div class="elForm">
            <el-form-item label="组织编码" style=" display: flex;">
              <el-input v-model="form.OrgCode" placeholder="请输入" style="width: 200px" />
            <el-form-item label="工单状态" style=" display: flex;">
              <el-input v-model="form.mesorderstus" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item label="组织名称" style=" display: flex;">
              <el-input v-model="form.OrgName" placeholder="请输入" style="width: 200px" />
            <el-form-item label="工单编号" style=" display: flex;">
              <el-input v-model="form.mesordercode" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item label="组织类型" style=" display: flex;">
              <el-select v-model="form.OrgType" style="width: 200px" placeholder="请选择">
            <el-form-item label="源单单号" style=" display: flex;">
              <el-input v-model="form.sourceorder" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item label="单据类型" style=" display: flex;">
              <el-select v-model="form.ordertype" style="width: 200px" placeholder="请选择">
                <el-option
                  v-for="item in OrgTypeArr"
                  v-for="item in ordertypeArr"
                  :key="item.code"
                  :label="item.name"
                  :value="item.code"
                />
              </el-select>
            </el-form-item>
            <el-form-item label="产品编码" style=" display: flex;">
              <el-input v-model="form.partcode" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="产品名称" style=" display: flex;">
              <el-input v-model="form.partname" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="产品规格" style=" display: flex;">
              <el-input v-model="form.partspec" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="创建人员" style=" display: flex;">
              <el-input v-model="form.UserName" style="width: 200px" placeholder="请输入" />
              <el-input v-model="form.creatuser" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="创建时间" style=" display: flex;">
              <el-input v-model="form.createdate" style="width: 200px" placeholder="请输入" />
            </el-form-item>
          </div>
          <div style="display: flex;align-items: start;margin-top: 5px;z-index: 2">
@@ -44,6 +62,7 @@
      <div class="elTableDiv">
        <el-table
          ref="multipleTable"
          :data="tableData"
          :height="tableHeight+'px'"
          border
@@ -52,38 +71,192 @@
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
          @selection-change="handleSelectionChange"
          @sort-change="sortChange"
        >
          <el-table-column
            type="selection"
            fixed
            width="50"
          />
          <!--          <el-table-column-->
          <!--            width="50"-->
          <!--            fixed-->
          <!--          >-->
          <!--            <template slot-scope="{row}">-->
          <!--              <el-radio-->
          <!--                v-model="radioSelected"-->
          <!--                :label="row.wo_code"-->
          <!--                style="color: transparent;padding-left: 10px;"-->
          <!--                @change.native="getCurrentRow(row.wo_code)"-->
          <!--              />-->
          <!--            </template>-->
          <!--          </el-table-column>-->
          <el-table-column
            prop="RowNum"
            width="50"
            fixed
            label="序号"
            fixed
          />
          <el-table-column
            prop="org_code"
            label="组织编码"
            prop="status"
            label="订单状态"
            sortable="custom"
            width="110"
          >
            <template slot-scope="{row}">
              <div v-if="row.status==='NEW'">新工单</div>
              <!--              <div v-if="row.status==='CREATING'">执行中</div>-->
              <!--              <div v-if="row.status==='CREATED'">已关闭</div>-->
              <div v-if="row.status==='ALLO'">已派发</div>
              <div v-if="row.status==='START'">开工</div>
              <div v-if="row.status==='CLOSED'">完工</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="wo_code"
            label="工单编号"
            sortable="custom"
            min-width="160"
          />
          <el-table-column
            prop="m_po"
            label="源单单号"
            sortable="custom"
            min-width="160"
          />
          <el-table-column
            prop="wotype"
            label="单据类型"
            sortable="custom"
            min-width="120"
          >
            <template slot-scope="{row}">
              <div v-if="row.wotype==='PO'">标准工单</div>
              <div v-else-if="row.wotype==='FO'">报废补单</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="partcode"
            label="产品编码"
            sortable="custom"
            min-width="120"
          />
          <el-table-column
            prop="partname"
            min-width="150"
            label="产品名称"
            sortable="custom"
          />
          <el-table-column
            prop="org_name"
            label="组织名称"
            prop="partspec"
            label="产品规格"
            sortable="custom"
            width="110"
          >
            <template slot-scope="{row}">
              <div v-if="row.partspec">{{ row.partspec }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="plan_qty"
            label="任务数量"
            sortable="custom"
            width="110"
          />
          <el-table-column
            prop="description"
            label="组织类型"
            prop="good_qty"
            label="合格数量"
            sortable="custom"
            width="110"
          />
          <el-table-column
            prop="parentorg_name"
            label="上级单位"
            prop="ng_qty"
            label="不良数量"
            sortable="custom"
            width="110"
          />
          <el-table-column
            prop="bad_qty"
            label="报废数量"
            sortable="custom"
            width="110"
          />
          <el-table-column
            prop="wkshp_name"
            label="生产车间"
            sortable="custom"
            width="120"
          >
            <template slot-scope="{row}">
              <div v-if="row.wkshp_name">{{ row.wkshp_name }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="route_name"
            label="工艺路线"
            show-tooltip-when-overflow
            sortable="custom"
            width="180"
          >
            <template slot-scope="{row}">
              <div v-if="row.route_name">{{ row.route_name }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <!--          <el-table-column-->
          <!--            prop="route_name"-->
          <!--            label="关联工艺路线"-->
          <!--            min-width="110"-->
          <!--          >-->
          <!--            <template slot-scope="{row}">-->
          <!--              <i v-if="row.route_name" class="el-icon-share" @click="routeClick(row)" />-->
          <!--              <i v-else style="color:rgb(180 ,181, 185)" class="el-icon-share" @click="routeClick(row)" />-->
          <!--            </template>-->
          <!--          </el-table-column>-->
          <el-table-column
            prop="plan_startdate"
            label="计划开始时间"
            sortable="custom"
            width="160"
          >
            <template slot-scope="{row}">
              <div v-if="row.plan_startdate">{{ row.plan_startdate }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="plan_enddate"
            label="计划结束时间"
            sortable="custom"
            width="160"
          >
            <template slot-scope="{row}">
              <div v-if="row.plan_enddate">{{ row.plan_enddate }}</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="piroque"
            label="工单等级"
            sortable="custom"
            width="120"
          >
            <template slot-scope="{row}">
              <div v-if="row.piroque==='1'">特级</div>
              <div v-if="row.piroque==='2'">紧急</div>
              <div v-if="row.piroque==='3'">正常</div>
              <div v-else>/</div>
            </template>
          </el-table-column>
          <el-table-column
            prop="lm_user"
            label="创建人员"
            sortable="custom"
            width="120"
          />
          <el-table-column
            prop="lm_date"
@@ -91,22 +264,26 @@
            width="160"
            sortable="custom"
          />
          <el-table-column
            label="操作"
            width="120"
            fixed="right"
          >
            <template slot-scope="{row}">
              <div class="operationClass">
                <el-tooltip class="item" effect="dark" content="编辑" placement="top">
                  <i class="el-icon-edit-outline" @click="edit('edit',row)" />
                </el-tooltip>
                <el-tooltip v-del-tab-index class="item" effect="dark" content="删除" placement="top">
                  <i class="el-icon-delete" @click="del(row)" />
                </el-tooltip>
              </div>
            </template>
          </el-table-column>
          <!--          <el-table-column-->
          <!--            label="操作"-->
          <!--            width="120"-->
          <!--            fixed="right"-->
          <!--          >-->
          <!--            <template slot-scope="{row}">-->
          <!--              <div class="operationClass">-->
          <!--                <el-tooltip class="item" effect="dark" content="工序任务" placement="top">-->
          <!--                  <i-->
          <!--                    class="el-icon-tickets"-->
          <!--                    style="cursor: pointer;color: #42b983;margin-right: 15px"-->
          <!--                    @click="check(row)"-->
          <!--                  />-->
          <!--                </el-tooltip>-->
          <!--                <el-tooltip v-del-tab-index class="item" effect="dark" content="删除" placement="top">-->
          <!--                  <i class="el-icon-delete" @click="del(row)" />-->
          <!--                </el-tooltip>-->
          <!--              </div>-->
          <!--            </template>-->
          <!--          </el-table-column>-->
        </el-table>
      </div>
      <!--分页-->
@@ -115,54 +292,21 @@
        :page.sync="form.page"
        :limit.sync="form.rows"
        align="right"
        layout="prev, pager, next,sizes"
        layout="total,prev, pager, next,sizes"
        popper-class="select_bottom"
        @pagination="getOrganizationSearch"
        @pagination="getMesOrderBitchClosedSearch"
      />
    </div>
    <el-dialog
      :title="operation==='add'?'新增':'编辑'"
      :visible.sync="dialogVisible"
      width="800px"
      :close-on-click-modal="false"
      top="15vh"
      @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-form-item prop="SupUnit" label="上级单位">
          <el-select
            v-model="dialogForm.SupUnit"
            style="width: 200px"
            placeholder="请选择"
            :popper-append-to-body="false"
          >
            <el-option
              v-for="item in SupUnitArr"
              :key="item.code"
              :label="item.name"
              :value="item.code"
            />
          </el-select>
        </el-form-item>
      </el-form>
      <span slot="footer" class="dialog-footer">
        <div class="footerButton">
          <el-button @click="dialogVisibleCancel">取 æ¶ˆ</el-button>
          <el-button type="primary" @click="dialogVisibleConfirm">ç¡® å®š</el-button>
        </div>
      </span>
    </el-dialog>
    <!--导入组件-->
    <import-picker ref="importPickerFunc" class="importPickerClass" :shows.sync="shows" :title="title_value" :colos="colos" :code="code" />
    <import-picker
      ref="importPickerFunc"
      class="importPickerClass"
      :shows.sync="shows"
      :title="title_value"
      :colos="colos"
      :code="code"
    />
  </div>
</template>
@@ -172,77 +316,41 @@
import { AddUpdateOrganization, DeleteOrganization, OrganizationSearch, PrentOrganization } from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
import { MesOrderBitchAntiClosedSeave, MesOrderBitchClosedSearch, MesOrderBitchClosedSeave } from '@/api/scgl'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
      form: {
        OrgCode: '', // ç»„织架构代码
        OrgName: '', // ç»„织架构名称
        OrgType: '', // ç»„织类型
        UserName: '', // åˆ›å»ºäººå‘˜
        mesorderstus: '', // å·¥å•状态
        mesordercode: '', // å·¥å•编号
        sourceorder: '', // æºå•单号
        ordertype: '', // å•据类型
        partcode: '', // äº§å“ç¼–码
        partname: '', // äº§å“åç§°
        partspec: '', // äº§å“è§„æ ¼
        creatuser: '', // åˆ›å»ºäººå‘˜
        createdate: '', // åˆ›å»ºæ—¶é—´
        prop: 'lm_date', // æŽ’序字段
        order: 'desc', // æŽ’序字段
        page: 1, // ç¬¬å‡ é¡µ
        rows: 20 // æ¯é¡µå¤šå°‘条
      },
      OrgTypeArr: [
        { label: '工厂', value: 'F' },
        { label: '部门', value: 'D' },
        { label: '车间', value: 'W' },
        { label: '科室', value: 'K' },
        { label: '生产线', value: 'L' }
      ordertypeArr: [// å·¥å•类型
        { code: 'PO', name: '标准工单' },
        { code: 'FO', name: '报废补单' }
      ],
      total: 10,
      tableData: [],
      dialogVisible: false,
      dialogForm: {
        OrgType: '',
        OrgCode: '',
        OrgName: '',
        SupUnit: ''// ä¸Šçº§å•位
      },
      operation: '',
      dialogFormRules: {
        OrgType: [
          { required: true, message: '请输入选择类型', trigger: ['blur', 'change'] }
        ],
        OrgCode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
        ],
        OrgName: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
        ],
        SupUnit: [
          { required: true, validator: validateTypeCode, trigger: ['blur', 'change'] }
        ]
      },
      multipleSelection: [],
      title_value: '数据导入 / ç‚¹æ£€éƒ¨ä½',
      code: '4',
@@ -253,20 +361,20 @@
  watch: {
    shows() {
      if (!this.shows) {
        this.getOrganizationSearch()
        this.getMesOrderBitchClosedSearch()
      }
    }
  },
  created() {
    this.getOrganizationSearch()
    this.getMesOrderBitchClosedSearch()
  },
  mounted() {
    window.addEventListener('resize', this.getHeight)
    this.getHeight()
  },
  methods: {
    async getOrganizationSearch() {
      const res = await OrganizationSearch(this.form)
    async getMesOrderBitchClosedSearch() {
      const res = await MesOrderBitchClosedSearch(this.form)
      this.tableData = res.data
      this.total = res.count
    },
@@ -281,11 +389,11 @@
      }
      this.form.order = order
      this.form.prop = prop
      this.getOrganizationSearch()
      this.getMesOrderBitchClosedSearch()
    },
    // æŸ¥è¯¢
    search() {
      this.getOrganizationSearch()
      this.getMesOrderBitchClosedSearch()
    },
    // å¯¼å…¥æŒ‰é’®
    upload() {
@@ -297,88 +405,71 @@
    },
    // é‡ç½®
    reset() {
      this.form.OrgCode = ''
      this.form.OrgName = ''
      this.form.OrgType = ''
      this.form.UserName = ''
      this.getOrganizationSearch()
      this.form.mesorderstus = ''
      this.form.mesordercode = ''
      this.form.sourceorder = ''
      this.form.ordertype = ''
      this.form.partcode = ''
      this.form.partname = ''
      this.form.partspec = ''
      this.form.creatuser = ''
      this.form.createdate = ''
      this.getMesOrderBitchClosedSearch()
    },
    // æ–°å¢žæŒ‰é’®
    add(operation) {
      this.operation = operation
      this.dialogVisible = true
    handleSelectionChange(val) {
      this.multipleSelection = val
    },
    // ä¿®æ”¹æŒ‰é’®
    edit(operation, row) {
      this.operation = operation
      this.dialogVisible = true
      this.$nextTick(() => {
        this.dialogForm.OrgCode = row.org_code
        this.dialogForm.OrgName = row.org_name
        this.dialogForm.SupUnit = row.parent_id
      })
    },
    // åˆ é™¤æŒ‰é’®
    async del(row) {
      this.$confirm('是否确认删除?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        DeleteOrganization({ orgid: row.code }).then(res => {
          if (res.code === '200') {
            this.$message.success('删除成功!')
            if (this.form.page > 1 && this.tableData.length === 1) {
              this.form.page--
            }
            this.getOrganizationSearch()
    handleClose(val) {
      const data = []
      if (val === 'close') {
        // åˆ¤æ–­é€»è¾‘:合格+不良>=任务数量时 ä¸”状态不为CLOSED
        this.multipleSelection.forEach(item => {
          if (item.status !== 'CLOSED' && parseFloat(item.good_qty) + parseFloat(item.ng_qty) + parseFloat(item.bad_qty) >= parseFloat(item.plan_qty)) {
            data.push({ wo_code: item.wo_code })
          }
        })
      }).catch(() => {
        this.$message.info('已取消删除')
      })
    },
    // å¯¹è¯æ¡†å…³é—­äº‹ä»¶
    handleClose() {
      this.dialogForm.OrgType = ''
      this.dialogForm.OrgCode = ''
      this.dialogForm.OrgName = ''
      this.dialogForm.SupUnit = ''
      this.$refs.dialogForm.clearValidate()
    },
    // å¯¹è¯æ¡†å–消
    dialogVisibleCancel() {
      this.dialogVisible = false
    },
    // å¯¹è¯æ¡†ç¡®è®¤
    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 => {
        this.$confirm('是否确认批量关单?', '提示', {
          confirmButtonText: '确定',
          cancelButtonText: '取消',
          type: 'warning'
        }).then(() => {
          MesOrderBitchClosedSeave({ dt: 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.$message.success('批量关单成功!')
              this.$refs.multipleTable.clearSelection()
            }
          })
        }
      })
        }).catch(() => {
          this.$message.info('已取消批量关单!')
        })
      } else if (val === 'noClose') {
        this.multipleSelection.forEach(item => {
          if (item.status === 'CLOSED') {
            data.push({ wo_code: item.wo_code })
          }
        })
        this.$confirm('是否确认批量反关单?', '提示', {
          confirmButtonText: '确定',
          cancelButtonText: '取消',
          type: 'warning'
        }).then(() => {
          MesOrderBitchAntiClosedSeave({ dt: data }).then(res => {
            if (res.code === '200') {
              this.$message.success('批量反关单成功!')
              this.$refs.multipleTable.clearSelection()
            }
          })
        }).catch(() => {
          this.$message.info('已取消批量反关单!')
        })
      }
    },
    // èŽ·å–é¡µé¢é«˜åº¦
    getHeight() {
      this.$nextTick(() => {
        this.mainHeight = window.innerHeight - 85
        this.tableHeight = this.mainHeight - 200
        this.tableHeight = this.mainHeight - 240
      })
    },
    tableRowClassName({ row, rowIndex }) {
@@ -391,15 +482,17 @@
<!--公共页面样式-->
<style lang="scss" scoped>
$main_color: #42b983;
::v-deep .el-button--text{
  font-size: 14px ;
  cursor: pointer ;
::v-deep .el-button--text {
  font-size: 14px;
  cursor: pointer;
}
.el-icon-share ,.el-icon-delete,.el-icon-edit-outline{
.el-icon-share, .el-icon-delete, .el-icon-edit-outline {
  color: $main_color;
  cursor: pointer;
}
.el-icon-edit-outline{
.el-icon-edit-outline {
  margin-right: 15px;
}
@@ -460,8 +553,8 @@
  background-color: #f8f8fa;
}
::v-deep .el-table__body .el-table__row.hover-row td{
  background-color: #eaecef ;
::v-deep .el-table__body .el-table__row.hover-row td {
  background-color: #eaecef;
}
::v-deep .el-form--inline .el-form-item__label {
@@ -482,7 +575,7 @@
  margin-bottom: 0;
}
::v-deep .el-select__caret{
::v-deep .el-select__caret {
  display: flex;
  align-items: center;
  justify-content: center;
src/views/scgl/scdd.vue
@@ -49,14 +49,13 @@
            <el-form-item label="产品名称" style=" display: flex;">
              <el-input v-model="form.partname" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="产品规格" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="产品规格" style=" display: flex;">
              <el-input v-model="form.partspec" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="创建人员" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="创建人员" style=" display: flex;">
              <el-input v-model="form.creatuser" style="width: 200px" placeholder="请输入" />
            </el-form-item>
            <el-form-item label="预计开工时间" label-width="100px" style=" display: flex;font-size: 14px;margin-top: 3px">
            <el-form-item v-show="isExpandForm" label="预计开工时间" label-width="100px" style=" line-height: 40px;;display: flex;font-size: 14px;">
              <el-date-picker
                v-model="form.paystartdate"
                type="daterange"
@@ -72,7 +71,7 @@
              <!--              :picker-options="expireTimeOption"-->
            </el-form-item>
            <el-form-item label="预计完工时间" label-width="100px" style=" display: flex;font-size: 14px;margin-top: 3px">
            <el-form-item v-show="isExpandForm" label="预计完工时间" label-width="100px" style=" display: flex;font-size: 14px;">
              <el-date-picker
                v-model="form.payenddate"
                type="daterange"
@@ -96,7 +95,7 @@
              <!--              />-->
            </el-form-item>
          </div>
          <div style="min-height: 100px">
          <div>
            <div style="display: flex;align-items: start;margin-top: 5px;z-index: 2;justify-content: end">
              <el-button type="primary" icon="el-icon-search" @click="search">查询</el-button>
              <el-button type="info" icon="el-icon-refresh" @click="reset">重置</el-button>
@@ -133,13 +132,23 @@
          </div>
        </el-form>
      </div>
      <div class="elTableDiv">
      <div
        class="bodyTopFormExpand"
        @click="isExpandForm=!isExpandForm"
      >
        <i
          :class="!isExpandForm?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <div class="elTableDiv" style="margin-top: 0">
        <el-table
          :data="tableData"
          :height="tableHeight+'px'"
          :height="isExpandForm?tableHeight:(tableHeight+40)+'px'"
          border
          :row-class-name="tableRowClassName"
          :style="{width: 100+'%',height:tableHeight+'px',}"
          :style="{width: 100+'%',height:isExpandForm?tableHeight:(tableHeight+40)+'px',}"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
@@ -474,7 +483,8 @@
          { required: true, message: '请输入下单单数', trigger: ['blur', 'change'] }
        ]
      }
      },
      isExpandForm: false
      // expireTimeOption: {
      //   disabledDate(time) {
      //     return time.getTime() > Date.now() - 8.64e6 // å¦‚果没有后面的-8.64e6就是不可以选择今天的
@@ -713,7 +723,7 @@
    getHeight() {
      this.$nextTick(() => {
        this.mainHeight = window.innerHeight - 85
        this.tableHeight = this.mainHeight - 260
        this.tableHeight = this.mainHeight - 250
        this.isIpad = window.innerHeight < 769 && window.innerWidth < 1367
        if (this.isIpad) {
src/views/template.vue
@@ -172,32 +172,14 @@
import { AddUpdateOrganization, DeleteOrganization, OrganizationSearch, PrentOrganization } from '@/api/jcsz'
import { getCookie } from '@/utils/auth'
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -234,14 +216,12 @@
          { required: true, message: '请输入选择类型', trigger: ['blur', 'change'] }
        ],
        OrgCode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        OrgName: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
        ],
        SupUnit: [
          { required: true, validator: validateTypeCode, trigger: ['blur', 'change'] }
        ]
      },
      title_value: '数据导入 / ç‚¹æ£€éƒ¨ä½',
src/views/wlgl/ckdy.vue
@@ -165,25 +165,14 @@
import { AddUpdateWareHouseDef, DeleteWareHouseDef, WareHouseDefSearch } from '@/api/wlgl'
import { SeaveSearchWhareHouseLocation } from '@/api/ErpSyncMes'
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'CKDY',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -210,7 +199,7 @@
      operation: '',
      dialogFormRules: {
        warehousecode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        warehousename: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/wlgl/kwdy.vue
@@ -192,25 +192,14 @@
<script>
import Pagination from '@/components/Pagination'
import { AddUpdateStorageDef, DeleteStorageDef, StorageDefSearch, WareHouseSelect } from '@/api/wlgl'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'KWDY',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -241,7 +230,7 @@
      operation: '',
      dialogFormRules: {
        storagecode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        storagename: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/xtsz/cjgg.vue
@@ -240,31 +240,12 @@
import { SystemAnnouncementAddUpdate, SystemAnnouncementDelete, SystemAnnouncementSearch } from '@/api/xtsz'
import { ShopSearch } from '@/api/dzkb'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Zzjg',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
src/views/zlgl/gxjybz.vue
@@ -268,32 +268,14 @@
  StepCheckItemSelect,
  StepCheckStanedSearch
} from '@/api/zlgl'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'ZJBZ',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -319,7 +301,7 @@
      operation: '',
      dialogFormRules: {
        code: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        name: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/zlgl/gxjyjl.vue
@@ -31,10 +31,10 @@
            <el-form-item label="工序名称" style=" display: flex;">
              <el-input v-model="form.stepname" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item label="标准名称" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="标准名称" style=" display: flex;">
              <el-input v-model="form.standname" placeholder="请输入" style="width: 200px" />
            </el-form-item>
            <el-form-item label="检验类型" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="检验类型" style=" display: flex;">
              <el-select v-model="form.checktype" style="width: 200px" placeholder="请选择">
                <el-option
                  v-for="item in checktypeArr"
@@ -44,7 +44,7 @@
                />
              </el-select>
            </el-form-item>
            <el-form-item label="检验结果" style=" display: flex;">
            <el-form-item v-show="isExpandForm" label="检验结果" style=" display: flex;">
              <el-select v-model="form.checkresult    " style="width: 200px" placeholder="请选择">
                <el-option
                  v-for="item in checkresultArr"
@@ -54,7 +54,6 @@
                />
              </el-select>
            </el-form-item>
          </div>
          <div style="display: flex;align-items: start;margin-top: 5px;z-index: 2">
            <el-button type="primary" icon="el-icon-search" @click="search">查询</el-button>
@@ -62,14 +61,21 @@
          </div>
        </el-form>
      </div>
      <div class="elTableDiv">
      <div
        class="bodyTopFormExpand"
        @click="isExpandForm=!isExpandForm"
      >
        <i
          :class="!isExpandForm?'el-icon-arrow-down':'el-icon-arrow-up'"
          :style="{color:'#42B983'}"
        /></div>
      <div class="elTableDiv" style="margin-top: 0">
        <el-table
          :data="tableData"
          :height="tableHeight+'px'"
          :height="isExpandForm?tableHeight:(tableHeight+40)+'px'"
          border
          :row-class-name="tableRowClassName"
          :style="{width: 100+'%',height:tableHeight+'px',}"
          :style="{width: 100+'%',height:isExpandForm?tableHeight:(tableHeight+40)+'px'}"
          highlight-current-row
          :header-cell-style="this.$headerCellStyle"
          :cell-style="this.$cellStyle"
@@ -341,25 +347,8 @@
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      isExpandForm: false,
      mainHeight: 0,
      tableHeight: 0,
      form: {
@@ -536,7 +525,7 @@
    getHeight() {
      this.$nextTick(() => {
        this.mainHeight = window.innerHeight - 85
        this.tableHeight = this.mainHeight - 240
        this.tableHeight = this.mainHeight - 250
      })
    },
    tableRowClassName({ row, rowIndex }) {
src/views/zlgl/gxjyxm.vue
@@ -146,25 +146,14 @@
<script>
import Pagination from '@/components/Pagination'
import { AddUpdateStepCheckItem, DeleteStepCheckItem, StepCheckItemSearch } from '@/api/zlgl'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'Xxxx',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -188,7 +177,7 @@
      operation: '',
      dialogFormRules: {
        checkitemcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        checkitemname: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/zlgl/qxdy.vue
@@ -153,25 +153,14 @@
import Pagination from '@/components/Pagination'
import { AddUpdateDedect, DedectSearch, DeleteDedect } from '@/api/zlgl'
import ImportPicker from '@/components/ImportPicker'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'QXDY',
  components: {
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入缺陷代码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('代码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      mainHeight: 0,
      tableHeight: 0,
@@ -195,7 +184,7 @@
      operation: '',
      dialogFormRules: {
        defectcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        defectname: [
          { required: true, message: '请输入缺陷名称', trigger: ['blur', 'change'] }
src/views/zzmx/chda.vue
@@ -608,25 +608,14 @@
} from '@/api/zzmx'
import $ from 'jquery'
import { SeaveSearchInventory, SeaveSearchInventoryClass, SeaveSearchUnit } from '@/api/ErpSyncMes'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'CHDA',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入物料编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -668,7 +657,7 @@
      operation: '',
      dialogFormRules: {
        materialcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        materialname: [
          { required: true, message: '请输入物料名称', trigger: ['blur', 'change'] }
src/views/zzmx/gxdy.vue
@@ -406,25 +406,14 @@
  StepSearch
} from '@/api/zzmx'
import $ from 'jquery'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'GXDY',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -464,7 +453,7 @@
      operation: '',
      dialogFormRules: {
        stepcode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        stepname: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/zzmx/gylx.vue
@@ -285,25 +285,14 @@
<script>
import Pagination from '@/components/Pagination'
import { AddUpdateRoute, DeleteRoute, RouteSearch, StepSelect, ViewRoute } from '@/api/zzmx'
import { validateCode } from '@/utils/global'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'GYLX',
  components: {
    Pagination
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -349,7 +338,7 @@
      operation: '',
      dialogFormRules: {
        code: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
          { required: true, validator: validateCode, trigger: ['blur', 'change'] }
        ],
        name: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
src/views/zzmx/jpgj.vue
@@ -2,9 +2,9 @@
  <div>
    <div class="body" :style="{height:mainHeight+'px'}">
      <div class="bodyTopButtonGroup">
      <div class="bodyTopButtonGroup" style="justify-content: space-between">
        <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">新增</el-button>
        <!--        <el-button type="primary" icon="el-icon-upload2" @click="upload">导入</el-button>-->
        <el-button icon="el-icon-download" @click="upload">导入</el-button>
      </div>
      <div class="bodyTopFormGroup">
@@ -453,6 +453,16 @@
        </div>
      </span>
    </el-dialog>
    <!--导入组件-->
    <import-picker
      ref="importPickerFunc"
      class="importPickerClass"
      :shows.sync="shows"
      :title="title_value"
      :colos="colos"
      :code="code"
    />
  </div>
</template>
@@ -466,32 +476,14 @@
  StepSelectEqp,
  StepSelectEqpList
} from '@/api/zzmx'
import ImportPicker from '@/components/ImportPicker'
const SER_HZ = /^[\u4e00-\u9fa5]+$/
export default {
  name: 'JPGJ',
  components: {
    Pagination
    Pagination, ImportPicker
  },
  data() {
    const validateName = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请输入编码'))
      } else {
        if (SER_HZ.test(value)) {
          return callback(new Error('编码不能为中文'))
        } else {
          callback()
        }
      }
    }
    const validateTypeCode = (rule, value, callback) => {
      if (!value) {
        return callback(new Error('请选择上级'))
      } else {
        callback()
      }
    }
    return {
      isIpad: false,
      mainHeight: 0,
@@ -543,21 +535,18 @@
      editRouteName: '', // ç¼–辑时工艺路线名称
      editStepName: '', // ç¼–辑时加工工序名称
      operation: '',
      dialogFormRules: {
        OrgType: [
          { required: true, message: '请输入选择类型', trigger: ['blur', 'change'] }
        ],
        OrgCode: [
          { required: true, validator: validateName, trigger: ['blur', 'change'] }
        ],
        OrgName: [
          { required: true, message: '请输入名称', trigger: ['blur', 'change'] }
        ],
        SupUnit: [
          { required: true, validator: validateTypeCode, trigger: ['blur', 'change'] }
        ]
      }
      dialogFormRules: {},
      title_value: '数据导入 / èŠ‚æ‹å·¥ä»·',
      code: '24',
      shows: false
    }
  },
  watch: {
    shows() {
      if (!this.shows) {
        this.getBeatRateSearch()
      }
    }
  },
  created() {
@@ -863,6 +852,14 @@
    //     }
    //   })
    // },
    // å¯¼å…¥æŒ‰é’®
    upload() {
      this.shows = true
      this.$refs.importPickerFunc.newDataFunc()
    },
    colos() {
      this.shows = false
    },
    // èŽ·å–é¡µé¢é«˜åº¦
    getHeight() {
      this.$nextTick(() => {