columns.js 3.86 KB
Newer Older
TZW's avatar
TZW committed
1
function getcolumns(setdrawer) {
TZW's avatar
TZW committed
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123
  return {
    columns: [
      {
        dataIndex: 'equipmentNo',
        valueType: 'input',
        title: '设备编号',
        key: 'equipmentNo',
        hideInForm: true,
      },
      {
        dataIndex: 'equipmentName',
        valueType: 'input',
        title: '设备名称',
        key: 'equipmentName',
        hideInForm: true,
      },
      {
        dataIndex: 'installPosition',
        valueType: 'input',
        title: '安装部位',
        key: 'installPosition',
        hideInForm: true,
      },
      {
        dataIndex: 'sparePartNo',
        valueType: 'input',
        title: '备件料号',
        key: 'sparePartNo',
        hideInForm: true,
      },
      {
        dataIndex: 'sparePartName',
        valueType: 'input',
        title: '备件名称',
        key: 'sparePartName',
        hideInForm: true,
      },
      {
        dataIndex: 'supplierNo',
        valueType: 'input',
        title: '供应商编号',
        key: 'supplierNo',
        hideInForm: true,
      },
      {
        dataIndex: 'supplierName',
        valueType: 'input',
        title: '供应商名称',
        key: 'supplierName',
        hideInForm: true,
      },
      {
        dataIndex: 'equipmentId',
        valueType: 'select',
        title: '选择设备',
        key: 'equipmentId',
        hideInDescriptions: true,
        hideInSearch: true,
        hideInTable: true,
        mode: 'radio',
        options: {
          path: '/asset/equipment/selection/user/shop',
          params: {},
        },
        formItemProps: {
          rules: [
            {
              required: true,
              message: '此项为必填项',
            },
          ],
        },
      },
      {
        dataIndex: 'lifePieceStandardId',
        valueType: 'select',
        title: '选择部位-寿命件',
        key: 'lifePieceStandardId',
        hideInDescriptions: true,
        hideInSearch: true,
        hideInTable: true,
        mode: 'radio',
        options: {
          path: '/sparepart/lifePieceStandard/querySelectByEquipmentId',
          linkParams: {},
        },
        formItemProps: {
          rules: [
            {
              required: true,
              message: '此项为必填项',
            },
          ],
        },
      },
      {
        dataIndex: 'supplierId',
        valueType: 'select',
        title: '选择供应商',
        key: 'supplierId',
        hideInDescriptions: true,
        hideInSearch: true,
        hideInTable: true,
        mode: 'radio',
        options: {
          path: '/sparepart/sparePartSupplier/queryOnSelect',
          params: {},
        },
        formItemProps: {
          rules: [
            {
              required: true,
              message: '此项为必填项',
            },
          ],
        },
      },
      {
        dataIndex: 'installNum',
        valueType: 'digit',
        title: '安装数量',
        key: 'installNum',
TZW's avatar
TZW committed
124
        hideInSearch: true,
TZW's avatar
TZW committed
125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166
        hideInTable: false,
        formItemProps: {
          rules: [
            {
              required: true,
              message: '此项为必填项',
            },
          ],
        },
      },
      {
        dataIndex: 'nextReplaceDate',
        valueType: 'date',
        title: '下次更换日期',
        searchValueType: 'dateRange',
        key: 'nextReplaceDateList',
        hideInSearch: false,
        hideInTable: false,
        formItemProps: {
          rules: [
            {
              required: true,
              message: '此项为必填项',
            },
          ],
        },
      },
    ],
    pathconfig: {
      enableadd: false,
      enableedit: true,
      enabledelete: false,
      enabledetail: false,
      add: '',
      edit: '',
      list: '/sparepart/lifePieceAccount/queryWarning',
      delete: '',
      detail: '',
    },
  };
}
export default getcolumns;