@@ -7,7 +7,6 @@ import { StateFetchConfig } from '@/types/redux';
77import {
88 BaseUser ,
99 DBUserRow ,
10- OrgAlertSettings ,
1110 OrgDefaultSyncDaysSettings
1211} from '@/types/resources' ;
1312import { addFetchCasesToReducer } from '@/utils/redux' ;
@@ -80,15 +79,6 @@ export const orgSlice = createSlice({
8079 ( state . members [ action . payload . id ] . is_deleted =
8180 action . payload . is_deleted )
8281 ) ;
83- addFetchCasesToReducer (
84- builder ,
85- getOrgAlertSettings ,
86- 'syncAlertsAsIncidents' ,
87- ( state , action ) => {
88- state . syncAlertsAsIncidents =
89- action . payload . should_sync_alerts_as_incidents ;
90- }
91- ) ;
9282 addFetchCasesToReducer (
9383 builder ,
9484 getDefaultSyncDaysSettings ,
@@ -188,36 +178,6 @@ export const restoreMember = createAsyncThunk(
188178 }
189179) ;
190180
191- export const getOrgAlertSettings = createAsyncThunk (
192- 'org/orgAlertSettings' ,
193- async ( params : { userId : ID ; orgId : ID } ) => {
194- return await handleApi < OrgAlertSettings > (
195- `/internal/${ params . orgId } /alerts_as_incidents` ,
196- {
197- params : {
198- user_id : params . userId
199- }
200- }
201- ) ;
202- }
203- ) ;
204-
205- export const updatedOrgAlertSettings = createAsyncThunk (
206- 'org/orgAlertSettings' ,
207- async ( params : { userId : ID ; orgId : ID ; updatedSetting : boolean } ) => {
208- return await handleApi < OrgAlertSettings > (
209- `/internal/${ params . orgId } /alerts_as_incidents` ,
210- {
211- data : {
212- updated_setting : params . updatedSetting ,
213- user_id : params . userId
214- } ,
215- method : 'PUT'
216- }
217- ) ;
218- }
219- ) ;
220-
221181export const getDefaultSyncDaysSettings = createAsyncThunk (
222182 'org/getDefaultSyncDaysSettings' ,
223183 async ( params : { orgId : ID } ) => {
0 commit comments