@bjsdistribution/dms-client-return 0.0.45 → 0.0.47
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.
- package/dist/dms-client-return.cjs.development.js +217 -207
- package/dist/dms-client-return.cjs.development.js.map +1 -1
- package/dist/dms-client-return.cjs.production.min.js +1 -1
- package/dist/dms-client-return.cjs.production.min.js.map +1 -1
- package/dist/dms-client-return.esm.js +217 -207
- package/dist/dms-client-return.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/order-daily-overview/header-filters/SelectionFilter.tsx +10 -4
- package/src/components/order-view/general-information/Status.tsx +1 -0
- package/src/components/order-view/order-details/expanded-content/orders-section/RecipientReference.tsx +16 -2
- package/src/index.tsx +3 -3
package/package.json
CHANGED
|
@@ -162,11 +162,17 @@ function SelectionFilter() {
|
|
|
162
162
|
const queryParams = new URLSearchParams({
|
|
163
163
|
customerId: selectedClient?.toString(),
|
|
164
164
|
});
|
|
165
|
-
|
|
166
|
-
|
|
165
|
+
const currentSearch = window.location.search;
|
|
166
|
+
console.log(currentSearch, 'currentSearch');
|
|
167
167
|
|
|
168
|
-
|
|
169
|
-
|
|
168
|
+
if (!currentSearch.includes('filter')) {
|
|
169
|
+
console.log('inside include');
|
|
170
|
+
// for dev
|
|
171
|
+
navigate(`/order/return/filter?${queryParams.toString()}`);
|
|
172
|
+
|
|
173
|
+
// for local
|
|
174
|
+
//navigate(`/filter?${queryParams.toString()}`);
|
|
175
|
+
}
|
|
170
176
|
}
|
|
171
177
|
|
|
172
178
|
const selectedClientValue = clientOptions?.find(
|
|
@@ -2,10 +2,15 @@ import { Input, Label } from '@bjsdistribution/dms-component-library';
|
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import { useOrderDetails } from '../../../store';
|
|
5
|
+
import CopyText from '../../../../../common/copy/CopyText';
|
|
5
6
|
|
|
6
7
|
function RecipientReference() {
|
|
7
8
|
const [orderDetails, setOrderDetails] = useOrderDetails();
|
|
8
|
-
|
|
9
|
+
const orderRecipient = orderDetails?.recipient_reference;
|
|
10
|
+
const showCopyIcon =
|
|
11
|
+
orderRecipient !== undefined &&
|
|
12
|
+
orderRecipient !== null &&
|
|
13
|
+
orderRecipient?.length > 0;
|
|
9
14
|
const onChange = (e: React.ChangeEvent<HTMLInputElement>) => {
|
|
10
15
|
setOrderDetails(prev => {
|
|
11
16
|
return {
|
|
@@ -16,7 +21,10 @@ function RecipientReference() {
|
|
|
16
21
|
};
|
|
17
22
|
return (
|
|
18
23
|
<Container>
|
|
19
|
-
<
|
|
24
|
+
<Wrapper>
|
|
25
|
+
<Label label="Recipient Reference" htmlFor="recipient-reference" />
|
|
26
|
+
{showCopyIcon && <CopyText text={orderRecipient!} />}
|
|
27
|
+
</Wrapper>
|
|
20
28
|
<Input
|
|
21
29
|
name="recipient-reference"
|
|
22
30
|
type="text"
|
|
@@ -36,4 +44,10 @@ const Container = styled.div`
|
|
|
36
44
|
flex: 1;
|
|
37
45
|
`;
|
|
38
46
|
|
|
47
|
+
const Wrapper = styled.div`
|
|
48
|
+
display: flex;
|
|
49
|
+
align-items: center;
|
|
50
|
+
gap: 5px;
|
|
51
|
+
`;
|
|
52
|
+
|
|
39
53
|
export default RecipientReference;
|
package/src/index.tsx
CHANGED
|
@@ -120,13 +120,13 @@ function ReturnClient() {
|
|
|
120
120
|
<Suspense fallback={<LoadingMessage />}>
|
|
121
121
|
<Routes>
|
|
122
122
|
{/* for local */}
|
|
123
|
-
{/* <Route path="
|
|
123
|
+
{/* <Route path="order/return" element={<ReturnMainTable />} /> */}
|
|
124
124
|
|
|
125
125
|
{/* for dev */}
|
|
126
126
|
<Route path="" element={<ReturnMainTable />} />
|
|
127
127
|
|
|
128
|
-
<Route path="
|
|
129
|
-
<Route path="
|
|
128
|
+
<Route path="view" element={<ReturnAfterTable />} />
|
|
129
|
+
<Route path="view/:id" element={<OrderView />} />
|
|
130
130
|
<Route path="filter" element={<ReturnTable />} />
|
|
131
131
|
|
|
132
132
|
{/* <Route
|