Browse Source

EQlevel报表 添加收货时间

faster_AG_grid
安虹睿 1 year ago
parent
commit
3b900af633
  1. 14
      PC/UI.WinIn.FasterZ.AgGridReport/src/utils/util.js
  2. 1
      PC/UI.WinIn.FasterZ.AgGridReport/src/views/report/EQLevelReport.vue

14
PC/UI.WinIn.FasterZ.AgGridReport/src/utils/util.js

@ -29,6 +29,17 @@ var dateFilterParams = {
}
}
// 2022-08-31T09:45:51.9340433 转 2022-08-31 09:45:51
var formatTimeStrToStr = function(timeStr) {
if (!timeStr || !new Date(timeStr)) {
return ''
}
if (timeStr.lastIndexOf('.') == -1) {
return timeStr.replace('T',' ').substring(0,timeStr.length)
}
return timeStr.replace('T',' ').substring(0,timeStr.lastIndexOf('.'))
}
// 转换数字小数点保留+千位符
/**
* @param {*} number 数值
@ -66,5 +77,6 @@ export default {
addEventResizeFlesh:addEventResizeFlesh,
dateFilterParams:dateFilterParams,
numberFixedFormatter,
numberPercentFormatter
numberPercentFormatter,
formatTimeStrToStr
}

1
PC/UI.WinIn.FasterZ.AgGridReport/src/views/report/EQLevelReport.vue

@ -31,6 +31,7 @@ export default {
{ field: '库位代码', filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
{ field: '物品质量信息', cellClass:"centerAlign", filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
{ field: '标签质量信息', cellClass:"centerAlign", filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
{ field: '收货时间', cellClass:"centerAlign", valueFormatter: ((data)=>{return util.formatTimeStrToStr(data.value)}), filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
],
searchConfig:[
{type:'select',prop:'ItemCode',label:'物料',optionsProc:'itemCode',options:[]},

Loading…
Cancel
Save