@bjsdistribution/dms-client-return 0.1.65-prod → 0.1.66-prod

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,7 @@ import { ClientData, ClientType } from '../order-daily-overview/common/interface
4
4
  interface OrderRecipient {
5
5
  recipient_name: string | null;
6
6
  postcode: string | null;
7
+ return_action?: string[] | null;
7
8
  }
8
9
  export declare const ordersInitialValue: OrdersType;
9
10
  export declare const orderProductInitialvalue: CreateProduct;
@@ -180,6 +180,7 @@ export interface OrdersType {
180
180
  order_customs_details?: OrderCustomsDetails;
181
181
  show_customs_details?: false;
182
182
  import_reference: string | null;
183
+ return_action?: string[] | null;
183
184
  }
184
185
  export declare type DeleteProds = {
185
186
  id: number | null | undefined;
@@ -2415,6 +2415,10 @@ var StyledTableWrapper$1 = /*#__PURE__*/styled__default.div(_templateObject20 ||
2415
2415
  var CustomDrop = /*#__PURE__*/styled__default.div(_templateObject21 || (_templateObject21 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n /* border-radius: 20px;\n border: 1px solid #e2e0db;\n background: #fff;\n display: flex;\n padding: 4px 8px;\n gap: 8px;\n align-items: center; */\n cursor: pointer;\n &.active .drop {\n transform: rotate(180deg);\n }\n"])));
2416
2416
 
2417
2417
  var _excluded = ["count"];
2418
+ var SELECTABLE_ACTIONS = ['RTS', 'CLAIMS PAID', 'DISPOSE', 'RE-ALLOCATE', 'RECYCLE', 'UNKNOWN'];
2419
+ var isSelectableItem = function isSelectableItem(item) {
2420
+ return SELECTABLE_ACTIONS.includes(item == null ? void 0 : item.product_return_action) && (item == null ? void 0 : item.return_location) !== 'null' && (item == null ? void 0 : item.return_location) !== null;
2421
+ };
2418
2422
  var ReturnOrderTable = function ReturnOrderTable() {
2419
2423
  var _useAtom = jotai.useAtom(filtersReducerAtom),
2420
2424
  state = _useAtom[0];
@@ -2576,8 +2580,14 @@ var ReturnOrderTable = function ReturnOrderTable() {
2576
2580
  var isChecked = e.target.checked;
2577
2581
  setSelectAll(isChecked);
2578
2582
  if (isChecked) {
2583
+ var _selectedReturnOrder$;
2584
+ var firstSelectable = returnData == null ? void 0 : returnData.find(function (loc) {
2585
+ return isSelectableItem(loc);
2586
+ });
2587
+ var targetAction = selectedReturnOrder.length > 0 ? (_selectedReturnOrder$ = selectedReturnOrder[0]) == null ? void 0 : _selectedReturnOrder$.product_return_action : firstSelectable == null ? void 0 : firstSelectable.product_return_action;
2588
+ if (!targetAction) return;
2579
2589
  var filteredData = returnData == null ? void 0 : returnData.filter(function (loc) {
2580
- return (loc == null ? void 0 : loc.product_return_action) === 'RTS';
2590
+ return isSelectableItem(loc) && (loc == null ? void 0 : loc.product_return_action) === targetAction;
2581
2591
  });
2582
2592
  var selectedOrders = filteredData.map(function (loc) {
2583
2593
  return {
@@ -2613,6 +2623,7 @@ var ReturnOrderTable = function ReturnOrderTable() {
2613
2623
  return loc.id === id;
2614
2624
  });
2615
2625
  if (isSelected) {
2626
+ var _returnData$filter;
2616
2627
  var updatedSelectedLocations = prevSelectedLocations.filter(function (loc) {
2617
2628
  return loc.id !== id;
2618
2629
  });
@@ -2628,10 +2639,14 @@ var ReturnOrderTable = function ReturnOrderTable() {
2628
2639
  return item.id !== id;
2629
2640
  });
2630
2641
  });
2631
- setSelectAll(false); // Ensure "select all" is false if one is deselected
2642
+ var targetAction = product_return_action;
2643
+ var totalItemsOfAction = returnData == null || (_returnData$filter = returnData.filter(function (loc) {
2644
+ return isSelectableItem(loc) && (loc == null ? void 0 : loc.product_return_action) === targetAction;
2645
+ })) == null ? void 0 : _returnData$filter.length;
2646
+ setSelectAll((updatedSelectedLocations == null ? void 0 : updatedSelectedLocations.length) > 0 && (updatedSelectedLocations == null ? void 0 : updatedSelectedLocations.length) === totalItemsOfAction);
2632
2647
  return updatedSelectedLocations;
2633
2648
  } else {
2634
- var _returnData$filter;
2649
+ var _returnData$filter2;
2635
2650
  var newReturnPayload = {
2636
2651
  id: id,
2637
2652
  account_number: accountNumber,
@@ -2649,38 +2664,41 @@ var ReturnOrderTable = function ReturnOrderTable() {
2649
2664
  return_location_name: return_location_name,
2650
2665
  product_return_action: product_return_action
2651
2666
  }]);
2652
- setSelectAll((_updatedSelectedLocations == null ? void 0 : _updatedSelectedLocations.length) === (returnData == null || (_returnData$filter = returnData.filter(function (loc) {
2653
- return (loc == null ? void 0 : loc.product_return_action) === 'RTS';
2654
- })) == null ? void 0 : _returnData$filter.length));
2667
+ var _targetAction = product_return_action;
2668
+ var _totalItemsOfAction = returnData == null || (_returnData$filter2 = returnData.filter(function (loc) {
2669
+ return isSelectableItem(loc) && (loc == null ? void 0 : loc.product_return_action) === _targetAction;
2670
+ })) == null ? void 0 : _returnData$filter2.length;
2671
+ setSelectAll((_updatedSelectedLocations == null ? void 0 : _updatedSelectedLocations.length) === _totalItemsOfAction);
2655
2672
  return _updatedSelectedLocations;
2656
2673
  }
2657
2674
  });
2658
2675
  };
2659
2676
  React.useEffect(function () {
2660
- if ((newpayload == null ? void 0 : newpayload.length) === 0) return;
2677
+ if ((newpayload == null ? void 0 : newpayload.length) === 0) {
2678
+ setGrouped([]);
2679
+ return;
2680
+ }
2661
2681
  var groupedPayload = newpayload == null ? void 0 : newpayload.reduce(function (acc, item) {
2662
- var return_location_token = item.return_location_token;
2663
- if (!return_location_token) {
2664
- acc.push(item);
2665
- } else {
2666
- if (!acc[return_location_token]) {
2667
- acc[return_location_token] = _extends({}, item, {
2668
- products: [],
2669
- return_action: []
2670
- });
2671
- }
2672
- acc[return_location_token].products = [].concat(acc[return_location_token].products, item.products);
2673
- acc[return_location_token].return_action = [].concat(acc[return_location_token].return_action, item.return_action);
2682
+ var return_location_token = item.return_location_token,
2683
+ id = item.id;
2684
+ var key = return_location_token || "no_token_" + id;
2685
+ if (!acc[key]) {
2686
+ acc[key] = _extends({}, item, {
2687
+ products: [],
2688
+ return_action: []
2689
+ });
2674
2690
  }
2691
+ acc[key].products = [].concat(acc[key].products, item.products);
2692
+ acc[key].return_action = Array.from(new Set([].concat(acc[key].return_action, item.return_action)));
2675
2693
  return acc;
2676
- }, []);
2694
+ }, {});
2677
2695
  var mergedPayload = Object.values(groupedPayload);
2678
2696
  setGrouped(mergedPayload);
2679
2697
  }, [newpayload]);
2680
2698
  return React__default.createElement(React__default.Fragment, null, React__default.createElement(StyledTableWrapper$1, {
2681
2699
  className: "fortables"
2682
2700
  }, React__default.createElement(StyledTable$1, null, React__default.createElement("thead", null, React__default.createElement("tr", null, returnData != null && returnData.some(function (item) {
2683
- return (item == null ? void 0 : item.product_return_action) === 'RTS' && (item == null ? void 0 : item.return_location) !== 'null' && (item == null ? void 0 : item.return_location) !== null;
2701
+ return isSelectableItem(item);
2684
2702
  }) ? React__default.createElement("th", {
2685
2703
  className: "emailInvoiceCheckbox"
2686
2704
  }, React__default.createElement(dmsComponentLibrary.Checkbox, {
@@ -2731,11 +2749,12 @@ var ReturnOrderTable = function ReturnOrderTable() {
2731
2749
  }))) : (sortedData == null ? void 0 : sortedData.length) === 0 ? React__default.createElement("tr", null, React__default.createElement("td", {
2732
2750
  colSpan: 14
2733
2751
  }, React__default.createElement(EmptyDataContainer, null, React__default.createElement(antd.Empty, null)))) : sortedData == null ? void 0 : sortedData.map(function (item, index) {
2734
- var _item$client_name;
2752
+ var _selectedReturnOrder$2, _item$client_name;
2735
2753
  return React__default.createElement("tr", {
2736
2754
  key: item.id
2737
- }, React__default.createElement("td", null, (item == null ? void 0 : item.product_return_action) === 'RTS' && (item == null ? void 0 : item.return_location) !== 'null' && (item == null ? void 0 : item.return_location) !== null ? React__default.createElement(dmsComponentLibrary.Checkbox, {
2755
+ }, React__default.createElement("td", null, isSelectableItem(item) ? React__default.createElement(dmsComponentLibrary.Checkbox, {
2738
2756
  className: "custom-check",
2757
+ disabled: selectedReturnOrder.length > 0 && ((_selectedReturnOrder$2 = selectedReturnOrder[0]) == null ? void 0 : _selectedReturnOrder$2.product_return_action) !== (item == null ? void 0 : item.product_return_action),
2739
2758
  checked: selectedReturnOrder.some(function (selectedInvoice) {
2740
2759
  return (selectedInvoice == null ? void 0 : selectedInvoice.id) === (item == null ? void 0 : item.id);
2741
2760
  }),
@@ -6465,7 +6484,7 @@ function OrderDetailsFooter() {
6465
6484
  var onSave = /*#__PURE__*/function () {
6466
6485
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
6467
6486
  var _response$data;
6468
- var _orderDetails$order_c, _ref2, consignor_eori, packaging_type, consignee_country, commodity_code, country_of_origin, item_invoice_amount, procedure_code, ni_additional_information_codes, additional_procedure_code, additional_procedures, customDetailsPayload, payload, serviceKeys, _i, _serviceKeys, key, response, _response$data$, _response$data$2, alertsApiRes, orderStatusApiRes;
6487
+ var _orderDetails$order_c, _ref2, consignor_eori, packaging_type, consignee_country, commodity_code, country_of_origin, item_invoice_amount, procedure_code, ni_additional_information_codes, additional_procedure_code, additional_procedures, customDetailsPayload, payload, serviceKeys, _i, _serviceKeys, key, response, _response$data$, _response$data$2, _response$data$3, alertsApiRes, orderStatusApiRes;
6469
6488
  return _regeneratorRuntime().wrap(function _callee$(_context) {
6470
6489
  while (1) switch (_context.prev = _context.next) {
6471
6490
  case 0:
@@ -6531,7 +6550,8 @@ function OrderDetailsFooter() {
6531
6550
  setPrevOrderDetails(response == null ? void 0 : response.data[0]);
6532
6551
  setCustomerInfo({
6533
6552
  recipient_name: response == null || (_response$data$ = response.data[0]) == null || (_response$data$ = _response$data$.order_recipient) == null ? void 0 : _response$data$.recipient_name,
6534
- postcode: response == null || (_response$data$2 = response.data[0]) == null || (_response$data$2 = _response$data$2.order_recipient) == null ? void 0 : _response$data$2.postcode
6553
+ postcode: response == null || (_response$data$2 = response.data[0]) == null || (_response$data$2 = _response$data$2.order_recipient) == null ? void 0 : _response$data$2.postcode,
6554
+ return_action: response == null || (_response$data$3 = response.data[0]) == null ? void 0 : _response$data$3.return_action
6535
6555
  });
6536
6556
  setRecallAuditLog(true);
6537
6557
  } else {
@@ -16525,15 +16545,24 @@ var Container$1k = /*#__PURE__*/styled__default.div(_templateObject$2r || (_temp
16525
16545
 
16526
16546
  var _templateObject$2s, _templateObject2$1P, _templateObject3$17, _templateObject4$F;
16527
16547
  var Details = function Details() {
16528
- var _globalEscData$, _globalEscData$2;
16548
+ var _customerInfo$return_, _globalEscData$, _globalEscData$2;
16529
16549
  // const [orderDetails] = useOrderDetails();
16530
16550
  var _useCustomerInfo = useCustomerInfo(),
16531
16551
  customerInfo = _useCustomerInfo[0];
16532
16552
  var recipient = (customerInfo == null ? void 0 : customerInfo.recipient_name) || '';
16533
16553
  var postcodeShow = (customerInfo == null ? void 0 : customerInfo.postcode) || '';
16554
+ var returnActionString = customerInfo != null && (_customerInfo$return_ = customerInfo.return_action) != null && _customerInfo$return_.length ? customerInfo.return_action.join(', ') + " - " : '';
16534
16555
  var _useGlobalEscData = useGlobalEscData(),
16535
16556
  globalEscData = _useGlobalEscData[0];
16536
- return React__default.createElement(DetailsContainer, null, React__default.createElement(Typo, null, "CUSTOMER RETURN - ", recipient, " , ", postcodeShow, " ", (globalEscData == null ? void 0 : globalEscData.length) > 0 && React__default.createElement(EscInfo, null, ((_globalEscData$ = globalEscData[0]) == null || (_globalEscData$ = _globalEscData$.escalation_type) == null ? void 0 : _globalEscData$.level) + " (" + ((_globalEscData$2 = globalEscData[0]) == null || (_globalEscData$2 = _globalEscData$2.escalation_type) == null ? void 0 : _globalEscData$2.name) + ")")));
16557
+ var isLoading = !recipient && !postcodeShow;
16558
+ return React__default.createElement(DetailsContainer, null, React__default.createElement(Typo, null, isLoading ? React__default.createElement(antd.Skeleton.Input, {
16559
+ active: true,
16560
+ size: "small",
16561
+ style: {
16562
+ width: 350,
16563
+ borderRadius: 8
16564
+ }
16565
+ }) : "RETURN - " + returnActionString + recipient + " - " + postcodeShow, (globalEscData == null ? void 0 : globalEscData.length) > 0 && !isLoading && React__default.createElement(EscInfo, null, ((_globalEscData$ = globalEscData[0]) == null || (_globalEscData$ = _globalEscData$.escalation_type) == null ? void 0 : _globalEscData$.level) + " (" + ((_globalEscData$2 = globalEscData[0]) == null || (_globalEscData$2 = _globalEscData$2.escalation_type) == null ? void 0 : _globalEscData$2.name) + ")")));
16537
16566
  };
16538
16567
  var DetailsContainer = /*#__PURE__*/styled__default.div(_templateObject$2s || (_templateObject$2s = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n align-items: center;\n gap: 10px;\n > svg {\n transform: scale(0.6);\n }\n"])));
16539
16568
  var Typo = /*#__PURE__*/styled__default.div(_templateObject2$1P || (_templateObject2$1P = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: row;\n gap: 15px;\n align-items: center;\n font-size: 20px;\n font-style: normal;\n font-weight: 600;\n line-height: 32px;\n text-transform: uppercase;\n margin: 0;\n padding: 0;\n\n @media screen and (max-width: 1220px) {\n font-size: 14px;\n }\n"])));
@@ -18151,7 +18180,7 @@ function OrderView(_ref) {
18151
18180
  React.useEffect(function () {
18152
18181
  setLoading(loading);
18153
18182
  if (fetchedData && fetchedData.data) {
18154
- var _requiredData$, _requiredData$2, _requiredData$3, _requiredData$4, _requiredData$0$order, _requiredData$5, _requiredData$0$order2, _requiredData$6, _fetchedData$data$;
18183
+ var _requiredData$, _requiredData$2, _requiredData$3, _requiredData$4, _requiredData$0$order, _requiredData$5, _requiredData$0$order2, _requiredData$6, _requiredData$0$retur, _requiredData$7, _fetchedData$data$;
18155
18184
  var requiredData = fetchedData == null ? void 0 : fetchedData.data;
18156
18185
  setOrderDetails(requiredData[0]);
18157
18186
  //@ts-ignore
@@ -18163,7 +18192,8 @@ function OrderView(_ref) {
18163
18192
  setOrderProductId((_requiredData$4 = requiredData[0]) == null ? void 0 : _requiredData$4.id);
18164
18193
  setCustomerInfo({
18165
18194
  recipient_name: (_requiredData$0$order = (_requiredData$5 = requiredData[0]) == null || (_requiredData$5 = _requiredData$5.order_recipient) == null ? void 0 : _requiredData$5.recipient_name) != null ? _requiredData$0$order : null,
18166
- postcode: (_requiredData$0$order2 = (_requiredData$6 = requiredData[0]) == null || (_requiredData$6 = _requiredData$6.order_recipient) == null ? void 0 : _requiredData$6.postcode) != null ? _requiredData$0$order2 : null
18195
+ postcode: (_requiredData$0$order2 = (_requiredData$6 = requiredData[0]) == null || (_requiredData$6 = _requiredData$6.order_recipient) == null ? void 0 : _requiredData$6.postcode) != null ? _requiredData$0$order2 : null,
18196
+ return_action: (_requiredData$0$retur = (_requiredData$7 = requiredData[0]) == null ? void 0 : _requiredData$7.return_action) != null ? _requiredData$0$retur : null
18167
18197
  });
18168
18198
  setPrevOrderDetails(requiredData[0]);
18169
18199
  //dbSync Api call
@@ -18771,7 +18801,7 @@ var ReturnTable$1 = function ReturnTable() {
18771
18801
  //for dev
18772
18802
  navigate("/orders/view/return/filter?" + queryParams.toString());
18773
18803
  //for local
18774
- //navigate(`/filter?${queryParams.toString()}`);
18804
+ // navigate(`/filter?${queryParams.toString()}`);
18775
18805
  };
18776
18806
  //for RTS
18777
18807
  var handleRedirectRTS = function handleRedirectRTS(customerId, RTS) {
@@ -18948,29 +18978,79 @@ var ReturnTable$1 = function ReturnTable() {
18948
18978
  }
18949
18979
  }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$PENDING = rowKey == null ? void 0 : rowKey.PENDING) != null ? _rowKey$PENDING : 0))), React__default.createElement("td", {
18950
18980
  style: {
18981
+ color: (rowKey == null ? void 0 : rowKey['CLAIMS PAID']) > 0 ? '#0099ff' : 'inherit',
18982
+ fontWeight: (rowKey == null ? void 0 : rowKey['CLAIMS PAID']) > 0 ? 600 : 'normal',
18983
+ cursor: (rowKey == null ? void 0 : rowKey['CLAIMS PAID']) > 0 ? 'pointer' : 'default',
18951
18984
  textAlign: 'center'
18985
+ },
18986
+ onClick: (rowKey == null ? void 0 : rowKey['CLAIMS PAID']) > 0 ? function () {
18987
+ return handleRedirectRTS(rowKey == null ? void 0 : rowKey.customer_id, 'CLAIMS PAID');
18988
+ } : undefined
18989
+ }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, {
18990
+ style: {
18991
+ backgroundColor: (rowKey == null ? void 0 : rowKey['CLAIMS PAID']) > 0 ? 'rgba(99, 150, 229, 0.1)' : 'rgba(153, 153, 153, 0.1)'
18952
18992
  }
18953
- }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$CLAIMSPAID = rowKey == null ? void 0 : rowKey['CLAIMS PAID']) != null ? _rowKey$CLAIMSPAID : 0))), React__default.createElement("td", {
18993
+ }, (_rowKey$CLAIMSPAID = rowKey == null ? void 0 : rowKey['CLAIMS PAID']) != null ? _rowKey$CLAIMSPAID : 0))), React__default.createElement("td", {
18954
18994
  style: {
18995
+ color: (rowKey == null ? void 0 : rowKey.DISPOSE) > 0 ? '#0099ff' : 'inherit',
18996
+ fontWeight: (rowKey == null ? void 0 : rowKey.DISPOSE) > 0 ? 600 : 'normal',
18997
+ cursor: (rowKey == null ? void 0 : rowKey.DISPOSE) > 0 ? 'pointer' : 'default',
18955
18998
  textAlign: 'center'
18999
+ },
19000
+ onClick: (rowKey == null ? void 0 : rowKey.DISPOSE) > 0 ? function () {
19001
+ return handleRedirectRTS(rowKey == null ? void 0 : rowKey.customer_id, 'DISPOSE');
19002
+ } : undefined
19003
+ }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, {
19004
+ style: {
19005
+ backgroundColor: (rowKey == null ? void 0 : rowKey.DISPOSE) > 0 ? 'rgba(99, 150, 229, 0.1)' : 'rgba(153, 153, 153, 0.1)'
18956
19006
  }
18957
- }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$DISPOSE = rowKey == null ? void 0 : rowKey.DISPOSE) != null ? _rowKey$DISPOSE : 0))), React__default.createElement("td", {
19007
+ }, (_rowKey$DISPOSE = rowKey == null ? void 0 : rowKey.DISPOSE) != null ? _rowKey$DISPOSE : 0))), React__default.createElement("td", {
18958
19008
  style: {
19009
+ color: (rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) > 0 ? '#0099ff' : 'inherit',
19010
+ fontWeight: (rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) > 0 ? 600 : 'normal',
19011
+ cursor: (rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) > 0 ? 'pointer' : 'default',
18959
19012
  textAlign: 'center'
19013
+ },
19014
+ onClick: (rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) > 0 ? function () {
19015
+ return handleRedirectRTS(rowKey == null ? void 0 : rowKey.customer_id, 'RE-ALLOCATE');
19016
+ } : undefined
19017
+ }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, {
19018
+ style: {
19019
+ backgroundColor: (rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) > 0 ? 'rgba(99, 150, 229, 0.1)' : 'rgba(153, 153, 153, 0.1)'
18960
19020
  }
18961
- }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$REALLOCATE = rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) != null ? _rowKey$REALLOCATE : 0))), React__default.createElement("td", {
19021
+ }, (_rowKey$REALLOCATE = rowKey == null ? void 0 : rowKey['RE-ALLOCATE']) != null ? _rowKey$REALLOCATE : 0))), React__default.createElement("td", {
18962
19022
  style: {
18963
19023
  textAlign: 'center'
18964
19024
  }
18965
19025
  }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$REDEL = rowKey == null ? void 0 : rowKey['RE-DEL']) != null ? _rowKey$REDEL : 0))), React__default.createElement("td", {
18966
19026
  style: {
19027
+ color: (rowKey == null ? void 0 : rowKey.RECYCLE) > 0 ? '#0099ff' : 'inherit',
19028
+ fontWeight: (rowKey == null ? void 0 : rowKey.RECYCLE) > 0 ? 600 : 'normal',
19029
+ cursor: (rowKey == null ? void 0 : rowKey.RECYCLE) > 0 ? 'pointer' : 'default',
18967
19030
  textAlign: 'center'
19031
+ },
19032
+ onClick: (rowKey == null ? void 0 : rowKey.RECYCLE) > 0 ? function () {
19033
+ return handleRedirectRTS(rowKey == null ? void 0 : rowKey.customer_id, 'RECYCLE');
19034
+ } : undefined
19035
+ }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, {
19036
+ style: {
19037
+ backgroundColor: (rowKey == null ? void 0 : rowKey.RECYCLE) > 0 ? 'rgba(99, 150, 229, 0.1)' : 'rgba(153, 153, 153, 0.1)'
18968
19038
  }
18969
- }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$RECYCLE = rowKey == null ? void 0 : rowKey.RECYCLE) != null ? _rowKey$RECYCLE : 0))), React__default.createElement("td", {
19039
+ }, (_rowKey$RECYCLE = rowKey == null ? void 0 : rowKey.RECYCLE) != null ? _rowKey$RECYCLE : 0))), React__default.createElement("td", {
18970
19040
  style: {
19041
+ color: (rowKey == null ? void 0 : rowKey.UNKNOWN) > 0 ? '#0099ff' : 'inherit',
19042
+ fontWeight: (rowKey == null ? void 0 : rowKey.UNKNOWN) > 0 ? 600 : 'normal',
19043
+ cursor: (rowKey == null ? void 0 : rowKey.UNKNOWN) > 0 ? 'pointer' : 'default',
18971
19044
  textAlign: 'center'
19045
+ },
19046
+ onClick: (rowKey == null ? void 0 : rowKey.UNKNOWN) > 0 ? function () {
19047
+ return handleRedirectRTS(rowKey == null ? void 0 : rowKey.customer_id, 'UNKNOWN');
19048
+ } : undefined
19049
+ }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, {
19050
+ style: {
19051
+ backgroundColor: (rowKey == null ? void 0 : rowKey.UNKNOWN) > 0 ? 'rgba(99, 150, 229, 0.1)' : 'rgba(153, 153, 153, 0.1)'
18972
19052
  }
18973
- }, React__default.createElement(ColumStyle, null, React__default.createElement(GreyBox, null, (_rowKey$UNKNOWN = rowKey == null ? void 0 : rowKey.UNKNOWN) != null ? _rowKey$UNKNOWN : 0))));
19053
+ }, (_rowKey$UNKNOWN = rowKey == null ? void 0 : rowKey.UNKNOWN) != null ? _rowKey$UNKNOWN : 0))));
18974
19054
  };
18975
19055
  if (!(key != null && key.children) || (key == null || (_key$children = key.children) == null ? void 0 : _key$children.length) === 0) {
18976
19056
  return React__default.createElement(React__default.Fragment, {