column.js 39 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684
  1. import orderApi from "@/api/business/purchase/purchase-order";
  2. import Cookies from "js-cookie";
  3. // 集采中心
  4. const PurColumns = [
  5. {
  6. key: "puOrgName",
  7. title: "采购组织",
  8. inputType: "PopoverSelect",
  9. valueKey: "name",
  10. referName: "ORG_PARAM",
  11. dataMapping: {
  12. puOrg: "id",
  13. puOrgName: "name",
  14. },
  15. queryParams: () => ({}),
  16. require: true,
  17. isShow: true,
  18. },
  19. {
  20. key: "createTime",
  21. title: "制单日期",
  22. inputType: "DatePicker",
  23. type: 'datetime',
  24. // valueFormat: "yyyy-MM-dd HH:mm:ss",
  25. require: true,
  26. disabled: true,
  27. isShow: true,
  28. },
  29. {
  30. key: "status",
  31. title: "单据状态",
  32. inputType: "Select",
  33. referName: "documents_status", // 字典名
  34. disabled: true,
  35. isShow: true,
  36. },
  37. {
  38. key: "paymentAgreementName",
  39. title: "付款协议",
  40. inputType: "PopoverSelect",
  41. valueKey: "name",
  42. referName: "PAYAGREEMENT_PARAM",
  43. dataMapping: {
  44. paymentAgreement: 'id',
  45. paymentAgreementName: 'name'
  46. },
  47. queryParams: () => ({}),
  48. isShow: true,
  49. disabled: true,
  50. },
  51. {
  52. key: "updateTime",
  53. title: "修改日期",
  54. inputType: "DatePicker",
  55. valueFormat: "yyyy-MM-dd HH-MM-SS",
  56. width: 200,
  57. disabled: true,
  58. isShow: true,
  59. },
  60. {
  61. key: "billType",
  62. title: "订单类型",
  63. inputType: "Select",
  64. referName: "sys_order_type", // 字典名
  65. isShow: true,
  66. require: true,
  67. },
  68. {
  69. key: "supplierName",
  70. title: "供应商",
  71. inputType: "PopoverSelect",
  72. valueKey: "name",
  73. referName: "SUPPLIER_PARAM",
  74. dataMapping: {
  75. supplier: "id",
  76. supplierCode: 'code',
  77. supplierName: "name",
  78. paymentAgreement: 'paymentId',
  79. paymentAgreementName: 'paymentName',
  80. },
  81. queryParams: () => ({}),
  82. require: true,
  83. isShow: true,
  84. },
  85. {
  86. key: "qty",
  87. title: "总数量",
  88. inputType: "InputNumber",
  89. controlsPosition: "right",
  90. isShow: true,
  91. disabled: true,
  92. },
  93. {
  94. key: "warehouseName",
  95. title: "WMS入库仓库",
  96. inputType: "PopoverSelect",
  97. valueKey: "name",
  98. referName: "WAREHOUSE_PARAM",
  99. dataMapping: {
  100. warehouse: 'id',
  101. warehouseName: 'name',
  102. },
  103. queryParams: (params) => ({
  104. pkOrg: params.puOrg,
  105. isWms: ['21-Cxx-02', '21-Cxx-04', '21-Cxx-10'].find(item => item === params.billType) ? 'Y' : 'N',
  106. }),
  107. isShow: true,
  108. // require: true,
  109. },
  110. {
  111. key: "originalQty",
  112. title: "原始总数量",
  113. inputType: "InputNumber",
  114. controlsPosition: "right",
  115. isShow: true,
  116. disabled: true,
  117. },
  118. {
  119. key: "createByName",
  120. title: "制单人",
  121. inputType: "Input",
  122. isShow: true,
  123. disabled: true,
  124. },
  125. {
  126. key: "code",
  127. title: "订单编号",
  128. inputType: "Input",
  129. readonly: true,
  130. disabled: true,
  131. isShow: true,
  132. },
  133. {
  134. key: "money",
  135. title: "价税合计",
  136. inputType: "InputNumber",
  137. controlsPosition: "right",
  138. // precision:2,
  139. isShow: true,
  140. disabled: true,
  141. },
  142. {
  143. key: "goodsWarehouseName",
  144. title: "收货仓库",
  145. inputType: "PopoverSelect",
  146. valueKey: "name",
  147. referName: "ADDRESS_PARAM",
  148. isShow: true,
  149. require: true,
  150. dataMapping: {
  151. address: 'address',
  152. // addressName: '',
  153. goodsWarehouse: 'id',
  154. goodsWarehouseName: 'name',
  155. contacts: 'contactsName',
  156. contactsPhone: 'contactsPhone'
  157. },
  158. queryParams: () => ({}),
  159. },
  160. {
  161. key: "originalMoney",
  162. title: "原始金额",
  163. inputType: "InputNumber",
  164. controlsPosition: "right",
  165. // precision:2,
  166. isShow: true,
  167. disabled: true,
  168. width: 180,
  169. },
  170. {
  171. key: "buyerName",
  172. title: "采购员",
  173. inputType: "PopoverSelect",
  174. valueKey: "name",
  175. referName: "CONTACTS_PARAM",
  176. dataMapping: {
  177. buyer: 'code',
  178. buyerName: 'name'
  179. },
  180. queryParams: () => ({}),
  181. require: true,
  182. isShow: true,
  183. },
  184. {
  185. key: "erpOrderCode",
  186. title: "erp订单编号",
  187. inputType: "Input",
  188. readonly: true,
  189. disabled: true,
  190. isShow: true,
  191. },
  192. {
  193. key: "rebateMoney",
  194. title: "订单使用返利金额",
  195. inputType: "InputNumber",
  196. controlsPosition: "right",
  197. // precision:2,
  198. isShow: true,
  199. require: true,
  200. },
  201. {
  202. key: "address",
  203. title: "收货地址",
  204. inputType: "Input",
  205. require: true,
  206. disabled: true,
  207. isShow: true,
  208. width: 180
  209. },
  210. {
  211. key: "isEnd",
  212. title: "整单关闭标识",
  213. inputType: "Checkbox",
  214. isShow: true,
  215. },
  216. {
  217. key: "isBack",
  218. title: "退货",
  219. inputType: "Input",
  220. inputType: "Checkbox",
  221. isShow: true,
  222. },
  223. {
  224. key: "deductionMoney",
  225. title: "订单抵扣余款金额",
  226. inputType: "InputNumber",
  227. controlsPosition: "right",
  228. // precision:2,
  229. isShow: true,
  230. require: true,
  231. },
  232. {
  233. key: "contacts",
  234. title: "收货联系人",
  235. inputType: "Input",
  236. isShow: true,
  237. disabled: true,
  238. },
  239. {
  240. key: "isClose",
  241. title: "最终关闭",
  242. inputType: "Checkbox",
  243. isShow: true,
  244. disabled: true,
  245. },
  246. {
  247. key: "retReasonName",
  248. title: "退换原因",
  249. inputType: "PopoverSelect",
  250. valueKey: "name",
  251. referName: "RETREASON_PARAM",
  252. dataMapping: {
  253. retReason: 'id',
  254. retReasonName: 'name'
  255. },
  256. isShow: true,
  257. queryParams: () => ({}),
  258. },
  259. {
  260. key: "applyPaymentMoney",
  261. title: "累计付款申请金额",
  262. inputType: "InputNumber",
  263. controlsPosition: "right",
  264. // precision:2,
  265. isShow: true,
  266. disabled: true,
  267. },
  268. {
  269. key: "puDeptName",
  270. title: "采购部门",
  271. inputType: "PopoverSelect",
  272. valueKey: "name",
  273. referName: "DEPT_PARAM",
  274. dataMapping: {
  275. puDept: 'id',
  276. puDeptName: 'name'
  277. },
  278. queryParams: (params) => ({
  279. drpOrg: params.puOrg,
  280. }),
  281. require: true,
  282. isShow: true,
  283. },
  284. {
  285. key: "closeTime",
  286. title: "最终关闭日期",
  287. inputType: "DatePicker",
  288. valueFormat: "yyyy-MM-dd",
  289. isShow: true,
  290. disabled: true,
  291. },
  292. {
  293. key: "processTypeName",
  294. title: "处理方式",
  295. inputType: "PopoverSelect",
  296. valueKey: "name",
  297. referName: "PROCESSTYPE_PARAM",
  298. dataMapping: {
  299. processType: 'id',
  300. processTypeName: 'name'
  301. },
  302. isShow: true,
  303. queryParams: () => ({}),
  304. },
  305. {
  306. key: "paymentMoney",
  307. title: "累计付款金额",
  308. inputType: "InputNumber",
  309. controlsPosition: "right",
  310. // precision:2,
  311. isShow: true,
  312. },
  313. {
  314. key: "freezeCause",
  315. title: "冻结原因",
  316. inputType: "Checkbox",
  317. isShow: true,
  318. },
  319. {
  320. key: "closeReason",
  321. title: "关闭原因",
  322. inputType: "Input",
  323. disabled: true,
  324. isShow: true,
  325. },
  326. {
  327. key: "invoiceMoney",
  328. title: "发票金额",
  329. inputType: "InputNumber",
  330. controlsPosition: "right",
  331. isShow: true,
  332. },
  333. {
  334. key: "oaDemandNo",
  335. title: "OA需求单号",
  336. inputType: "Input",
  337. isShow: true,
  338. },
  339. {
  340. key: "remark",
  341. title: "备注",
  342. // span: 12,
  343. rows: 1,
  344. inputType: "Textarea",
  345. isShow: true,
  346. maxlength: 180,
  347. },
  348. {
  349. key: "sysFileRecordList",
  350. title: "附件",
  351. inputType: "Upload",
  352. span: 24,
  353. // fileType: ["pdf",""],
  354. isShow: true,
  355. },
  356. ];
  357. const PurchaseTabColumns = [
  358. {
  359. title: '物料信息',
  360. key: 'puOrderItemList',
  361. tableColumns: [
  362. {
  363. key: "customerName",
  364. title: "收货客户",
  365. inputType: "PopoverSelect",
  366. valueKey: "name",
  367. referName: "CUSTOMER_PARAM",
  368. width: 180,
  369. copy: true,
  370. clearable: true,
  371. dataMapping: {
  372. customer: 'id',
  373. customerName: 'name',
  374. },
  375. },
  376. {
  377. key: "goodsAllocationName",
  378. title: "货位",
  379. inputType: "PopoverSelect",
  380. valueKey: "name",
  381. referName: "ALLOCATION_PARAM",
  382. dataMapping: {
  383. goodsAllocation: 'id',
  384. goodsAllocationName: 'name',
  385. },
  386. isShow: true,
  387. copy: true,
  388. clearable: true,
  389. queryParams: (params) => ({
  390. stordocId: params.warehouse,
  391. pkOrg: params.puOrg,
  392. }),
  393. width: 180,
  394. },
  395. {
  396. key: "rowNo",
  397. title: "行号",
  398. inputType: "Input",
  399. disabled: true,
  400. require: false,
  401. },
  402. {
  403. key: "materialCode",
  404. title: "物料编码",
  405. inputType: "PopoverSelect",
  406. width: 180,
  407. require: true,
  408. valueKey: "code",
  409. referName: "MATERIAL_PARAM",
  410. copy: true,
  411. dataMapping: {
  412. material: "id",
  413. materialName: "name",
  414. materialCode: "code",
  415. // materialClassify:'classifyIdName',
  416. materialManufacturersCode: 'manufacturersMaterialCode',
  417. specification: 'specification',
  418. model: 'model',
  419. isMedcine: 'isMedicineYN',
  420. manufacturer: 'manufacturerId',
  421. manufacturerName: 'manufacturerIdName',
  422. unit: 'unitId',
  423. unitName: 'unitIdName',
  424. storageCondition: 'storageCondition',
  425. carriageCondition: 'transportationCondition',
  426. materialClassifyOneName: 'oneClass',
  427. materialClassifyTwoName: 'twoClass',
  428. materialClassifyThreeName: 'threeClass',
  429. materialClassifyFourName: 'fourClass',
  430. registration: 'registrationNo',
  431. isDrug: 'isDrug',
  432. rateCode: "materialRateName",
  433. materialManufacturersCode: "materialManufacturersCode",
  434. materialRemark: "remark",
  435. },
  436. queryParams: () => ({}),
  437. width: 180,
  438. },
  439. {
  440. key: "materialManufacturersCode",
  441. title: "厂家物料编码",
  442. inputType: "Input",
  443. width: 180,
  444. disabled: true,
  445. readonly: true,
  446. },
  447. {
  448. key: "materialName",
  449. title: "物料名称",
  450. inputType: "Input",
  451. require: true,
  452. width: 180,
  453. disabled: true,
  454. readonly: true,
  455. },
  456. {
  457. key: "specification",
  458. title: "规格",
  459. inputType: "Input",
  460. width: 180,
  461. disabled: true,
  462. readonly: true,
  463. },
  464. {
  465. key: "model",
  466. title: "型号",
  467. inputType: "Input",
  468. disabled: true,
  469. readonly: true,
  470. },
  471. {
  472. key: "materialRemark",
  473. title: "物料备注",
  474. inputType: "Input",
  475. disabled: true,
  476. width: 180,
  477. readonly: true,
  478. },
  479. { // manufacturerId manufacturerIdName
  480. key: "manufacturerName",
  481. title: "生产厂家代理人",
  482. inputType: "Input",
  483. width: 180,
  484. disabled: true,
  485. readonly: true,
  486. },
  487. { //unitId unitIdName
  488. key: "unitName",
  489. title: "单位",
  490. inputType: "Input",
  491. disabled: true,
  492. readonly: true,
  493. },
  494. {
  495. key: "qty",
  496. title: "数量",
  497. inputType: "Input",
  498. copy: true,
  499. // inputType: "InputNumber",
  500. // controlsPosition: "right",
  501. width: 120,
  502. require: true,
  503. isSummary: true,
  504. },
  505. {
  506. key: "taxPrice",
  507. title: "含税单价",
  508. inputType: "InputNumber",
  509. controlsPosition: "right",
  510. // precision:2,
  511. require: true,
  512. disabled: true,
  513. width: 180,
  514. },
  515. {
  516. key: "money",
  517. title: "价税合计",
  518. inputType: "InputNumber",
  519. controlsPosition: "right",
  520. // precision:2,
  521. disabled: true,
  522. width: 180,
  523. isSummary: true,
  524. // formatter: (prop) => {
  525. // const { tax = 0, taxPrice = 0 } = prop;
  526. // return (prop.price = iunitprice(tax, taxPrice));
  527. // },
  528. },
  529. {
  530. key: "isGift",
  531. title: "赠品",
  532. inputType: "Checkbox",
  533. },
  534. {
  535. key: "nitemdiscountrate",
  536. title: "折扣(%)",
  537. inputType: "Input",
  538. // precision:2,
  539. disabled: true,
  540. width: 180,
  541. },
  542. {
  543. key: "taxDeductMoneya",
  544. title: "折扣金额",
  545. inputType: "InputNumber",
  546. controlsPosition: "right",
  547. // precision:2,
  548. disabled: true,
  549. width: 180,
  550. isSummary: true,
  551. },
  552. {
  553. key: "discountRule",
  554. title: "折扣规则编码",
  555. inputType: "Input",
  556. width: 180
  557. },
  558. { //materialRate materialRateName
  559. key: "tax",
  560. title: "税率",
  561. // inputType: "Input",
  562. inputType: "InputNumber",
  563. controlsPosition: "right",
  564. // precision:2,
  565. disabled: true,
  566. width: 180,
  567. },
  568. {
  569. key: "registration",
  570. title: "注册证号",
  571. inputType: "Input",
  572. width: 180,
  573. disabled: true,
  574. },
  575. {
  576. key: "demandCode",
  577. title: "采购需求单号",
  578. inputType: "Input",
  579. width: 180
  580. },
  581. {
  582. key: "isReplenishment",
  583. title: "补单标识",
  584. inputType: "Checkbox",
  585. },
  586. {
  587. key: "isUrgency",
  588. title: "紧急标识",
  589. inputType: "Checkbox",
  590. },
  591. {
  592. key: "priceType",
  593. title: "价格类型",
  594. inputType: "Select",
  595. referName: "sys_price_type", // 字典名
  596. width: 180,
  597. },
  598. {
  599. key: "isDistributionPrice",
  600. title: "配送价",
  601. inputType: "Checkbox",
  602. },
  603. {
  604. key: "deliveryDate",
  605. title: "交货日期",
  606. inputType: "DatePicker",
  607. type: 'date',
  608. // disabled: true,
  609. isShow: true,
  610. width: 180,
  611. },
  612. {
  613. key: "floatQty",
  614. title: "未到货数量",
  615. inputType: "InputNumber",
  616. controlsPosition: "right",
  617. width: 180,
  618. isSummary: true,
  619. },
  620. { key: "isArrival", title: "到货关闭", inputType: "Checkbox", disabled: true, },
  621. { key: "isStorage", title: "入库关闭", inputType: "Checkbox", disabled: true, },
  622. { key: "isPayment", title: "付款关闭", inputType: "Checkbox", disabled: true, },
  623. { key: "isInvoice", title: "开票关闭", inputType: "Checkbox", disabled: true, },
  624. { //isMedicine isMedicineValue
  625. key: "isMedcine",
  626. title: "医药物料",
  627. inputType: "Checkbox",
  628. disabled: true,
  629. readonly: true,
  630. },
  631. {
  632. key: "originalQty",
  633. title: "原始数量",
  634. inputType: "InputNumber",
  635. controlsPosition: "right",
  636. disabled: true,
  637. width: 180,
  638. isSummary: true,
  639. },
  640. {
  641. key: "originalMoney",
  642. title: "原始金额",
  643. inputType: "InputNumber",
  644. controlsPosition: "right",
  645. // precision:2,
  646. disabled: true,
  647. width: 180,
  648. isSummary: true,
  649. },
  650. {
  651. key: "closeReason",
  652. title: "行关闭/打开原因",
  653. inputType: "Input",
  654. width: 180,
  655. disabled: true,
  656. },
  657. {
  658. key: "sourceBillDate",
  659. title: "原单据生成时间",
  660. inputType: "DatePicker",
  661. type: 'datetime',
  662. // valueFormat: "yyyy-MM-dd HH:mm:ss",
  663. disabled: true,
  664. isShow: true,
  665. width: 180,
  666. },
  667. ]
  668. },
  669. // {
  670. // title: '执行结果',
  671. // key: 'puOrderExecuteList',
  672. // tableColumns: [
  673. // // { key: "orderId", title: "采购订单ID", inputType: "Input", width: 180 },
  674. // {
  675. // key: "rowno",
  676. // title: "行号",
  677. // inputType: "Input",
  678. // disabled:true,
  679. // require:false,
  680. // },
  681. // {
  682. // key: "materialName",
  683. // title: "物料",
  684. // inputType: "PopoverSelect",
  685. // width: 180,
  686. // require: true,
  687. // valueKey: "id",
  688. // referName: "MATERIAL_PARAM",
  689. // dataMapping: {
  690. // material: "id",
  691. // materialName: "name",
  692. // materialCode: "code",
  693. // // materialClassify:'classifyIdName',
  694. // materialManufacturersCode:'manufacturersMaterialCode',
  695. // specification:'specification',
  696. // model:'model',
  697. // isMedcine:'isMedicine',
  698. // manufacturer:'manufacturerId',
  699. // manufacturerName:'manufacturerIdName',
  700. // unit:'unitId',
  701. // unitName:'unitIdName',
  702. // // tax:'materialRateName',
  703. // storageCondition:'storageCondition',
  704. // carriageCondition:'transportationCondition',
  705. // materialClassifyOneName:'oneClass',
  706. // materialClassifyTwoName:'twoClass',
  707. // materialClassifyThreeName:'threeClass',
  708. // materialClassifyFourName:'fourClass',
  709. // registration:'registrationNo',
  710. // isDrug:'isDrug',
  711. // },
  712. // queryParams: () => ({}),
  713. // width:180,
  714. // },
  715. // {
  716. // key: "specification",
  717. // title: "规格",
  718. // inputType: "Input",
  719. // disabled:true,
  720. // readonly:true,
  721. // },
  722. // {
  723. // key: "qty",
  724. // title: "数量",
  725. // inputType: "InputNumber",
  726. // controlsPosition: "right",
  727. // width: 180,
  728. // require: true,
  729. // isSummary:true,
  730. // },
  731. // {
  732. // key: "stroageQty",
  733. // title: "累计到货主数量",
  734. // inputType: "InputNumber",
  735. // controlsPosition: "right",
  736. // width: 180,
  737. // isSummary:true,
  738. // },
  739. // {
  740. // key: "stockQty",
  741. // title: "累计入库主数量",
  742. // inputType: "InputNumber",
  743. // controlsPosition: "right",
  744. // width: 180,
  745. // isSummary:true,
  746. // },
  747. // {
  748. // key: "invoiceQty",
  749. // title: "累计开票主数量",
  750. // inputType: "InputNumber",
  751. // controlsPosition: "right",
  752. // width: 180,
  753. // isSummary:true,
  754. // },
  755. // {
  756. // key: "rollbackQty",
  757. // title: "累计退货主数量",
  758. // inputType: "InputNumber",
  759. // controlsPosition: "right",
  760. // width: 180,
  761. // isSummary:true,
  762. // },
  763. // {
  764. // key: "backStockQty",
  765. // title: "累计退库主数量",
  766. // inputType: "InputNumber",
  767. // controlsPosition: "right",
  768. // width: 180,
  769. // isSummary:true,
  770. // },
  771. // {
  772. // key: "floatQty",
  773. // title: "未到货数量",
  774. // inputType: "InputNumber",
  775. // controlsPosition: "right",
  776. // width: 180,
  777. // isSummary:true,
  778. // },
  779. // // {
  780. // // key: "createByName",
  781. // // title: "创建人",
  782. // // inputType: "Input",
  783. // // width: 120
  784. // // },
  785. // // {
  786. // // key: "updateByName",
  787. // // title: "更新人",
  788. // // inputType: "Input",
  789. // // width: 120
  790. // // },
  791. // ]
  792. // },
  793. ];
  794. // 事业发展部
  795. const CauseColumns = [
  796. {
  797. key: "puOrgName",
  798. title: "采购组织",
  799. inputType: "PopoverSelect",
  800. valueKey: "name",
  801. referName: "ORG_PARAM",
  802. dataMapping: {
  803. puOrg: "id",
  804. puOrgName: "name",
  805. },
  806. queryParams: () => ({}),
  807. require: true,
  808. isShow: true,
  809. },
  810. {
  811. key: "billType",
  812. title: "订单类型",
  813. inputType: "Select",
  814. referName: "sys_order_type", // 字典名
  815. isShow: true,
  816. require: true,
  817. },
  818. {
  819. key: "code",
  820. title: "订单编号",
  821. inputType: "Input",
  822. readonly: true,
  823. disabled: true,
  824. isShow: true,
  825. },
  826. {
  827. key: "billDate",
  828. title: "订单日期",
  829. inputType: "DatePicker",
  830. valueFormat: "yyyy-MM-dd",
  831. width: 200,
  832. require: true,
  833. isShow: true,
  834. },
  835. {
  836. key: "billType",
  837. title: "订单类型编号",
  838. inputType: "Input",
  839. disabled: true,
  840. isShow: true,
  841. require: true,
  842. },
  843. {
  844. key: "supplierName",
  845. title: "供应商",
  846. inputType: "PopoverSelect",
  847. valueKey: "name",
  848. referName: "SUPPLIER_PARAM",
  849. dataMapping: {
  850. supplier: "id",
  851. supplierCode: 'code',
  852. supplierName: "name",
  853. paymentAgreement: 'paymentId',
  854. paymentAgreementName: 'paymentName',
  855. },
  856. queryParams: () => ({}),
  857. require: true,
  858. isShow: true,
  859. },
  860. {
  861. key: "paymentAgreementName",
  862. title: "付款协议",
  863. inputType: "PopoverSelect",
  864. valueKey: "name",
  865. referName: "PAYAGREEMENT_PARAM",
  866. dataMapping: {
  867. paymentAgreement: 'id',
  868. paymentAgreementName: 'name'
  869. },
  870. queryParams: () => ({}),
  871. isShow: true,
  872. disabled: true,
  873. require: true,
  874. },
  875. // {
  876. // key: "currencyName",
  877. // title: "币种",
  878. // inputType: "PopoverSelect",
  879. // valueKey: "id",
  880. // referName: "CURRENCY_PARAM",
  881. // dataMapping: {
  882. // currency: 'id',
  883. // currencyName: 'name'
  884. // },
  885. // queryParams: () => ({}),
  886. // width: 180,
  887. // },
  888. {
  889. key: "buyerName",
  890. title: "采购员",
  891. inputType: "PopoverSelect",
  892. valueKey: "name",
  893. referName: "CONTACTS_PARAM",
  894. dataMapping: {
  895. buyer: 'code',
  896. buyerName: 'name'
  897. },
  898. queryParams: () => ({}),
  899. require: true,
  900. isShow: true,
  901. },
  902. {
  903. key: "puDeptName",
  904. title: "采购部门",
  905. inputType: "PopoverSelect",
  906. valueKey: "name",
  907. referName: "DEPT_PARAM",
  908. dataMapping: {
  909. puDept: 'id',
  910. puDeptName: 'name'
  911. },
  912. queryParams: (params) => ({
  913. drpOrg: params.puOrg,
  914. }),
  915. require: true,
  916. isShow: true,
  917. },
  918. {
  919. key: "customerName",
  920. title: "收货客户",
  921. inputType: "PopoverSelect",
  922. valueKey: "name",
  923. referName: "CUSTOMER_PARAM",
  924. width: 180,
  925. dataMapping: {
  926. customer: 'id',
  927. customerName: 'name',
  928. },
  929. isShow: true,
  930. },
  931. { key: "isBack", title: "退货", inputType: "Input", inputType: "Checkbox", isShow: true, },
  932. { key: "freezeCause", title: "冻结原因", inputType: "Checkbox", isShow: true, },
  933. {
  934. key: "qty",
  935. title: "总数量",
  936. inputType: "InputNumber",
  937. controlsPosition: "right",
  938. isShow: true,
  939. disabled: true,
  940. },
  941. {
  942. key: "money",
  943. title: "价税合计",
  944. inputType: "InputNumber",
  945. controlsPosition: "right",
  946. // precision:2,
  947. isShow: true,
  948. disabled: true,
  949. },
  950. // {
  951. // key: "remark",
  952. // title: "备注",
  953. // inputType: "Textarea",
  954. // isShow:true,
  955. // },
  956. { key: "isMarketing", title: "已协同生成销售订单", inputType: "Checkbox", isShow: true, },
  957. { key: "isMarketingSource", title: "由销售订单协同生成", inputType: "Checkbox", isShow: true, },
  958. {
  959. key: "isInvoice",
  960. title: "发票标识",
  961. inputType: "Checkbox",
  962. isShow: true,
  963. disabled: true,
  964. },
  965. {
  966. key: "rebateMoney",
  967. title: "订单使用返利金额",
  968. inputType: "InputNumber",
  969. controlsPosition: "right",
  970. // precision:2,
  971. isShow: true,
  972. },
  973. {
  974. key: "deductionMoney",
  975. title: "订单抵扣余款金额",
  976. inputType: "InputNumber",
  977. controlsPosition: "right",
  978. // precision:2,
  979. isShow: true,
  980. },
  981. {
  982. key: "warehouseName",
  983. title: "WMS入库仓库",
  984. inputType: "PopoverSelect",
  985. valueKey: "name",
  986. referName: "WAREHOUSE_PARAM",
  987. dataMapping: {
  988. warehouse: 'id',
  989. warehouseName: 'name',
  990. },
  991. queryParams: (params) => ({
  992. pkOrg: params.puOrg,
  993. isWms: ['21-Cxx-02', '21-Cxx-04', '21-Cxx-10'].find(item => item === params.billType) ? 'Y' : 'N',
  994. }),
  995. isShow: true,
  996. // require: true,
  997. },
  998. {
  999. key: "customerDeptName",
  1000. title: "客户部门",
  1001. inputType: "PopoverSelect",
  1002. width: 200,
  1003. valueKey: "name",
  1004. referName: "CUSTOMERDEPT_PARAM",
  1005. dataMapping: {
  1006. customerDept: 'id',
  1007. customerDeptName: 'name'
  1008. },
  1009. isShow: true,
  1010. queryParams: () => ({}),
  1011. },
  1012. // { key: "place", title: "收货地点", inputType: "Input", width: 180 },
  1013. {
  1014. key: "goodsWarehouseName",
  1015. title: "收货仓库",
  1016. inputType: "PopoverSelect",
  1017. valueKey: "name",
  1018. referName: "ADDRESS_PARAM",
  1019. width: 200,
  1020. isShow: true,
  1021. dataMapping: {
  1022. address: 'address',
  1023. goodsWarehouse: 'id',
  1024. goodsWarehouseName: 'name',
  1025. contacts: 'contactsName',
  1026. contactsPhone: 'contactsPhone'
  1027. }
  1028. },
  1029. {
  1030. key: "address",
  1031. title: "收货地址",
  1032. inputType: "Input",
  1033. width: 180,
  1034. isShow: true,
  1035. disabled: true,
  1036. },
  1037. {
  1038. key: "contacts",
  1039. title: "收货联系人",
  1040. inputType: "Input",
  1041. isShow: true,
  1042. disabled: true,
  1043. },
  1044. {
  1045. key: "isClose",
  1046. title: "最终关闭",
  1047. inputType: "Checkbox",
  1048. isShow: true,
  1049. disabled: true,
  1050. },
  1051. {
  1052. key: "supplierContactsName",
  1053. title: "供应商业务联系人",
  1054. inputType: "PopoverSelect",
  1055. valueKey: "name",
  1056. referName: "SUPPLIERCONTACTS_PARAM",
  1057. dataMapping: {
  1058. supplierContacts: 'id',
  1059. supplierContactsName: 'name'
  1060. },
  1061. isShow: true,
  1062. queryParams: (params) => ({
  1063. supplierId: params.supplier
  1064. }),
  1065. width: 200,
  1066. },
  1067. {
  1068. key: "isUrgency",
  1069. title: "紧急程度",
  1070. inputType: "Checkbox",
  1071. isShow: true,
  1072. disabled: true,
  1073. },
  1074. {
  1075. key: "agentName",
  1076. title: "代理人",
  1077. inputType: "PopoverSelect",
  1078. valueKey: "name",
  1079. referName: "CONTACTS_PARAM",
  1080. dataMapping: {
  1081. agent: 'code',
  1082. agentName: 'name'
  1083. },
  1084. isShow: true,
  1085. queryParams: () => ({}),
  1086. width: 200,
  1087. },
  1088. {
  1089. key: "closeReason",
  1090. title: "关闭原因",
  1091. inputType: "Input",
  1092. isShow: true,
  1093. disabled: true,
  1094. },
  1095. {
  1096. key: "invoiceMoney",
  1097. title: "发票金额",
  1098. inputType: "InputNumber",
  1099. controlsPosition: "right",
  1100. // precision:2,
  1101. isShow: true,
  1102. },
  1103. {
  1104. key: "closeTime",
  1105. title: "最终关闭日期",
  1106. inputType: "DatePicker",
  1107. valueFormat: "yyyy-MM-dd",
  1108. isShow: true,
  1109. disabled: true,
  1110. },
  1111. {
  1112. key: "applyPaymentMoney",
  1113. title: "累计付款申请金额",
  1114. inputType: "InputNumber",
  1115. controlsPosition: "right",
  1116. // precision:2,
  1117. isShow: true,
  1118. disabled: true,
  1119. },
  1120. {
  1121. key: "paymentMoney",
  1122. title: "累计付款金额",
  1123. inputType: "InputNumber",
  1124. controlsPosition: "right",
  1125. // precision:2,
  1126. isShow: true,
  1127. },
  1128. {
  1129. key: "supplierPersonalName",
  1130. title: "供应商业务员",
  1131. inputType: "PopoverSelect",
  1132. valueKey: "name",
  1133. // referName: "SUPPLIERCONTACTS_PARAM",
  1134. referName: "PSNLICENSE_PARAM",
  1135. dataMapping: {
  1136. supplierPersonal: 'id',
  1137. supplierPersonalName: 'name'
  1138. },
  1139. isShow: true,
  1140. queryParams: (params) => ({
  1141. // 组织、供应商id
  1142. pkOrg: params.puOrg,
  1143. supplierId: params.supplier
  1144. }),
  1145. },
  1146. {
  1147. key: "isSendSrm",
  1148. title: "是否同步SRM",
  1149. inputType: "Checkbox",
  1150. isShow: true,
  1151. },
  1152. {
  1153. key: "oaDemandNo",
  1154. title: "OA需求单号",
  1155. inputType: "Input",
  1156. isShow: true,
  1157. },
  1158. {
  1159. key: "remark",
  1160. title: "备注",
  1161. rows: 1,
  1162. inputType: "Textarea",
  1163. isShow: true,
  1164. maxlength: 180,
  1165. },
  1166. {
  1167. key: "sysFileRecordList",
  1168. title: "附件",
  1169. inputType: "Upload",
  1170. // fileType: ["pdf",""],
  1171. span: 24,
  1172. isShow: true,
  1173. },
  1174. ];
  1175. const CauseTabColumns = [
  1176. {
  1177. title: '物料信息',
  1178. key: 'puOrderItemList',
  1179. tableColumns: [
  1180. {
  1181. key: "customerName",
  1182. title: "收货客户",
  1183. inputType: "PopoverSelect",
  1184. valueKey: "name",
  1185. referName: "CUSTOMER_PARAM",
  1186. width: 180,
  1187. dataMapping: {
  1188. customer: 'id',
  1189. customerName: 'name',
  1190. },
  1191. copy: true,
  1192. clearable: true,
  1193. },
  1194. {
  1195. key: "goodsAllocationName",
  1196. title: "货位",
  1197. inputType: "PopoverSelect",
  1198. valueKey: "name",
  1199. referName: "ALLOCATION_PARAM",
  1200. dataMapping: {
  1201. goodsAllocation: 'id',
  1202. goodsAllocationName: 'name',
  1203. },
  1204. isShow: true,
  1205. copy: true,
  1206. clearable: true,
  1207. queryParams: (params) => ({
  1208. stordocId: params.warehouse,
  1209. pkOrg: params.puOrg,
  1210. }),
  1211. width: 180,
  1212. },
  1213. {
  1214. key: "rowNo",
  1215. title: "行号",
  1216. inputType: "Input",
  1217. disabled: true,
  1218. require: false,
  1219. },
  1220. {
  1221. key: "materialCode",
  1222. title: "物料编码",
  1223. inputType: "PopoverSelect",
  1224. width: 180,
  1225. require: true,
  1226. valueKey: "code",
  1227. referName: "MATERIAL_PARAM",
  1228. copy: true,
  1229. dataMapping: {
  1230. material: "id",
  1231. materialName: "name",
  1232. materialCode: "code",
  1233. materialManufacturersCode: 'manufacturersMaterialCode',
  1234. specification: 'specification',
  1235. model: 'model',
  1236. isMedcine: 'isMedicineYN',
  1237. manufacturer: 'manufacturerId',
  1238. manufacturerName: 'manufacturerIdName',
  1239. unit: 'unitId',
  1240. unitName: 'unitIdName',
  1241. // tax:'materialRateName',
  1242. storageCondition: 'storageCondition',
  1243. carriageCondition: 'transportationCondition',
  1244. materialClassifyOneName: 'oneClass',
  1245. materialClassifyTwoName: 'twoClass',
  1246. materialClassifyThreeName: 'threeClass',
  1247. materialClassifyFourName: 'fourClass',
  1248. registration: 'registrationNo',
  1249. isDrug: 'isDrug',
  1250. rateCode: "materialRateName",
  1251. materialManufacturersCode: "materialManufacturersCode",
  1252. materialRemark: "remark",
  1253. },
  1254. queryParams: () => ({}),
  1255. },
  1256. {
  1257. key: "materialManufacturersCode",
  1258. title: "厂家物料编码",
  1259. inputType: "Input",
  1260. width: 180,
  1261. disabled: true,
  1262. readonly: true,
  1263. },
  1264. {
  1265. key: "materialName",
  1266. title: "物料名称",
  1267. inputType: "Input",
  1268. require: true,
  1269. width: 180,
  1270. disabled: true,
  1271. readonly: true,
  1272. },
  1273. {
  1274. key: "specification",
  1275. title: "规格",
  1276. inputType: "Input",
  1277. width: 180,
  1278. disabled: true,
  1279. readonly: true,
  1280. },
  1281. {
  1282. key: "model",
  1283. title: "型号",
  1284. inputType: "Input",
  1285. disabled: true,
  1286. readonly: true,
  1287. },
  1288. {
  1289. key: "materialRemark",
  1290. title: "物料备注",
  1291. inputType: "Input",
  1292. disabled: true,
  1293. readonly: true,
  1294. width: 180,
  1295. },
  1296. { //isMedicine isMedicineValue
  1297. key: "isMedcine",
  1298. title: "医药物料",
  1299. inputType: "Checkbox",
  1300. disabled: true,
  1301. readonly: true,
  1302. },
  1303. { //unitId unitIdName
  1304. key: "unitName",
  1305. title: "主单位",
  1306. inputType: "Input",
  1307. disabled: true,
  1308. readonly: true,
  1309. },
  1310. {
  1311. key: "qty",
  1312. title: "主数量",
  1313. inputType: "InputNumber",
  1314. controlsPosition: "right",
  1315. width: 120,
  1316. require: true,
  1317. isSummary: true,
  1318. },
  1319. {
  1320. key: "taxPrice",
  1321. title: "主含税单价",
  1322. inputType: "InputNumber",
  1323. controlsPosition: "right",
  1324. // precision:2,
  1325. require: true,
  1326. width: 180,
  1327. },
  1328. { //unitId unitIdName
  1329. key: "unitName",
  1330. title: "单位",
  1331. inputType: "Input",
  1332. disabled: true,
  1333. readonly: true,
  1334. require: true,
  1335. },
  1336. {
  1337. key: "qty",
  1338. title: "数量",
  1339. // inputType: "InputNumber",
  1340. // controlsPosition: "right",
  1341. inputType: "Input",
  1342. copy: true,
  1343. width: 120,
  1344. isSummary: true,
  1345. },
  1346. {
  1347. key: "taxPrice",
  1348. title: "含税单价",
  1349. inputType: "InputNumber",
  1350. controlsPosition: "right",
  1351. // precision:2,
  1352. width: 180,
  1353. },
  1354. {
  1355. key: "money",
  1356. title: "价税合计",
  1357. inputType: "InputNumber",
  1358. controlsPosition: "right",
  1359. // precision:2,
  1360. disabled: true,
  1361. width: 180,
  1362. isSummary: true,
  1363. },
  1364. {
  1365. key: "ntaxnetprice",
  1366. title: "含税净价",
  1367. inputType: "Input",
  1368. controlsPosition: "right",
  1369. // precision:2,
  1370. disabled: true,
  1371. width: 180,
  1372. },
  1373. { //materialRate materialRateName
  1374. key: "tax",
  1375. title: "税率",
  1376. // inputType: "Input",
  1377. inputType: "InputNumber",
  1378. controlsPosition: "right",
  1379. // precision:2,
  1380. disabled: true,
  1381. require: true,
  1382. width: 180,
  1383. },
  1384. {
  1385. key: "taxDeductClassify",
  1386. title: "扣税类别",
  1387. inputType: "Select",
  1388. referName: "tax_deduction_category", // 字典名
  1389. width: 180,
  1390. require: true,
  1391. },
  1392. {
  1393. key: "exchangeRate",
  1394. title: "折本汇率",
  1395. inputType: "Input",
  1396. disabled: true,
  1397. width: 180,
  1398. require: true,
  1399. },
  1400. {
  1401. key: "nitemdiscountrate",
  1402. title: "折扣(%)",
  1403. inputType: "Input",
  1404. // precision:2,
  1405. disabled: true,
  1406. width: 180,
  1407. require: true,
  1408. },
  1409. {
  1410. key: "taxDeductMoneya",
  1411. title: "折扣金额",
  1412. inputType: "InputNumber",
  1413. controlsPosition: "right",
  1414. require: true,
  1415. // precision:2,
  1416. disabled: true,
  1417. width: 180,
  1418. isSummary: true,
  1419. },
  1420. {
  1421. key: "deliveryDate",
  1422. title: "交货日期",
  1423. inputType: "DatePicker",
  1424. type: 'date',
  1425. // disabled: true,
  1426. isShow: true,
  1427. width: 180,
  1428. },
  1429. {
  1430. key: "goodsWarehouseName",
  1431. title: "收货仓库",
  1432. inputType: "Input",
  1433. width: 200,
  1434. disabled: true,
  1435. },
  1436. { key: "productBatch", title: "产品批号", inputType: "Input", width: 180 },
  1437. {
  1438. key: "registration",
  1439. title: "注册证号",
  1440. inputType: "Input",
  1441. width: 180,
  1442. disabled: true,
  1443. },
  1444. { key: "isStorage", title: "入库关闭", inputType: "Checkbox", disabled: true, },
  1445. { key: "isInvoice", title: "开票关闭", inputType: "Checkbox", disabled: true, },
  1446. { key: "isArrival", title: "到货关闭", inputType: "Checkbox", disabled: true, },
  1447. { key: "isPayment", title: "付款关闭", inputType: "Checkbox", disabled: true, },
  1448. { key: "isGift", title: "赠品", inputType: "Checkbox", },
  1449. { //storageCondition storageConditionName
  1450. key: "storageCondition",
  1451. title: "存储条件",
  1452. inputType: "Select",
  1453. referName: "sys_storage_condition", // 字典名
  1454. width: 180,
  1455. disabled: true,
  1456. readonly: true,
  1457. },
  1458. { // transportationCondition transportationConditionName
  1459. key: "carriageCondition",
  1460. title: "运输条件",
  1461. inputType: "Select",
  1462. referName: "sys_conditions_carriage", // 字典名
  1463. width: 180,
  1464. disabled: true,
  1465. readonly: true,
  1466. },
  1467. {
  1468. key: "originalQty",
  1469. title: "原始数量",
  1470. inputType: "InputNumber",
  1471. controlsPosition: "right",
  1472. disabled: true,
  1473. width: 180,
  1474. isSummary: true,
  1475. },
  1476. {
  1477. key: "originalMoney",
  1478. title: "原始金额",
  1479. inputType: "InputNumber",
  1480. controlsPosition: "right",
  1481. // precision:2,
  1482. disabled: true,
  1483. width: 180,
  1484. isSummary: true,
  1485. },
  1486. { key: "discountRule", title: "折扣规则编码", inputType: "Input", width: 180 },
  1487. { key: "demandCode", title: "采购需求单号", inputType: "Input", width: 180 },
  1488. { key: "remark", title: "备注", inputType: "Input", width: 200 },
  1489. {
  1490. key: "closeReason",
  1491. title: "关闭原因",
  1492. inputType: "Input",
  1493. isShow: true,
  1494. disabled: true,
  1495. width: 180,
  1496. },
  1497. {
  1498. key: "sourceBillDate",
  1499. title: "原单据生成时间",
  1500. inputType: "DatePicker",
  1501. type: 'datetime',
  1502. // valueFormat: "yyyy-MM-dd HH:mm:ss",
  1503. disabled: true,
  1504. isShow: true,
  1505. width: 180,
  1506. },
  1507. ]
  1508. },
  1509. // {
  1510. // title: '执行结果',
  1511. // key: 'puOrderExecuteList',
  1512. // tableColumns: [
  1513. // // { key: "orderId", title: "采购订单ID", inputType: "Input", width: 180 },
  1514. // {
  1515. // key: "rowno",
  1516. // title: "行号",
  1517. // inputType: "Input",
  1518. // disabled:true,
  1519. // require:false,
  1520. // },
  1521. // {
  1522. // key: "materialName",
  1523. // title: "物料",
  1524. // inputType: "PopoverSelect",
  1525. // width: 180,
  1526. // require: true,
  1527. // valueKey: "id",
  1528. // referName: "MATERIAL_PARAM",
  1529. // dataMapping: {
  1530. // material: "id",
  1531. // materialName: "name",
  1532. // materialCode: "code",
  1533. // // materialClassify:'classifyIdName',
  1534. // materialManufacturersCode:'manufacturersMaterialCode',
  1535. // specification:'specification',
  1536. // model:'model',
  1537. // isMedcine:'isMedicine',
  1538. // manufacturer:'manufacturerId',
  1539. // manufacturerName:'manufacturerIdName',
  1540. // unit:'unitId',
  1541. // unitName:'unitIdName',
  1542. // // tax:'materialRateName',
  1543. // storageCondition:'storageCondition',
  1544. // carriageCondition:'transportationCondition',
  1545. // materialClassifyOneName:'oneClass',
  1546. // materialClassifyTwoName:'twoClass',
  1547. // materialClassifyThreeName:'threeClass',
  1548. // materialClassifyFourName:'fourClass',
  1549. // registration:'registrationNo',
  1550. // isDrug:'isDrug',
  1551. // },
  1552. // queryParams: () => ({}),
  1553. // width:180,
  1554. // },
  1555. // {
  1556. // key: "specification",
  1557. // title: "规格",
  1558. // inputType: "Input",
  1559. // disabled:true,
  1560. // readonly:true,
  1561. // },
  1562. // {
  1563. // key: "qty",
  1564. // title: "数量",
  1565. // inputType: "InputNumber",
  1566. // controlsPosition: "right",
  1567. // width: 180,
  1568. // require: true,
  1569. // isSummary:true,
  1570. // },
  1571. // {
  1572. // key: "stroageQty",
  1573. // title: "累计到货主数量",
  1574. // inputType: "InputNumber",
  1575. // controlsPosition: "right",
  1576. // width: 180,
  1577. // isSummary:true,
  1578. // },
  1579. // {
  1580. // key: "stockQty",
  1581. // title: "累计入库主数量",
  1582. // inputType: "InputNumber",
  1583. // controlsPosition: "right",
  1584. // width: 180,
  1585. // isSummary:true,
  1586. // },
  1587. // {
  1588. // key: "invoiceQty",
  1589. // title: "累计开票主数量",
  1590. // inputType: "InputNumber",
  1591. // controlsPosition: "right",
  1592. // width: 180,
  1593. // isSummary:true,
  1594. // },
  1595. // {
  1596. // key: "rollbackQty",
  1597. // title: "累计退货主数量",
  1598. // inputType: "InputNumber",
  1599. // controlsPosition: "right",
  1600. // width: 180,
  1601. // isSummary:true,
  1602. // },
  1603. // {
  1604. // key: "backStockQty",
  1605. // title: "累计退库主数量",
  1606. // inputType: "InputNumber",
  1607. // controlsPosition: "right",
  1608. // width: 180,
  1609. // isSummary:true,
  1610. // },
  1611. // {
  1612. // key: "floatQty",
  1613. // title: "未到货数量",
  1614. // inputType: "InputNumber",
  1615. // controlsPosition: "right",
  1616. // width: 180,
  1617. // isSummary:true,
  1618. // },
  1619. // // {
  1620. // // key: "createByName",
  1621. // // title: "创建人",
  1622. // // inputType: "Input",
  1623. // // width: 120
  1624. // // },
  1625. // // {
  1626. // // key: "updateByName",
  1627. // // title: "更新人",
  1628. // // inputType: "Input",
  1629. // // width: 120
  1630. // // },
  1631. // ]
  1632. // },
  1633. ];
  1634. // export const initTabColumns = () => tabColumns;
  1635. export default function judgeColumns() {
  1636. let Columns = _.cloneDeep(PurColumns);
  1637. let TabColumns = _.cloneDeep(PurchaseTabColumns);
  1638. let roles = Cookies.get('roles').split(',');
  1639. let role = roles.find(item => item === "syfz-purchaseorder") || "procurementManager";
  1640. if (role === "syfz-purchaseorder") {
  1641. // 事业发展部
  1642. Columns = _.cloneDeep(CauseColumns);
  1643. TabColumns = _.cloneDeep(CauseTabColumns);
  1644. }
  1645. return { Columns, TabColumns }
  1646. }