@bjsdistribution/dms-client-return 0.0.55 → 0.0.56
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/components/order-view/details-filters/left-side-filters/dropdowns/MenuDropDown.d.ts +2 -2
- package/dist/components/order-view/details-filters/left-side-filters/dropdowns/OptionsDropDown.d.ts +2 -2
- package/dist/components/order-view/fakedata.d.ts +1 -1
- package/dist/components/order-view/store.d.ts +2 -2
- package/dist/dms-client-return.cjs.development.js +415 -384
- 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 +415 -384
- 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 +1 -1
- package/src/components/order-daily-overview/return-after-table/table/OrderTable.tsx +1 -1
- package/src/components/order-daily-overview/table/ReturnTable.tsx +2 -2
- package/src/components/order-view/details-filters/left-side-filters/dropdowns/DropDowns.tsx +1 -1
- package/src/components/order-view/details-filters/left-side-filters/dropdowns/MenuDropDown.tsx +57 -45
- package/src/components/order-view/details-filters/left-side-filters/dropdowns/OptionsDropDown.tsx +74 -61
- package/src/components/order-view/fakedata.ts +6 -69
- package/src/components/order-view/general-information/dropdowns/Print.tsx +57 -35
- package/src/components/order-view/general-information/dropdowns/index.tsx +1 -2
- package/src/components/order-view/hooks/useUpdateOrder.ts +0 -3
- package/src/components/order-view/index.tsx +81 -56
- package/src/components/order-view/modalsPopup/DeleteProduct.tsx +2 -2
- package/src/components/order-view/modalsPopup/ModalManager.tsx +1 -1
- package/src/components/order-view/notes/order-dropdown/NewReturnDropdown.tsx +3 -1
- package/src/components/order-view/order-actions/actions/change-customer-account/ChangeCustomerAccModal.tsx +3 -3
- package/src/components/order-view/order-actions/actions/confirm-order/tables/NotesTable.tsx +3 -1
- package/src/components/order-view/order-actions/actions/unhold-order/UnholdOrder.tsx +72 -7
- package/src/components/order-view/order-details/expanded-content/footer/index.tsx +5 -3
- package/src/components/order-view/return-client-products/product-table/ReturnProductTable.tsx +9 -3
- package/src/components/order-view/store.ts +14 -13
- package/src/index.tsx +4 -20
- package/dist/components/order-view/general-information/dropdowns/Options.d.ts +0 -3
- package/src/components/order-view/general-information/dropdowns/Options.tsx +0 -68
package/package.json
CHANGED
|
@@ -168,7 +168,7 @@ function SelectionFilter() {
|
|
|
168
168
|
if (!currentSearch.includes('filter')) {
|
|
169
169
|
console.log('inside include');
|
|
170
170
|
// for dev
|
|
171
|
-
navigate(`/
|
|
171
|
+
navigate(`/filter?${queryParams.toString()}`);
|
|
172
172
|
|
|
173
173
|
// for local
|
|
174
174
|
//navigate(`/filter?${queryParams.toString()}`);
|
|
@@ -138,7 +138,7 @@ const ReturnTable: React.FC = () => {
|
|
|
138
138
|
customerId: customerId?.toString(),
|
|
139
139
|
});
|
|
140
140
|
//for dev
|
|
141
|
-
navigate(`/
|
|
141
|
+
navigate(`/filter?${queryParams.toString()}`);
|
|
142
142
|
|
|
143
143
|
//for local
|
|
144
144
|
//navigate(`/filter?${queryParams.toString()}`);
|
|
@@ -167,7 +167,7 @@ const ReturnTable: React.FC = () => {
|
|
|
167
167
|
type: RTS,
|
|
168
168
|
});
|
|
169
169
|
//for dev
|
|
170
|
-
navigate(`/
|
|
170
|
+
navigate(`/filter?${queryParams.toString()}`);
|
|
171
171
|
|
|
172
172
|
//for local
|
|
173
173
|
//navigate(`/filter?${queryParams.toString()}`);
|
package/src/components/order-view/details-filters/left-side-filters/dropdowns/MenuDropDown.tsx
CHANGED
|
@@ -1,54 +1,66 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
{ label: 'Split Order ', value: 'split-order' },
|
|
11
|
-
];
|
|
12
|
-
|
|
13
|
-
const MenuDropDown: React.FC = () => {
|
|
14
|
-
const [isOpen, setIsOpen] = useState(false);
|
|
15
|
-
const dropdownRef = useRef<HTMLDivElement>(null);
|
|
1
|
+
import {
|
|
2
|
+
SelectDropdown,
|
|
3
|
+
dropdownStyles,
|
|
4
|
+
filterDropdownStyles,
|
|
5
|
+
} from '@bjsdistribution/dms-component-library';
|
|
6
|
+
import React from 'react';
|
|
7
|
+
import { bjsMenu } from '../../../fakedata';
|
|
8
|
+
import { useCurrentAction, useStatusDetails } from '../../../store';
|
|
9
|
+
function BjsMenu() {
|
|
16
10
|
const [, setCurrentAction] = useCurrentAction();
|
|
17
|
-
const
|
|
18
|
-
|
|
11
|
+
const handleSelectChange = (selectedOption: any) => {
|
|
12
|
+
setCurrentAction(selectedOption.value);
|
|
19
13
|
};
|
|
20
14
|
|
|
21
|
-
const
|
|
22
|
-
setCurrentAction(selectedOption);
|
|
23
|
-
setIsOpen(false);
|
|
24
|
-
};
|
|
15
|
+
const [orderStatus] = useStatusDetails();
|
|
25
16
|
|
|
26
|
-
|
|
27
|
-
const handleClickOutside = (event: MouseEvent) => {
|
|
28
|
-
if (
|
|
29
|
-
dropdownRef.current &&
|
|
30
|
-
!dropdownRef.current.contains(event.target as Node)
|
|
31
|
-
) {
|
|
32
|
-
setIsOpen(false);
|
|
33
|
-
}
|
|
34
|
-
};
|
|
17
|
+
const isReleased = orderStatus[0]?.released;
|
|
35
18
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
}
|
|
40
|
-
|
|
19
|
+
const filteredOptions = bjsMenu.filter(option => {
|
|
20
|
+
if (isReleased) {
|
|
21
|
+
return option.value !== 'release-order';
|
|
22
|
+
} else {
|
|
23
|
+
return option;
|
|
24
|
+
}
|
|
25
|
+
});
|
|
41
26
|
|
|
42
27
|
return (
|
|
43
|
-
<
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
28
|
+
<SelectDropdown
|
|
29
|
+
placeholder="BJS MENU"
|
|
30
|
+
inputId="bjsmenu"
|
|
31
|
+
options={filteredOptions}
|
|
32
|
+
onChange={handleSelectChange}
|
|
33
|
+
isSearchable={false}
|
|
34
|
+
styles={{
|
|
35
|
+
...dropdownStyles,
|
|
36
|
+
...filterDropdownStyles,
|
|
37
|
+
container: styles => ({
|
|
38
|
+
...styles,
|
|
39
|
+
cursor: 'pointer',
|
|
40
|
+
}),
|
|
41
|
+
menu: styles => ({
|
|
42
|
+
...styles,
|
|
43
|
+
top: '113%',
|
|
44
|
+
borderRadius: '5px',
|
|
45
|
+
width: 'max-content',
|
|
46
|
+
cursor: 'pointer',
|
|
47
|
+
}),
|
|
48
|
+
control: styles => ({
|
|
49
|
+
...styles,
|
|
50
|
+
width: '105px',
|
|
51
|
+
boxShadow: 'none',
|
|
52
|
+
borderColor: 'transparent',
|
|
53
|
+
cursor: 'pointer',
|
|
54
|
+
backgroundColor: 'transparent',
|
|
55
|
+
'&:hover': {
|
|
56
|
+
boxShadow: 'none',
|
|
57
|
+
borderColor: 'transparent',
|
|
58
|
+
},
|
|
59
|
+
}),
|
|
60
|
+
}}
|
|
61
|
+
value="BJS MENU"
|
|
62
|
+
/>
|
|
51
63
|
);
|
|
52
|
-
}
|
|
64
|
+
}
|
|
53
65
|
|
|
54
|
-
export default
|
|
66
|
+
export default BjsMenu;
|
package/src/components/order-view/details-filters/left-side-filters/dropdowns/OptionsDropDown.tsx
CHANGED
|
@@ -1,72 +1,85 @@
|
|
|
1
|
-
import
|
|
1
|
+
import {
|
|
2
|
+
SelectDropdown,
|
|
3
|
+
dropdownStyles,
|
|
4
|
+
filterDropdownStyles,
|
|
5
|
+
} from '@bjsdistribution/dms-component-library';
|
|
6
|
+
import React from 'react';
|
|
7
|
+
import styled from 'styled-components';
|
|
8
|
+
import { optionsMenu } from '../../../fakedata';
|
|
9
|
+
import { useCurrentAction, useOrderDetails } from '../../../store';
|
|
2
10
|
|
|
3
|
-
|
|
4
|
-
import DropDownMenu from './DropDownMenu';
|
|
5
|
-
import DropDownItem from './DropDownItem';
|
|
6
|
-
import DropDownLarge from '../../../../../assets/icons/DropDownLarge';
|
|
7
|
-
import { useCurrentAction, useIsOnHoldOrder } from '../../../store';
|
|
8
|
-
|
|
9
|
-
const Options = [
|
|
10
|
-
{ label: 'Create Reminder', value: 'create-task' },
|
|
11
|
-
{ label: 'Confirm', value: 'confirm-order' },
|
|
12
|
-
// { label: 'Force Debrief', value: 'force-debrief' },
|
|
13
|
-
// { label: 'Clear Booking Status', value: 'booking-status' },
|
|
14
|
-
// { label: 'Remove From Route', value: 'remove-route' },
|
|
15
|
-
{ label: 'Hold', value: 'hold-order' },
|
|
16
|
-
// { label: 'Flag', value: 'view-flag' },
|
|
17
|
-
{ label: 'Cancel', value: 'cancel-order' },
|
|
18
|
-
{ label: 'Charge Log', value: 'charge-log' },
|
|
19
|
-
];
|
|
20
|
-
|
|
21
|
-
const OptionsDropDown: React.FC = () => {
|
|
22
|
-
const [isOpen, setIsOpen] = useState(false);
|
|
23
|
-
const dropdownRef = useRef<HTMLDivElement>(null);
|
|
11
|
+
function Options() {
|
|
24
12
|
const [, setCurrentAction] = useCurrentAction();
|
|
25
|
-
const [hold] = useIsOnHoldOrder();
|
|
26
13
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
setIsOpen(prev => !prev);
|
|
14
|
+
const handleSelectChange = (selectedOption: any) => {
|
|
15
|
+
setCurrentAction(selectedOption.value);
|
|
30
16
|
};
|
|
31
17
|
|
|
32
|
-
const
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
});
|
|
39
|
-
const handleSelect = (selectedOption: any) => {
|
|
40
|
-
setCurrentAction(selectedOption);
|
|
41
|
-
setIsOpen(false);
|
|
42
|
-
};
|
|
18
|
+
const [orderDetails] = useOrderDetails();
|
|
19
|
+
const isOrderOnHold = orderDetails?.status === 'OO';
|
|
20
|
+
const isOrderCancelled = orderDetails?.status === 'CO';
|
|
21
|
+
|
|
22
|
+
const filteredOptions = optionsMenu.filter(option => {
|
|
23
|
+
let shouldExclude = false;
|
|
43
24
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
25
|
+
if (isOrderOnHold && option.value === 'hold-order') {
|
|
26
|
+
shouldExclude = true;
|
|
27
|
+
}
|
|
28
|
+
if (isOrderCancelled && option.value === 'cancel-order') {
|
|
29
|
+
shouldExclude = true;
|
|
30
|
+
}
|
|
31
|
+
if (!isOrderCancelled || isOrderOnHold) {
|
|
32
|
+
if (option.value === 'uncancel-order') {
|
|
33
|
+
shouldExclude = true;
|
|
51
34
|
}
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
35
|
+
}
|
|
36
|
+
if (!isOrderOnHold && option.value === 'unhold-order') {
|
|
37
|
+
shouldExclude = true;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
return !shouldExclude;
|
|
41
|
+
});
|
|
58
42
|
|
|
59
43
|
return (
|
|
60
|
-
<
|
|
61
|
-
<
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
44
|
+
<Option>
|
|
45
|
+
<SelectDropdown
|
|
46
|
+
placeholder="OPTIONS"
|
|
47
|
+
inputId="bjsmenu"
|
|
48
|
+
options={filteredOptions}
|
|
49
|
+
onChange={handleSelectChange}
|
|
50
|
+
isSearchable={false}
|
|
51
|
+
styles={{
|
|
52
|
+
...dropdownStyles,
|
|
53
|
+
...filterDropdownStyles,
|
|
54
|
+
container: styles => ({
|
|
55
|
+
...styles,
|
|
56
|
+
cursor: 'pointer',
|
|
57
|
+
}),
|
|
58
|
+
menu: styles => ({
|
|
59
|
+
...styles,
|
|
60
|
+
top: '113%',
|
|
61
|
+
borderRadius: '5px',
|
|
62
|
+
width: 'max-content',
|
|
63
|
+
cursor: 'pointer',
|
|
64
|
+
}),
|
|
65
|
+
control: styles => ({
|
|
66
|
+
...styles,
|
|
67
|
+
width: '105px',
|
|
68
|
+
boxShadow: 'none',
|
|
69
|
+
borderColor: 'transparent',
|
|
70
|
+
cursor: 'pointer',
|
|
71
|
+
backgroundColor: 'transparent',
|
|
72
|
+
'&:hover': {
|
|
73
|
+
boxShadow: 'none',
|
|
74
|
+
borderColor: 'transparent',
|
|
75
|
+
},
|
|
76
|
+
}),
|
|
77
|
+
}}
|
|
78
|
+
value="OPTIONS"
|
|
65
79
|
/>
|
|
66
|
-
|
|
67
|
-
<DropDownMenu options={filteredOptions} onSelect={handleSelect} />
|
|
68
|
-
)}
|
|
69
|
-
</DropDownContainer>
|
|
80
|
+
</Option>
|
|
70
81
|
);
|
|
71
|
-
}
|
|
72
|
-
|
|
82
|
+
}
|
|
83
|
+
const Option = styled.div``;
|
|
84
|
+
|
|
85
|
+
export default Options;
|
|
@@ -10,77 +10,14 @@ export const bjsMenu = [
|
|
|
10
10
|
label: 'Split Order',
|
|
11
11
|
value: 'split-order',
|
|
12
12
|
},
|
|
13
|
-
{
|
|
14
|
-
label: 'Escalations',
|
|
15
|
-
value: 'escalations',
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
label: 'Release Order',
|
|
19
|
-
value: 'release-order',
|
|
20
|
-
},
|
|
21
13
|
];
|
|
22
14
|
|
|
23
|
-
export const
|
|
24
|
-
{
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
label: 'Confirm',
|
|
30
|
-
value: 'confirm-order',
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
label: 'Force Debrief',
|
|
34
|
-
value: 'force-debrief',
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
label: 'Charge Log',
|
|
38
|
-
value: 'charge-log',
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
label: 'Log Feedback',
|
|
42
|
-
value: 'log-feedback',
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
label: 'On Hold',
|
|
46
|
-
value: 'hold-order',
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
label: 'Un Hold',
|
|
50
|
-
value: 'unhold-order',
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
label: 'Change Customer Account',
|
|
54
|
-
value: 'change-customer-account',
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
label: 'Proximity Report',
|
|
58
|
-
value: 'promixity-report',
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
label: 'Raise Collection',
|
|
62
|
-
value: 'raise-collection',
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
label: 'Remove from Route',
|
|
66
|
-
value: 'remove-from-route',
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
label: 'Add New Flag',
|
|
70
|
-
value: 'add-new-flag',
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
label: 'Un-Release Order',
|
|
74
|
-
value: 'unrelease-order',
|
|
75
|
-
},
|
|
76
|
-
{
|
|
77
|
-
label: 'Cancel',
|
|
78
|
-
value: 'cancel-order',
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
label: 'Clear Booking Status',
|
|
82
|
-
value: 'clear-booking-status',
|
|
83
|
-
},
|
|
15
|
+
export const optionsMenu = [
|
|
16
|
+
{ label: 'Create Reminder', value: 'create-task' },
|
|
17
|
+
{ label: 'Confirm', value: 'confirm-order' },
|
|
18
|
+
{ label: 'Hold', value: 'hold-order' },
|
|
19
|
+
{ label: 'Cancel', value: 'cancel-order' },
|
|
20
|
+
// { label: 'Charge Log', value: 'charge-log' },
|
|
84
21
|
];
|
|
85
22
|
|
|
86
23
|
export const PrintMenu = [
|
|
@@ -1,21 +1,16 @@
|
|
|
1
|
-
import
|
|
1
|
+
import {
|
|
2
|
+
SelectDropdown,
|
|
3
|
+
dropdownStyles,
|
|
4
|
+
filterDropdownStyles,
|
|
5
|
+
} from '@bjsdistribution/dms-component-library';
|
|
6
|
+
import React from 'react';
|
|
7
|
+
import styled from 'styled-components';
|
|
2
8
|
import { PrintMenu } from '../../fakedata';
|
|
3
9
|
import { useOrderDetails } from '../../store';
|
|
4
|
-
import { DropDownContainer } from '../../details-filters/left-side-filters/dropdowns/DropdownStyles';
|
|
5
|
-
import DropDownItem from '../../details-filters/left-side-filters/dropdowns/DropDownItem';
|
|
6
|
-
import DropDownLarge from '../../../../assets/icons/DropDownLarge';
|
|
7
|
-
import DropDownMenu from '../../details-filters/left-side-filters/dropdowns/DropDownMenu';
|
|
8
10
|
|
|
9
11
|
function Print() {
|
|
10
12
|
const [orderDetails] = useOrderDetails();
|
|
11
13
|
const gsitId = orderDetails?.gsit_order_id;
|
|
12
|
-
const dropdownRef = useRef<HTMLDivElement>(null);
|
|
13
|
-
// console.log(gsitId, 'gsitId');
|
|
14
|
-
const [isOpen, setIsOpen] = useState(false);
|
|
15
|
-
|
|
16
|
-
const handleClick = () => {
|
|
17
|
-
setIsOpen(prev => !prev);
|
|
18
|
-
};
|
|
19
14
|
|
|
20
15
|
const getEnvironment = (): 'development' | 'us' => {
|
|
21
16
|
console.log('project env', process.env.REACT_APP_API_PATH);
|
|
@@ -39,50 +34,77 @@ function Print() {
|
|
|
39
34
|
if (val === 'Proof Of Delivery') {
|
|
40
35
|
return '';
|
|
41
36
|
}
|
|
42
|
-
if (val === '
|
|
37
|
+
if (val === 'proofofdelivery(doc)') {
|
|
43
38
|
return '';
|
|
44
39
|
}
|
|
45
|
-
if (val === '
|
|
40
|
+
if (val === 'orderdeliverylabels') {
|
|
46
41
|
return `${baseUrl}/generate_labels?pdf=true&product_type=Deliver&order_id=${gsitId}`;
|
|
47
42
|
}
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
else {
|
|
43
|
+
if (val === 'ordercollectionlabels') {
|
|
44
|
+
return `${baseUrl}/generate_labels?pdf=true&product_type=Collect&order_id=${gsitId}`;
|
|
45
|
+
}
|
|
46
|
+
if (val === 'orderreturnlabels') {
|
|
47
|
+
return `${baseUrl}/generate_labels?pdf=true&product_type=Return&order_id=${gsitId}`;
|
|
48
|
+
}
|
|
49
|
+
if (val === 'returnscovernote') {
|
|
50
|
+
return '';
|
|
51
|
+
} else {
|
|
58
52
|
return '';
|
|
59
53
|
}
|
|
60
54
|
};
|
|
61
55
|
|
|
62
56
|
const handleSelectChange = (selectedOption: any) => {
|
|
57
|
+
console.log(selectedOption);
|
|
63
58
|
const selectedValue = selectedOption?.value;
|
|
64
|
-
|
|
65
|
-
console.log(selectedValue, 'erf');
|
|
66
59
|
if (selectedValue) {
|
|
67
60
|
console.log(selectedValue);
|
|
68
61
|
const url = getUrl(selectedValue);
|
|
69
62
|
console.log('Generated URL:', url);
|
|
63
|
+
// You can navigate to the URL or handle it further here
|
|
70
64
|
window.open(url, '_blank');
|
|
71
65
|
}
|
|
72
66
|
};
|
|
73
67
|
|
|
74
68
|
return (
|
|
75
|
-
<
|
|
76
|
-
<
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
69
|
+
<Container>
|
|
70
|
+
<SelectDropdown
|
|
71
|
+
placeholder="PRINT"
|
|
72
|
+
options={PrintMenu}
|
|
73
|
+
value="PRINT"
|
|
74
|
+
isSearchable={false}
|
|
75
|
+
onChange={handleSelectChange}
|
|
76
|
+
styles={{
|
|
77
|
+
...dropdownStyles,
|
|
78
|
+
...filterDropdownStyles,
|
|
79
|
+
container: styles => ({
|
|
80
|
+
...styles,
|
|
81
|
+
cursor: 'pointer',
|
|
82
|
+
}),
|
|
83
|
+
menu: styles => ({
|
|
84
|
+
...styles,
|
|
85
|
+
top: '113%',
|
|
86
|
+
borderRadius: '5px',
|
|
87
|
+
width: 'max-content',
|
|
88
|
+
cursor: 'pointer',
|
|
89
|
+
}),
|
|
90
|
+
control: styles => ({
|
|
91
|
+
...styles,
|
|
92
|
+
width: '90px',
|
|
93
|
+
boxShadow: 'none',
|
|
94
|
+
borderColor: 'transparent',
|
|
95
|
+
cursor: 'pointer',
|
|
96
|
+
backgroundColor: 'transparent',
|
|
97
|
+
'&:hover': {
|
|
98
|
+
boxShadow: 'none',
|
|
99
|
+
borderColor: 'transparent',
|
|
100
|
+
},
|
|
101
|
+
}),
|
|
102
|
+
}}
|
|
80
103
|
/>
|
|
81
|
-
|
|
82
|
-
<DropDownMenu options={PrintMenu} onSelect={handleSelectChange} />
|
|
83
|
-
)}
|
|
84
|
-
</DropDownContainer>
|
|
104
|
+
</Container>
|
|
85
105
|
);
|
|
86
106
|
}
|
|
87
107
|
|
|
108
|
+
const Container = styled.div``;
|
|
109
|
+
|
|
88
110
|
export default Print;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import styled from 'styled-components';
|
|
3
3
|
import BjsMenu from './BjsMenu';
|
|
4
|
-
import Options from './Options';
|
|
5
4
|
import Print from './Print';
|
|
5
|
+
import Options from '../../details-filters/left-side-filters/dropdowns/OptionsDropDown';
|
|
6
6
|
function DropDownOptions() {
|
|
7
7
|
return (
|
|
8
8
|
<Container>
|
|
@@ -16,7 +16,6 @@ function DropDownOptions() {
|
|
|
16
16
|
const Container = styled.div`
|
|
17
17
|
display: flex;
|
|
18
18
|
padding: 0 20px;
|
|
19
|
-
/* height: 40px; */
|
|
20
19
|
gap: 10px;
|
|
21
20
|
align-items: center;
|
|
22
21
|
border-top: 1px solid #ccc;
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import { getBaseEndpoint } from '@bjsdistribution/dms-component-library';
|
|
2
2
|
import { getCookie } from '../utils';
|
|
3
3
|
import { notification } from 'antd';
|
|
4
|
-
import { useUpdateApiCall } from '../store';
|
|
5
4
|
|
|
6
5
|
function useUpdateOrder() {
|
|
7
6
|
let controller: AbortController;
|
|
8
7
|
const ssoToken = getCookie('id_token');
|
|
9
|
-
const [, setCallApi] = useUpdateApiCall(); //single detail
|
|
10
8
|
|
|
11
9
|
const update = async (data: any) => {
|
|
12
10
|
const endpoint = `${getBaseEndpoint()}/orders/update/`;
|
|
@@ -40,7 +38,6 @@ function useUpdateOrder() {
|
|
|
40
38
|
message: 'Success',
|
|
41
39
|
description: 'Order has been updated.',
|
|
42
40
|
});
|
|
43
|
-
setCallApi(true);
|
|
44
41
|
return json;
|
|
45
42
|
} catch (err) {
|
|
46
43
|
// setLoading(false);
|