zss
2024-01-17 c49d413fe39ee6cb9062f6fa915a3d203933a73a
src/views/equipment/equipment/index.vue
@@ -68,7 +68,7 @@
      multipleSelection: [],
      uploadInfo: {
        // 是否展示上传EXCEL以及对应的url
        isShow: true,
        isShow: false,
        url: '/mes/equipment/upload'
      },
      diaPrintTab: false,
@@ -97,6 +97,7 @@
          // 设备编号
          {
            minWidth: '30',
            width: '200',
            prop: 'number',
            label: '设备编号',
            sort: true,
@@ -110,8 +111,19 @@
          // 设备名称
          {
            minWidth: '30',
            width: '100',
            prop: 'name',
            label: '设备名称',
            sort: true,
            isTrue: true,
            isSearch: true,
            searchInfoType: 'text'
          },
          // 状态
          {
            minWidth: '30',
            prop: 'state',
            label: '状态',
            sort: true,
            isTrue: true,
            isSearch: true,
@@ -151,15 +163,15 @@
            searchInfoType: 'text'
          },
          // 邮箱
          {
            minWidth: '30',
            prop: 'email',
            label: '邮箱',
            sort: true,
            isTrue: true,
            isSearch: false,
            searchInfoType: 'text'
          },
          // {
          //   minWidth: '30',
          //   prop: 'email',
          //   label: '邮箱',
          //   sort: true,
          //   isTrue: true,
          //   isSearch: false,
          //   searchInfoType: 'text'
          // },
          // 供应商
          {
            minWidth: '30',
@@ -193,7 +205,7 @@
          // 制造日期
          {
            minWidth: '150',
            width: '250',
            width: '100',
            prop: 'manufactureDate',
            label: '制造日期',
            sort: true,
@@ -205,7 +217,7 @@
          // 安装日期
          {
            minWidth: '150',
            width: '250',
            width: '100',
            prop: 'installDate',
            label: '安装日期',
            sort: true,
@@ -213,16 +225,6 @@
            isSearch: true,
            formatter: this.formatReceiveTime,
            searchInfoType: 'datetimerange'
          },
          // 状态
          {
            minWidth: '30',
            prop: 'state',
            label: '状态',
            sort: true,
            isTrue: true,
            isSearch: true,
            searchInfoType: 'text'
          }
        ],
        toolbar: [],
@@ -247,7 +249,6 @@
    ...mapGetters(['permissions'])
  },
  created() {
    this.uploadInfo.isShow = this.permissions.equipment_equipment_upload
    if(this.permissions.equipment_equipment_add){
      this.table.toolbar.push({
            text: '新增',
@@ -306,7 +307,7 @@
                printable: 'printRaw',//页面
                type: "html",//文档类型
                  maxWidth:450,
                  targetStyles:['*'],
                  targetStyles:['*'],
                  style: `@page {
                    margin:0;
                    padding: 0;
@@ -329,7 +330,7 @@
    pullEquipFun(){
      this.table.toolbar.find((e) => e.text === '同步').loading = true
      pullEquip().then(res=>{
        this.$message.success(res.data.data.msg)
        this.$message.success(res.data.msg)
        this.table.toolbar.find((e) => e.text === '同步').loading = false
      }).catch(error=>{
        this.$message.error("同步失败",error)