5 changed files with 2865 additions and 340 deletions
-
2src/api/knifemold/tool-info.js
-
69src/views/main-sidebar.vue
-
1144src/views/modules/knifemold/tool-info.vue
-
896src/views/modules/knifemold/toolOperatorRecord.vue
-
1094src/views/modules/knifemold/toolOperatorRecord_old.vue
1144
src/views/modules/knifemold/tool-info.vue
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -0,0 +1,896 @@ |
|||
<template> |
|||
<div class="mod-config"> |
|||
<!-- 查询条件 --> |
|||
<el-form :inline="true" label-position="top"> |
|||
<el-form-item :label="'工具编码'"> |
|||
<el-input style="width: 100px" v-model="queryTool.toolId" ></el-input> |
|||
</el-form-item> |
|||
<el-form-item :label="'工具实例编码'"> |
|||
<el-input style="width: 100px" v-model="queryTool.toolInstanceId" ></el-input> |
|||
</el-form-item> |
|||
<el-form-item :label="'库位编码'"> |
|||
<el-input style="width: 100px" v-model="queryTool.locationId"></el-input> |
|||
</el-form-item> |
|||
<el-form-item :label="'操作日期'"> |
|||
<el-date-picker style="width: 120px" v-model="queryTool.startDate" value-format='yyyy-MM-dd' format = 'yyyy-MM-dd'></el-date-picker> - |
|||
<el-date-picker style="width: 120px" v-model="queryTool.endDate" value-format='yyyy-MM-dd' format = 'yyyy-MM-dd'></el-date-picker> |
|||
</el-form-item> |
|||
<el-form-item label="操作类型"> |
|||
<el-select v-model="queryTool.typeFlag" style="width: 120px"> |
|||
<el-option label="工具入库" value="TR"></el-option> |
|||
<el-option label="工具出库" value="TC"></el-option> |
|||
<el-option label="工具报废" value="TB"></el-option> |
|||
<el-option label="工具维修" value="TW"></el-option> |
|||
<el-option label="工具维修返回" value="TWF"></el-option> |
|||
<el-option label="工具借用" value="TJ"></el-option> |
|||
<el-option label="工具借用返回" value="TJF"></el-option> |
|||
<el-option label="工具领用" value="TL"></el-option> |
|||
<el-option label="工具领用返回" value="TLF"></el-option> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item :label="' '"> |
|||
<el-button @click="getDataList()" type="primary">查询</el-button> |
|||
<download-excel |
|||
:fields="fields()" |
|||
:data="exportData" |
|||
type="xls" |
|||
:name="exportName" |
|||
:header="exportHeader" |
|||
:footer="exportFooter" |
|||
:defaultValue="exportDefaultValue" |
|||
:fetch="createExportData" |
|||
:before-generate="startDownload" |
|||
:before-finish="finishDownload" |
|||
worksheet="导出信息" |
|||
class="el-button el-button--primary el-button--medium"> |
|||
导出 |
|||
</download-excel> |
|||
</el-form-item> |
|||
</el-form> |
|||
<!-- 数据列表 --> |
|||
<el-table |
|||
:height="height" |
|||
:data="dataList" |
|||
border |
|||
v-loading="dataListLoading" |
|||
style="width: 100%;"> |
|||
<el-table-column |
|||
v-for="(item,index) in columnList" :key="index" |
|||
:sortable="item.columnSortable" |
|||
:prop="item.columnProp" |
|||
:header-align="item.headerAlign" |
|||
:show-overflow-tooltip="item.showOverflowTooltip" |
|||
:align="item.align" |
|||
:fixed="item.fixed==''?false:item.fixed" |
|||
:min-width="item.columnWidth" |
|||
:label="item.columnLabel"> |
|||
<template slot-scope="scope"> |
|||
<span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span> |
|||
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
<!-- 分页 --> |
|||
<el-pagination |
|||
@size-change="sizeChangeHandle" |
|||
@current-change="currentChangeHandle" |
|||
:current-page="pageIndex" |
|||
:page-sizes="[100, 200, 500]" |
|||
:page-size="pageSize" |
|||
:total="totalPage" |
|||
layout="total, sizes, prev, pager, next, jumper"> |
|||
</el-pagination> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import getLodop from '@/utils/LodopFuncs.js' |
|||
import {queryToolOperatorRecord} from '@/api/knifemold/tool-info.js' |
|||
export default { |
|||
data () { |
|||
return { |
|||
height: 0, |
|||
// 数据查询属性 |
|||
tagNo: '', |
|||
dataListLoading: false, |
|||
queryTool: { |
|||
limit: 500, |
|||
page: 1, |
|||
supplierId: '', |
|||
toolId: '', |
|||
toolInstanceId: '', |
|||
locationId: '', |
|||
startDate: '', |
|||
endDate: '', |
|||
typeFlag: 'TR' |
|||
}, |
|||
pageIndex: 1, |
|||
pageSize: 100, |
|||
totalPage: 0, |
|||
// 数据集 |
|||
dataList: [], |
|||
// 展示列集 |
|||
columnList: [], |
|||
// ------------ 页面属性 end ---------- |
|||
// 导出 start |
|||
exportData: [], |
|||
exportName: this.$route.meta.title, |
|||
exportHeader: [this.$route.meta.title], |
|||
exportFooter: [], |
|||
exportDefaultValue: '', |
|||
toolRepairList: [ |
|||
{ |
|||
columnProp: 'transNo', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '单号', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'toolInstanceId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '工具实例编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '出入库数量', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'wareHouseId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库房编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'locationId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库位编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'supplierId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '供应商编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'supplierName', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '供应商名称', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'remark', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '备注', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdBy', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdDate', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作时间', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
} |
|||
], |
|||
toolRepairReturnList: [ |
|||
{ |
|||
columnProp: 'transNo', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '单号', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'toolInstanceId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '工具实例编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '出入库数量', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'wareHouseId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库房编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'locationId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库位编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'estUseQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '维修寿命', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transPrice', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '维修金额', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'remark', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '备注', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdBy', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdDate', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作时间', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
} |
|||
], |
|||
toolBorrowingList: [ |
|||
{ |
|||
columnProp: 'transNo', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '单号', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'toolInstanceId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '工具实例编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '出入库数量', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'wareHouseId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库房编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'locationId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库位编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'supplierId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '借用部门', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'remark', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '备注', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdBy', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdDate', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作时间', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
} |
|||
], |
|||
toolBorrowingReturnList: [ |
|||
{ |
|||
columnProp: 'transNo', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '单号', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'toolInstanceId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '工具实例编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '出入库数量', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'wareHouseId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库房编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'locationId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库位编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'remark', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '备注', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdBy', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdDate', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作时间', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
} |
|||
], |
|||
toolOutOfLibraryList: [ |
|||
{ |
|||
columnProp: 'transNo', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '单号', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'toolInstanceId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '工具实例编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '出入库数量', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'wareHouseId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库房编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'locationId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库位编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'supplierId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '机台编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'supplierName', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '机台名称', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'remark', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '备注', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdBy', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdDate', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作时间', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
} |
|||
], |
|||
toolRequisitionList: [ |
|||
{ |
|||
columnProp: 'transNo', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '单号', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'toolInstanceId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '工具实例编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'transQty', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '出入库数量', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'wareHouseId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库房编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'locationId', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '库位编码', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'supplierName', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '领用人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'remark', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '备注', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdBy', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作人', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
}, |
|||
{ |
|||
columnProp: 'createdDate', |
|||
headerAlign: 'center', |
|||
align: 'center', |
|||
columnLabel: '操作时间', |
|||
columnHidden: false, |
|||
columnImage: false, |
|||
columnSortable: false, |
|||
sortLv: 0, |
|||
status: true, |
|||
fixed: false |
|||
} |
|||
] |
|||
} |
|||
}, |
|||
created () { |
|||
this.getDataList() |
|||
}, |
|||
mounted () { |
|||
this.$nextTick(() => { |
|||
this.height = window.innerHeight - 220; |
|||
this.changeColumn(); |
|||
}) |
|||
}, |
|||
methods: { |
|||
/** |
|||
* 操作类型内容改变事件 |
|||
*/ |
|||
changeColumn(){ |
|||
if(this.queryTool.typeFlag === 'TR' || this.queryTool.typeFlag === 'TJF' || this.queryTool.typeFlag === 'TB' || this.queryTool.typeFlag === 'TLF'){ |
|||
this.columnList = this.toolBorrowingReturnList; |
|||
} |
|||
}, |
|||
/** |
|||
* 查询基础数据 |
|||
*/ |
|||
getDataList () { |
|||
this.dataListLoading = true |
|||
this.queryTool.limit = this.pageSize |
|||
this.queryTool.page = this.pageIndex |
|||
queryToolOperatorRecord (this.queryTool).then(({data}) => { |
|||
if (data.code === 0) { |
|||
if(this.queryTool.typeFlag === 'TR' || this.queryTool.typeFlag === 'TJF' || this.queryTool.typeFlag === 'TB' || this.queryTool.typeFlag === 'TLF'){ |
|||
this.columnList = this.toolBorrowingReturnList |
|||
} else if (this.queryTool.typeFlag === 'TW') { |
|||
this.columnList = this.toolRepairList |
|||
} else if (this.queryTool.typeFlag === 'TWF') { |
|||
this.columnList = this.toolRepairReturnList |
|||
} else if (this.queryTool.typeFlag === 'TJ') { |
|||
this.columnList = this.toolBorrowingList |
|||
} else if (this.queryTool.typeFlag === 'TC') { |
|||
this.columnList = this.toolOutOfLibraryList |
|||
} else if (this.queryTool.typeFlag === 'TL') { |
|||
this.columnList = this.toolRequisitionList |
|||
} |
|||
this.dataList = data.page.list |
|||
this.pageIndex = data.page.currPage |
|||
this.pageSize = data.page.pageSize |
|||
this.totalPage = data.page.totalCount |
|||
} |
|||
this.dataListLoading = false |
|||
}) |
|||
}, |
|||
// --------- 分页 ---------- |
|||
// 每页数 |
|||
sizeChangeHandle (val) { |
|||
this.pageSize = val |
|||
this.pageIndex = 1 |
|||
this.getDataList() |
|||
}, |
|||
// 当前页 |
|||
currentChangeHandle (val) { |
|||
this.pageIndex = val |
|||
this.getDataList() |
|||
}, |
|||
// --------- 分页 end ---------- |
|||
// --------- 导出 ---------- |
|||
fields () { |
|||
let json = "{" |
|||
this.columnList.forEach((item, index) => { |
|||
if (index == this.columnList.length - 1) { |
|||
json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" |
|||
} else { |
|||
json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + "," |
|||
} |
|||
}) |
|||
json += "}" |
|||
let s = eval("(" + json + ")") |
|||
return s |
|||
}, |
|||
createExportData () { |
|||
// 点击导出按钮之后,开始导出数据之前的执行函数,返回值为需要下载的数据 |
|||
return this.dataList |
|||
}, |
|||
startDownload () { |
|||
}, |
|||
finishDownload () { |
|||
} |
|||
// --------- 导出 end ---------- |
|||
} |
|||
} |
|||
</script> |
|||
<style> |
|||
|
|||
</style> |
|||
1094
src/views/modules/knifemold/toolOperatorRecord_old.vue
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
Write
Preview
Loading…
Cancel
Save
Reference in new issue