Lius
2024-01-27 791db9676de3fac540b3a508d222a77a83f11d29
src/views/mdc/base/EquipmentList.vue
@@ -19,6 +19,14 @@
              <a-input placeholder="请输入设备名称" v-model="queryParam.equipmentName"></a-input>
            </a-form-item>
          </a-col>
          <a-col :md="6" :sm="8">
            <a-form-item label="车间名称">
              <!--<a-input placeholder="请输入账号查询" v-model="queryParam.username"></a-input>-->
              <a-input placeholder="请输入车间名称" v-model="queryParam.productionName"></a-input>
            </a-form-item>
          </a-col>
          <a-col :md="6" :sm="8">
            <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
            <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
@@ -30,6 +38,7 @@
    <!-- 操作按钮区域 -->
    <div class="table-operator" style="border-top: 5px">
      <a-button @click="handleAdd" type="primary" icon="plus" >添加设备</a-button>
      <a-button type="primary" icon="download" @click="handleExportXls('设备信息')">导出</a-button>
      <a-dropdown v-if="selectedRowKeys.length > 0">
        <a-menu slot="overlay" @click="handleMenuClick">
          <a-menu-item key="1">
@@ -56,6 +65,7 @@
        bordered
        size="middle"
        rowKey="id"
        :scroll="{x:'max-content',y:465}"
        :columns="columns"
        :dataSource="dataSource"
        :pagination="ipagination"
@@ -172,25 +182,25 @@
            title: '设备编号',
            align: "center",
            dataIndex: 'equipmentId',
            width: 120,
            width: 200,
            // sorter: true
          },
          {
            title: '设备名称',
            align: "center",
            width: 150,
            width: 200,
            dataIndex: 'equipmentName',
          },
          {
            title: '车间',
            align: "center",
            width: 180,
            width: 200,
            dataIndex: 'productionName'
          },
          {
            title: '设备类型',
            align: "center",
            width: 120,
            width: 200,
            dataIndex: 'equipmentType',
            // scopedSlots: {customRender: "avatarslot"}
          },
@@ -198,33 +208,33 @@
          {
            title: '驱动类型',
            align: "center",
            width: 80,
            width: 200,
            dataIndex: 'driveType',
            // sorter: true
          },
          {
            title: '机床IP',
            align: "center",
            width: 100,
            width: 200,
            dataIndex: 'equipmentIp'
          },
          {
            title: '设备功率',
            align: "center",
            width: 100,
            width: 200,
            dataIndex: 'devicePower'
          },
          {
            title: '部门',
            align: "center",
            width: 180,
            width: 200,
            dataIndex: 'orgCodeTxt'
          },
          {
            title: '系统版本',
            align: "center",
            width: 80,
            width: 200,
            dataIndex: 'systemVersion'
          },
          {
@@ -232,7 +242,8 @@
            dataIndex: 'action',
            scopedSlots: {customRender: 'action'},
            align: "center",
            width: 120
            width: 150,
            fixed:'right'
          }
        ],
@@ -246,7 +257,7 @@
          list: "/mdc/mdcEquipment/list",
          delete: "/mdc/mdcEquipment/delete",
          deleteBatch: "/mdc/mdcEquipment/deleteBatch",
          // exportXlsUrl: "/sys/user/exportXls",
          exportXlsUrl: "/mdc/mdcEquipment/exportXls",
          // importExcelUrl: "sys/user/importExcel",
        },
        isDepartType:''
@@ -282,25 +293,25 @@
                  title: '设备编号',
                  align: "center",
                  dataIndex: 'equipmentId',
                  width: 120,
                  width: 200,
                  // sorter: true
                },
                {
                  title: '设备名称',
                  align: "center",
                  width: 150,
                  width: 200,
                  dataIndex: 'equipmentName',
                },
                {
                  title: '车间',
                  align: "center",
                  width: 180,
                  width: 200,
                  dataIndex: 'productionName'
                },
                {
                  title: '设备类型',
                  align: "center",
                  width: 120,
                  width: 200,
                  dataIndex: 'equipmentType',
                  // scopedSlots: {customRender: "avatarslot"}
                },
@@ -308,33 +319,33 @@
                {
                  title: '驱动类型',
                  align: "center",
                  width: 80,
                  width: 200,
                  dataIndex: 'driveType',
                  // sorter: true
                },
                {
                  title: '机床IP',
                  align: "center",
                  width: 100,
                  width: 200,
                  dataIndex: 'equipmentIp'
                },
                {
                  title: '设备功率',
                  align: "center",
                  width: 100,
                  width: 200,
                  dataIndex: 'devicePower'
                },
                // {
                //   title: '部门',
                //   align: "center",
                //   width: 180,
                //   width: 200,
                //   dataIndex: 'orgCodeTxt'
                // },
                {
                  title: '系统版本',
                  align: "center",
                  width: 80,
                  width: 200,
                  dataIndex: 'systemVersion'
                },
                {
@@ -342,7 +353,8 @@
                  dataIndex: 'action',
                  scopedSlots: {customRender: 'action'},
                  align: "center",
                  width: 120
                  width: 150,
                  fixed:'right'
                }
              ]
@@ -362,25 +374,25 @@
                  title: '设备编号',
                  align: "center",
                  dataIndex: 'equipmentId',
                  width: 120,
                  width: 200,
                  // sorter: true
                },
                {
                  title: '设备名称',
                  align: "center",
                  width: 150,
                  width: 200,
                  dataIndex: 'equipmentName',
                },
                {
                  title: '车间',
                  align: "center",
                  width: 180,
                  width: 200,
                  dataIndex: 'productionName'
                },
                {
                  title: '设备类型',
                  align: "center",
                  width: 120,
                  width: 200,
                  dataIndex: 'equipmentType',
                  // scopedSlots: {customRender: "avatarslot"}
                },
@@ -388,33 +400,33 @@
                {
                  title: '驱动类型',
                  align: "center",
                  width: 80,
                  width: 200,
                  dataIndex: 'driveType',
                  // sorter: true
                },
                {
                  title: '机床IP',
                  align: "center",
                  width: 100,
                  width: 200,
                  dataIndex: 'equipmentIp'
                },
                {
                  title: '设备功率',
                  align: "center",
                  width: 100,
                  width: 200,
                  dataIndex: 'devicePower'
                },
                {
                  title: '部门',
                  align: "center",
                  width: 180,
                  width: 200,
                  dataIndex: 'orgCodeTxt'
                },
                {
                  title: '系统版本',
                  align: "center",
                  width: 80,
                  width: 200,
                  dataIndex: 'systemVersion'
                },
                {
@@ -422,7 +434,8 @@
                  dataIndex: 'action',
                  scopedSlots: {customRender: 'action'},
                  align: "center",
                  width: 120
                  width: 150,
                  fixed:'right'
                }
              ]
@@ -443,6 +456,8 @@
        this.$refs.modalForm.title = "编辑";
        this.$refs.modalForm.disableSubmit = false;
        this.$refs.modalForm.disSeach = true;
        // 调用抽屉表单组件中的清除表单验证方法
        this.$refs.modalForm.removeValidate()
      },
      handleAdd: function () {
        this.$refs.modalForm.add();
@@ -453,7 +468,6 @@
      getAvatarView: function (avatar) {
        return getFileAccessHttpUrl(avatar)
      },
      batchFrozen: function (status) {
        if (this.selectedRowKeys.length <= 0) {
          // this.$message.warning('请选择一条记录!');
@@ -485,7 +499,7 @@
              frozenBatch({ids: ids, status: status}).then((res) => {
                if (res.success) {
                  // that.$message.success(res.message);
                  that.$notification.warning({
                  that.$notification.success({
                    message:'消息',
                    description:res.message
                  });