¶Ô±ÈÐÂÎļþ |
| | |
| | | export const columns = [ |
| | | { |
| | | type: 'seq', |
| | | width: 60, |
| | | title: 'åºå·', |
| | | }, |
| | | { |
| | | field: 'materialCode', |
| | | title: 'ç©æç¼ç ', |
| | | }, |
| | | { |
| | | field: 'materialName', |
| | | title: 'ç©æåç§°', |
| | | }, |
| | | { |
| | | field: 'purchaseType', |
| | | title: 'éè´ç±»å', |
| | | formatter: ({ cellValue }) => { |
| | | // You'll need to map the enum values to display text |
| | | const purchaseTypeMap = { |
| | | 0: 'ç±»å1', |
| | | 1: 'ç±»å2', |
| | | // Add all enum values |
| | | } |
| | | return purchaseTypeMap[cellValue] || cellValue |
| | | }, |
| | | }, |
| | | { |
| | | field: 'materialType', |
| | | title: 'ç©æç±»å', |
| | | formatter: ({ cellValue }) => { |
| | | // Map material type enum to display text |
| | | const materialTypeMap = { |
| | | 0: 'ç±»åA', |
| | | 1: 'ç±»åB', |
| | | // Add all enum values |
| | | } |
| | | return materialTypeMap[cellValue] || cellValue |
| | | }, |
| | | }, |
| | | { |
| | | field: 'primaryUnit', |
| | | title: '主åä½', |
| | | }, |
| | | { |
| | | field: 'standard', |
| | | title: 'è§æ ¼/æ å', |
| | | }, |
| | | { |
| | | field: 'outerDiameter', |
| | | title: 'å¤å¾(mm)', |
| | | }, |
| | | { |
| | | field: 'wallThickness', |
| | | title: 'å£å(mm)', |
| | | }, |
| | | { |
| | | field: 'materialQuality', |
| | | title: 'æè´¨', |
| | | }, |
| | | { |
| | | field: 'length', |
| | | title: 'é¿åº¦(m)', |
| | | }, |
| | | { |
| | | field: 'isMainBranch', |
| | | title: '主æ¯ç®¡', |
| | | formatter: ({ cellValue }) => (cellValue ? 'æ¯' : 'å¦'), |
| | | }, |
| | | { |
| | | field: 'factory', |
| | | title: 'ç产工å', |
| | | }, |
| | | { |
| | | field: 'certification', |
| | | title: 'è¯ä¹¦ç¼å·', |
| | | }, |
| | | { |
| | | field: 'sort', |
| | | title: 'æåº', |
| | | }, |
| | | { |
| | | field: 'remark', |
| | | title: '夿³¨', |
| | | }, |
| | | ] |