@axelor/aos-mobile-helpdesk 7.2.3 → 7.2.5
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/lib/api/customer-api.js +1 -1
- package/lib/api/helpdesk-config-api.js +1 -1
- package/lib/api/index.js +1 -1
- package/lib/api/project-api.js +1 -1
- package/lib/api/ticket-api.js +1 -1
- package/lib/api/timer-api.js +1 -1
- package/lib/components/index.js +1 -1
- package/lib/components/molecules/DurationFormInput/DurationFormInput.js +1 -1
- package/lib/components/molecules/DurationFormInput/duration.helpers.js +4 -1
- package/lib/components/molecules/DurationFormInput/duration.helpers.js.map +1 -1
- package/lib/components/molecules/ProgressFormInput/ProgressFormInput.js +1 -1
- package/lib/components/molecules/TicketCard/TicketCard.js +1 -1
- package/lib/components/molecules/index.js +1 -1
- package/lib/components/templates/ContactPartnerSearchBar/ContactPartnerSearchBar.js +1 -1
- package/lib/components/templates/CustomerSearchBar/CustomerSearchBar.js +1 -1
- package/lib/components/templates/{TicketSearchBar/TicketSearchBar.d.ts → MyTeamTicketSearchBar/MyTeamTicketSearchBar.d.ts} +2 -3
- package/lib/components/templates/MyTeamTicketSearchBar/MyTeamTicketSearchBar.js +38 -0
- package/lib/components/templates/MyTeamTicketSearchBar/MyTeamTicketSearchBar.js.map +1 -0
- package/lib/components/templates/MyTicketSearchBar/MyTicketSearchBar.d.ts +10 -0
- package/lib/components/templates/{TicketSearchBar/TicketSearchBar.js → MyTicketSearchBar/MyTicketSearchBar.js} +11 -12
- package/lib/components/templates/MyTicketSearchBar/MyTicketSearchBar.js.map +1 -0
- package/lib/components/templates/ProjectSearchBar/ProjectSearchBar.js +1 -1
- package/lib/components/templates/TicketDropdownCards/DropdownGeneralView.js +1 -1
- package/lib/components/templates/TicketDropdownCards/DropdownTimingView.js +1 -1
- package/lib/components/templates/TicketDropdownCards/TicketDropdownCards.js +1 -1
- package/lib/components/templates/TicketEditButton/TicketEditButton.js +1 -1
- package/lib/components/templates/TicketHeader/TicketHeader.js +1 -1
- package/lib/components/templates/TicketPriorityPicker/TicketPriorityPicker.js +1 -1
- package/lib/components/templates/TicketStopwatch/TicketStopwatch.js +1 -1
- package/lib/components/templates/TicketTypeSearchBar/TicketTypeSearchBar.js +1 -1
- package/lib/components/templates/TicketsStatusButton/TicketsStatusButton.js +1 -1
- package/lib/components/templates/index.d.ts +2 -1
- package/lib/components/templates/index.js +3 -2
- package/lib/components/templates/index.js.map +1 -1
- package/lib/features/asyncFunctions-index.d.ts +1 -1
- package/lib/features/asyncFunctions-index.js +2 -2
- package/lib/features/asyncFunctions-index.js.map +1 -1
- package/lib/features/customerSlice.js +1 -1
- package/lib/features/customerSlice.js.map +1 -1
- package/lib/features/helpdeskConfigSlice.js +1 -1
- package/lib/features/index.js +1 -1
- package/lib/features/projectSlice.js +1 -1
- package/lib/features/ticketSlice.d.ts +17 -2
- package/lib/features/ticketSlice.js +27 -7
- package/lib/features/ticketSlice.js.map +1 -1
- package/lib/features/timerSlice.js +1 -1
- package/lib/hooks/use-helpdesk-header-actions.js +1 -1
- package/lib/index.js +1 -1
- package/lib/models/forms.js +1 -1
- package/lib/models/index.js +1 -1
- package/lib/models/objectFields.js +1 -1
- package/lib/models/searchFields.js +1 -1
- package/lib/models/sortFields.js +1 -1
- package/lib/screens/MyTeamTicketListScreen.js +13 -17
- package/lib/screens/MyTeamTicketListScreen.js.map +1 -1
- package/lib/screens/MyTicketListScreen.js +13 -17
- package/lib/screens/MyTicketListScreen.js.map +1 -1
- package/lib/screens/TicketDetailsScreen.js +1 -1
- package/lib/screens/TicketFormScreen.js +9 -1
- package/lib/screens/TicketFormScreen.js.map +1 -1
- package/lib/screens/index.js +1 -1
- package/lib/types/index.js +1 -1
- package/lib/types/ticket.js +1 -1
- package/lib/utils/displayers.js +1 -1
- package/lib/utils/index.js +1 -1
- package/package.json +3 -3
- package/lib/components/templates/TicketSearchBar/TicketSearchBar.js.map +0 -1
package/lib/api/customer-api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/api/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/api/project-api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/api/ticket-api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/api/timer-api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/components/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -32,6 +32,9 @@ export const formatDurationFromSeconds = (seconds) => {
|
|
|
32
32
|
return formatDuration(hours, minutes);
|
|
33
33
|
};
|
|
34
34
|
export const parseDuration = (value) => {
|
|
35
|
+
if (value == null) {
|
|
36
|
+
return 0;
|
|
37
|
+
}
|
|
35
38
|
const [hours, minutes] = value.split(':');
|
|
36
39
|
const parsedHours = parseInt(hours, 10);
|
|
37
40
|
const parsedMinutes = parseInt(minutes, 10);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"duration.helpers.js","sourceRoot":"","sources":["../../../../src/components/molecules/DurationFormInput/duration.helpers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAC;AAC1B,MAAM,CAAC,MAAM,oBAAoB,GAAG,EAAE,CAAC;AACvC,MAAM,CAAC,MAAM,kBAAkB,GAAG,IAAI,CAAC;AAEvC,MAAM,CAAC,MAAM,cAAc,GAAG,SAAS,CAAC;AACxC,MAAM,CAAC,MAAM,iBAAiB,GAAG,UAAU,CAAC;AAC5C,MAAM,CAAC,MAAM,aAAa,GAAG,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,KAAa,EAAE,OAAe,EAAE,EAAE;IAC/D,MAAM,cAAc,GAAG,KAAK,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IACzD,MAAM,gBAAgB,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IAE7D,OAAO,GAAG,cAAc,IAAI,gBAAgB,EAAE,CAAC;AACjD,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,OAAe,EAAE,EAAE;IAC3D,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,GAAG,kBAAkB,CAAC,CAAC;IACvD,MAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CACxB,CAAC,OAAO,GAAG,kBAAkB,CAAC,GAAG,oBAAoB,CACtD,CAAC;IAEF,OAAO,cAAc,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;AACxC,CAAC,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OAAO,GAAG,cAAc,IAAI,gBAAgB,EAAE,CAAC;AACjD,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,OAAe,EAAE,EAAE;IAC3D,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,GAAG,kBAAkB,CAAC,CAAC;IACvD,MAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CACxB,CAAC,OAAO,GAAG,kBAAkB,CAAC,GAAG,oBAAoB,CACtD,CAAC;IAEF,OAAO,cAAc,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;AACxC,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,KAAa,EAAE,EAAE;IAC7C,IAAI,KAAK,IAAI,IAAI,EAAE;QACjB,OAAO,CAAC,CAAC;KACV;IAED,MAAM,CAAC,KAAK,EAAE,OAAO,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC1C,MAAM,WAAW,GAAG,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;IACxC,MAAM,aAAa,GAAG,QAAQ,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC;IAE5C,IAAI,KAAK,CAAC,WAAW,CAAC,IAAI,KAAK,CAAC,aAAa,CAAC,EAAE;QAC9C,OAAO,CAAC,CAAC;KACV;IAED,MAAM,YAAY,GAChB,WAAW,GAAG,kBAAkB,GAAG,aAAa,GAAG,oBAAoB,CAAC;IAE1E,OAAO,YAAY,CAAC;AACtB,CAAC,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export default
|
|
2
|
-
declare function
|
|
1
|
+
export default MyTeamTicketSearchBar;
|
|
2
|
+
declare function MyTeamTicketSearchBar({ placeholderKey, defaultValue, onChange, showDetailsPopup, navigate, oneFilter, isFocus, }: {
|
|
3
3
|
placeholderKey?: string;
|
|
4
4
|
defaultValue?: string;
|
|
5
5
|
onChange?: () => void;
|
|
@@ -7,5 +7,4 @@ declare function TicketSearchBar({ placeholderKey, defaultValue, onChange, showD
|
|
|
7
7
|
navigate?: boolean;
|
|
8
8
|
oneFilter?: boolean;
|
|
9
9
|
isFocus?: boolean;
|
|
10
|
-
team?: boolean;
|
|
11
10
|
}): JSX.Element;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Axelor Business Solutions
|
|
3
|
+
*
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
|
+
*
|
|
6
|
+
* This program is free software: you can redistribute it and/or modify
|
|
7
|
+
* it under the terms of the GNU Affero General Public License, version 3,
|
|
8
|
+
* as published by the Free Software Foundation.
|
|
9
|
+
*
|
|
10
|
+
* This program is distributed in the hope that it will be useful,
|
|
11
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
12
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
13
|
+
* GNU Affero General Public License for more details.
|
|
14
|
+
*
|
|
15
|
+
* You should have received a copy of the GNU Affero General Public License
|
|
16
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
17
|
+
*/
|
|
18
|
+
import React, { useCallback } from 'react';
|
|
19
|
+
import { useDispatch, useSelector, useTranslator } from '@axelor/aos-mobile-core';
|
|
20
|
+
import { AutoCompleteSearch } from '@axelor/aos-mobile-ui';
|
|
21
|
+
import { fetchMyTeamTickets } from '../../../features/ticketSlice';
|
|
22
|
+
const MyTeamTicketSearchBar = ({ placeholderKey = 'Helpdesk_Ticket', defaultValue = '', onChange = () => { }, showDetailsPopup = true, navigate = false, oneFilter = false, isFocus = false, }) => {
|
|
23
|
+
const I18n = useTranslator();
|
|
24
|
+
const dispatch = useDispatch();
|
|
25
|
+
const displayItemTicketSeq = item => item.ticketSeq;
|
|
26
|
+
const { myTeamTicketList, loadingMyTeamTicket, moreMoadingMyTeamTicket, isListEndMyTeamTicket, } = useSelector(state => state.ticket);
|
|
27
|
+
const { user } = useSelector(state => state.user);
|
|
28
|
+
const fetchMyTeamTicketSearchBarAPI = useCallback(({ page = 0, searchValue }) => {
|
|
29
|
+
dispatch(fetchMyTeamTickets({
|
|
30
|
+
searchValue: searchValue,
|
|
31
|
+
userTeam: user.activeTeam,
|
|
32
|
+
page: page,
|
|
33
|
+
}));
|
|
34
|
+
}, [dispatch, user]);
|
|
35
|
+
return (<AutoCompleteSearch objectList={myTeamTicketList} value={defaultValue} onChangeValue={onChange} fetchData={fetchMyTeamTicketSearchBarAPI} displayValue={displayItemTicketSeq} placeholder={I18n.t(placeholderKey)} showDetailsPopup={showDetailsPopup} loadingList={loadingMyTeamTicket} moreLoading={moreMoadingMyTeamTicket} isListEnd={isListEndMyTeamTicket} navigate={navigate} oneFilter={oneFilter} isFocus={isFocus}/>);
|
|
36
|
+
};
|
|
37
|
+
export default MyTeamTicketSearchBar;
|
|
38
|
+
//# sourceMappingURL=MyTeamTicketSearchBar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MyTeamTicketSearchBar.js","sourceRoot":"","sources":["../../../../src/components/templates/MyTeamTicketSearchBar/MyTeamTicketSearchBar.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAC,MAAM,OAAO,CAAC;AACzC,OAAO,EAAC,WAAW,EAAE,WAAW,EAAE,aAAa,EAAC,MAAM,yBAAyB,CAAC;AAChF,OAAO,EAAC,kBAAkB,EAAC,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAC,kBAAkB,EAAC,MAAM,+BAA+B,CAAC;AAEjE,MAAM,qBAAqB,GAAG,CAAC,EAC7B,cAAc,GAAG,iBAAiB,EAClC,YAAY,GAAG,EAAE,EACjB,QAAQ,GAAG,GAAG,EAAE,GAAE,CAAC,EACnB,gBAAgB,GAAG,IAAI,EACvB,QAAQ,GAAG,KAAK,EAChB,SAAS,GAAG,KAAK,EACjB,OAAO,GAAG,KAAK,GAChB,EAAE,EAA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AC,CACrB,OAAO,CAAC,CAAC,OAAO,CAAC,EACjB,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export default MyTicketSearchBar;
|
|
2
|
+
declare function MyTicketSearchBar({ placeholderKey, defaultValue, onChange, showDetailsPopup, navigate, oneFilter, isFocus, }: {
|
|
3
|
+
placeholderKey?: string;
|
|
4
|
+
defaultValue?: string;
|
|
5
|
+
onChange?: () => void;
|
|
6
|
+
showDetailsPopup?: boolean;
|
|
7
|
+
navigate?: boolean;
|
|
8
|
+
oneFilter?: boolean;
|
|
9
|
+
isFocus?: boolean;
|
|
10
|
+
}): JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -18,22 +18,21 @@
|
|
|
18
18
|
import React, { useCallback } from 'react';
|
|
19
19
|
import { useDispatch, useSelector, useTranslator } from '@axelor/aos-mobile-core';
|
|
20
20
|
import { AutoCompleteSearch } from '@axelor/aos-mobile-ui';
|
|
21
|
-
import {
|
|
22
|
-
const
|
|
21
|
+
import { fetchMyTickets } from '../../../features/ticketSlice';
|
|
22
|
+
const MyTicketSearchBar = ({ placeholderKey = 'Helpdesk_Ticket', defaultValue = '', onChange = () => { }, showDetailsPopup = true, navigate = false, oneFilter = false, isFocus = false, }) => {
|
|
23
23
|
const I18n = useTranslator();
|
|
24
24
|
const dispatch = useDispatch();
|
|
25
25
|
const displayItemTicketSeq = item => item.ticketSeq;
|
|
26
|
-
const { ticketList,
|
|
26
|
+
const { ticketList, loadingTicketList, moreLoading, isListEnd } = useSelector(state => state.ticket);
|
|
27
27
|
const { user } = useSelector(state => state.user);
|
|
28
|
-
const
|
|
29
|
-
dispatch(
|
|
28
|
+
const fetchMyTicketSearchBarAPI = useCallback(({ page = 0, searchValue }) => {
|
|
29
|
+
dispatch(fetchMyTickets({
|
|
30
30
|
page: page,
|
|
31
31
|
searchValue: searchValue,
|
|
32
|
-
userId:
|
|
33
|
-
userTeam: team ? user.activeTeam : null,
|
|
32
|
+
userId: user.id,
|
|
34
33
|
}));
|
|
35
|
-
}, [dispatch, user
|
|
36
|
-
return (<AutoCompleteSearch objectList={ticketList} value={defaultValue} onChangeValue={onChange} fetchData={
|
|
34
|
+
}, [dispatch, user]);
|
|
35
|
+
return (<AutoCompleteSearch objectList={ticketList} value={defaultValue} onChangeValue={onChange} fetchData={fetchMyTicketSearchBarAPI} displayValue={displayItemTicketSeq} placeholder={I18n.t(placeholderKey)} showDetailsPopup={showDetailsPopup} loadingList={loadingTicketList} moreLoading={moreLoading} isListEnd={isListEnd} navigate={navigate} oneFilter={oneFilter} isFocus={isFocus}/>);
|
|
37
36
|
};
|
|
38
|
-
export default
|
|
39
|
-
//# sourceMappingURL=
|
|
37
|
+
export default MyTicketSearchBar;
|
|
38
|
+
//# sourceMappingURL=MyTicketSearchBar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MyTicketSearchBar.js","sourceRoot":"","sources":["../../../../src/components/templates/MyTicketSearchBar/MyTicketSearchBar.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAC,MAAM,OAAO,CAAC;AACzC,OAAO,EAAC,WAAW,EAAE,WAAW,EAAE,aAAa,EAAC,MAAM,yBAAyB,CAAC;AAChF,OAAO,EAAC,kBAAkB,EAAC,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAC,cAAc,EAAC,MAAM,+BAA+B,CAAC;AAE7D,MAAM,iBAAiB,GAAG,CAAC,EACzB,cAAc,GAAG,iBAAiB,EA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,iBAAiB,CAAC,CAC/B,WAAW,CAAC,CAAC,WAAW,CAAC,CACzB,SAAS,CAAC,CAAC,SAAS,CAAC,CACrB,QAAQ,CAAC,CAAC,QAAQ,CAAC,CACnB,SAAS,CAAC,CAAC,SAAS,CAAC,CACrB,OAAO,CAAC,CAAC,OAAO,CAAC,EACjB,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
export { default as ContactPartnerSearchBar } from "./ContactPartnerSearchBar/ContactPartnerSearchBar";
|
|
2
2
|
export { default as CustomerSearchBar } from "./CustomerSearchBar/CustomerSearchBar";
|
|
3
|
+
export { default as MyTeamTicketSearchBar } from "./MyTeamTicketSearchBar/MyTeamTicketSearchBar";
|
|
4
|
+
export { default as MyTicketSearchBar } from "./MyTicketSearchBar/MyTicketSearchBar";
|
|
3
5
|
export { default as ProjectSearchBar } from "./ProjectSearchBar/ProjectSearchBar";
|
|
4
6
|
export { default as TicketDropdownCards } from "./TicketDropdownCards/TicketDropdownCards";
|
|
5
7
|
export { default as TicketEditButton } from "./TicketEditButton/TicketEditButton";
|
|
6
8
|
export { default as TicketHeader } from "./TicketHeader/TicketHeader";
|
|
7
9
|
export { default as TicketPriorityPicker } from "./TicketPriorityPicker/TicketPriorityPicker";
|
|
8
|
-
export { default as TicketSearchBar } from "./TicketSearchBar/TicketSearchBar";
|
|
9
10
|
export { default as TicketsStatusButton } from "./TicketsStatusButton/TicketsStatusButton";
|
|
10
11
|
export { default as TicketStopwatch } from "./TicketStopwatch/TicketStopwatch";
|
|
11
12
|
export { default as TicketTypeSearchBar } from "./TicketTypeSearchBar/TicketTypeSearchBar";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -17,12 +17,13 @@
|
|
|
17
17
|
*/
|
|
18
18
|
export { default as ContactPartnerSearchBar } from './ContactPartnerSearchBar/ContactPartnerSearchBar';
|
|
19
19
|
export { default as CustomerSearchBar } from './CustomerSearchBar/CustomerSearchBar';
|
|
20
|
+
export { default as MyTeamTicketSearchBar } from './MyTeamTicketSearchBar/MyTeamTicketSearchBar';
|
|
21
|
+
export { default as MyTicketSearchBar } from './MyTicketSearchBar/MyTicketSearchBar';
|
|
20
22
|
export { default as ProjectSearchBar } from './ProjectSearchBar/ProjectSearchBar';
|
|
21
23
|
export { default as TicketDropdownCards } from './TicketDropdownCards/TicketDropdownCards';
|
|
22
24
|
export { default as TicketEditButton } from './TicketEditButton/TicketEditButton';
|
|
23
25
|
export { default as TicketHeader } from './TicketHeader/TicketHeader';
|
|
24
26
|
export { default as TicketPriorityPicker } from './TicketPriorityPicker/TicketPriorityPicker';
|
|
25
|
-
export { default as TicketSearchBar } from './TicketSearchBar/TicketSearchBar';
|
|
26
27
|
export { default as TicketsStatusButton } from './TicketsStatusButton/TicketsStatusButton';
|
|
27
28
|
export { default as TicketStopwatch } from './TicketStopwatch/TicketStopwatch';
|
|
28
29
|
export { default as TicketTypeSearchBar } from './TicketTypeSearchBar/TicketTypeSearchBar';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/templates/index.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,OAAO,IAAI,uBAAuB,EAAC,MAAM,mDAAmD,CAAC;AACrG,OAAO,EAAC,OAAO,IAAI,iBAAiB,EAAC,MAAM,uCAAuC,CAAC;AACnF,OAAO,EAAC,OAAO,IAAI,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/templates/index.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,OAAO,IAAI,uBAAuB,EAAC,MAAM,mDAAmD,CAAC;AACrG,OAAO,EAAC,OAAO,IAAI,iBAAiB,EAAC,MAAM,uCAAuC,CAAC;AACnF,OAAO,EAAC,OAAO,IAAI,qBAAqB,EAAC,MAAM,+CAA+C,CAAC;AAC/F,OAAO,EAAC,OAAO,IAAI,iBAAiB,EAAC,MAAM,uCAAuC,CAAC;AACnF,OAAO,EAAC,OAAO,IAAI,gBAAgB,EAAC,MAAM,qCAAqC,CAAC;AAChF,OAAO,EAAC,OAAO,IAAI,mBAAmB,EAAC,MAAM,2CAA2C,CAAC;AACzF,OAAO,EAAC,OAAO,IAAI,gBAAgB,EAAC,MAAM,qCAAqC,CAAC;AAChF,OAAO,EAAC,OAAO,IAAI,YAAY,EAAC,MAAM,6BAA6B,CAAC;AACpE,OAAO,EAAC,OAAO,IAAI,oBAAoB,EAAC,MAAM,6CAA6C,CAAC;AAC5F,OAAO,EAAC,OAAO,IAAI,mBAAmB,EAAC,MAAM,2CAA2C,CAAC;AACzF,OAAO,EAAC,OAAO,IAAI,eAAe,EAAC,MAAM,mCAAmC,CAAC;AAC7E,OAAO,EAAC,OAAO,IAAI,mBAAmB,EAAC,MAAM,2CAA2C,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { getCustomerbyId, searchCustomer, searchCustomerContact, } from './customerSlice';
|
|
2
2
|
export { fetchHelpdeskConfig } from './helpdeskConfigSlice';
|
|
3
3
|
export { searchProject } from './projectSlice';
|
|
4
|
-
export { createTicket, fetchTicketById,
|
|
4
|
+
export { createTicket, fetchTicketById, fetchMyTeamTickets, fetchMyTickets, fetchTicketType, searchTicketType, updateTicket, updateTicketStatus, } from './ticketSlice';
|
|
5
5
|
export { fetchTimerById, searchTimerHistoryById } from './timerSlice';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -18,6 +18,6 @@
|
|
|
18
18
|
export { getCustomerbyId, searchCustomer, searchCustomerContact, } from './customerSlice';
|
|
19
19
|
export { fetchHelpdeskConfig } from './helpdeskConfigSlice';
|
|
20
20
|
export { searchProject } from './projectSlice';
|
|
21
|
-
export { createTicket, fetchTicketById,
|
|
21
|
+
export { createTicket, fetchTicketById, fetchMyTeamTickets, fetchMyTickets, fetchTicketType, searchTicketType, updateTicket, updateTicketStatus, } from './ticketSlice';
|
|
22
22
|
export { fetchTimerById, searchTimerHistoryById } from './timerSlice';
|
|
23
23
|
//# sourceMappingURL=asyncFunctions-index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"asyncFunctions-index.js","sourceRoot":"","sources":["../../src/features/asyncFunctions-index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EACL,eAAe,EACf,cAAc,EACd,qBAAqB,GACtB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAC,mBAAmB,EAAC,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAC,aAAa,EAAC,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EACL,YAAY,EACZ,eAAe,EACf,
|
|
1
|
+
{"version":3,"file":"asyncFunctions-index.js","sourceRoot":"","sources":["../../src/features/asyncFunctions-index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EACL,eAAe,EACf,cAAc,EACd,qBAAqB,GACtB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAC,mBAAmB,EAAC,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAC,aAAa,EAAC,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EACL,YAAY,EACZ,eAAe,EACf,kBAAkB,EAClB,cAAc,EACd,eAAe,EACf,gBAAgB,EAChB,YAAY,EACZ,kBAAkB,GACnB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAC,cAAc,EAAE,sBAAsB,EAAC,MAAM,cAAc,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"customerSlice.js","sourceRoot":"","sources":["../../src/features/customerSlice.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,gBAAgB,EAAE,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EACL,cAAc,EACd,4BAA4B,GAC7B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,WAAW,EACX,cAAc,IAAI,eAAe,EACjC,qBAAqB,IAAI,sBAAsB,GAChD,MAAM,qBAAqB,CAAC;AAE7B,MAAM,CAAC,MAAM,cAAc,GAAG,gBAAgB,CAC5C,yBAAyB,EACzB,KAAK,WAAW,IAAI,EAAE,EAAC,QAAQ,EAAC;IAC9B,OAAO,cAAc,CAAC;QACpB,aAAa,EAAE,eAAe;QAC9B,IAAI;QACJ,MAAM,EAAE,oCAAoC;QAC5C,QAAQ;QACR,eAAe,EAAE,EAAC,eAAe,EAAE,IAAI,EAAC;KACzC,CAAC,CAAC;AACL,CAAC,CACF,CAAC;AAEF,MAAM,CAAC,MAAM,qBAAqB,GAAG,gBAAgB,CACnD,gCAAgC,EAChC,KAAK,WAAW,IAAI,EAAE,EAAC,QAAQ,EAAC;IAC9B,OAAO,cAAc,CAAC;QACpB,aAAa,EAAE,sBAAsB;QACrC,IAAI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AE,0BAA0B;YACrC,IAAI,EAAE,qBAAqB;SAC5B,CAAC,CAAC;QACH,OAAO,CAAC,OAAO,CAAC,eAAe,CAAC,SAAS,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;YAC3D,KAAK,CAAC,YAAY,GAAG,MAAM,CAAC,OAAO,CAAC;QACtC,CAAC,CAAC,CAAC;IACL,CAAC;CACF,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,eAAe,GAAG,aAAa,CAAC,OAAO,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/features/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,4 +1,14 @@
|
|
|
1
|
-
export const
|
|
1
|
+
export const fetchMyTickets: import("@reduxjs/toolkit").AsyncThunk<any, void, {
|
|
2
|
+
state?: unknown;
|
|
3
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction>;
|
|
4
|
+
extra?: unknown;
|
|
5
|
+
rejectValue?: unknown;
|
|
6
|
+
serializedErrorType?: unknown;
|
|
7
|
+
pendingMeta?: unknown;
|
|
8
|
+
fulfilledMeta?: unknown;
|
|
9
|
+
rejectedMeta?: unknown;
|
|
10
|
+
}>;
|
|
11
|
+
export const fetchMyTeamTickets: import("@reduxjs/toolkit").AsyncThunk<any, void, {
|
|
2
12
|
state?: unknown;
|
|
3
13
|
dispatch?: import("redux").Dispatch<import("redux").AnyAction>;
|
|
4
14
|
extra?: unknown;
|
|
@@ -70,12 +80,17 @@ export const createTicket: import("@reduxjs/toolkit").AsyncThunk<any, void, {
|
|
|
70
80
|
}>;
|
|
71
81
|
export const ticketReducer: import("redux").Reducer<{
|
|
72
82
|
loadingTicket: boolean;
|
|
83
|
+
ticket: {};
|
|
84
|
+
loadingTicketList: boolean;
|
|
73
85
|
moreLoading: boolean;
|
|
74
86
|
isListEnd: boolean;
|
|
75
87
|
ticketList: any[];
|
|
76
|
-
ticket: {};
|
|
77
88
|
loadingTicketType: boolean;
|
|
78
89
|
moreLoadingTicketType: boolean;
|
|
79
90
|
isListEndTicketType: boolean;
|
|
80
91
|
ticketTypeList: any[];
|
|
92
|
+
loadingMyTeamTicket: boolean;
|
|
93
|
+
moreMoadingMyTeamTicket: boolean;
|
|
94
|
+
isListEndMyTeamTicket: boolean;
|
|
95
|
+
myTeamTicketList: any[];
|
|
81
96
|
}>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';
|
|
19
19
|
import { generateInifiniteScrollCases, handlerApiCall, updateAgendaItems, } from '@axelor/aos-mobile-core';
|
|
20
20
|
import { getTicket, getTicketType, searchTickets, updateStatusTicket, searchTicketType as _searchTicketType, updateTicket as _updateTicket, createTicket as _createTicket, } from '../api/ticket-api';
|
|
21
|
-
export const
|
|
21
|
+
export const fetchMyTickets = createAsyncThunk('ticket/fetchMyTickets', async function (data, { getState }) {
|
|
22
22
|
return handlerApiCall({
|
|
23
23
|
fetchFunction: searchTickets,
|
|
24
24
|
data,
|
|
@@ -27,6 +27,15 @@ export const fetchTickets = createAsyncThunk('ticket/fetchTickets', async functi
|
|
|
27
27
|
responseOptions: { isArrayResponse: true },
|
|
28
28
|
});
|
|
29
29
|
});
|
|
30
|
+
export const fetchMyTeamTickets = createAsyncThunk('ticket/fetchMyTeamTickets', async function (data, { getState }) {
|
|
31
|
+
return handlerApiCall({
|
|
32
|
+
fetchFunction: searchTickets,
|
|
33
|
+
data,
|
|
34
|
+
action: 'Helpdesk_SliceAction_FetchMyTeamTicket',
|
|
35
|
+
getState,
|
|
36
|
+
responseOptions: { isArrayResponse: true },
|
|
37
|
+
});
|
|
38
|
+
});
|
|
30
39
|
export const fetchTicketType = createAsyncThunk('ticket/fetchTicketType', async function (data = {}, { getState }) {
|
|
31
40
|
return handlerApiCall({
|
|
32
41
|
fetchFunction: getTicketType,
|
|
@@ -107,25 +116,36 @@ export const createTicket = createAsyncThunk('ticket/createTicket', async functi
|
|
|
107
116
|
});
|
|
108
117
|
const initialState = {
|
|
109
118
|
loadingTicket: true,
|
|
119
|
+
ticket: {},
|
|
120
|
+
loadingTicketList: true,
|
|
110
121
|
moreLoading: false,
|
|
111
122
|
isListEnd: false,
|
|
112
123
|
ticketList: [],
|
|
113
|
-
ticket: {},
|
|
114
124
|
loadingTicketType: true,
|
|
115
125
|
moreLoadingTicketType: false,
|
|
116
126
|
isListEndTicketType: false,
|
|
117
127
|
ticketTypeList: [],
|
|
128
|
+
loadingMyTeamTicket: true,
|
|
129
|
+
moreMoadingMyTeamTicket: false,
|
|
130
|
+
isListEndMyTeamTicket: false,
|
|
131
|
+
myTeamTicketList: [],
|
|
118
132
|
};
|
|
119
133
|
const ticketSlice = createSlice({
|
|
120
134
|
name: 'ticket',
|
|
121
135
|
initialState,
|
|
122
136
|
extraReducers: builder => {
|
|
123
|
-
generateInifiniteScrollCases(builder,
|
|
124
|
-
loading: '
|
|
137
|
+
generateInifiniteScrollCases(builder, fetchMyTickets, {
|
|
138
|
+
loading: 'loadingTicketList',
|
|
125
139
|
moreLoading: 'moreLoading',
|
|
126
140
|
isListEnd: 'isListEnd',
|
|
127
141
|
list: 'ticketList',
|
|
128
142
|
});
|
|
143
|
+
generateInifiniteScrollCases(builder, fetchMyTeamTickets, {
|
|
144
|
+
loading: 'loadingMyTeamTicket',
|
|
145
|
+
moreLoading: 'moreMoadingMyTeamTicket',
|
|
146
|
+
isListEnd: 'isListEndMyTeamTicket',
|
|
147
|
+
list: 'myTeamTicketList',
|
|
148
|
+
});
|
|
129
149
|
generateInifiniteScrollCases(builder, searchTicketType, {
|
|
130
150
|
loading: 'loadingTicketType',
|
|
131
151
|
moreLoading: 'moreLoadingTicketType',
|
|
@@ -163,10 +183,10 @@ const ticketSlice = createSlice({
|
|
|
163
183
|
state.ticketList = updateAgendaItems(state.ticketList, [action.payload]);
|
|
164
184
|
});
|
|
165
185
|
builder.addCase(createTicket.pending, (state, action) => {
|
|
166
|
-
state.
|
|
186
|
+
state.loadingTicketList = true;
|
|
167
187
|
});
|
|
168
188
|
builder.addCase(createTicket.fulfilled, (state, action) => {
|
|
169
|
-
state.
|
|
189
|
+
state.loadingTicketList = false;
|
|
170
190
|
state.ticketList = action.payload;
|
|
171
191
|
});
|
|
172
192
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ticketSlice.js","sourceRoot":"","sources":["../../src/features/ticketSlice.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,gBAAgB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AAC,OAAO,CAAC,CAAC,CAAC;QAC3E,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;YACtD,KAAK,CAAC,aAAa,GAAG,IAAI,CAAC;QAC7B,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,SAAS,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;YACxD,KAAK,CAAC,aAAa,GAAG,KAAK,CAAC;YAC5B,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC;YAC9B,KAAK,CAAC,UAAU,GAAG,iBAAiB,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;QAC3E,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;YACtD,KAAK,CAAC,iBAAiB,GAAG,IAAI,CAAC;QACjC,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,SAAS,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;YACxD,KAAK,CAAC,iBAAiB,GAAG,KAAK,CAAC;YAChC,KAAK,CAAC,UAAU,GAAG,MAAM,CAAC,OAAO,CAAC;QACpC,CAAC,CAAC,CAAC;IACL,CAAC;CACF,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,aAAa,GAAG,WAAW,CAAC,OAAO,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/models/forms.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/models/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/models/sortFields.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -19,15 +19,15 @@ import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
|
19
19
|
import { Dimensions, StyleSheet, View } from 'react-native';
|
|
20
20
|
import { Screen, HeaderContainer, ScrollList, MultiValuePicker, useThemeColor, ChipSelect, } from '@axelor/aos-mobile-ui';
|
|
21
21
|
import { useDispatch, useSelector, useTranslator, filterChip, } from '@axelor/aos-mobile-core';
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
22
|
+
import { fetchMyTeamTickets, fetchTicketType } from '../features/ticketSlice';
|
|
23
|
+
import { MyTeamTicketSearchBar, TicketCard } from '../components';
|
|
24
24
|
import { Ticket } from '../types';
|
|
25
25
|
const MyTeamTicketListScreen = ({ navigation }) => {
|
|
26
26
|
const I18n = useTranslator();
|
|
27
27
|
const dispatch = useDispatch();
|
|
28
28
|
const Colors = useThemeColor();
|
|
29
29
|
const { user } = useSelector(state => state.user);
|
|
30
|
-
const {
|
|
30
|
+
const { myTeamTicketList, loadingMyTeamTicket, moreMoadingMyTeamTicket, isListEndMyTeamTicket, ticketTypeList, } = useSelector(state => state.ticket);
|
|
31
31
|
const [selectedType, setSelectedType] = useState([]);
|
|
32
32
|
const [selectedStatus, setSelectedStatus] = useState([]);
|
|
33
33
|
const [priorityStatus, setPriorityStatus] = useState(Ticket.getPriorityList(Colors, I18n).filter(e => e.isActive === true));
|
|
@@ -35,7 +35,7 @@ const MyTeamTicketListScreen = ({ navigation }) => {
|
|
|
35
35
|
dispatch(fetchTicketType());
|
|
36
36
|
}, [dispatch]);
|
|
37
37
|
const fetchTicketsAPI = useCallback((page = 0) => {
|
|
38
|
-
dispatch(
|
|
38
|
+
dispatch(fetchMyTeamTickets({ userTeam: user.activeTeam, page: page }));
|
|
39
39
|
}, [dispatch, user]);
|
|
40
40
|
const ticketTypeListItems = useMemo(() => {
|
|
41
41
|
return ticketTypeList
|
|
@@ -52,8 +52,8 @@ const MyTeamTicketListScreen = ({ navigation }) => {
|
|
|
52
52
|
return Ticket.getStatusList(Colors, I18n);
|
|
53
53
|
}, [Colors, I18n]);
|
|
54
54
|
const filterOnType = useCallback(list => {
|
|
55
|
-
if (list
|
|
56
|
-
return
|
|
55
|
+
if (!Array.isArray(list) || list.length === 0) {
|
|
56
|
+
return [];
|
|
57
57
|
}
|
|
58
58
|
else {
|
|
59
59
|
if (selectedType.length > 0) {
|
|
@@ -65,8 +65,8 @@ const MyTeamTicketListScreen = ({ navigation }) => {
|
|
|
65
65
|
}
|
|
66
66
|
}, [selectedType]);
|
|
67
67
|
const filterOnStatus = useCallback(list => {
|
|
68
|
-
if (list
|
|
69
|
-
return
|
|
68
|
+
if (!Array.isArray(list) || list.length === 0) {
|
|
69
|
+
return [];
|
|
70
70
|
}
|
|
71
71
|
else {
|
|
72
72
|
if (selectedStatus.length > 0) {
|
|
@@ -80,19 +80,17 @@ const MyTeamTicketListScreen = ({ navigation }) => {
|
|
|
80
80
|
const filterOnPriority = useCallback(list => {
|
|
81
81
|
return filterChip(list, priorityStatus, 'prioritySelect');
|
|
82
82
|
}, [priorityStatus]);
|
|
83
|
-
const filteredList = useMemo(() => filterOnStatus(filterOnType(filterOnPriority(
|
|
83
|
+
const filteredList = useMemo(() => filterOnStatus(filterOnType(filterOnPriority(myTeamTicketList))), [myTeamTicketList, filterOnType, filterOnStatus, filterOnPriority]);
|
|
84
84
|
return (<Screen removeSpaceOnTop={true}>
|
|
85
|
-
<HeaderContainer expandableFilter={true} fixedItems={<
|
|
86
|
-
<TicketSearchBar showDetailsPopup={false} oneFilter={true} placeholderKey={I18n.t('Helpdesk_Ticket')} team={true}/>
|
|
87
|
-
</View>} chipComponent={<ChipSelect mode="multi" marginHorizontal={4} width={Dimensions.get('window').width * 0.3} onChangeValue={chiplist => setPriorityStatus(chiplist)} selectionItems={Ticket.getPriorityList(Colors, I18n)}/>}>
|
|
85
|
+
<HeaderContainer expandableFilter={true} fixedItems={<MyTeamTicketSearchBar showDetailsPopup={false} oneFilter={true} placeholderKey={I18n.t('Helpdesk_Ticket')} team={true}/>} chipComponent={<ChipSelect mode="multi" marginHorizontal={4} width={Dimensions.get('window').width * 0.3} onChangeValue={chiplist => setPriorityStatus(chiplist)} selectionItems={Ticket.getPriorityList(Colors, I18n)}/>}>
|
|
88
86
|
<View style={styles.headerContainer}>
|
|
89
87
|
<MultiValuePicker listItems={ticketStatusListItems} title={I18n.t('Helpdesk_Status')} onValueChange={statusList => setSelectedStatus(statusList)}/>
|
|
90
88
|
<MultiValuePicker listItems={ticketTypeListItems} title={I18n.t('Helpdesk_Type')} onValueChange={typeList => setSelectedType(typeList)}/>
|
|
91
89
|
</View>
|
|
92
90
|
</HeaderContainer>
|
|
93
|
-
<ScrollList loadingList={
|
|
91
|
+
<ScrollList loadingList={loadingMyTeamTicket} data={filteredList} renderItem={({ item }) => (<TicketCard style={styles.item} ticketSeq={item.ticketSeq} subject={item.subject} progressSelect={item.progressSelect} ticketType={item.ticketType} statusSelect={item.statusSelect} deadlineDateT={item.deadlineDateT} responsibleUser={item?.responsibleUser?.fullName} prioritySelect={item.prioritySelect} duration={item.duration} allTicketType={ticketTypeList} assignedToUser={item?.assignedToUser?.fullName} onPress={() => navigation.navigate('TicketDetailsScreen', {
|
|
94
92
|
idTicket: item.id,
|
|
95
|
-
})}/>)} fetchData={fetchTicketsAPI} moreLoading={
|
|
93
|
+
})}/>)} fetchData={fetchTicketsAPI} moreLoading={moreMoadingMyTeamTicket} isListEnd={isListEndMyTeamTicket} translator={I18n.t}/>
|
|
96
94
|
</Screen>);
|
|
97
95
|
};
|
|
98
96
|
const styles = StyleSheet.create({
|
|
@@ -104,8 +102,6 @@ const styles = StyleSheet.create({
|
|
|
104
102
|
alignItems: 'center',
|
|
105
103
|
zIndex: 30,
|
|
106
104
|
},
|
|
107
|
-
toggleSwitchContainer: { width: '90%', height: 40 },
|
|
108
|
-
toggle: { width: '54%', height: 38, borderRadius: 13 },
|
|
109
105
|
});
|
|
110
106
|
export default MyTeamTicketListScreen;
|
|
111
107
|
//# sourceMappingURL=MyTeamTicketListScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MyTeamTicketListScreen.js","sourceRoot":"","sources":["../../src/screens/MyTeamTicketListScreen.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AACvE,OAAO,EAAC,UAAU,EAAE,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAC1D,OAAO,EACL,MAAM,EACN,eAAe,EACf,UAAU,EACV,gBAAgB,EAChB,aAAa,EACb,UAAU,G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AAS,CAAC,CAAC,eAAe,CAAC,CAC3B,WAAW,CAAC,CAAC,uBAAuB,CAAC,CACrC,SAAS,CAAC,CAAC,qBAAqB,CAAC,CACjC,UAAU,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAEvB;IAAA,EAAE,MAAM,CAAC,CACV,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,IAAI,EAAE;QACJ,gBAAgB,EAAE,EAAE;QACpB,cAAc,EAAE,CAAC;KAClB;IACD,eAAe,EAAE;QACf,UAAU,EAAE,QAAQ;QACpB,MAAM,EAAE,EAAE;KACX;CACF,CAAC,CAAC;AAEH,eAAe,sBAAsB,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -19,23 +19,23 @@ import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
|
19
19
|
import { Dimensions, StyleSheet, View } from 'react-native';
|
|
20
20
|
import { Screen, HeaderContainer, ScrollList, MultiValuePicker, useThemeColor, ChipSelect, } from '@axelor/aos-mobile-ui';
|
|
21
21
|
import { useDispatch, useSelector, useTranslator, filterChip, } from '@axelor/aos-mobile-core';
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
22
|
+
import { fetchMyTickets, fetchTicketType } from '../features/ticketSlice';
|
|
23
|
+
import { MyTicketSearchBar, TicketCard } from '../components';
|
|
24
24
|
import { Ticket } from '../types';
|
|
25
25
|
const MyTicketListScreen = ({ navigation }) => {
|
|
26
26
|
const I18n = useTranslator();
|
|
27
27
|
const dispatch = useDispatch();
|
|
28
28
|
const Colors = useThemeColor();
|
|
29
29
|
const { userId } = useSelector(state => state.auth);
|
|
30
|
-
const { ticketList,
|
|
30
|
+
const { ticketList, loadingTicketList, moreLoading, isListEnd, ticketTypeList, } = useSelector(state => state.ticket);
|
|
31
31
|
const [selectedType, setSelectedType] = useState([]);
|
|
32
32
|
const [selectedStatus, setSelectedStatus] = useState([]);
|
|
33
33
|
const [priorityStatus, setPriorityStatus] = useState(Ticket.getPriorityList(Colors, I18n).filter(e => e.isActive === true));
|
|
34
34
|
useEffect(() => {
|
|
35
35
|
dispatch(fetchTicketType());
|
|
36
36
|
}, [dispatch]);
|
|
37
|
-
const
|
|
38
|
-
dispatch(
|
|
37
|
+
const fetchMyTicketsAPI = useCallback((page = 0) => {
|
|
38
|
+
dispatch(fetchMyTickets({ userId: userId, page: page }));
|
|
39
39
|
}, [dispatch, userId]);
|
|
40
40
|
const ticketTypeListItems = useMemo(() => {
|
|
41
41
|
return ticketTypeList
|
|
@@ -52,8 +52,8 @@ const MyTicketListScreen = ({ navigation }) => {
|
|
|
52
52
|
return Ticket.getStatusList(Colors, I18n);
|
|
53
53
|
}, [Colors, I18n]);
|
|
54
54
|
const filterOnType = useCallback(list => {
|
|
55
|
-
if (list
|
|
56
|
-
return
|
|
55
|
+
if (!Array.isArray(list) || list.length === 0) {
|
|
56
|
+
return [];
|
|
57
57
|
}
|
|
58
58
|
else {
|
|
59
59
|
if (selectedType.length > 0) {
|
|
@@ -65,8 +65,8 @@ const MyTicketListScreen = ({ navigation }) => {
|
|
|
65
65
|
}
|
|
66
66
|
}, [selectedType]);
|
|
67
67
|
const filterOnStatus = useCallback(list => {
|
|
68
|
-
if (list
|
|
69
|
-
return
|
|
68
|
+
if (!Array.isArray(list) || list.length === 0) {
|
|
69
|
+
return [];
|
|
70
70
|
}
|
|
71
71
|
else {
|
|
72
72
|
if (selectedStatus.length > 0) {
|
|
@@ -82,17 +82,15 @@ const MyTicketListScreen = ({ navigation }) => {
|
|
|
82
82
|
}, [priorityStatus]);
|
|
83
83
|
const filteredList = useMemo(() => filterOnStatus(filterOnType(filterOnPriority(ticketList))), [ticketList, filterOnType, filterOnStatus, filterOnPriority]);
|
|
84
84
|
return (<Screen removeSpaceOnTop={true}>
|
|
85
|
-
<HeaderContainer expandableFilter={true} fixedItems={<
|
|
86
|
-
<TicketSearchBar showDetailsPopup={false} oneFilter={true} placeholderKey={I18n.t('Helpdesk_Ticket')}/>
|
|
87
|
-
</View>} chipComponent={<ChipSelect mode="multi" marginHorizontal={4} width={Dimensions.get('window').width * 0.3} onChangeValue={chiplist => setPriorityStatus(chiplist)} selectionItems={Ticket.getPriorityList(Colors, I18n)}/>}>
|
|
85
|
+
<HeaderContainer expandableFilter={true} fixedItems={<MyTicketSearchBar showDetailsPopup={false} oneFilter={true} placeholderKey={I18n.t('Helpdesk_Ticket')}/>} chipComponent={<ChipSelect mode="multi" marginHorizontal={4} width={Dimensions.get('window').width * 0.3} onChangeValue={chiplist => setPriorityStatus(chiplist)} selectionItems={Ticket.getPriorityList(Colors, I18n)}/>}>
|
|
88
86
|
<View style={styles.headerContainer}>
|
|
89
87
|
<MultiValuePicker listItems={ticketStatusListItems} title={I18n.t('Helpdesk_Status')} onValueChange={statusList => setSelectedStatus(statusList)}/>
|
|
90
88
|
<MultiValuePicker listItems={ticketTypeListItems} title={I18n.t('Helpdesk_Type')} onValueChange={typeList => setSelectedType(typeList)}/>
|
|
91
89
|
</View>
|
|
92
90
|
</HeaderContainer>
|
|
93
|
-
<ScrollList loadingList={
|
|
91
|
+
<ScrollList loadingList={loadingTicketList} data={filteredList} renderItem={({ item }) => (<TicketCard style={styles.item} ticketSeq={item.ticketSeq} subject={item.subject} progressSelect={item.progressSelect} ticketType={item.ticketType} statusSelect={item.statusSelect} deadlineDateT={item.deadlineDateT} responsibleUser={item?.responsibleUser?.fullName} prioritySelect={item.prioritySelect} duration={item.duration} allTicketType={ticketTypeList} onPress={() => navigation.navigate('TicketDetailsScreen', {
|
|
94
92
|
idTicket: item.id,
|
|
95
|
-
})}/>)} fetchData={
|
|
93
|
+
})}/>)} fetchData={fetchMyTicketsAPI} moreLoading={moreLoading} isListEnd={isListEnd} translator={I18n.t}/>
|
|
96
94
|
</Screen>);
|
|
97
95
|
};
|
|
98
96
|
const styles = StyleSheet.create({
|
|
@@ -104,8 +102,6 @@ const styles = StyleSheet.create({
|
|
|
104
102
|
alignItems: 'center',
|
|
105
103
|
zIndex: 30,
|
|
106
104
|
},
|
|
107
|
-
toggleSwitchContainer: { width: '90%', height: 40 },
|
|
108
|
-
toggle: { width: '54%', height: 38, borderRadius: 13 },
|
|
109
105
|
});
|
|
110
106
|
export default MyTicketListScreen;
|
|
111
107
|
//# sourceMappingURL=MyTicketListScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MyTicketListScreen.js","sourceRoot":"","sources":["../../src/screens/MyTicketListScreen.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AACvE,OAAO,EAAC,UAAU,EAAE,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc,CAAC;AAC1D,OAAO,EACL,MAAM,EACN,eAAe,EACf,UAAU,EACV,gBAAgB,EAChB,aAAa,EACb,UAAU,GACX,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,WAAW,EACX,WAAW,EACX,aAAa,EACb,UAAU,GACX,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAC,
|
|
1
|
+
{"version":3,"file":"MyTicketListScreen.js","sourceRoot":"","sources":["../../src/screens/MyTicketListScreen.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAC,MAAM,OAAO,CAAC;AACvE,OAAO,EAAC,UAAU,EAAE,UAAU,EAAE,IAAI,EAAC,MAAM,cAAc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
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
|
@@ -17,10 +17,12 @@
|
|
|
17
17
|
*/
|
|
18
18
|
import React, { useCallback, useMemo, useEffect } from 'react';
|
|
19
19
|
import { useSelector, useDispatch, FormView } from '@axelor/aos-mobile-core';
|
|
20
|
+
import { useThemeColor } from '@axelor/aos-mobile-ui';
|
|
20
21
|
import { createTicket, updateTicket } from '../features/ticketSlice';
|
|
21
22
|
import { getCustomerbyId } from '../features/customerSlice';
|
|
22
23
|
const TicketFormScreen = ({ navigation, route }) => {
|
|
23
24
|
const idTicket = route?.params?.idTicket;
|
|
25
|
+
const Colors = useThemeColor();
|
|
24
26
|
const _dispatch = useDispatch();
|
|
25
27
|
const { ticket } = useSelector(state => state.ticket);
|
|
26
28
|
const defaultValue = useMemo(() => {
|
|
@@ -63,6 +65,12 @@ const TicketFormScreen = ({ navigation, route }) => {
|
|
|
63
65
|
handleReset();
|
|
64
66
|
},
|
|
65
67
|
},
|
|
68
|
+
{
|
|
69
|
+
color: Colors.cautionColor,
|
|
70
|
+
key: 'reset-ticket',
|
|
71
|
+
type: 'reset',
|
|
72
|
+
hideIf: () => idTicket != null,
|
|
73
|
+
},
|
|
66
74
|
{
|
|
67
75
|
key: 'update-ticket',
|
|
68
76
|
type: 'update',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TicketFormScreen.js","sourceRoot":"","sources":["../../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G,EAAE,CAAC,QAAQ,IAAI,IAAI;gBAC9B,YAAY,EAAE,CAAC,EAAC,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAC,EAAE,EAAE;oBACrD,eAAe,CAAC,WAAW,EAAE,QAAQ,CAAC,CAAC;oBACvC,WAAW,EAAE,CAAC;gBAChB,CAAC;aACF;YACD;gBACE,KAAK,EAAE,MAAM,CAAC,YAAY;gBAC1B,GAAG,EAAE,cAAc;gBACnB,IAAI,EAAE,OAAO;gBACb,MAAM,EAAE,GAAG,EAAE,CAAC,QAAQ,IAAI,IAAI;aAC/B;YACD;gBACE,GAAG,EAAE,eAAe;gBACpB,IAAI,EAAE,QAAQ;gBACd,cAAc,EAAE,IAAI;gBACpB,kBAAkB,EAAE,IAAI;gBACxB,MAAM,EAAE,GAAG,EAAE,CAAC,QAAQ,IAAI,IAAI;gBAC9B,YAAY,EAAE,CAAC,EAAC,QAAQ,EAAE,WAAW,EAAC,EAAE,EAAE;oBACxC,eAAe,CAAC,WAAW,EAAE,QAAQ,CAAC,CAAC;gBACzC,CAAC;aACF;SACF,CAAC,EACF,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
package/lib/screens/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/types/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/types/ticket.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/utils/displayers.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/lib/utils/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Axelor Business Solutions
|
|
3
3
|
*
|
|
4
|
-
* Copyright (C)
|
|
4
|
+
* Copyright (C) 2024 Axelor (<http://axelor.com>).
|
|
5
5
|
*
|
|
6
6
|
* This program is free software: you can redistribute it and/or modify
|
|
7
7
|
* it under the terms of the GNU Affero General Public License, version 3,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axelor/aos-mobile-helpdesk",
|
|
3
|
-
"version": "7.2.
|
|
3
|
+
"version": "7.2.5",
|
|
4
4
|
"author": "Axelor",
|
|
5
5
|
"license": "AGPL-3.0-only",
|
|
6
6
|
"publishConfig": {
|
|
@@ -28,8 +28,8 @@
|
|
|
28
28
|
"react-i18next": "^11.18.6"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@axelor/aos-mobile-core": "7.2.
|
|
32
|
-
"@axelor/aos-mobile-ui": "7.2.
|
|
31
|
+
"@axelor/aos-mobile-core": "7.2.5",
|
|
32
|
+
"@axelor/aos-mobile-ui": "7.2.5",
|
|
33
33
|
"@reduxjs/toolkit": "^1.8.5"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TicketSearchBar.js","sourceRoot":"","sources":["../../../../src/components/templates/TicketSearchBar/TicketSearchBar.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,EAAC,WAAW,EAAC,MAAM,OAAO,CAAC;AACzC,OAAO,EAAC,WAAW,EAAE,WAAW,EAAE,aAAa,EAAC,MAAM,yBAAyB,CAAC;AAChF,OAAO,EAAC,kBAAkB,EAAC,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAC,YAAY,EAAC,MAAM,+BAA+B,CAAC;AAE3D,MAAM,eAAe,GAAG,CAAC,EACvB,cAAc,GAAG,iBAAiB,EAClC,YAAY,GAAG,EAAE,EACjB,QAAQ,GAAG,GAAG,EAAE,GAAE,CAAC,EACnB,gBAAgB,GAAG,IAAI,EACvB,QAAQ,GAAG,KAAK,EAChB,SAAS,GAAG,KAAK,EACjB,OAAO,GAAG,KAAK,EACf,IAAI,GAAG,KAAK,GACb,EAAE,EAAE;IACH,MAAM,IAAI,GAAG,aAAa,EAAE,CAAC;IAC7B,MAAM,QAAQ,GAAG,WAAW,EAAE,CAAC;IAE/B,MAAM,oBAAoB,GAAG,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,SAAS,CAAC;IAEpD,MAAM,EAAC,UAAU,EAAE,aAAa,EAAE,WAAW,EAAE,SAAS,EAAC,GAAG,WAAW,CACrE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,MAAM,CACtB,CAAC;IACF,MAAM,EAAC,IAAI,EAAC,GAAG,WAAW,CAAC,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAEhD,MAAM,uBAA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