@bjsdistribution/dms-client-return 0.1.13-prod → 0.1.14-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.
- package/dist/components/order-view/DynamicTable.d.ts +2 -1
- package/dist/components/order-view/general-information/Status.d.ts +1 -1
- package/dist/components/order-view/general-information/index.d.ts +1 -1
- package/dist/components/order-view/index.d.ts +1 -1
- package/dist/components/order-view/order-actions/types.d.ts +1 -1
- package/dist/components/order-view/order-details/expanded-content/index.d.ts +1 -1
- package/dist/components/order-view/order-details/index.d.ts +1 -1
- package/dist/components/order-view/order-resources/expanded-content/index.d.ts +1 -1
- package/dist/components/order-view/products-info/expanded-content/index.d.ts +2 -0
- package/dist/components/order-view/products-info/index.d.ts +1 -1
- package/dist/components/order-view/return-client-products/ProductTable.d.ts +2 -0
- package/dist/components/order-view/return-client-products/product-table/ReturnProductTable.d.ts +2 -0
- package/dist/components/order-view/store.d.ts +1 -1
- package/dist/components/order-view/system-event-logs/expanded-content/index.d.ts +1 -1
- package/dist/dms-client-return.cjs.development.js +539 -411
- 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 +540 -412
- package/dist/dms-client-return.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/order-daily-overview/index.tsx +2 -0
- package/src/components/order-daily-overview/return-after-table/ReturnAfterTable.tsx +1 -0
- package/src/components/order-daily-overview/return-order-table/return-orders-filters/ReturnOrderTable.tsx +1 -0
- package/src/components/order-daily-overview/table/ReturnTable.tsx +2 -4
- package/src/components/order-view/DynamicTable.tsx +21 -8
- package/src/components/order-view/details-filters/left-side-filters/dropdowns/DropDowns.tsx +1 -1
- package/src/components/order-view/flags-action-modal/Dropdowns.tsx +2 -0
- package/src/components/order-view/general-information/Status.tsx +92 -18
- package/src/components/order-view/general-information/index.tsx +2 -2
- package/src/components/order-view/index.tsx +12 -6
- package/src/components/order-view/modalsPopup/ModalManager.tsx +1 -1
- package/src/components/order-view/notes/AddNote.tsx +1 -0
- package/src/components/order-view/notification/index.tsx +33 -28
- package/src/components/order-view/order-actions/actions/confirm-order/tables/NotesTable.tsx +1 -0
- package/src/components/order-view/order-actions/actions/create-task-reminder/CreateTaskModal.tsx +5 -3
- package/src/components/order-view/order-actions/actions/create-task-reminder/TaskModal.tsx +2 -2
- package/src/components/order-view/order-actions/index.tsx +3 -2
- package/src/components/order-view/order-actions/store.ts +1 -1
- package/src/components/order-view/order-actions/types.ts +1 -1
- package/src/components/order-view/order-details/expanded-content/index.tsx +37 -16
- package/src/components/order-view/order-details/index.tsx +5 -2
- package/src/components/order-view/order-resources/expanded-content/index.tsx +2 -2
- package/src/components/order-view/products-info/expanded-content/index.tsx +7 -1
- package/src/components/order-view/products-info/index.tsx +8 -4
- package/src/components/order-view/return-client-products/ProductTable.tsx +7 -1
- package/src/components/order-view/return-client-products/product-table/ReturnProductTable.tsx +19 -8
- package/src/components/order-view/store.ts +1 -1
- package/src/components/order-view/system-event-logs/expanded-content/index.tsx +6 -2
- package/src/index.tsx +6 -3
package/package.json
CHANGED
|
@@ -51,6 +51,7 @@ function ReturnMainTable() {
|
|
|
51
51
|
method: 'GET',
|
|
52
52
|
//@ts-ignore
|
|
53
53
|
pagination: { is_pagination: false },
|
|
54
|
+
showLoader: false,
|
|
54
55
|
});
|
|
55
56
|
|
|
56
57
|
useEffect(() => {
|
|
@@ -71,6 +72,7 @@ function ReturnMainTable() {
|
|
|
71
72
|
//@ts-ignore
|
|
72
73
|
pagination: pagination,
|
|
73
74
|
filters: filters,
|
|
75
|
+
showLoader: false,
|
|
74
76
|
});
|
|
75
77
|
|
|
76
78
|
useEffect(() => {
|
|
@@ -108,7 +108,6 @@ const ReturnTable: React.FC = () => {
|
|
|
108
108
|
customerId: customerId?.toString(),
|
|
109
109
|
});
|
|
110
110
|
//for dev
|
|
111
|
-
//navigate(`filter?${queryParams.toString()}`);
|
|
112
111
|
navigate(`/orders/view/return/filter?${queryParams.toString()}`);
|
|
113
112
|
|
|
114
113
|
//for local
|
|
@@ -138,7 +137,6 @@ const ReturnTable: React.FC = () => {
|
|
|
138
137
|
type: RTS,
|
|
139
138
|
});
|
|
140
139
|
//for dev
|
|
141
|
-
//navigate(`filter?${queryParams.toString()}`);
|
|
142
140
|
navigate(`/orders/view/return/filter?${queryParams.toString()}`);
|
|
143
141
|
|
|
144
142
|
//for local
|
|
@@ -176,13 +174,13 @@ const ReturnTable: React.FC = () => {
|
|
|
176
174
|
<tbody>
|
|
177
175
|
{statsLoading ? (
|
|
178
176
|
<tr>
|
|
179
|
-
<td colSpan={
|
|
177
|
+
<td colSpan={12}>
|
|
180
178
|
<Skeleton active />
|
|
181
179
|
</td>
|
|
182
180
|
</tr>
|
|
183
181
|
) : sortedData?.length === 0 ? (
|
|
184
182
|
<tr>
|
|
185
|
-
<td colSpan={
|
|
183
|
+
<td colSpan={12}>
|
|
186
184
|
<EmptyDataContainer>
|
|
187
185
|
<Empty />
|
|
188
186
|
</EmptyDataContainer>
|
|
@@ -8,14 +8,19 @@ import React, { useMemo } from 'react';
|
|
|
8
8
|
import styled from 'styled-components';
|
|
9
9
|
import CustomScrollBar from '../../common/scrollbar';
|
|
10
10
|
import { atom, useAtom } from 'jotai';
|
|
11
|
+
import { Skeleton } from 'antd';
|
|
11
12
|
export const selectedID = atom<any>([]);
|
|
12
13
|
|
|
13
14
|
interface DynamicTableProps {
|
|
14
15
|
columns: any;
|
|
15
16
|
data: any[];
|
|
17
|
+
loading: boolean;
|
|
16
18
|
}
|
|
17
19
|
|
|
18
|
-
function DynamicTable(
|
|
20
|
+
function DynamicTable(
|
|
21
|
+
{ columns, data, loading }: DynamicTableProps,
|
|
22
|
+
props: any
|
|
23
|
+
) {
|
|
19
24
|
const tableColumns = useMemo(() => columns, [columns]);
|
|
20
25
|
const tableData = useMemo(() => data, [data]);
|
|
21
26
|
|
|
@@ -44,6 +49,8 @@ function DynamicTable({ columns, data }: DynamicTableProps, props: any) {
|
|
|
44
49
|
const largeColumns = ['details', 'datetime'];
|
|
45
50
|
const noFlexColumns = ['id'];
|
|
46
51
|
|
|
52
|
+
console.log(rows, '<===========rows');
|
|
53
|
+
console.log(props, 'props');
|
|
47
54
|
return (
|
|
48
55
|
<MainContainer>
|
|
49
56
|
<Container>
|
|
@@ -78,7 +85,19 @@ function DynamicTable({ columns, data }: DynamicTableProps, props: any) {
|
|
|
78
85
|
))}
|
|
79
86
|
</TableHead>
|
|
80
87
|
<TableBody>
|
|
81
|
-
{
|
|
88
|
+
{loading ? (
|
|
89
|
+
<tr>
|
|
90
|
+
<td colSpan={5}>
|
|
91
|
+
<Skeleton active />
|
|
92
|
+
</td>
|
|
93
|
+
</tr>
|
|
94
|
+
) : rows?.length === 0 ? (
|
|
95
|
+
<TableRow>
|
|
96
|
+
<TableData colSpan={columns.length}>
|
|
97
|
+
No entries found.
|
|
98
|
+
</TableData>
|
|
99
|
+
</TableRow>
|
|
100
|
+
) : (
|
|
82
101
|
rows?.map(row => (
|
|
83
102
|
<TableRow
|
|
84
103
|
key={row.id}
|
|
@@ -115,12 +134,6 @@ function DynamicTable({ columns, data }: DynamicTableProps, props: any) {
|
|
|
115
134
|
))}
|
|
116
135
|
</TableRow>
|
|
117
136
|
))
|
|
118
|
-
) : (
|
|
119
|
-
<TableRow>
|
|
120
|
-
<TableData colSpan={columns.length}>
|
|
121
|
-
No entries found.
|
|
122
|
-
</TableData>
|
|
123
|
-
</TableRow>
|
|
124
137
|
)}
|
|
125
138
|
</TableBody>
|
|
126
139
|
</Table>
|
|
@@ -75,6 +75,7 @@ function ButtonsSection() {
|
|
|
75
75
|
placeholder="Select Type"
|
|
76
76
|
onChange={handleTaskTypeChange}
|
|
77
77
|
value={selectedTypeId}
|
|
78
|
+
style={{ minWidth: '200px', width: 'auto' }}
|
|
78
79
|
/>
|
|
79
80
|
</Flex>
|
|
80
81
|
<Flex>
|
|
@@ -84,6 +85,7 @@ function ButtonsSection() {
|
|
|
84
85
|
placeholder="Select Type"
|
|
85
86
|
onChange={handlePriorityChange}
|
|
86
87
|
value={taskPayload?.priority || flagById?.priority}
|
|
88
|
+
style={{ minWidth: '100px', width: 'auto' }}
|
|
87
89
|
/>
|
|
88
90
|
</Flex>
|
|
89
91
|
<Flex>
|
|
@@ -1,34 +1,66 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import styled from 'styled-components';
|
|
3
3
|
import { StatusOptions } from '../helper';
|
|
4
|
-
import Divider from '../../../assets/icons/Divider';
|
|
5
4
|
// Import icon
|
|
6
5
|
import RouteIcon from '../../../assets/icons/RoutedIcon';
|
|
7
6
|
import SuccessIcon from '../../../assets/icons/SuccessIcon';
|
|
8
7
|
import DeliveredIcon from '../../../assets/icons/DeliveredIcon';
|
|
9
8
|
import ConfirmedIcon from '../../../assets/icons/ConfirmedIcon';
|
|
10
9
|
import { useStatusDetails } from '../store';
|
|
10
|
+
import { Skeleton } from 'antd';
|
|
11
|
+
import Divider from '../../../assets/icons/Divider';
|
|
11
12
|
|
|
12
|
-
function Status() {
|
|
13
|
+
function Status({ statusDataLoading }: any) {
|
|
13
14
|
const [orderStatus] = useStatusDetails();
|
|
14
|
-
|
|
15
15
|
return (
|
|
16
|
-
|
|
17
|
-
<
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
16
|
+
<>
|
|
17
|
+
<Container>
|
|
18
|
+
<BoxContainer>
|
|
19
|
+
{statusDataLoading ? (
|
|
20
|
+
<>
|
|
21
|
+
<StatusSkeletonRow />
|
|
22
|
+
</>
|
|
23
|
+
) : (
|
|
24
|
+
StatusOptions?.map((option, index) => (
|
|
25
|
+
<React.Fragment key={index}>
|
|
26
|
+
<TextContainer>
|
|
27
|
+
{renderIcon(option.value, orderStatus)}
|
|
28
|
+
<Heading>{option.label}</Heading>
|
|
29
|
+
</TextContainer>
|
|
30
|
+
{index < StatusOptions.length - 1 && <Divider />}
|
|
31
|
+
</React.Fragment>
|
|
32
|
+
))
|
|
33
|
+
)}
|
|
34
|
+
</BoxContainer>
|
|
35
|
+
</Container>
|
|
36
|
+
</>
|
|
29
37
|
);
|
|
30
38
|
}
|
|
31
|
-
|
|
39
|
+
const StatusSkeletonItem = () => (
|
|
40
|
+
<SkeletonItemContainer>
|
|
41
|
+
<Skeleton.Avatar size="small" style={{ marginRight: 12 }} />
|
|
42
|
+
<Skeleton.Input
|
|
43
|
+
active
|
|
44
|
+
size="small"
|
|
45
|
+
style={{ width: 150, borderRadius: 8 }}
|
|
46
|
+
/>
|
|
47
|
+
</SkeletonItemContainer>
|
|
48
|
+
);
|
|
49
|
+
const StatusSkeletonRow = () => (
|
|
50
|
+
<StatusBox>
|
|
51
|
+
<StatusSkeletonItem />
|
|
52
|
+
<SkeletonDivider />
|
|
53
|
+
<StatusSkeletonItem />
|
|
54
|
+
<SkeletonDivider />
|
|
55
|
+
<StatusSkeletonItem />
|
|
56
|
+
<SkeletonDivider />
|
|
57
|
+
<StatusSkeletonItem />
|
|
58
|
+
<SkeletonDivider />
|
|
59
|
+
<StatusSkeletonItem />
|
|
60
|
+
<SkeletonDivider />
|
|
61
|
+
<StatusSkeletonItem />
|
|
62
|
+
</StatusBox>
|
|
63
|
+
);
|
|
32
64
|
const renderIcon = (value: any, orderStatus: any) => {
|
|
33
65
|
const status = orderStatus && orderStatus.length > 0 ? orderStatus[0] : null;
|
|
34
66
|
|
|
@@ -72,11 +104,53 @@ const renderIcon = (value: any, orderStatus: any) => {
|
|
|
72
104
|
}
|
|
73
105
|
};
|
|
74
106
|
|
|
107
|
+
// const RowWrapper = styled.div`
|
|
108
|
+
// display: flex;
|
|
109
|
+
// flex-direction: column;
|
|
110
|
+
// background: #fff;
|
|
111
|
+
// border-radius: 12px;
|
|
112
|
+
// box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
|
|
113
|
+
// padding: 16px;
|
|
114
|
+
// `;
|
|
115
|
+
|
|
116
|
+
// const HeaderPlaceholder = styled.div`
|
|
117
|
+
// display: flex;
|
|
118
|
+
// align-items: center;
|
|
119
|
+
// padding: 8px 0;
|
|
120
|
+
// gap: 12px;
|
|
121
|
+
// `;
|
|
122
|
+
|
|
123
|
+
const StatusBox = styled.div`
|
|
124
|
+
display: flex;
|
|
125
|
+
align-items: center;
|
|
126
|
+
background: #fcfcfc;
|
|
127
|
+
border: 1px solid #eee;
|
|
128
|
+
border-radius: 20px;
|
|
129
|
+
justify-content: space-between;
|
|
130
|
+
flex-wrap: wrap;
|
|
131
|
+
padding: 5px;
|
|
132
|
+
width: -webkit-fill-available;
|
|
133
|
+
`;
|
|
134
|
+
|
|
135
|
+
const SkeletonItemContainer = styled.div`
|
|
136
|
+
display: flex;
|
|
137
|
+
align-items: center;
|
|
138
|
+
gap: 8px;
|
|
139
|
+
`;
|
|
140
|
+
|
|
141
|
+
const SkeletonDivider = styled.div`
|
|
142
|
+
width: 12px;
|
|
143
|
+
height: 2px;
|
|
144
|
+
background-color: #e0e0e0;
|
|
145
|
+
margin: 0 4px;
|
|
146
|
+
border-radius: 2px;
|
|
147
|
+
`;
|
|
148
|
+
|
|
75
149
|
const BoxContainer = styled.div`
|
|
76
150
|
border: 1px solid #e3e3e3;
|
|
77
151
|
display: flex;
|
|
78
152
|
justify-content: space-evenly;
|
|
79
|
-
border-radius:
|
|
153
|
+
border-radius: 20px;
|
|
80
154
|
background: #f8fafc;
|
|
81
155
|
align-items: center;
|
|
82
156
|
height: 5%;
|
|
@@ -3,10 +3,10 @@ import Status from './Status';
|
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
// import DropDownOptions from './dropdowns';
|
|
5
5
|
|
|
6
|
-
function GeneralHeader() {
|
|
6
|
+
function GeneralHeader({ statusDataLoading }: any) {
|
|
7
7
|
return (
|
|
8
8
|
<Section>
|
|
9
|
-
<Status />
|
|
9
|
+
<Status statusDataLoading={statusDataLoading} />
|
|
10
10
|
{/* <DropDownOptions /> */}
|
|
11
11
|
</Section>
|
|
12
12
|
);
|
|
@@ -48,7 +48,7 @@ interface ApiResponse {
|
|
|
48
48
|
setShouldPerformAction: boolean;
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
function OrderView() {
|
|
51
|
+
function OrderView({ locationloading }: any) {
|
|
52
52
|
notification.config({
|
|
53
53
|
top: 150,
|
|
54
54
|
});
|
|
@@ -98,6 +98,7 @@ function OrderView() {
|
|
|
98
98
|
value: `${order_id}`,
|
|
99
99
|
},
|
|
100
100
|
],
|
|
101
|
+
showLoader: false,
|
|
101
102
|
});
|
|
102
103
|
|
|
103
104
|
// query param
|
|
@@ -291,12 +292,14 @@ function OrderView() {
|
|
|
291
292
|
const {
|
|
292
293
|
data: fetchedResourcesData,
|
|
293
294
|
setShouldPerformAction: setActions,
|
|
295
|
+
loading: loadingResources,
|
|
294
296
|
} = useApiHook<{
|
|
295
297
|
data: ApiResponse[];
|
|
296
298
|
}>({
|
|
297
299
|
endpoint: `/orders/${orderId}/order_resources/`,
|
|
298
300
|
method: 'GET',
|
|
299
301
|
performAction: false,
|
|
302
|
+
showLoader: false,
|
|
300
303
|
});
|
|
301
304
|
|
|
302
305
|
useEffect(() => {
|
|
@@ -449,19 +452,22 @@ function OrderView() {
|
|
|
449
452
|
|
|
450
453
|
return (
|
|
451
454
|
<MainContainer>
|
|
452
|
-
<GeneralHeader />
|
|
455
|
+
<GeneralHeader statusDataLoading={statusDataLoading} />
|
|
453
456
|
|
|
454
457
|
<DetailsFilters />
|
|
455
458
|
<Notification />
|
|
456
|
-
<OrderDetails
|
|
457
|
-
|
|
459
|
+
<OrderDetails
|
|
460
|
+
orderLoading={loading}
|
|
461
|
+
depotDataLoading={depotDataLoading}
|
|
462
|
+
/>
|
|
463
|
+
<ProductsInfo locationloading={locationloading} />
|
|
458
464
|
<SplitLayout>
|
|
459
465
|
<NotesContainer>
|
|
460
466
|
<Notes />
|
|
461
467
|
</NotesContainer>
|
|
462
468
|
<TablesContainer>
|
|
463
|
-
<Order />
|
|
464
|
-
<SystemLogs />
|
|
469
|
+
<Order loading={loadingResources} />
|
|
470
|
+
<SystemLogs loading={logsLoading} />
|
|
465
471
|
</TablesContainer>
|
|
466
472
|
</SplitLayout>
|
|
467
473
|
<OrderActions />
|
|
@@ -22,6 +22,7 @@ import {
|
|
|
22
22
|
useAllOrderStatus,
|
|
23
23
|
} from '../order-actions/store';
|
|
24
24
|
import { useParams, useSearchParams } from 'react-router-dom';
|
|
25
|
+
import { Skeleton } from 'antd';
|
|
25
26
|
|
|
26
27
|
interface ApiResponse {
|
|
27
28
|
message: string;
|
|
@@ -74,6 +75,7 @@ function Notification() {
|
|
|
74
75
|
method: 'GET',
|
|
75
76
|
pagination: { is_pagination: false },
|
|
76
77
|
filters: [{ field: 'order_id', op: '=', value: orderId }],
|
|
78
|
+
showLoader: false,
|
|
77
79
|
});
|
|
78
80
|
|
|
79
81
|
//reminder get
|
|
@@ -88,6 +90,7 @@ function Notification() {
|
|
|
88
90
|
method: 'GET',
|
|
89
91
|
pagination: { is_pagination: false },
|
|
90
92
|
filters: [{ field: 'order_id', op: '=', value: orderId }],
|
|
93
|
+
showLoader: false,
|
|
91
94
|
});
|
|
92
95
|
|
|
93
96
|
useEffect(() => {
|
|
@@ -120,6 +123,7 @@ function Notification() {
|
|
|
120
123
|
}>({
|
|
121
124
|
endpoint: `route/${routeId}`,
|
|
122
125
|
method: 'GET',
|
|
126
|
+
showLoader: false,
|
|
123
127
|
});
|
|
124
128
|
|
|
125
129
|
useEffect(() => {
|
|
@@ -140,6 +144,7 @@ function Notification() {
|
|
|
140
144
|
}>({
|
|
141
145
|
endpoint: `v1/orders/alerts/?order_id=${orderId}`,
|
|
142
146
|
method: 'GET',
|
|
147
|
+
showLoader: false,
|
|
143
148
|
});
|
|
144
149
|
|
|
145
150
|
useEffect(() => {
|
|
@@ -219,6 +224,7 @@ function Notification() {
|
|
|
219
224
|
const totalClosedCount =
|
|
220
225
|
closedTasks?.filter((item: any) => item.status === 'SD')?.length +
|
|
221
226
|
closedReminders?.length;
|
|
227
|
+
console.log(unresolvedLoading, 'unresolved', reminderLoading, 'reminder');
|
|
222
228
|
|
|
223
229
|
return (
|
|
224
230
|
<>
|
|
@@ -245,10 +251,9 @@ function Notification() {
|
|
|
245
251
|
</StyledTab>
|
|
246
252
|
</TabsData>
|
|
247
253
|
</Container>
|
|
248
|
-
{unresolvedLoading || reminderLoading ? (
|
|
254
|
+
{unresolvedLoading || reminderLoading || alertsApiLoading ? (
|
|
249
255
|
<Loader>
|
|
250
|
-
<
|
|
251
|
-
<Text>Fetching Notifications...</Text>
|
|
256
|
+
<Skeleton avatar paragraph={{ rows: 2 }} />
|
|
252
257
|
</Loader>
|
|
253
258
|
) : taskData?.length > 0 ||
|
|
254
259
|
reminderNotifyData?.length > 0 ||
|
|
@@ -288,23 +293,23 @@ const Loader = styled.div`
|
|
|
288
293
|
gap: 10px;
|
|
289
294
|
`;
|
|
290
295
|
|
|
291
|
-
const Spinner = styled.div`
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
`;
|
|
296
|
+
// const Spinner = styled.div`
|
|
297
|
+
// border: 4px solid rgba(0, 0, 0, 0.1);
|
|
298
|
+
// border-left-color: #3a3630;
|
|
299
|
+
// border-radius: 50%;
|
|
300
|
+
// width: 40px;
|
|
301
|
+
// height: 40px;
|
|
302
|
+
// animation: spin 1s linear infinite;
|
|
303
|
+
|
|
304
|
+
// @keyframes spin {
|
|
305
|
+
// 0% {
|
|
306
|
+
// transform: rotate(0deg);
|
|
307
|
+
// }
|
|
308
|
+
// 100% {
|
|
309
|
+
// transform: rotate(360deg);
|
|
310
|
+
// }
|
|
311
|
+
// }
|
|
312
|
+
// `;
|
|
308
313
|
|
|
309
314
|
const FlagContainer = styled.div`
|
|
310
315
|
padding: 8px;
|
|
@@ -369,7 +374,7 @@ const Label = styled(SectionHeader)`
|
|
|
369
374
|
|
|
370
375
|
const TabsWrapper = styled.div`
|
|
371
376
|
/* min-height: 200px; */
|
|
372
|
-
max-height:
|
|
377
|
+
max-height: 300px;
|
|
373
378
|
overflow-y: auto;
|
|
374
379
|
scrollbar-width: none;
|
|
375
380
|
-ms-overflow-style: none;
|
|
@@ -391,11 +396,11 @@ const TabsWrapper = styled.div`
|
|
|
391
396
|
}
|
|
392
397
|
`;
|
|
393
398
|
|
|
394
|
-
const Text = styled.div`
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
`;
|
|
399
|
+
// const Text = styled.div`
|
|
400
|
+
// color: var(--tonal-brown-651, #6a7378);
|
|
401
|
+
// font-family: Lato;
|
|
402
|
+
// font-size: 13px;
|
|
403
|
+
// font-style: normal;
|
|
404
|
+
// font-weight: 600;
|
|
405
|
+
// `;
|
|
401
406
|
export default Notification;
|
package/src/components/order-view/order-actions/actions/create-task-reminder/CreateTaskModal.tsx
CHANGED
|
@@ -87,7 +87,7 @@ function CreateTaskModal() {
|
|
|
87
87
|
/>
|
|
88
88
|
</FormRow>
|
|
89
89
|
|
|
90
|
-
<FormRow label="Due Date & Time"
|
|
90
|
+
<FormRow label="Due Date & Time">
|
|
91
91
|
<StyleContainer>
|
|
92
92
|
<DatePickerWrap>
|
|
93
93
|
<DatePicker
|
|
@@ -129,7 +129,9 @@ function CreateTaskModal() {
|
|
|
129
129
|
const getTaskTypeOptions = (staticData: any) => {
|
|
130
130
|
return (
|
|
131
131
|
staticData?.[0]?.order_flag_types?.map((item: any) => ({
|
|
132
|
-
label: item?.type
|
|
132
|
+
label: item?.type
|
|
133
|
+
?.replace(/_/g, ' ')
|
|
134
|
+
?.replace(/\b\w/g, (char: any) => char.toUpperCase()),
|
|
133
135
|
value: item?.id,
|
|
134
136
|
})) || []
|
|
135
137
|
);
|
|
@@ -190,7 +192,7 @@ const StyledTextArea = styled(TextArea)`
|
|
|
190
192
|
border: 1px solid var(--Neutral-Gray-Gray-100, #e0e2e7);
|
|
191
193
|
background: var(--Flowkit-White, #fff);
|
|
192
194
|
resize: none;
|
|
193
|
-
height:
|
|
195
|
+
height: 50%;
|
|
194
196
|
`;
|
|
195
197
|
|
|
196
198
|
export default CreateTaskModal;
|
|
@@ -95,8 +95,8 @@ function TaskModal(props: IProps) {
|
|
|
95
95
|
};
|
|
96
96
|
|
|
97
97
|
const isSubmitDisabled = () => {
|
|
98
|
-
const { description,
|
|
99
|
-
return !description || !
|
|
98
|
+
const { description, flag_type, priority } = taskPayload;
|
|
99
|
+
return !description || !flag_type || !priority;
|
|
100
100
|
};
|
|
101
101
|
|
|
102
102
|
return (
|
|
@@ -94,8 +94,8 @@ function OrderActions() {
|
|
|
94
94
|
setProductDetails(productsData?.data);
|
|
95
95
|
setProductDetailsCopy(productsData?.data);
|
|
96
96
|
} else {
|
|
97
|
-
setProductDetails(
|
|
98
|
-
setProductDetailsCopy(
|
|
97
|
+
setProductDetails([]);
|
|
98
|
+
setProductDetailsCopy([]);
|
|
99
99
|
}
|
|
100
100
|
}, [orderProductsLoading]);
|
|
101
101
|
|
|
@@ -177,6 +177,7 @@ function OrderActions() {
|
|
|
177
177
|
method: 'GET',
|
|
178
178
|
pagination: { is_pagination: false },
|
|
179
179
|
filters: [{ field: 'order_id', op: '=', value: orderId }],
|
|
180
|
+
showLoader: false,
|
|
180
181
|
});
|
|
181
182
|
|
|
182
183
|
useEffect(() => {
|
|
@@ -22,7 +22,7 @@ export interface CreateTaskPayload {
|
|
|
22
22
|
flag_type: string | null;
|
|
23
23
|
priority: number | null;
|
|
24
24
|
status: string | null;
|
|
25
|
-
due_datetime
|
|
25
|
+
due_datetime?: string | null;
|
|
26
26
|
}
|
|
27
27
|
export interface resolveTaskPayload {
|
|
28
28
|
task_ids: number[] | null;
|