@@ -68,29 +68,29 @@ const deleteResourceChartImage: any = graphql(`
6868 }
6969` ) ;
7070
71- const AddResourceChartImage : any = graphql ( `
72- mutation GenerateResourceChartImage($dataset: UUID!) {
73- addResourceChartImage(dataset: $dataset) {
74- __typename
75- ... on TypeResourceChartImage {
76- id
77- name
78- }
79- }
80- }
81- ` ) ;
71+ // const AddResourceChartImage: any = graphql(`
72+ // mutation GenerateResourceChartImage($dataset: UUID!) {
73+ // addResourceChartImage(dataset: $dataset) {
74+ // __typename
75+ // ... on TypeResourceChartImage {
76+ // id
77+ // name
78+ // }
79+ // }
80+ // }
81+ // `);
8282
83- const AddResourceChart : any = graphql ( `
84- mutation GenerateResourceChart($resource: UUID!) {
85- addResourceChart(resource: $resource) {
86- __typename
87- ... on TypeResourceChart {
88- id
89- name
90- }
91- }
92- }
93- ` ) ;
83+ // const AddResourceChart: any = graphql(`
84+ // mutation GenerateResourceChart($resource: UUID!) {
85+ // addResourceChart(resource: $resource) {
86+ // __typename
87+ // ... on TypeResourceChart {
88+ // id
89+ // name
90+ // }
91+ // }
92+ // }
93+ // `);
9494
9595// const datasetResourceList: any = graphql(`
9696// query all_resources($datasetId: UUID!) {
@@ -184,32 +184,32 @@ const ChartsList: React.FC<ChartsListProps> = ({
184184 }
185185 ) ;
186186
187- const resourceChartImageMutation : {
188- mutate : any ;
189- isLoading : any ;
190- } = useMutation (
191- ( data : { dataset : UUID } ) =>
192- GraphQL (
193- AddResourceChartImage ,
194- {
195- [ params . entityType ] : params . entitySlug ,
196- } ,
197- data
198- ) ,
199- {
200- onSuccess : ( res : any ) => {
201- toast ( 'Resource ChartImage Created Successfully' ) ;
202- chartListRes . refetch ( ) ;
203- setType ( 'img' ) ;
204- setImageId ( res . addResourceChartImage . id ) ;
187+ // const resourceChartImageMutation: {
188+ // mutate: any;
189+ // isLoading: any;
190+ // } = useMutation(
191+ // (data: { dataset: UUID }) =>
192+ // GraphQL(
193+ // AddResourceChartImage,
194+ // {
195+ // [params.entityType]: params.entitySlug,
196+ // },
197+ // data
198+ // ),
199+ // {
200+ // onSuccess: (res: any) => {
201+ // toast('Resource ChartImage Created Successfully');
202+ // chartListRes.refetch();
203+ // setType('img');
204+ // setImageId(res.addResourceChartImage.id);
205205
206- // setImageId(res.id);
207- } ,
208- onError : ( err : any ) => {
209- toast ( `Received ${ err } while deleting chart ` ) ;
210- } ,
211- }
212- ) ;
206+ // // setImageId(res.id);
207+ // },
208+ // onError: (err: any) => {
209+ // toast(`Received ${err} while deleting chart `);
210+ // },
211+ // }
212+ // );
213213
214214 // AddResourceImage
215215
@@ -223,32 +223,32 @@ const ChartsList: React.FC<ChartsListProps> = ({
223223 // )
224224 // );
225225
226- const resourceChart : {
227- mutate : any ;
228- isLoading : any ;
229- } = useMutation (
230- ( data : { resource : UUID } ) =>
231- GraphQL (
232- AddResourceChart ,
233- {
234- [ params . entityType ] : params . entitySlug ,
235- } ,
236- data
237- ) ,
238- {
239- onSuccess : ( res : any ) => {
240- toast ( 'Resource Chart Created Successfully' ) ;
241- chartListRes . refetch ( ) ;
242- setType ( 'visualize' ) ;
243- setChartId ( res . addResourceChart . id ) ;
226+ // const resourceChart: {
227+ // mutate: any;
228+ // isLoading: any;
229+ // } = useMutation(
230+ // (data: { resource: UUID }) =>
231+ // GraphQL(
232+ // AddResourceChart,
233+ // {
234+ // [params.entityType]: params.entitySlug,
235+ // },
236+ // data
237+ // ),
238+ // {
239+ // onSuccess: (res: any) => {
240+ // toast('Resource Chart Created Successfully');
241+ // chartListRes.refetch();
242+ // setType('visualize');
243+ // setChartId(res.addResourceChart.id);
244244
245- // setImageId(res.id);
246- } ,
247- onError : ( err : any ) => {
248- toast ( `Received ${ err } while deleting chart ` ) ;
249- } ,
250- }
251- ) ;
245+ // // setImageId(res.id);
246+ // },
247+ // onError: (err: any) => {
248+ // toast(`Received ${err} while deleting chart `);
249+ // },
250+ // }
251+ // );
252252
253253 const handleChart = ( row : any ) => {
254254 if ( row . original . typename === 'TypeResourceChart' ) {
0 commit comments