|
@@ -385,12 +385,16 @@ function Search({route, navigation }) {
|
385
|
385
|
//is not searching for anything yet
|
386
|
386
|
// console.log(tags.length)
|
387
|
387
|
// console.log(city.id)
|
|
388
|
+
|
|
389
|
+ const users = []
|
388
|
390
|
if (tags.length === 0 && (typeof city.id ==="undefined" || city.id === -1)) {
|
|
391
|
+
|
|
392
|
+ setUsers(users)
|
389
|
393
|
return
|
390
|
394
|
}
|
391
|
395
|
|
392
|
396
|
//reset the users usestate to empty
|
393
|
|
- const users = []
|
|
397
|
+
|
394
|
398
|
|
395
|
399
|
|
396
|
400
|
const db = firebase.firestore()
|
|
@@ -770,12 +774,12 @@ function Search({route, navigation }) {
|
770
|
774
|
<ScrollView>
|
771
|
775
|
<View style={{ margin: 30 }}>
|
772
|
776
|
<View style={{ width: '100%', alignItems: 'center' }}>
|
773
|
|
- <Text style={{ fontSize: 30, paddingBottom: 20 }}>Search</Text>
|
|
777
|
+ <Text style={{ fontSize: 30, paddingBottom: 20 }}>Busqueda</Text>
|
774
|
778
|
</View>
|
775
|
779
|
|
776
|
|
- <Text style={{ fontSize: 20, paddingBottom: 10 }}>Interpreter city</Text>
|
|
780
|
+ <Text style={{ fontSize: 20, paddingBottom: 10 }}>Pueblo</Text>
|
777
|
781
|
<SelectBox
|
778
|
|
- label="Select single"
|
|
782
|
+ label="Selecciona"
|
779
|
783
|
options={City}
|
780
|
784
|
value={selectedCity}
|
781
|
785
|
onChange={onChange()}
|
|
@@ -786,12 +790,14 @@ function Search({route, navigation }) {
|
786
|
790
|
|
787
|
791
|
|
788
|
792
|
/>
|
789
|
|
- <Text style={{ fontSize: 20, paddingBottom: 10 }}>Interpreter Tags</Text>
|
|
793
|
+
|
|
794
|
+
|
|
795
|
+ <Text style={{ fontSize: 20, paddingBottom: 10, paddingTop:20 }}>Tags de interprete</Text>
|
790
|
796
|
|
791
|
797
|
|
792
|
798
|
|
793
|
799
|
<SelectBox
|
794
|
|
- label="Select multiple"
|
|
800
|
+ label="Selecciona multiple"
|
795
|
801
|
options={Tags}
|
796
|
802
|
selectedValues={selectedTags}
|
797
|
803
|
onMultiSelect={onMultiChange()}
|
|
@@ -817,9 +823,13 @@ function Search({route, navigation }) {
|
817
|
823
|
/>
|
818
|
824
|
|
819
|
825
|
|
|
826
|
+
|
|
827
|
+ <View style={{ width: '100%', paddingTop:40, paddingBottom: 30 }}>
|
820
|
828
|
{/* button that will fetch the users */}
|
821
|
829
|
<Button title='Buscar' onPress={() => fetchUsers(selectedTags, selectedCity)}/>
|
822
|
830
|
|
|
831
|
+ </View>
|
|
832
|
+
|
823
|
833
|
|
824
|
834
|
<FlatList
|
825
|
835
|
numColumns={1}
|