muba-posting 4.1.13 → 4.1.16
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/.expo/README.md +15 -0
- package/.expo/packager-info.json +5 -0
- package/.expo/settings.json +9 -0
- package/Posting.js +4 -1
- package/Publish5.js +58 -0
- package/assets/images/animals-hover.png +0 -0
- package/assets/images/animals.png +0 -0
- package/assets/images/exteriorFacade-hover.png +0 -0
- package/assets/images/exteriorFacade.png +0 -0
- package/assets/images/orientation-hover.png +0 -0
- package/assets/images/orientation.png +0 -0
- package/locales/ar.json +6 -1
- package/locales/en.json +6 -1
- package/locales/es.json +6 -1
- package/locales/fr.json +6 -1
- package/locales/it.json +6 -1
- package/locales/nl.json +6 -1
- package/package.json +1 -1
package/.expo/README.md
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
> Why do I have a folder named ".expo" in my project?
|
|
2
|
+
|
|
3
|
+
The ".expo" folder is created when an Expo project is started using "expo start" command.
|
|
4
|
+
|
|
5
|
+
> What do the files contain?
|
|
6
|
+
|
|
7
|
+
- "devices.json": contains information about devices that have recently opened this project. This is used to populate the "Development sessions" list in your development builds.
|
|
8
|
+
- "packager-info.json": contains port numbers and process PIDs that are used to serve the application to the mobile device/simulator.
|
|
9
|
+
- "settings.json": contains the server configuration that is used to serve the application manifest.
|
|
10
|
+
|
|
11
|
+
> Should I commit the ".expo" folder?
|
|
12
|
+
|
|
13
|
+
No, you should not share the ".expo" folder. It does not contain any information that is relevant for other developers working on the project, it is specific to your machine.
|
|
14
|
+
|
|
15
|
+
Upon project creation, the ".expo" folder is already added to your ".gitignore" file.
|
package/Posting.js
CHANGED
|
@@ -90,6 +90,7 @@ export default class Posting extends React.Component {
|
|
|
90
90
|
age: null,
|
|
91
91
|
floorType: null,
|
|
92
92
|
floorNumber: null,
|
|
93
|
+
orientation: null,
|
|
93
94
|
garden: false,
|
|
94
95
|
terrace: false,
|
|
95
96
|
garage: false,
|
|
@@ -116,6 +117,8 @@ export default class Posting extends React.Component {
|
|
|
116
117
|
washer: false,
|
|
117
118
|
microwave: false,
|
|
118
119
|
internet: false,
|
|
120
|
+
exteriorFacade: false,
|
|
121
|
+
animals: false,
|
|
119
122
|
phones: this.props.phones ? this.props.phones.includes('###') ? this.props.phones.split('###') : Array.isArray(this.props.phones) ? this.props.phones : [this.props.phones] : [],
|
|
120
123
|
reference: null,
|
|
121
124
|
id: null,
|
|
@@ -275,7 +278,7 @@ export default class Posting extends React.Component {
|
|
|
275
278
|
const response = await this.props.request(this, CREATE_AD, this.state.postingAd);
|
|
276
279
|
if (response.httpStatus === 200) {
|
|
277
280
|
await this.setState({
|
|
278
|
-
postingAd: { ...this.state.postingAd, id: response.
|
|
281
|
+
postingAd: { ...this.state.postingAd, id: response.id }
|
|
279
282
|
})
|
|
280
283
|
}
|
|
281
284
|
}
|
package/Publish5.js
CHANGED
|
@@ -4,6 +4,7 @@ import { strings } from 'muba-i18n';
|
|
|
4
4
|
import commonStyles from './commonStyles';
|
|
5
5
|
import InputSelect from 'muba-input-select';
|
|
6
6
|
import { Views } from './utils/Views';
|
|
7
|
+
import { Orientation } from 'expo-screen-orientation';
|
|
7
8
|
const window = Dimensions.get('window');
|
|
8
9
|
|
|
9
10
|
export default class Publish5 extends React.Component {
|
|
@@ -13,12 +14,14 @@ export default class Publish5 extends React.Component {
|
|
|
13
14
|
const age = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "age" });
|
|
14
15
|
const floorType = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "floorType" });
|
|
15
16
|
const floorNumber = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "floorNumber" });
|
|
17
|
+
const orientationType = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "orientation" });
|
|
16
18
|
|
|
17
19
|
this.state = {
|
|
18
20
|
isLoading: false,
|
|
19
21
|
age: age,
|
|
20
22
|
floorType: floorType,
|
|
21
23
|
floorNumber: floorNumber,
|
|
24
|
+
orientation: orientationType,
|
|
22
25
|
ageOptions: {
|
|
23
26
|
elements:
|
|
24
27
|
[
|
|
@@ -77,6 +80,17 @@ export default class Publish5 extends React.Component {
|
|
|
77
80
|
subCategoryDetails: this.props.postingAd.subCategoryDetails,
|
|
78
81
|
viewLoaded: false
|
|
79
82
|
},
|
|
83
|
+
orientationOptions: {
|
|
84
|
+
elements:
|
|
85
|
+
[
|
|
86
|
+
{ section: true, value: null, label: orientationType[0] ? orientationType[0].label : 'orientation' },
|
|
87
|
+
{ label: strings('setup.north'), value: 'NORTH' },
|
|
88
|
+
{ label: strings('setup.west'), value: 'WEST' },
|
|
89
|
+
{ label: strings('setup.est'), value: 'EST' },
|
|
90
|
+
{ label: strings('setup.south'), value: 'SOUTH' }
|
|
91
|
+
],
|
|
92
|
+
selectedItem: this.props.postingAd.orientation
|
|
93
|
+
},
|
|
80
94
|
}
|
|
81
95
|
}
|
|
82
96
|
|
|
@@ -99,11 +113,13 @@ export default class Publish5 extends React.Component {
|
|
|
99
113
|
const age = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "age" });
|
|
100
114
|
const floorType = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "floorType" });
|
|
101
115
|
const floorNumber = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "floorNumber" });
|
|
116
|
+
const orientationType = this.props.postingAd.subCategoryDetails.filter(function (detail) { return detail.value == "orientation" });
|
|
102
117
|
|
|
103
118
|
await this.setState({
|
|
104
119
|
age: age,
|
|
105
120
|
floorType: floorType,
|
|
106
121
|
floorNumber: floorNumber,
|
|
122
|
+
orientation: orientationType,
|
|
107
123
|
subCategory: this.props.postingAd.subCategory,
|
|
108
124
|
subCategoryDetails: this.props.postingAd.subCategoryDetails,
|
|
109
125
|
ageOptions: {
|
|
@@ -117,6 +133,10 @@ export default class Publish5 extends React.Component {
|
|
|
117
133
|
floorNumberOptions: {
|
|
118
134
|
elements: [{ section: true, value: null, label: floorNumber[0]?.label }, ...this.state.floorNumberOptions.elements.slice(1)],
|
|
119
135
|
selectedItem: this.props.postingAd.floorNumber + ''
|
|
136
|
+
},
|
|
137
|
+
orientationOptions: {
|
|
138
|
+
elements: [{ section: true, value: null, label: orientationType[0]?.label }, ...this.state.orientationOptions.elements.slice(1)],
|
|
139
|
+
selectedItem: this.props.postingAd.orientation + ''
|
|
120
140
|
}
|
|
121
141
|
});
|
|
122
142
|
}
|
|
@@ -147,6 +167,10 @@ export default class Publish5 extends React.Component {
|
|
|
147
167
|
validate = this.inputSelectFloorNumber.onSubmitValidate() && validate;
|
|
148
168
|
}
|
|
149
169
|
|
|
170
|
+
if (this.state.orientation.length > 0) {
|
|
171
|
+
validate = this.inputSelectOrientation.onSubmitValidate() && validate;
|
|
172
|
+
}
|
|
173
|
+
|
|
150
174
|
return validate;
|
|
151
175
|
}
|
|
152
176
|
|
|
@@ -210,6 +234,22 @@ export default class Publish5 extends React.Component {
|
|
|
210
234
|
:
|
|
211
235
|
null
|
|
212
236
|
}
|
|
237
|
+
{this.state.orientation.length > 0 ?
|
|
238
|
+
<View style={[commonStyles.col, commonStyles.col6, commonStyles.selectPublish]}>
|
|
239
|
+
<InputSelect
|
|
240
|
+
options={this.state.orientationOptions}
|
|
241
|
+
placeholder={strings('setup.select')}
|
|
242
|
+
required={false}
|
|
243
|
+
scroll={(ref) => this.props.scroll(ref)}
|
|
244
|
+
label={this.state.orientation[0].label}
|
|
245
|
+
labelStyle={commonStyles.progressbarField}
|
|
246
|
+
selectStyle={commonStyles.inputSelect}
|
|
247
|
+
onChange={(value) => this.props.postingAd.orientation = value}
|
|
248
|
+
ref={(element) => this.inputSelectOrientation = element} />
|
|
249
|
+
</View>
|
|
250
|
+
:
|
|
251
|
+
null
|
|
252
|
+
}
|
|
213
253
|
</View>
|
|
214
254
|
</View>
|
|
215
255
|
|
|
@@ -306,6 +346,14 @@ export default class Publish5 extends React.Component {
|
|
|
306
346
|
selected={this.props.postingAd.furnished}
|
|
307
347
|
onPress={(value) => this.props.postingAd.furnished = value}
|
|
308
348
|
ref={(element) => this.inputFurnished = element} />
|
|
349
|
+
<IconFeatures
|
|
350
|
+
iconSource={require('./assets/images/exteriorFacade.png')}
|
|
351
|
+
iconHoverSource={require('./assets/images/exteriorFacade-hover.png')}
|
|
352
|
+
iconText={this.state.subCategoryDetails.filter(function (detail) { return detail.value == "exteriorFacade" })[0]?.label}
|
|
353
|
+
visible={this.state.subCategoryDetails.filter(function (detail) { return detail.value == "exteriorFacade" }).length > 0}
|
|
354
|
+
selected={this.props.postingAd.exteriorFacade}
|
|
355
|
+
onPress={(value) => this.props.postingAd.exteriorFacade = value}
|
|
356
|
+
ref={(element) => this.inputExteriorFacade = element} />
|
|
309
357
|
</View>
|
|
310
358
|
|
|
311
359
|
<Text style={commonStyles.progressbarFieldH4}>{strings('setup.inside').toUpperCase()}</Text>
|
|
@@ -458,6 +506,16 @@ export default class Publish5 extends React.Component {
|
|
|
458
506
|
selected={this.props.postingAd.internet}
|
|
459
507
|
onPress={(value) => this.props.postingAd.internet = value}
|
|
460
508
|
ref={(element) => this.inputInternet = element} />
|
|
509
|
+
|
|
510
|
+
|
|
511
|
+
<IconFeatures
|
|
512
|
+
iconSource={require('./assets/images/animals.png')}
|
|
513
|
+
iconHoverSource={require('./assets/images/animals-hover.png')}
|
|
514
|
+
iconText={this.state.subCategoryDetails.filter(function (detail) { return detail.value == "animals" })[0]?.label}
|
|
515
|
+
visible={this.state.subCategoryDetails.filter(function (detail) { return detail.value == "animals" }).length > 0}
|
|
516
|
+
selected={this.props.postingAd.animals}
|
|
517
|
+
onPress={(value) => this.props.postingAd.animals = value}
|
|
518
|
+
ref={(element) => this.inputAnimals = element} />
|
|
461
519
|
</View>
|
|
462
520
|
</View>
|
|
463
521
|
</View>
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/locales/ar.json
CHANGED
|
@@ -111,7 +111,12 @@
|
|
|
111
111
|
"contactOwner": "اتصل بالناشر",
|
|
112
112
|
"allPicturesSelected": "لقد قمت بتحديد جميع الصور",
|
|
113
113
|
"selected": "المختار(ة)",
|
|
114
|
-
"max": "(كحد أقصى)"
|
|
114
|
+
"max": "(كحد أقصى)",
|
|
115
|
+
"orientation": "اتجاه",
|
|
116
|
+
"north": "شمال",
|
|
117
|
+
"south": "جنوب",
|
|
118
|
+
"west": "الغرب",
|
|
119
|
+
"est": "شرق"
|
|
115
120
|
},
|
|
116
121
|
"product": {
|
|
117
122
|
"LISTING": "قوائم",
|
package/locales/en.json
CHANGED
|
@@ -111,7 +111,12 @@
|
|
|
111
111
|
"contactOwner": "Price on request",
|
|
112
112
|
"allPicturesSelected": "You have already selected all the photos",
|
|
113
113
|
"selected": "Selected",
|
|
114
|
-
"max": "(max)"
|
|
114
|
+
"max": "(max)",
|
|
115
|
+
"orientation": "Orientation",
|
|
116
|
+
"north": "North",
|
|
117
|
+
"south": "South",
|
|
118
|
+
"west": "West",
|
|
119
|
+
"est": "Est"
|
|
115
120
|
},
|
|
116
121
|
"product": {
|
|
117
122
|
"LISTING": "Listing",
|
package/locales/es.json
CHANGED
|
@@ -111,7 +111,12 @@
|
|
|
111
111
|
"contactOwner": "Precio a consultar",
|
|
112
112
|
"allPicturesSelected": "Ya has seleccionado todas las fotos",
|
|
113
113
|
"selected": "Seleccionado",
|
|
114
|
-
"max": "(max)"
|
|
114
|
+
"max": "(max)",
|
|
115
|
+
"orientation": "Orientación",
|
|
116
|
+
"north": "Norte",
|
|
117
|
+
"south": "Sur",
|
|
118
|
+
"west": "Oeste",
|
|
119
|
+
"est": "Este"
|
|
115
120
|
},
|
|
116
121
|
"product": {
|
|
117
122
|
"LISTING": "Listing",
|
package/locales/fr.json
CHANGED
|
@@ -111,7 +111,12 @@
|
|
|
111
111
|
"contactOwner": "Prix à consulter",
|
|
112
112
|
"allPicturesSelected": "Vous avez déjà sélectionné toutes les photos",
|
|
113
113
|
"selected": "Sélectionné(s)",
|
|
114
|
-
"max": "(max)"
|
|
114
|
+
"max": "(max)",
|
|
115
|
+
"orientation": "Orientation",
|
|
116
|
+
"north": "Nord",
|
|
117
|
+
"south": "South",
|
|
118
|
+
"west": "Ouest",
|
|
119
|
+
"est": "Est"
|
|
115
120
|
},
|
|
116
121
|
"product": {
|
|
117
122
|
"LISTING": "Liste",
|
package/locales/it.json
CHANGED
|
@@ -111,7 +111,12 @@
|
|
|
111
111
|
"contactOwner": "Prezzo su richiesta",
|
|
112
112
|
"allPicturesSelected": "Hai già selezionato tutte le foto",
|
|
113
113
|
"selected": "Selezionato",
|
|
114
|
-
"max": "(max)"
|
|
114
|
+
"max": "(max)",
|
|
115
|
+
"orientation": "Orientamento",
|
|
116
|
+
"north": "Nord",
|
|
117
|
+
"south": "Sud",
|
|
118
|
+
"west": "Ovest",
|
|
119
|
+
"est": "Est"
|
|
115
120
|
},
|
|
116
121
|
"product": {
|
|
117
122
|
"LISTING": "Inserzioni",
|
package/locales/nl.json
CHANGED
|
@@ -111,7 +111,12 @@
|
|
|
111
111
|
"contactOwner": "Prijs op aanvraag",
|
|
112
112
|
"allPicturesSelected": "U hebt alle foto's al geselecteerd",
|
|
113
113
|
"selected": "Geselecteerd",
|
|
114
|
-
"max": "(max)"
|
|
114
|
+
"max": "(max)",
|
|
115
|
+
"orientation": "Oriëntatie",
|
|
116
|
+
"north": "North",
|
|
117
|
+
"south": "Zuid",
|
|
118
|
+
"west": "Oost",
|
|
119
|
+
"est": "North"
|
|
115
120
|
},
|
|
116
121
|
"product": {
|
|
117
122
|
"LISTING": "Advertenties",
|