wt-enjoy-link-antd-repack 4.1.17

Sign up to get free protection for your applications and to get access to all the features.
Files changed (286) hide show
  1. package/README.md +26 -0
  2. package/dist/esm/assets/location.png +0 -0
  3. package/dist/esm/component/BiuAButton/index.d.ts +18 -0
  4. package/dist/esm/component/BiuAButton/index.js +8 -0
  5. package/dist/esm/component/BiuACard/index.d.ts +2 -0
  6. package/dist/esm/component/BiuACard/index.js +9 -0
  7. package/dist/esm/component/BiuACascader/index.d.ts +10 -0
  8. package/dist/esm/component/BiuACascader/index.js +8 -0
  9. package/dist/esm/component/BiuADatePicker/index.d.ts +19 -0
  10. package/dist/esm/component/BiuADatePicker/index.js +18 -0
  11. package/dist/esm/component/BiuAForm/index.d.ts +7 -0
  12. package/dist/esm/component/BiuAForm/index.js +10 -0
  13. package/dist/esm/component/BiuAInput/index.d.ts +14 -0
  14. package/dist/esm/component/BiuAInput/index.js +32 -0
  15. package/dist/esm/component/BiuASelect/index.d.ts +6 -0
  16. package/dist/esm/component/BiuASelect/index.js +14 -0
  17. package/dist/esm/component/BiuASwitch/index.d.ts +2 -0
  18. package/dist/esm/component/BiuASwitch/index.js +9 -0
  19. package/dist/esm/component/BiuATimePicker/index.d.ts +4 -0
  20. package/dist/esm/component/BiuATimePicker/index.js +8 -0
  21. package/dist/esm/component/BiuATreeSelect/index.d.ts +2 -0
  22. package/dist/esm/component/BiuATreeSelect/index.js +8 -0
  23. package/dist/esm/component/BiuBar/index.d.ts +13 -0
  24. package/dist/esm/component/BiuBar/index.js +42 -0
  25. package/dist/esm/component/BiuComSelect/index.d.ts +24 -0
  26. package/dist/esm/component/BiuComSelect/index.js +104 -0
  27. package/dist/esm/component/BiuCue/index.d.ts +18 -0
  28. package/dist/esm/component/BiuCue/index.js +44 -0
  29. package/dist/esm/component/BiuCustomSelect/index.d.ts +19 -0
  30. package/dist/esm/component/BiuCustomSelect/index.js +153 -0
  31. package/dist/esm/component/BiuCustomTable/index.d.ts +14 -0
  32. package/dist/esm/component/BiuCustomTable/index.js +76 -0
  33. package/dist/esm/component/BiuCustomerOperCard/component/editTable.d.ts +8 -0
  34. package/dist/esm/component/BiuCustomerOperCard/component/editTable.js +264 -0
  35. package/dist/esm/component/BiuCustomerOperCard/component/index.d.ts +1 -0
  36. package/dist/esm/component/BiuCustomerOperCard/component/index.js +1 -0
  37. package/dist/esm/component/BiuCustomerOperCard/index.d.ts +20 -0
  38. package/dist/esm/component/BiuCustomerOperCard/index.js +56 -0
  39. package/dist/esm/component/BiuCustomerOperCard/type.d.ts +117 -0
  40. package/dist/esm/component/BiuCustomerOperCard/type.js +1 -0
  41. package/dist/esm/component/BiuCustomerOperCard/utils.d.ts +48 -0
  42. package/dist/esm/component/BiuCustomerOperCard/utils.js +236 -0
  43. package/dist/esm/component/BiuDescriptions/index.d.ts +9 -0
  44. package/dist/esm/component/BiuDescriptions/index.js +39 -0
  45. package/dist/esm/component/BiuDetailDrawer/index.d.ts +15 -0
  46. package/dist/esm/component/BiuDetailDrawer/index.js +54 -0
  47. package/dist/esm/component/BiuDivider/index.d.ts +4 -0
  48. package/dist/esm/component/BiuDivider/index.js +29 -0
  49. package/dist/esm/component/BiuField/component/AddressTableSelect.d.ts +3 -0
  50. package/dist/esm/component/BiuField/component/AddressTableSelect.js +150 -0
  51. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/index.d.ts +3 -0
  52. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/index.js +3 -0
  53. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/useConvertSubValue.d.ts +2 -0
  54. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/useConvertSubValue.js +49 -0
  55. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/useConvertUnSubValue.d.ts +2 -0
  56. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/useConvertUnSubValue.js +98 -0
  57. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/useInConvertUnSubValue.d.ts +5 -0
  58. package/dist/esm/component/BiuField/component/DepartOrgSelect/hooks/useInConvertUnSubValue.js +82 -0
  59. package/dist/esm/component/BiuField/component/DepartOrgSelect/index.d.ts +14 -0
  60. package/dist/esm/component/BiuField/component/DepartOrgSelect/index.js +393 -0
  61. package/dist/esm/component/BiuField/component/DepartOrgSelect/type.d.ts +123 -0
  62. package/dist/esm/component/BiuField/component/DepartOrgSelect/type.js +1 -0
  63. package/dist/esm/component/BiuField/component/DepartOrgSelect/utils.d.ts +5 -0
  64. package/dist/esm/component/BiuField/component/DepartOrgSelect/utils.js +59 -0
  65. package/dist/esm/component/BiuField/component/OMSSystem/cityAreaSelect.d.ts +12 -0
  66. package/dist/esm/component/BiuField/component/OMSSystem/cityAreaSelect.js +130 -0
  67. package/dist/esm/component/BiuField/component/OMSSystem/warehouseSel.d.ts +7 -0
  68. package/dist/esm/component/BiuField/component/OMSSystem/warehouseSel.js +80 -0
  69. package/dist/esm/component/BiuField/component/SNInput.d.ts +13 -0
  70. package/dist/esm/component/BiuField/component/SNInput.js +622 -0
  71. package/dist/esm/component/BiuField/component/TableSelectLocal/addressSelect.d.ts +23 -0
  72. package/dist/esm/component/BiuField/component/TableSelectLocal/addressSelect.js +187 -0
  73. package/dist/esm/component/BiuField/component/TableSelectLocal/base.d.ts +13 -0
  74. package/dist/esm/component/BiuField/component/TableSelectLocal/base.js +153 -0
  75. package/dist/esm/component/BiuField/component/TableSelectLocal/goodSelect.d.ts +21 -0
  76. package/dist/esm/component/BiuField/component/TableSelectLocal/goodSelect.js +238 -0
  77. package/dist/esm/component/BiuField/component/TableSelectLocal/index.d.ts +3 -0
  78. package/dist/esm/component/BiuField/component/TableSelectLocal/index.js +66 -0
  79. package/dist/esm/component/BiuField/component/TableSelectLocal/interface.d.ts +16 -0
  80. package/dist/esm/component/BiuField/component/TableSelectLocal/interface.js +1 -0
  81. package/dist/esm/component/BiuField/component/TableSelectLocal/locationSelect.d.ts +24 -0
  82. package/dist/esm/component/BiuField/component/TableSelectLocal/locationSelect.js +164 -0
  83. package/dist/esm/component/BiuField/component/TableSelectLocal/package.d.ts +3 -0
  84. package/dist/esm/component/BiuField/component/TableSelectLocal/package.js +149 -0
  85. package/dist/esm/component/BiuField/component/TableSelectLocal/supplierSelect.d.ts +18 -0
  86. package/dist/esm/component/BiuField/component/TableSelectLocal/supplierSelect.js +145 -0
  87. package/dist/esm/component/BiuField/component/TableSelectLocal/warehouseAreaSelect.d.ts +3 -0
  88. package/dist/esm/component/BiuField/component/TableSelectLocal/warehouseAreaSelect.js +113 -0
  89. package/dist/esm/component/BiuField/component/TableSelectLocal/warehouseInfoSelects.d.ts +18 -0
  90. package/dist/esm/component/BiuField/component/TableSelectLocal/warehouseInfoSelects.js +100 -0
  91. package/dist/esm/component/BiuField/component/appliedgoodsTypeSelect.d.ts +9 -0
  92. package/dist/esm/component/BiuField/component/appliedgoodsTypeSelect.js +75 -0
  93. package/dist/esm/component/BiuField/component/autoComplete.d.ts +8 -0
  94. package/dist/esm/component/BiuField/component/autoComplete.js +82 -0
  95. package/dist/esm/component/BiuField/component/boxTypeSelect.d.ts +11 -0
  96. package/dist/esm/component/BiuField/component/boxTypeSelect.js +139 -0
  97. package/dist/esm/component/BiuField/component/businessdistrictselect.d.ts +55 -0
  98. package/dist/esm/component/BiuField/component/businessdistrictselect.js +414 -0
  99. package/dist/esm/component/BiuField/component/carrierInfoSelect.d.ts +13 -0
  100. package/dist/esm/component/BiuField/component/carrierInfoSelect.js +145 -0
  101. package/dist/esm/component/BiuField/component/channelSelect.d.ts +8 -0
  102. package/dist/esm/component/BiuField/component/channelSelect.js +94 -0
  103. package/dist/esm/component/BiuField/component/cityAreaCascader.d.ts +11 -0
  104. package/dist/esm/component/BiuField/component/cityAreaCascader.js +86 -0
  105. package/dist/esm/component/BiuField/component/clientInfoTableSelect.d.ts +3 -0
  106. package/dist/esm/component/BiuField/component/clientInfoTableSelect.js +175 -0
  107. package/dist/esm/component/BiuField/component/customMenu.d.ts +3 -0
  108. package/dist/esm/component/BiuField/component/customMenu.js +110 -0
  109. package/dist/esm/component/BiuField/component/databaseSelect.d.ts +6 -0
  110. package/dist/esm/component/BiuField/component/databaseSelect.js +42 -0
  111. package/dist/esm/component/BiuField/component/departmentTreeSelect.d.ts +3 -0
  112. package/dist/esm/component/BiuField/component/departmentTreeSelect.js +107 -0
  113. package/dist/esm/component/BiuField/component/dicNameSelect.d.ts +12 -0
  114. package/dist/esm/component/BiuField/component/dicNameSelect.js +53 -0
  115. package/dist/esm/component/BiuField/component/dicTypeSelect.d.ts +41 -0
  116. package/dist/esm/component/BiuField/component/dicTypeSelect.js +84 -0
  117. package/dist/esm/component/BiuField/component/dockingPartySelect.d.ts +8 -0
  118. package/dist/esm/component/BiuField/component/dockingPartySelect.js +63 -0
  119. package/dist/esm/component/BiuField/component/editLocationSelect.d.ts +18 -0
  120. package/dist/esm/component/BiuField/component/editLocationSelect.js +119 -0
  121. package/dist/esm/component/BiuField/component/electronicFaceSheet/accountSelect.d.ts +3 -0
  122. package/dist/esm/component/BiuField/component/electronicFaceSheet/accountSelect.js +36 -0
  123. package/dist/esm/component/BiuField/component/electronicFaceSheet/addresSelect.d.ts +14 -0
  124. package/dist/esm/component/BiuField/component/electronicFaceSheet/addresSelect.js +97 -0
  125. package/dist/esm/component/BiuField/component/electronicFaceSheet/platformSelect.d.ts +7 -0
  126. package/dist/esm/component/BiuField/component/electronicFaceSheet/platformSelect.js +73 -0
  127. package/dist/esm/component/BiuField/component/goodsTypeSelect.d.ts +10 -0
  128. package/dist/esm/component/BiuField/component/goodsTypeSelect.js +92 -0
  129. package/dist/esm/component/BiuField/component/index.d.ts +37 -0
  130. package/dist/esm/component/BiuField/component/index.js +37 -0
  131. package/dist/esm/component/BiuField/component/interfaceNameSelect.d.ts +9 -0
  132. package/dist/esm/component/BiuField/component/interfaceNameSelect.js +65 -0
  133. package/dist/esm/component/BiuField/component/lpnSelect.d.ts +3 -0
  134. package/dist/esm/component/BiuField/component/lpnSelect.js +88 -0
  135. package/dist/esm/component/BiuField/component/orderTypeSelect.d.ts +15 -0
  136. package/dist/esm/component/BiuField/component/orderTypeSelect.js +79 -0
  137. package/dist/esm/component/BiuField/component/orderTypeTableSelect.d.ts +3 -0
  138. package/dist/esm/component/BiuField/component/orderTypeTableSelect.js +45 -0
  139. package/dist/esm/component/BiuField/component/parkSelect.d.ts +12 -0
  140. package/dist/esm/component/BiuField/component/parkSelect.js +88 -0
  141. package/dist/esm/component/BiuField/component/personnelinfoselect.d.ts +57 -0
  142. package/dist/esm/component/BiuField/component/personnelinfoselect.js +431 -0
  143. package/dist/esm/component/BiuField/component/propertNameSelect.d.ts +9 -0
  144. package/dist/esm/component/BiuField/component/propertNameSelect.js +114 -0
  145. package/dist/esm/component/BiuField/component/shipperTableSelect.d.ts +3 -0
  146. package/dist/esm/component/BiuField/component/shipperTableSelect.js +94 -0
  147. package/dist/esm/component/BiuField/component/userSelect.d.ts +8 -0
  148. package/dist/esm/component/BiuField/component/userSelect.js +163 -0
  149. package/dist/esm/component/BiuField/component/warehouseAreaSelect.d.ts +9 -0
  150. package/dist/esm/component/BiuField/component/warehouseAreaSelect.js +103 -0
  151. package/dist/esm/component/BiuField/component/warehouseInfoSelect.d.ts +13 -0
  152. package/dist/esm/component/BiuField/component/warehouseInfoSelect.js +92 -0
  153. package/dist/esm/component/BiuField/component/warehouseLoctionSelect.d.ts +14 -0
  154. package/dist/esm/component/BiuField/component/warehouseLoctionSelect.js +124 -0
  155. package/dist/esm/component/BiuField/index.d.ts +8 -0
  156. package/dist/esm/component/BiuField/index.js +607 -0
  157. package/dist/esm/component/BiuFileInput/index.d.ts +11 -0
  158. package/dist/esm/component/BiuFileInput/index.js +53 -0
  159. package/dist/esm/component/BiuForm/index.d.ts +12 -0
  160. package/dist/esm/component/BiuForm/index.js +241 -0
  161. package/dist/esm/component/BiuForm/type.d.ts +45 -0
  162. package/dist/esm/component/BiuForm/type.js +1 -0
  163. package/dist/esm/component/BiuForm/utils.d.ts +2 -0
  164. package/dist/esm/component/BiuForm/utils.js +46 -0
  165. package/dist/esm/component/BiuIcon/index.d.ts +3 -0
  166. package/dist/esm/component/BiuIcon/index.js +15 -0
  167. package/dist/esm/component/BiuMapSelectSite/index.d.ts +48 -0
  168. package/dist/esm/component/BiuMapSelectSite/index.js +453 -0
  169. package/dist/esm/component/BiuModal/index.d.ts +24 -0
  170. package/dist/esm/component/BiuModal/index.js +239 -0
  171. package/dist/esm/component/BiuOperForm/index.d.ts +15 -0
  172. package/dist/esm/component/BiuOperForm/index.js +375 -0
  173. package/dist/esm/component/BiuOperForm/type.d.ts +23 -0
  174. package/dist/esm/component/BiuOperForm/type.js +1 -0
  175. package/dist/esm/component/BiuOperTable/index.d.ts +15 -0
  176. package/dist/esm/component/BiuOperTable/index.js +349 -0
  177. package/dist/esm/component/BiuOperTable/type.d.ts +142 -0
  178. package/dist/esm/component/BiuOperTable/type.js +1 -0
  179. package/dist/esm/component/BiuOperTable/utils.d.ts +6 -0
  180. package/dist/esm/component/BiuOperTable/utils.js +13 -0
  181. package/dist/esm/component/BiuPagination/index.d.ts +14 -0
  182. package/dist/esm/component/BiuPagination/index.js +34 -0
  183. package/dist/esm/component/BiuResizeTable/component/biuTableCell.d.ts +1 -0
  184. package/dist/esm/component/BiuResizeTable/component/biuTableCell.js +74 -0
  185. package/dist/esm/component/BiuResizeTable/component/index.d.ts +1 -0
  186. package/dist/esm/component/BiuResizeTable/component/index.js +1 -0
  187. package/dist/esm/component/BiuResizeTable/index.d.ts +2 -0
  188. package/dist/esm/component/BiuResizeTable/index.js +71 -0
  189. package/dist/esm/component/BiuResizeTable/index.less +19 -0
  190. package/dist/esm/component/BiuSplit/index.d.ts +32 -0
  191. package/dist/esm/component/BiuSplit/index.js +57 -0
  192. package/dist/esm/component/BiuTable/component/index.d.ts +3 -0
  193. package/dist/esm/component/BiuTable/component/index.js +3 -0
  194. package/dist/esm/component/BiuTable/component/tableActionBarRender.d.ts +9 -0
  195. package/dist/esm/component/BiuTable/component/tableActionBarRender.js +88 -0
  196. package/dist/esm/component/BiuTable/component/tableCellRender.d.ts +14 -0
  197. package/dist/esm/component/BiuTable/component/tableCellRender.js +108 -0
  198. package/dist/esm/component/BiuTable/component/tableSettingRender.d.ts +2 -0
  199. package/dist/esm/component/BiuTable/component/tableSettingRender.js +345 -0
  200. package/dist/esm/component/BiuTable/context.d.ts +2 -0
  201. package/dist/esm/component/BiuTable/context.js +2 -0
  202. package/dist/esm/component/BiuTable/hooks/index.d.ts +1 -0
  203. package/dist/esm/component/BiuTable/hooks/index.js +1 -0
  204. package/dist/esm/component/BiuTable/hooks/useFetchData.d.ts +4 -0
  205. package/dist/esm/component/BiuTable/hooks/useFetchData.js +64 -0
  206. package/dist/esm/component/BiuTable/index.d.ts +42 -0
  207. package/dist/esm/component/BiuTable/index.js +484 -0
  208. package/dist/esm/component/BiuTable/type.d.ts +168 -0
  209. package/dist/esm/component/BiuTable/type.js +1 -0
  210. package/dist/esm/component/BiuTable/utils.d.ts +10 -0
  211. package/dist/esm/component/BiuTable/utils.js +117 -0
  212. package/dist/esm/component/BiuTableLink/index.d.ts +11 -0
  213. package/dist/esm/component/BiuTableLink/index.js +54 -0
  214. package/dist/esm/component/BiuTableSelect/index.d.ts +49 -0
  215. package/dist/esm/component/BiuTableSelect/index.js +209 -0
  216. package/dist/esm/component/BiuTabs/index.d.ts +4 -0
  217. package/dist/esm/component/BiuTabs/index.js +18 -0
  218. package/dist/esm/component/BiuVirtualTable/index.d.ts +21 -0
  219. package/dist/esm/component/BiuVirtualTable/index.js +161 -0
  220. package/dist/esm/component/index.d.ts +35 -0
  221. package/dist/esm/component/index.js +35 -0
  222. package/dist/esm/constant/Cache_Key.d.ts +28 -0
  223. package/dist/esm/constant/Cache_Key.js +28 -0
  224. package/dist/esm/constant/DateTime.d.ts +12 -0
  225. package/dist/esm/constant/DateTime.js +15 -0
  226. package/dist/esm/constant/External.d.ts +64 -0
  227. package/dist/esm/constant/External.js +260 -0
  228. package/dist/esm/constant/Gateway_Path.d.ts +5 -0
  229. package/dist/esm/constant/Gateway_Path.js +5 -0
  230. package/dist/esm/constant/Layout.d.ts +210 -0
  231. package/dist/esm/constant/Layout.js +215 -0
  232. package/dist/esm/constant/Regexp.d.ts +109 -0
  233. package/dist/esm/constant/Regexp.js +130 -0
  234. package/dist/esm/constant/index.d.ts +6 -0
  235. package/dist/esm/constant/index.js +6 -0
  236. package/dist/esm/hooks/index.d.ts +6 -0
  237. package/dist/esm/hooks/index.js +6 -0
  238. package/dist/esm/hooks/useAuth.d.ts +4 -0
  239. package/dist/esm/hooks/useAuth.js +22 -0
  240. package/dist/esm/hooks/useCurrentSystem.d.ts +6 -0
  241. package/dist/esm/hooks/useCurrentSystem.js +15 -0
  242. package/dist/esm/hooks/useLayoutInfo.d.ts +10 -0
  243. package/dist/esm/hooks/useLayoutInfo.js +14 -0
  244. package/dist/esm/hooks/useReducerState.d.ts +16 -0
  245. package/dist/esm/hooks/useReducerState.js +43 -0
  246. package/dist/esm/hooks/useUserInfo.d.ts +4 -0
  247. package/dist/esm/hooks/useUserInfo.js +15 -0
  248. package/dist/esm/hooks/useWareInfo.d.ts +4 -0
  249. package/dist/esm/hooks/useWareInfo.js +15 -0
  250. package/dist/esm/index.d.ts +5 -0
  251. package/dist/esm/index.js +5 -0
  252. package/dist/esm/package/index.d.ts +1 -0
  253. package/dist/esm/package/index.js +1 -0
  254. package/dist/esm/package/requestWrapper/baseRequest.d.ts +3 -0
  255. package/dist/esm/package/requestWrapper/baseRequest.js +47 -0
  256. package/dist/esm/package/requestWrapper/index.d.ts +4 -0
  257. package/dist/esm/package/requestWrapper/index.js +402 -0
  258. package/dist/esm/package/requestWrapper/type.d.ts +36 -0
  259. package/dist/esm/package/requestWrapper/type.js +1 -0
  260. package/dist/esm/package/requestWrapper/utils.d.ts +10 -0
  261. package/dist/esm/package/requestWrapper/utils.js +35 -0
  262. package/dist/esm/utils/authUtils.d.ts +18 -0
  263. package/dist/esm/utils/authUtils.js +36 -0
  264. package/dist/esm/utils/cacheUtils.d.ts +4 -0
  265. package/dist/esm/utils/cacheUtils.js +24 -0
  266. package/dist/esm/utils/chainUtils.d.ts +26 -0
  267. package/dist/esm/utils/chainUtils.js +54 -0
  268. package/dist/esm/utils/dateUtils.d.ts +23 -0
  269. package/dist/esm/utils/dateUtils.js +55 -0
  270. package/dist/esm/utils/decimalUtils.d.ts +5 -0
  271. package/dist/esm/utils/decimalUtils.js +7 -0
  272. package/dist/esm/utils/excelUtils.d.ts +22 -0
  273. package/dist/esm/utils/excelUtils.js +153 -0
  274. package/dist/esm/utils/index.d.ts +11 -0
  275. package/dist/esm/utils/index.js +11 -0
  276. package/dist/esm/utils/layoutUtils.d.ts +1 -0
  277. package/dist/esm/utils/layoutUtils.js +13 -0
  278. package/dist/esm/utils/objectUtils.d.ts +1 -0
  279. package/dist/esm/utils/objectUtils.js +3 -0
  280. package/dist/esm/utils/soundUtils.d.ts +5 -0
  281. package/dist/esm/utils/soundUtils.js +29 -0
  282. package/dist/esm/utils/stringUtils.d.ts +24 -0
  283. package/dist/esm/utils/stringUtils.js +39 -0
  284. package/dist/esm/utils/sysUtils.d.ts +4 -0
  285. package/dist/esm/utils/sysUtils.js +4 -0
  286. package/package.json +59 -0
@@ -0,0 +1,163 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ var _excluded = ["isModel", "onChange", "onChangeData", "value", "warehouseFilter"];
3
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
9
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
10
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
11
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
12
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
13
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
14
+ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
15
+ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
16
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
17
+ function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
18
+ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
19
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
20
+ import { useControllableValue } from 'ahooks';
21
+ import React, { forwardRef, useCallback, useEffect, useMemo, useState } from 'react';
22
+ import { BiuASelect, BiuASelectOption } from "../..";
23
+ import { BUBU100_CACHE_USERINFO_KEY, GATEWAY_ROUTE_MDM } from "../../../constant";
24
+ import { request } from "../../../package";
25
+ import { jsx as _jsx } from "react/jsx-runtime";
26
+ var getuserData = function getuserData(data) {
27
+ return request({
28
+ apiName: 'wms.mdm.userQuery',
29
+ data: data,
30
+ requestConfig: {
31
+ GatewayRoute: GATEWAY_ROUTE_MDM
32
+ }
33
+ });
34
+ };
35
+ var getDepartList = function getDepartList(data) {
36
+ return request({
37
+ apiName: 'wms.mdm.companyQuery',
38
+ data: data,
39
+ requestConfig: {
40
+ GatewayRoute: GATEWAY_ROUTE_MDM
41
+ }
42
+ });
43
+ };
44
+ var flatSubValue = function flatSubValue(departList, currentId) {
45
+ var subObj = [];
46
+ var filterObj = departList.filter(function (n) {
47
+ return n.pId === currentId;
48
+ });
49
+ subObj = [].concat(_toConsumableArray(subObj), _toConsumableArray(filterObj));
50
+ filterObj.map(function (n) {
51
+ subObj = [].concat(_toConsumableArray(subObj), _toConsumableArray(flatSubValue(departList, n.id)));
52
+ return n;
53
+ });
54
+ return subObj;
55
+ };
56
+ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props, ref) {
57
+ var _sessionStorage$getIt;
58
+ var mode = props.isModel,
59
+ onChange = props.onChange,
60
+ onChangeData = props.onChangeData,
61
+ value = props.value,
62
+ _props$warehouseFilte = props.warehouseFilter,
63
+ warehouseFilter = _props$warehouseFilte === void 0 ? true : _props$warehouseFilte,
64
+ restProps = _objectWithoutProperties(props, _excluded);
65
+ var linkUserInfo = JSON.parse((_sessionStorage$getIt = sessionStorage.getItem(BUBU100_CACHE_USERINFO_KEY)) !== null && _sessionStorage$getIt !== void 0 ? _sessionStorage$getIt : '{}');
66
+ var _useState = useState([]),
67
+ _useState2 = _slicedToArray(_useState, 2),
68
+ userList = _useState2[0],
69
+ setUserList = _useState2[1];
70
+ var _useState3 = useState(false),
71
+ _useState4 = _slicedToArray(_useState3, 2),
72
+ loading = _useState4[0],
73
+ setLoading = _useState4[1];
74
+ var _useState5 = useState([]),
75
+ _useState6 = _slicedToArray(_useState5, 2),
76
+ treeNodeList = _useState6[0],
77
+ setTreeNodeList = _useState6[1];
78
+ var _useControllableValue = useControllableValue({
79
+ value: value,
80
+ onChange: onChange
81
+ }, {
82
+ defaultValue: linkUserInfo.id
83
+ }),
84
+ _useControllableValue2 = _slicedToArray(_useControllableValue, 2),
85
+ controlValue = _useControllableValue2[0],
86
+ setControlValue = _useControllableValue2[1];
87
+ useEffect(function () {
88
+ if (!linkUserInfo.companyid) return;
89
+ getDepartList({
90
+ id: linkUserInfo.companyid,
91
+ companyIdQueryTree: 1,
92
+ page: 1,
93
+ size: 1000000
94
+ }).then(function (res) {
95
+ var filterData = res.rows.reduce(function (arr, current) {
96
+ arr.push({
97
+ id: current.id,
98
+ pId: current.fatherid,
99
+ title: current.name,
100
+ value: current.id
101
+ });
102
+ return arr;
103
+ }, []);
104
+ setTreeNodeList(filterData);
105
+ });
106
+ }, [linkUserInfo.companyid]);
107
+ useEffect(function () {
108
+ if (treeNodeList && Array.isArray(treeNodeList) && treeNodeList.length > 0) {
109
+ var departStr = flatSubValue(treeNodeList, linkUserInfo.companyid).reduce(function (arr, current) {
110
+ return [].concat(_toConsumableArray(arr), [current.id]);
111
+ }, [linkUserInfo.companyid]).join(',');
112
+ getuserData({
113
+ companyid: departStr,
114
+ id: value,
115
+ warehouseFilter: warehouseFilter
116
+ }).then(function (res) {
117
+ setUserList(res.rows);
118
+ setLoading(false);
119
+ });
120
+ }
121
+ }, [linkUserInfo.companyid, treeNodeList, value, warehouseFilter]);
122
+ var selectProps = useMemo(function () {
123
+ return {
124
+ showSearch: true,
125
+ mode: mode,
126
+ style: {},
127
+ loading: loading,
128
+ optionFilterProp: 'children',
129
+ value: controlValue
130
+ };
131
+ }, [controlValue, loading, mode]);
132
+ var onSearch = useCallback(function (searchValue) {
133
+ getuserData({
134
+ remoteSearchCValue: searchValue,
135
+ warehouseFilter: warehouseFilter,
136
+ page: 1,
137
+ size: 20
138
+ }).then(function (data) {
139
+ if (data !== null && data !== void 0 && data.rows) {
140
+ setUserList(data.rows);
141
+ }
142
+ });
143
+ }, [warehouseFilter]);
144
+ return /*#__PURE__*/_jsx(BiuASelect, _objectSpread(_objectSpread(_objectSpread({
145
+ ref: ref
146
+ }, selectProps), restProps), {}, {
147
+ onSearch: onSearch,
148
+ onChange: function onChange(changeValue) {
149
+ setControlValue(changeValue);
150
+ if (onChangeData) {
151
+ onChangeData(changeValue, userList.filter(function (item) {
152
+ return "".concat(item.id) === "".concat(changeValue);
153
+ })[0]);
154
+ }
155
+ },
156
+ children: userList.map(function (d) {
157
+ return /*#__PURE__*/_jsx(BiuASelectOption, {
158
+ value: d.id,
159
+ children: d.employeename || ' '
160
+ }, d.id);
161
+ })
162
+ }), "userSelect");
163
+ }));
@@ -0,0 +1,9 @@
1
+ import type { SelectProps } from 'antd';
2
+ import React from 'react';
3
+ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<{
4
+ warehouseId?: number | undefined;
5
+ value?: string | number | string[] | number[] | undefined;
6
+ onChangeData?: ((value: any, record: any) => void) | undefined;
7
+ isFirstLoad?: boolean | undefined;
8
+ } & SelectProps<any, import("antd/lib/select").DefaultOptionType> & React.RefAttributes<unknown>>>;
9
+ export default _default;
@@ -0,0 +1,103 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ var _excluded = ["warehouseId", "onChange", "onChangeData", "isFirstLoad"];
3
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
9
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
10
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
11
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
12
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
13
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
14
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
15
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
16
+ import React, { forwardRef, useCallback, useEffect, useState } from 'react';
17
+ import { BiuASelectOption, BiuASelect } from "../..";
18
+ import { GATEWAY_ROUTE_WMS } from "../../../constant";
19
+ import { request } from "../../../package";
20
+ import { jsx as _jsx } from "react/jsx-runtime";
21
+ /**
22
+ * 库区查询条件
23
+ * @param queryData
24
+ */
25
+ var getWarehouseAreaList = function getWarehouseAreaList(queryData) {
26
+ return request({
27
+ apiName: 'wms.basedata.quarySimpleWA',
28
+ data: queryData,
29
+ requestConfig: {
30
+ GatewayRoute: GATEWAY_ROUTE_WMS
31
+ }
32
+ });
33
+ };
34
+
35
+ /**
36
+ * 组件封装对所有字段去掉验证,组件验证对于开发来说不需要,组件参数错误,数据也就错了
37
+ */
38
+
39
+ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props, ref) {
40
+ var warehouseId = props.warehouseId,
41
+ _onChange = props.onChange,
42
+ onChangeData = props.onChangeData,
43
+ _props$isFirstLoad = props.isFirstLoad,
44
+ isFirstLoad = _props$isFirstLoad === void 0 ? true : _props$isFirstLoad,
45
+ restProps = _objectWithoutProperties(props, _excluded);
46
+ var _useState = useState([]),
47
+ _useState2 = _slicedToArray(_useState, 2),
48
+ warehouseAreaList = _useState2[0],
49
+ setWarehouseAreaList = _useState2[1];
50
+ var _useState3 = useState(false),
51
+ _useState4 = _slicedToArray(_useState3, 2),
52
+ loading = _useState4[0],
53
+ setLoading = _useState4[1];
54
+
55
+ /**
56
+ * 加载原始数据源,根据传入值查询
57
+ * ps。依赖传入参数
58
+ */
59
+ useEffect(function () {
60
+ if (!warehouseId || !isFirstLoad) {
61
+ setWarehouseAreaList([]);
62
+ return;
63
+ }
64
+ setLoading(true);
65
+ getWarehouseAreaList({
66
+ warehouseId: warehouseId
67
+ }).then(function (res) {
68
+ setWarehouseAreaList(res);
69
+ setLoading(false);
70
+ });
71
+ }, [warehouseId, isFirstLoad]);
72
+ var onSearch = useCallback(function (value) {
73
+ getWarehouseAreaList({
74
+ warehouseId: warehouseId,
75
+ warehouseAreaCode: value
76
+ }).then(function (res) {
77
+ setWarehouseAreaList(res);
78
+ setLoading(false);
79
+ });
80
+ }, [warehouseId]);
81
+ return /*#__PURE__*/_jsx(BiuASelect, _objectSpread(_objectSpread({
82
+ ref: ref,
83
+ showSearch: true,
84
+ optionFilterProp: "children",
85
+ loading: loading
86
+ }, restProps), {}, {
87
+ onChange: function onChange(value, option) {
88
+ if (_onChange) _onChange(value, option);
89
+ if (onChangeData) {
90
+ onChangeData(value, warehouseAreaList.filter(function (item) {
91
+ return "".concat(item.id) === "".concat(value);
92
+ })[0]);
93
+ }
94
+ },
95
+ onSearch: onSearch,
96
+ children: warehouseAreaList.map(function (d) {
97
+ return /*#__PURE__*/_jsx(BiuASelectOption, {
98
+ value: d.id,
99
+ children: d.warehouseAreaName || ' '
100
+ }, d.id);
101
+ })
102
+ }), "warehouseAreaSelect");
103
+ }));
@@ -0,0 +1,13 @@
1
+ import type { SelectProps } from 'antd';
2
+ import React from 'react';
3
+ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<{
4
+ warehouseName?: string | undefined;
5
+ value?: string | number | string[] | number[] | undefined;
6
+ ownerId?: string | undefined;
7
+ clientid?: string | undefined;
8
+ employeecode?: string | undefined;
9
+ onChangeData?: ((value: any, record: any) => void) | undefined;
10
+ type?: string | undefined;
11
+ isFirstLoad?: boolean | undefined;
12
+ } & SelectProps<any, import("antd/lib/select").DefaultOptionType> & React.RefAttributes<unknown>>>;
13
+ export default _default;
@@ -0,0 +1,92 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ var _excluded = ["warehouseName", "ownerId", "clientid", "onChange", "onChangeData", "type", "employeecode"];
3
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
9
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
10
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
11
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
12
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
13
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
14
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
15
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
16
+ import React, { forwardRef, useCallback, useMemo, useState } from 'react';
17
+ import { BiuCustomSelect } from "../..";
18
+ import { GATEWAY_ROUTE_MDM } from "../../../constant";
19
+
20
+ /**
21
+ * 字典传入类型定义
22
+ */
23
+ import { jsx as _jsx } from "react/jsx-runtime";
24
+ var requestConfig = {
25
+ GatewayRoute: GATEWAY_ROUTE_MDM
26
+ };
27
+ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props, ref) {
28
+ var _props$warehouseName = props.warehouseName,
29
+ warehouseName = _props$warehouseName === void 0 ? '' : _props$warehouseName,
30
+ _props$ownerId = props.ownerId,
31
+ ownerId = _props$ownerId === void 0 ? '' : _props$ownerId,
32
+ clientid = props.clientid,
33
+ onChange = props.onChange,
34
+ onChangeData = props.onChangeData,
35
+ _props$type = props.type,
36
+ type = _props$type === void 0 ? '' : _props$type,
37
+ employeecode = props.employeecode,
38
+ restProps = _objectWithoutProperties(props, _excluded);
39
+ var _useState = useState([]),
40
+ _useState2 = _slicedToArray(_useState, 2),
41
+ warehouseList = _useState2[0],
42
+ setWarehouseList = _useState2[1];
43
+ var _useState3 = useState(warehouseName),
44
+ _useState4 = _slicedToArray(_useState3, 2),
45
+ wareName = _useState4[0],
46
+ setWareName = _useState4[1];
47
+ var requestParams = useMemo(function () {
48
+ return {
49
+ warehouseName: wareName,
50
+ ownerId: ownerId,
51
+ clientId: clientid,
52
+ employeecode: employeecode
53
+ };
54
+ }, [wareName, ownerId, clientid, employeecode]);
55
+ var onSearch = useCallback(function (value) {
56
+ setWareName(value);
57
+ }, []);
58
+ var onFetchData = useCallback(function (res) {
59
+ setWarehouseList(res);
60
+ return res.map(function (item) {
61
+ return {
62
+ label: item.warehouseName,
63
+ value: item.id
64
+ };
65
+ });
66
+ }, []);
67
+ var isOnChange = useCallback(function (value, option) {
68
+ if (onChange) onChange(value, option);
69
+ if (onChangeData) {
70
+ onChangeData(value, warehouseList.filter(function (item) {
71
+ return "".concat(item.id) === "".concat(value);
72
+ })[0]);
73
+ }
74
+ }, [onChange, onChangeData, warehouseList]);
75
+ var mode = useMemo(function () {
76
+ return type === '1' ? 'multiple' : undefined;
77
+ }, [type]);
78
+ var maxTagCount = useMemo(function () {
79
+ return type === '1' ? 1 : undefined;
80
+ }, [type]);
81
+ return /*#__PURE__*/_jsx(BiuCustomSelect, _objectSpread({
82
+ ref: ref,
83
+ requestName: "wms.mdm.warhouseSimpleList",
84
+ requestParams: requestParams,
85
+ requestConfig: requestConfig,
86
+ mode: mode,
87
+ maxTagCount: maxTagCount,
88
+ onChange: isOnChange,
89
+ onSearch: onSearch,
90
+ onFetchData: onFetchData
91
+ }, restProps), "warehouseInfoSelect");
92
+ }));
@@ -0,0 +1,14 @@
1
+ import type { SelectProps } from 'antd';
2
+ import React from 'react';
3
+ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<{
4
+ id?: number | undefined;
5
+ warehouseId?: number | undefined;
6
+ locationCode?: string | undefined;
7
+ warehouseAreaId?: number | undefined;
8
+ value?: string | number | string[] | number[] | undefined;
9
+ onSelectChange?: ((value: any, record: any) => any) | undefined;
10
+ isFirstLoad?: true | undefined;
11
+ warehouseAreaType?: string | undefined;
12
+ isAutoGenerate?: string | undefined;
13
+ } & SelectProps<any, import("antd/lib/select").DefaultOptionType> & React.RefAttributes<unknown>>>;
14
+ export default _default;
@@ -0,0 +1,124 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ var _excluded = ["locationCode", "warehouseAreaId", "warehouseId", "onSelectChange", "warehouseAreaType", "isFirstLoad", "isAutoGenerate"];
3
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
9
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
10
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
11
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
12
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
13
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
14
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
15
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
16
+ import { isNil } from 'lodash';
17
+ import React, { forwardRef, useCallback, useEffect, useState } from 'react';
18
+ import { BiuASelectOption, BiuASelect } from "../..";
19
+ import { GATEWAY_ROUTE_WMS } from "../../../constant";
20
+ import { request } from "../../../package";
21
+ import { jsx as _jsx } from "react/jsx-runtime";
22
+ /**
23
+ * 库位查询(根据商品区分)
24
+ * @param queryData
25
+ */
26
+ var getWarehouseLoctionList = function getWarehouseLoctionList(queryData) {
27
+ return request({
28
+ apiName: isNil(queryData.goodsId) ? 'wms.basedata.querySimpleComponent' : 'wms.base.getLocationGoods',
29
+ data: queryData,
30
+ requestConfig: {
31
+ GatewayRoute: GATEWAY_ROUTE_WMS
32
+ }
33
+ });
34
+ };
35
+
36
+ /**
37
+ * 组件封装对所有字段去掉验证,组件验证对于开发来说不需要,组件参数错误,数据也就错了
38
+ */
39
+
40
+ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props, ref) {
41
+ var locationCode = props.locationCode,
42
+ warehouseAreaId = props.warehouseAreaId,
43
+ warehouseId = props.warehouseId,
44
+ onSelectChange = props.onSelectChange,
45
+ warehouseAreaType = props.warehouseAreaType,
46
+ _props$isFirstLoad = props.isFirstLoad,
47
+ isFirstLoad = _props$isFirstLoad === void 0 ? true : _props$isFirstLoad,
48
+ _props$isAutoGenerate = props.isAutoGenerate,
49
+ isAutoGenerate = _props$isAutoGenerate === void 0 ? '2' : _props$isAutoGenerate,
50
+ restProps = _objectWithoutProperties(props, _excluded);
51
+ var _useState = useState([]),
52
+ _useState2 = _slicedToArray(_useState, 2),
53
+ warehouseLoctionList = _useState2[0],
54
+ setWarehouseLoctionList = _useState2[1];
55
+ var _useState3 = useState(false),
56
+ _useState4 = _slicedToArray(_useState3, 2),
57
+ loading = _useState4[0],
58
+ setLoading = _useState4[1];
59
+
60
+ /**
61
+ * 加载原始数据源,根据传入值查询
62
+ * ps。依赖传入参数
63
+ */
64
+ useEffect(function () {
65
+ if (!warehouseId || !isFirstLoad) {
66
+ setWarehouseLoctionList([]);
67
+ return;
68
+ }
69
+ setLoading(true);
70
+ getWarehouseLoctionList({
71
+ locationCode: locationCode,
72
+ warehouseAreaId: warehouseAreaId,
73
+ warehouseId: warehouseId,
74
+ warehouseAreaType: warehouseAreaType,
75
+ page: 1,
76
+ size: 20,
77
+ isAutoGenerate: isAutoGenerate
78
+ }).then(function (res) {
79
+ setWarehouseLoctionList(res);
80
+ setLoading(false);
81
+ });
82
+ }, [locationCode, warehouseAreaId, warehouseId, warehouseAreaType, isFirstLoad, isAutoGenerate]);
83
+ var onSearch = useCallback(function (value) {
84
+ getWarehouseLoctionList({
85
+ locationCode: value,
86
+ warehouseAreaId: warehouseAreaId,
87
+ warehouseId: warehouseId,
88
+ warehouseAreaType: warehouseAreaType,
89
+ page: 1,
90
+ size: 20,
91
+ isAutoGenerate: isAutoGenerate
92
+ }).then(function (res) {
93
+ setWarehouseLoctionList(res);
94
+ setLoading(false);
95
+ });
96
+ }, [isAutoGenerate, warehouseAreaId, warehouseAreaType, warehouseId]);
97
+ return /*#__PURE__*/_jsx(BiuASelect, _objectSpread(_objectSpread({
98
+ ref: ref,
99
+ showSearch: true,
100
+ optionFilterProp: "children",
101
+ loading: loading,
102
+ onChange: function onChange(value) {
103
+ var _warehouseLoctionList = warehouseLoctionList.filter(function (n) {
104
+ return n.id === value;
105
+ }),
106
+ _warehouseLoctionList2 = _slicedToArray(_warehouseLoctionList, 1),
107
+ record = _warehouseLoctionList2[0];
108
+ if (onSelectChange) {
109
+ onSelectChange(value, record);
110
+ }
111
+ },
112
+ filterOption: function filterOption() {
113
+ return true;
114
+ },
115
+ onSearch: onSearch
116
+ }, restProps), {}, {
117
+ children: warehouseLoctionList.map(function (d) {
118
+ return /*#__PURE__*/_jsx(BiuASelectOption, {
119
+ value: d.id,
120
+ children: d.locationName || ' '
121
+ }, d.id);
122
+ })
123
+ }), "warehouseLoctionSelect");
124
+ }));
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ export type BiuFieldPropsType = {
3
+ valueType: BiuFieldType;
4
+ } & {
5
+ [P in string]: any;
6
+ };
7
+ export type BiuFieldType = 'sninput' | 'omswarehousesel' | 'cityareaselect' | 'label' | 'text' | 'textarea' | 'inputpassword' | 'number' | 'time' | 'date' | 'datetime' | 'month' | 'dicselect' | 'cityareacascader' | 'daterange' | 'distributioncentreselect' | 'warehouseinfoselect' | 'warehouseloctionwelect' | 'departtreeselect' | 'select' | 'goodsselect' | 'warehouseareaselect' | 'clientselect' | 'checkbox' | 'ordertypetableselect' | 'customer' | 'goodstypeselect' | 'shipperselect' | 'ordertypeselect' | 'dicselectname' | 'carrierinfoselect' | 'databaseSelect' | 'editLocationSelect' | 'departorgselect' | 'departmentTreeSelect' | 'tableselectlocal' | 'appliedgoodstypeselect' | 'dockingPartySelect' | 'interfaceNameSelect' | 'boxtypeselect' | 'propertNameSelect' | 'userSelect' | 'channelSelect' | 'customMenu' | 'lpnselect' | 'autoComplete' | 'platformSelect' | 'accountSelect' | 'addressSelect' | 'addressTableSelect' | 'personnelinfoselect' | 'businessdistrictselect' | 'checkboxgroup' | 'filter';
8
+ export declare const BiuField: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<BiuFieldPropsType, "ref"> & React.RefAttributes<unknown>>>;