payne
2024-04-25 b57f4eca1133a7ecad85abf3cff87fe88c366ec2
iWare_RawMaterialWarehouse_Web/src/views/main/WmsBase/WmsMaterial/index.vue
@@ -23,16 +23,19 @@
              </a-col>
              <a-col :md="8" :sm="24">
                <a-form-item label="物料类型名称">
                  <a-input v-model="queryParam.materialTypeName" allow-clear placeholder="请输入物料类型名称"/>
                              <a-input v-model="queryParam.materialTypeName" allow-clear
                                 placeholder="请输入物料类型名称" />
                </a-form-item>
              </a-col>
              <a-col :md="8" :sm="24">
                <a-form-item label="物料类型描述">
                  <a-input v-model="queryParam.materialTypeDescr" allow-clear placeholder="请输入物料类型描述"/>
                              <a-input v-model="queryParam.materialTypeDescr" allow-clear
                                 placeholder="请输入物料类型描述" />
                </a-form-item>
              </a-col><a-col :md="8" :sm="24">
                <a-form-item label="物料类型">
                  <a-input-number v-model="queryParam.materialType" style="width: 100%" allow-clear placeholder="请输入物料类型"/>
                              <a-input-number v-model="queryParam.materialType" style="width: 100%" allow-clear
                                 placeholder="请输入物料类型" />
                </a-form-item>
              </a-col>
              <a-col :md="8" :sm="24">
@@ -42,11 +45,12 @@
              </a-col>
              <a-col :md="8" :sm="24">
                <a-form-item label="ABC分类名称">
                  <a-input v-model="queryParam.aBCClassName" allow-clear placeholder="请输入ABC分类名称"/>
                              <a-input v-model="queryParam.abcClassName" allow-clear placeholder="请输入ABC分类名称" />
                </a-form-item>
              </a-col><a-col :md="8" :sm="24">
                <a-form-item label="ABC分类">
                  <a-input-number v-model="queryParam.aBCClass" style="width: 100%" allow-clear placeholder="请输入ABC分类"/>
                              <a-input-number v-model="queryParam.abcClass" style="width: 100%" allow-clear
                                 placeholder="请输入ABC分类" />
                </a-form-item>
              </a-col>
              <a-col :md="8" :sm="24">
@@ -101,8 +105,10 @@
              </a-col>
         <a-col :md="8" :sm="24">
            <a-form-item label="是否禁用">
               <a-select :allowClear="true" style="width: 100%" v-model="queryParam.isDisabled" placeholder="请选择是否禁用">
                  <a-select-option v-for="(item,index) in isDisabledData" :key="index" :value="item.code">{{ item.name }}</a-select-option>
                              <a-select :allowClear="true" style="width: 100%" v-model="queryParam.isDisabled"
                                 placeholder="请选择是否禁用">
                                 <a-select-option v-for="(item, index) in isDisabledData" :key="index"
                                    :value="item.code">{{ item.name }}</a-select-option>
               </a-select>
            </a-form-item>
         </a-col>
@@ -117,7 +123,10 @@
            <a-col :md="8" :sm="24">
               <a-form-item label="创建时间">
                  <a-range-picker style="width: 100%" :placeholder="['开始时间', '结束时间']"  :show-time="{
format: 'HH:mm:ss',  defaultValue: [moment('00:00:00', 'HH:mm:ss'),moment('23:59:59', 'HH:mm:ss')]}" v-model="queryParam.createdTime"  value-format="YYYY-MM-DD HH:mm:ss" format="YYYY-MM-DD HH:mm:ss"   @change="onChangecreatedTime"/>
                                 format: 'HH:mm:ss', defaultValue: [moment('00:00:00', 'HH:mm:ss'), moment('23:59:59', 'HH:mm:ss')]
                              }"
                                 v-model="queryParam.createdTime" value-format="YYYY-MM-DD HH:mm:ss"
                                 format="YYYY-MM-DD HH:mm:ss" @change="onChangecreatedTime" />
               </a-form-item>
            </a-col>
@@ -127,7 +136,10 @@
            <a-col :md="8" :sm="24">
               <a-form-item label="更新时间">
                  <a-range-picker style="width: 100%" :placeholder="['开始时间', '结束时间']"  :show-time="{
format: 'HH:mm:ss',  defaultValue: [moment('00:00:00', 'HH:mm:ss'),moment('23:59:59', 'HH:mm:ss')]}" v-model="queryParam.updatedTime"  value-format="YYYY-MM-DD HH:mm:ss" format="YYYY-MM-DD HH:mm:ss"   @change="onChangeupdatedTime"/>
                                 format: 'HH:mm:ss', defaultValue: [moment('00:00:00', 'HH:mm:ss'), moment('23:59:59', 'HH:mm:ss')]
                              }"
                                 v-model="queryParam.updatedTime" value-format="YYYY-MM-DD HH:mm:ss"
                                 format="YYYY-MM-DD HH:mm:ss" @change="onChangeupdatedTime" />
               </a-form-item>
            </a-col>
@@ -159,26 +171,23 @@
    </a-card>
   </div>
    <a-card :bordered="false">
      <s-table
        ref="table"
        :columns="columns"
        :data="loadData"
        :alert="true"
      @changeTablePage="pageInfo = $event"
      :scroll="{x: true,y:tableHeight}"
        :rowKey="(record) => record.id"
         <s-table ref="table" :columns="columns" :data="loadData" :alert="true" @changeTablePage="pageInfo = $event"
            :scroll="{ x: true, y: tableHeight }" :rowKey="(record) => record.id"
        :rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }">
        <template class="table-operator" slot="operator" v-if="hasPerm('WmsMaterial:add')" >
      <div ref="actionBar" class="actionBar">
         <a-button type="info" v-if="hasPerm('sysExcelTemplate:importExcel')" icon="upload" @click="$refs.excelForm.index()">
                  <a-button type="info" v-if="hasPerm('sysExcelTemplate:importExcel')" icon="upload"
                     @click="$refs.excelForm.index()">
            导入
          </a-button>
          <a-button type="info" v-if="hasPerm('WmsMaterial:exportExcel')" icon="download" @click="WmsMaterialToExcel()">
                  <a-button type="info" v-if="hasPerm('WmsMaterial:exportExcel')" icon="download"
                     @click="WmsMaterialToExcel()">
            导出
          </a-button>
         <!-- <a-button type="primary" v-if="hasPerm('WmsMaterial:add')" icon="plus" @click="$refs.addForm.add()">新增物料信息表</a-button> -->
         <!-- 自定义 -->
         <a-button type="primary" v-if="hasPerm('WmsMaterial:add')" icon="plus" @click="$refs.tabForm.add()">新增物料信息</a-button>
                  <a-button type="primary" v-if="hasPerm('WmsMaterial:add')" icon="plus"
                     @click="$refs.tabForm.add()">新增物料信息</a-button>
      </div>
      </template>
        <span slot="isDisabledscopedSlots" slot-scope="text">
@@ -197,7 +206,8 @@
         <a-divider type="vertical" v-if="hasPerm('WmsMaterial:edit') & hasPerm('WmsMaterial:delete')"/>
         <a v-if="hasPerm('WmsMaterial:edit')" @click="$refs.tabForm.add(record,'详情')">详情</a>
          <a-divider type="vertical" v-if="hasPerm('WmsMaterial:edit') & hasPerm('WmsMaterial:delete')"/>
          <a-popconfirm v-if="hasPerm('WmsMaterial:delete')" placement="topRight" title="确认删除?" @confirm="() => WmsMaterialDelete(record)">
               <a-popconfirm v-if="hasPerm('WmsMaterial:delete')" placement="topRight" title="确认删除?"
                  @confirm="() => WmsMaterialDelete(record)">
            <a>删除</a>
          </a-popconfirm>
        </span>
@@ -407,7 +417,7 @@
   }
   },
   sorter: true,
   dataIndex: 'aBCClassName'
               dataIndex: 'abcClassName'
   },
   {
   title: 'ABC分类',
@@ -427,7 +437,7 @@
   }
   },
   sorter: true,
   dataIndex: 'aBCClass'
               dataIndex: 'abcClass'
   },
   {
   title: '物料规格',
@@ -888,11 +898,10 @@
   }
   }
</script>
<style lang="less">
  .table-operator {
<style lang="less">.table-operator {
    margin-bottom: 18px;
  }
  button {
    margin-right: 8px;
  }
</style>
}</style>