forked from unicef-drp/GeoSight-OS
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
17 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,17 +10,17 @@ | |
* | ||
* __author__ = '[email protected]' | ||
* __date__ = '20/03/2024' | ||
* __copyright__ = ('Copyright 2023, Unicef') | ||
* __copyright__ = ('Copyright 2024, Unicef') | ||
*/ | ||
|
||
import React, {Fragment, useEffect, useState} from 'react'; | ||
import React, { Fragment, useEffect, useState } from 'react'; | ||
|
||
|
||
import {SelectWithSearch} from "../../../../components/Input/SelectWithSearch"; | ||
import { SelectWithSearch } from "../../../../components/Input/SelectWithSearch"; | ||
import WhereInputModal from "../../../../components/SqlQueryGenerator/WhereInputModal"; | ||
import {getRelatedTableFields} from "../../../../utils/relatedTable"; | ||
import {fetchingData} from "../../../../Requests"; | ||
import {dictDeepCopy} from "../../../../utils/main"; | ||
import { getRelatedTableFields } from "../../../../utils/relatedTable"; | ||
import { fetchingData } from "../../../../Requests"; | ||
import { dictDeepCopy } from "../../../../utils/main"; | ||
|
||
|
||
/** | ||
|
@@ -70,10 +70,10 @@ export default function RelatedTableFields( | |
<SelectWithSearch | ||
value={data.latitude} | ||
onChangeFn={evt => { | ||
onSetData({...data, latitude: evt}) | ||
onSetData({ ...data, latitude: evt }) | ||
}} | ||
options={relatedFields.filter(rf => rf.type === 'number').map(rf => rf.name)} | ||
className='FilterInput'/> | ||
className='FilterInput' /> | ||
</div> | ||
</div> | ||
<div className='BasicFormSection'> | ||
|
@@ -82,10 +82,10 @@ export default function RelatedTableFields( | |
<SelectWithSearch | ||
value={data.longitude} | ||
onChangeFn={evt => { | ||
onSetData({...data, longitude: evt}) | ||
onSetData({ ...data, longitude: evt }) | ||
}} | ||
options={relatedFields.filter(rf => rf.type === 'number').map(rf => rf.name)} | ||
className='FilterInput'/> | ||
className='FilterInput' /> | ||
</div> | ||
</div> | ||
<div className='BasicFormSection'> | ||
|
@@ -94,18 +94,18 @@ export default function RelatedTableFields( | |
<SelectWithSearch | ||
value={data.datetime} | ||
onChangeFn={evt => { | ||
onSetData({...data, datetime: evt}) | ||
onSetData({ ...data, datetime: evt }) | ||
}} | ||
options={relatedFields.filter(rf => rf.type === 'date').map(rf => rf.name)} | ||
className='FilterInput'/> | ||
className='FilterInput' /> | ||
</div> | ||
</div> | ||
|
||
<WhereInputModal | ||
value={data.query ? data.query : ''} | ||
fields={relatedFields} | ||
setValue={evt => { | ||
onSetData({...data, query: evt}) | ||
onSetData({ ...data, query: evt }) | ||
}} | ||
title={"Filter the Data"} | ||
/> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,9 +8,9 @@ | |
* the Free Software Foundation; either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* __author__ = '[email protected]' | ||
* __date__ = '13/06/2023' | ||
* __copyright__ = ('Copyright 2023, Unicef') | ||
* __author__ = '[email protected]' | ||
* __date__ = '20/03/2024' | ||
* __copyright__ = ('Copyright 2024, Unicef') | ||
*/ | ||
|
||
import { fetchingData } from "../../../../Requests"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters