|
@@ -48,6 +48,12 @@
|
|
:selected-row-keys="selectedRowKeys"
|
|
:selected-row-keys="selectedRowKeys"
|
|
@select-change="selectChange"
|
|
@select-change="selectChange"
|
|
>
|
|
>
|
|
|
|
+ <template #inouttime="{ col, row }">
|
|
|
|
+ {{ timestampFilter(row[col.colKey]) }}
|
|
|
|
+ </template>
|
|
|
|
+ <template #status="{ col, row }">
|
|
|
|
+ {{ runningStatusFilter(row[col.colKey]) }}
|
|
|
|
+ </template>
|
|
</t-table>
|
|
</t-table>
|
|
</div>
|
|
</div>
|
|
<AddDeviceDialog
|
|
<AddDeviceDialog
|
|
@@ -65,9 +71,10 @@ import { deviceOutInSearch } from '@/api/sop';
|
|
import { omit } from 'lodash';
|
|
import { omit } from 'lodash';
|
|
import { DEVICE_USAGE_TYPE, RUNNING_STATUS } from '@/config/constants';
|
|
import { DEVICE_USAGE_TYPE, RUNNING_STATUS } from '@/config/constants';
|
|
import { dictToOptionList } from '@/utils/tool';
|
|
import { dictToOptionList } from '@/utils/tool';
|
|
|
|
+import { timestampFilter, runningStatusFilter } from '@/utils/filter';
|
|
|
|
|
|
const selectedRowKeys = ref([]);
|
|
const selectedRowKeys = ref([]);
|
|
-const selectChange = (value, { selectedRowData }) => {
|
|
|
|
|
|
+const selectChange = (value) => {
|
|
selectedRowKeys.value = value;
|
|
selectedRowKeys.value = value;
|
|
};
|
|
};
|
|
const showAddDeviceDialog = ref(false);
|
|
const showAddDeviceDialog = ref(false);
|
|
@@ -78,16 +85,16 @@ const columns = [
|
|
width: 50,
|
|
width: 50,
|
|
fixed: 'left',
|
|
fixed: 'left',
|
|
},
|
|
},
|
|
- { colKey: 'serviceUnitName', title: '服务单元' },
|
|
|
|
- { colKey: 'usageType', title: '用途类型' },
|
|
|
|
- { colKey: 'deviceNo', title: '设备编号' },
|
|
|
|
- { colKey: 'deviceStatus', title: '运行状态' },
|
|
|
|
- { colKey: 'inOutTime', title: '出/入库时间', width: 150 },
|
|
|
|
- { colKey: 'userName', title: '登记人' },
|
|
|
|
- { colKey: 'customName', title: '客户名称' },
|
|
|
|
- { colKey: 'inOutType', title: '出库/入库' },
|
|
|
|
- { colKey: 'location', title: '当前地' },
|
|
|
|
- { colKey: 'address', title: '发往地' },
|
|
|
|
|
|
+ { colKey: 'serviceUnitName', title: '服务单元', width: 120 },
|
|
|
|
+ { colKey: 'usageType', title: '用途类型', width: 120 },
|
|
|
|
+ { colKey: 'deviceNo', title: '设备编号', width: 200 },
|
|
|
|
+ { colKey: 'deviceStatus', title: '运行状态', width: 120, cell: 'status' },
|
|
|
|
+ { colKey: 'inOutTime', title: '出/入库时间', width: 180, cell: 'inouttime' },
|
|
|
|
+ { colKey: 'userName', title: '登记人', width: 140 },
|
|
|
|
+ { colKey: 'customName', title: '客户名称', width: 140 },
|
|
|
|
+ { colKey: 'inOutType', title: '出库/入库', width: 120 },
|
|
|
|
+ { colKey: 'location', title: '当前地', width: 120 },
|
|
|
|
+ { colKey: 'address', title: '发往地', width: 120 },
|
|
];
|
|
];
|
|
const fields = ref([
|
|
const fields = ref([
|
|
{
|
|
{
|