@plusscommunities/pluss-maintenance-app 6.0.20 → 6.0.22-beta.0
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/dist/module/actions/JobActions.js +4 -4
- package/dist/module/actions/JobActions.js.map +1 -1
- package/dist/module/actions/index.js +1 -1
- package/dist/module/actions/index.js.map +1 -1
- package/dist/module/actions/types.js +1 -1
- package/dist/module/actions/types.js.map +1 -1
- package/dist/module/apis/index.js +3 -3
- package/dist/module/apis/index.js.map +1 -1
- package/dist/module/apis/maintenanceActions.js +36 -36
- package/dist/module/apis/maintenanceActions.js.map +1 -1
- package/dist/module/apis/userActions.js +5 -5
- package/dist/module/apis/userActions.js.map +1 -1
- package/dist/module/components/FilterPopupMenu.js +49 -49
- package/dist/module/components/FilterPopupMenu.js.map +1 -1
- package/dist/module/components/MaintenanceList.js +38 -38
- package/dist/module/components/MaintenanceList.js.map +1 -1
- package/dist/module/components/MaintenanceListItem.js +62 -62
- package/dist/module/components/MaintenanceListItem.js.map +1 -1
- package/dist/module/components/MaintenanceWidgetItem.js +27 -27
- package/dist/module/components/MaintenanceWidgetItem.js.map +1 -1
- package/dist/module/components/PrioritySelectorPopup.js +15 -15
- package/dist/module/components/PrioritySelectorPopup.js.map +1 -1
- package/dist/module/components/StatusSelectorPopup.js +16 -16
- package/dist/module/components/StatusSelectorPopup.js.map +1 -1
- package/dist/module/components/WidgetLarge.js +2 -2
- package/dist/module/components/WidgetLarge.js.map +1 -1
- package/dist/module/components/WidgetSmall.js +19 -19
- package/dist/module/components/WidgetSmall.js.map +1 -1
- package/dist/module/core.config.js +1 -1
- package/dist/module/core.config.js.map +1 -1
- package/dist/module/feature.config.js +17 -17
- package/dist/module/feature.config.js.map +1 -1
- package/dist/module/helper.js +10 -10
- package/dist/module/helper.js.map +1 -1
- package/dist/module/index.js +11 -11
- package/dist/module/index.js.map +1 -1
- package/dist/module/reducers/JobsReducer.js +13 -13
- package/dist/module/reducers/JobsReducer.js.map +1 -1
- package/dist/module/screens/JobTypePicker.js +17 -17
- package/dist/module/screens/JobTypePicker.js.map +1 -1
- package/dist/module/screens/MaintenancePage.js +10 -10
- package/dist/module/screens/MaintenancePage.js.map +1 -1
- package/dist/module/screens/MaintenanceUserPicker.js +129 -22
- package/dist/module/screens/MaintenanceUserPicker.js.map +1 -1
- package/dist/module/screens/RequestDetail.js +145 -145
- package/dist/module/screens/RequestDetail.js.map +1 -1
- package/dist/module/screens/RequestNotes.js +59 -59
- package/dist/module/screens/RequestNotes.js.map +1 -1
- package/dist/module/screens/ServiceRequest.js +2 -2
- package/dist/module/screens/ServiceRequest.js.map +1 -1
- package/dist/module/values.config.a.js +30 -30
- package/dist/module/values.config.a.js.map +1 -1
- package/dist/module/values.config.default.js +34 -34
- package/dist/module/values.config.default.js.map +1 -1
- package/dist/module/values.config.enquiry.js +34 -34
- package/dist/module/values.config.enquiry.js.map +1 -1
- package/dist/module/values.config.feedback.js +34 -34
- package/dist/module/values.config.feedback.js.map +1 -1
- package/dist/module/values.config.food.js +34 -34
- package/dist/module/values.config.food.js.map +1 -1
- package/dist/module/values.config.forms.js +34 -34
- package/dist/module/values.config.forms.js.map +1 -1
- package/dist/module/values.config.js +34 -34
- package/dist/module/values.config.js.map +1 -1
- package/package.json +51 -51
- package/src/actions/JobActions.js +67 -60
- package/src/actions/index.js +1 -1
- package/src/actions/types.js +1 -2
- package/src/apis/index.js +3 -3
- package/src/apis/maintenanceActions.js +189 -178
- package/src/apis/userActions.js +17 -17
- package/src/components/FilterPopupMenu.js +313 -256
- package/src/components/MaintenanceList.js +396 -317
- package/src/components/MaintenanceListItem.js +347 -288
- package/src/components/MaintenanceWidgetItem.js +145 -124
- package/src/components/PrioritySelectorPopup.js +81 -68
- package/src/components/StatusSelectorPopup.js +81 -70
- package/src/components/WidgetLarge.js +5 -5
- package/src/components/WidgetSmall.js +153 -133
- package/src/core.config.js +27 -3
- package/src/feature.config.js +62 -62
- package/src/helper.js +58 -53
- package/src/index.js +22 -22
- package/src/reducers/JobsReducer.js +85 -66
- package/src/screens/JobTypePicker.js +115 -92
- package/src/screens/MaintenancePage.js +89 -80
- package/src/screens/MaintenanceUserPicker.js +263 -100
- package/src/screens/RequestDetail.js +1348 -1125
- package/src/screens/RequestNotes.js +950 -806
- package/src/screens/ServiceRequest.js +68 -21
- package/src/values.config.a.js +33 -33
- package/src/values.config.default.js +39 -39
- package/src/values.config.enquiry.js +39 -39
- package/src/values.config.feedback.js +39 -39
- package/src/values.config.food.js +39 -39
- package/src/values.config.forms.js +39 -39
- package/src/values.config.js +39 -39
|
@@ -1,303 +1,362 @@
|
|
|
1
|
-
import React, { Component } from
|
|
2
|
-
import { Image, Text, TouchableOpacity, View, StyleSheet } from
|
|
3
|
-
import _ from
|
|
4
|
-
import { Icon } from
|
|
5
|
-
import { connect } from
|
|
6
|
-
import moment from
|
|
7
|
-
import { getJobStatus, getJobPriority } from
|
|
8
|
-
import { Services } from
|
|
9
|
-
import { Helper, Colours } from
|
|
10
|
-
import { values } from
|
|
1
|
+
import React, { Component } from "react";
|
|
2
|
+
import { Image, Text, TouchableOpacity, View, StyleSheet } from "react-native";
|
|
3
|
+
import _ from "lodash";
|
|
4
|
+
import { Icon } from "react-native-elements";
|
|
5
|
+
import { connect } from "react-redux";
|
|
6
|
+
import moment from "moment";
|
|
7
|
+
import { getJobStatus, getJobPriority } from "../helper";
|
|
8
|
+
import { Services } from "../feature.config";
|
|
9
|
+
import { Helper, Colours } from "../core.config";
|
|
10
|
+
import { values } from "../values.config";
|
|
11
11
|
|
|
12
12
|
class MaintenanceListItem extends Component {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
onPressJob = () => {
|
|
14
|
+
Services.navigation.navigate(values.screenRequestDetail, {
|
|
15
|
+
job: this.props.job,
|
|
16
|
+
});
|
|
17
|
+
};
|
|
16
18
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
19
|
+
renderCommentCount() {
|
|
20
|
+
const { job } = this.props;
|
|
21
|
+
if (!job.commentCount) {
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
return (
|
|
25
|
+
<View style={styles.commentCountContainer}>
|
|
26
|
+
<Text style={styles.commentCountText}>
|
|
27
|
+
{job.commentCount > 99 ? "99" : job.commentCount}
|
|
28
|
+
</Text>
|
|
29
|
+
</View>
|
|
30
|
+
);
|
|
31
|
+
}
|
|
28
32
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
renderDescription() {
|
|
34
|
+
const { job } = this.props;
|
|
35
|
+
if (_.isEmpty(job.description)) {
|
|
36
|
+
return null;
|
|
37
|
+
}
|
|
38
|
+
return <Text style={styles.jobDescriptionText}>{job.description}</Text>;
|
|
39
|
+
}
|
|
36
40
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
41
|
+
renderSeen() {
|
|
42
|
+
const { job, hideSeen } = this.props;
|
|
43
|
+
const showSeen =
|
|
44
|
+
!job.status || job.status === getJobStatus(null, this.props).text;
|
|
45
|
+
if (hideSeen || !showSeen || !job.seen) {
|
|
46
|
+
return null;
|
|
47
|
+
}
|
|
48
|
+
return (
|
|
49
|
+
<View style={styles.jobSeenContainer}>
|
|
50
|
+
<Icon
|
|
51
|
+
name="check"
|
|
52
|
+
type="font-awesome"
|
|
53
|
+
iconStyle={[
|
|
54
|
+
styles.jobSeenIcon,
|
|
55
|
+
{ color: this.props.colourBrandingMain },
|
|
56
|
+
]}
|
|
57
|
+
/>
|
|
58
|
+
<Text
|
|
59
|
+
style={[styles.jobSeenText, { color: this.props.colourBrandingMain }]}
|
|
60
|
+
>
|
|
61
|
+
Seen
|
|
62
|
+
</Text>
|
|
63
|
+
</View>
|
|
64
|
+
);
|
|
65
|
+
}
|
|
50
66
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
67
|
+
render() {
|
|
68
|
+
const { job } = this.props;
|
|
69
|
+
const createdTime = moment(job.createdUnix);
|
|
70
|
+
const createdTimeText = `${createdTime.format("ddd, D MMMM")} • ${createdTime.format("h:mma")}`;
|
|
71
|
+
const assigneeText = job.Assignee
|
|
72
|
+
? `Assigned to\n${job.Assignee.displayName}`
|
|
73
|
+
: "";
|
|
74
|
+
const status = getJobStatus(job.status, this.props);
|
|
75
|
+
const priority = getJobPriority(job.priority);
|
|
76
|
+
const isStaff = this.props.user.category === "staff";
|
|
59
77
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
78
|
+
return (
|
|
79
|
+
<TouchableOpacity onPress={this.onPressJob}>
|
|
80
|
+
<View style={[styles.jobContainer, this.props.style]}>
|
|
81
|
+
<View style={styles.jobInnerContainer}>
|
|
82
|
+
<View style={styles.jobTopSection}>
|
|
83
|
+
<View style={styles.jobTopLeft}>
|
|
84
|
+
{job.jobId ? (
|
|
85
|
+
<Text
|
|
86
|
+
style={[
|
|
87
|
+
styles.jobIdText,
|
|
88
|
+
{ color: this.props.colourBrandingMain },
|
|
89
|
+
]}
|
|
90
|
+
>{`${values.textEntityName} #${job.jobId}`}</Text>
|
|
91
|
+
) : null}
|
|
92
|
+
<Text style={styles.jobTitleText}>{job.title}</Text>
|
|
93
|
+
{job.room ? (
|
|
94
|
+
<Text style={styles.jobLocationText}>{job.room}</Text>
|
|
95
|
+
) : null}
|
|
96
|
+
<View style={styles.jobTypeSeenContainer}>
|
|
97
|
+
<View
|
|
98
|
+
style={[
|
|
99
|
+
styles.jobTypeContainer,
|
|
100
|
+
{
|
|
101
|
+
backgroundColor: Colours.hexToRGBAstring(
|
|
102
|
+
this.props.colourBrandingMain,
|
|
103
|
+
0.2,
|
|
104
|
+
),
|
|
105
|
+
},
|
|
106
|
+
]}
|
|
107
|
+
>
|
|
108
|
+
<Text
|
|
109
|
+
style={[
|
|
110
|
+
styles.jobTypeText,
|
|
111
|
+
{ color: this.props.colourBrandingMain },
|
|
112
|
+
]}
|
|
113
|
+
numberOfLines={2}
|
|
114
|
+
>
|
|
115
|
+
{job.type}
|
|
116
|
+
</Text>
|
|
117
|
+
</View>
|
|
118
|
+
{this.renderSeen()}
|
|
119
|
+
</View>
|
|
120
|
+
</View>
|
|
121
|
+
<View style={styles.jobTopRight}>
|
|
122
|
+
<Image
|
|
123
|
+
style={styles.jobCommentImage}
|
|
124
|
+
source={require("../images/speechbubble.png")}
|
|
125
|
+
/>
|
|
126
|
+
{this.renderCommentCount()}
|
|
127
|
+
</View>
|
|
128
|
+
</View>
|
|
129
|
+
<View style={styles.jobBottomSection}>
|
|
130
|
+
{/* {this.renderDescription()} */}
|
|
131
|
+
<Text style={styles.jobCreatedText}>{createdTimeText}</Text>
|
|
132
|
+
<View style={styles.jobActivityContainer}>
|
|
133
|
+
<View
|
|
134
|
+
style={[
|
|
135
|
+
styles.jobStatusContainer,
|
|
136
|
+
{ backgroundColor: status?.color },
|
|
137
|
+
]}
|
|
138
|
+
>
|
|
139
|
+
{/* <Icon name="wrench" type="font-awesome" iconStyle={styles.jobStatusIcon} /> */}
|
|
140
|
+
<Text style={styles.jobStatusText}>{status?.text}</Text>
|
|
141
|
+
</View>
|
|
142
|
+
<View
|
|
143
|
+
style={[styles.jobStatusLine, { borderColor: status?.color }]}
|
|
144
|
+
>
|
|
145
|
+
<View style={styles.jobStatusLineMask} />
|
|
146
|
+
</View>
|
|
147
|
+
<View
|
|
148
|
+
style={[
|
|
149
|
+
styles.jobStatusCircle,
|
|
150
|
+
{ backgroundColor: status?.color },
|
|
151
|
+
]}
|
|
152
|
+
/>
|
|
153
|
+
<Text style={styles.jobStatusDateText}>{assigneeText}</Text>
|
|
154
|
+
</View>
|
|
155
|
+
{isStaff && (
|
|
156
|
+
<View
|
|
157
|
+
style={[
|
|
158
|
+
styles.jobPriorityContainer,
|
|
159
|
+
{ backgroundColor: priority.color },
|
|
160
|
+
]}
|
|
161
|
+
>
|
|
162
|
+
<Text style={styles.jobPriorityText}>{priority.label}</Text>
|
|
163
|
+
</View>
|
|
164
|
+
)}
|
|
165
|
+
</View>
|
|
166
|
+
</View>
|
|
167
|
+
</View>
|
|
168
|
+
</TouchableOpacity>
|
|
169
|
+
);
|
|
170
|
+
}
|
|
112
171
|
}
|
|
113
172
|
|
|
114
173
|
const styles = StyleSheet.create({
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
174
|
+
jobContainer: {
|
|
175
|
+
marginVertical: 8,
|
|
176
|
+
paddingHorizontal: 16,
|
|
177
|
+
},
|
|
178
|
+
jobInnerContainer: {
|
|
179
|
+
...Helper.getShadowStyle(),
|
|
180
|
+
},
|
|
181
|
+
jobTopSection: {
|
|
182
|
+
flexDirection: "row",
|
|
183
|
+
alignItems: "flex-end",
|
|
184
|
+
paddingHorizontal: 10,
|
|
185
|
+
paddingVertical: 10,
|
|
186
|
+
borderBottomWidth: 1,
|
|
187
|
+
borderBottomColor: Colours.LINEGREY,
|
|
188
|
+
},
|
|
189
|
+
jobTopLeft: {
|
|
190
|
+
flex: 1,
|
|
191
|
+
},
|
|
192
|
+
jobIdText: {
|
|
193
|
+
fontFamily: "sf-medium",
|
|
194
|
+
fontSize: 12,
|
|
195
|
+
marginBottom: 4,
|
|
196
|
+
},
|
|
197
|
+
jobTitleText: {
|
|
198
|
+
fontFamily: "sf-semibold",
|
|
199
|
+
fontSize: 18,
|
|
200
|
+
color: Colours.TEXT_DARK,
|
|
201
|
+
marginBottom: 4,
|
|
202
|
+
},
|
|
203
|
+
jobLocationText: {
|
|
204
|
+
fontFamily: "sf-medium",
|
|
205
|
+
fontSize: 12,
|
|
206
|
+
color: Colours.TEXT_LIGHT,
|
|
207
|
+
marginBottom: 4,
|
|
208
|
+
},
|
|
209
|
+
jobTypeSeenContainer: {
|
|
210
|
+
marginTop: 4,
|
|
211
|
+
flexDirection: "row",
|
|
212
|
+
alignItems: "center",
|
|
213
|
+
},
|
|
214
|
+
jobTypeContainer: {
|
|
215
|
+
padding: 4,
|
|
216
|
+
minWidth: 80,
|
|
217
|
+
maxWidth: 140,
|
|
218
|
+
borderRadius: 4,
|
|
219
|
+
justifyContent: "center",
|
|
220
|
+
},
|
|
221
|
+
jobTypeText: {
|
|
222
|
+
fontFamily: "sf-semibold",
|
|
223
|
+
fontSize: 12,
|
|
224
|
+
textAlign: "center",
|
|
225
|
+
maxWidth: "100%",
|
|
226
|
+
},
|
|
227
|
+
jobSeenContainer: {
|
|
228
|
+
flexDirection: "row",
|
|
229
|
+
alignItems: "center",
|
|
230
|
+
marginLeft: 10,
|
|
231
|
+
},
|
|
232
|
+
jobSeenIcon: {
|
|
233
|
+
fontSize: 12,
|
|
234
|
+
},
|
|
235
|
+
jobSeenText: {
|
|
236
|
+
fontFamily: "sf-semibold",
|
|
237
|
+
fontSize: 12,
|
|
238
|
+
marginLeft: 4,
|
|
239
|
+
},
|
|
240
|
+
jobTopRight: {
|
|
241
|
+
alignItems: "center",
|
|
242
|
+
justifyContent: "center",
|
|
243
|
+
paddingHorizontal: 10,
|
|
244
|
+
paddingTop: 10,
|
|
245
|
+
},
|
|
246
|
+
jobCommentImage: {
|
|
247
|
+
width: 34,
|
|
248
|
+
height: 34,
|
|
249
|
+
resizeMode: "contain",
|
|
250
|
+
},
|
|
251
|
+
commentCountContainer: {
|
|
252
|
+
position: "absolute",
|
|
253
|
+
top: 0,
|
|
254
|
+
right: 0,
|
|
255
|
+
borderRadius: 10,
|
|
256
|
+
borderWidth: 2,
|
|
257
|
+
borderColor: "#fff",
|
|
258
|
+
width: 20,
|
|
259
|
+
height: 20,
|
|
260
|
+
backgroundColor: Colours.COLOUR_GREEN,
|
|
261
|
+
justifyContent: "center",
|
|
262
|
+
alignItems: "center",
|
|
263
|
+
},
|
|
264
|
+
commentCountText: {
|
|
265
|
+
textAlign: "center",
|
|
266
|
+
fontFamily: "sf-bold",
|
|
267
|
+
fontSize: 10,
|
|
268
|
+
color: "#fff",
|
|
269
|
+
},
|
|
270
|
+
jobBottomSection: {
|
|
271
|
+
paddingHorizontal: 10,
|
|
272
|
+
paddingVertical: 16,
|
|
273
|
+
},
|
|
274
|
+
jobDescriptionText: {
|
|
275
|
+
fontFamily: "sf-medium",
|
|
276
|
+
fontSize: 14,
|
|
277
|
+
color: Colours.TEXT_DARK,
|
|
278
|
+
marginBottom: 8,
|
|
279
|
+
},
|
|
280
|
+
jobCreatedText: {
|
|
281
|
+
fontFamily: "sf-medium",
|
|
282
|
+
fontSize: 12,
|
|
283
|
+
color: Colours.TEXT_LIGHT,
|
|
284
|
+
marginBottom: 10,
|
|
285
|
+
},
|
|
286
|
+
jobActivityContainer: {
|
|
287
|
+
flexDirection: "row",
|
|
288
|
+
alignItems: "center",
|
|
289
|
+
},
|
|
290
|
+
jobStatusContainer: {
|
|
291
|
+
flexDirection: "row",
|
|
292
|
+
alignItems: "center",
|
|
293
|
+
justifyContent: "center",
|
|
294
|
+
width: 105,
|
|
295
|
+
height: 30,
|
|
296
|
+
paddingHorizontal: 8,
|
|
297
|
+
borderRadius: 4,
|
|
298
|
+
},
|
|
299
|
+
jobStatusIcon: {
|
|
300
|
+
color: "#fff",
|
|
301
|
+
fontSize: 14,
|
|
302
|
+
},
|
|
303
|
+
jobStatusText: {
|
|
304
|
+
color: "#fff",
|
|
305
|
+
textAlign: "center",
|
|
306
|
+
fontFamily: "sf-semibold",
|
|
307
|
+
fontSize: 13,
|
|
308
|
+
},
|
|
309
|
+
jobStatusLine: {
|
|
310
|
+
borderWidth: 1,
|
|
311
|
+
borderStyle: "dashed",
|
|
312
|
+
width: 30,
|
|
313
|
+
},
|
|
314
|
+
jobStatusLineMask: {
|
|
315
|
+
position: "absolute",
|
|
316
|
+
left: -1,
|
|
317
|
+
top: -1,
|
|
318
|
+
width: "100%",
|
|
319
|
+
height: 1,
|
|
320
|
+
backgroundColor: "#fff",
|
|
321
|
+
zIndex: 1,
|
|
322
|
+
},
|
|
323
|
+
jobStatusCircle: {
|
|
324
|
+
width: 18,
|
|
325
|
+
height: 18,
|
|
326
|
+
borderRadius: 9,
|
|
327
|
+
},
|
|
328
|
+
jobStatusDateText: {
|
|
329
|
+
flex: 1,
|
|
330
|
+
textAlign: "right",
|
|
331
|
+
fontFamily: "sf-medium",
|
|
332
|
+
fontSize: 14,
|
|
333
|
+
color: Colours.TEXT_DARK,
|
|
334
|
+
},
|
|
335
|
+
jobPriorityContainer: {
|
|
336
|
+
flexDirection: "row",
|
|
337
|
+
alignItems: "center",
|
|
338
|
+
justifyContent: "center",
|
|
339
|
+
width: 105,
|
|
340
|
+
height: 24,
|
|
341
|
+
paddingHorizontal: 8,
|
|
342
|
+
borderRadius: 4,
|
|
343
|
+
marginTop: 8,
|
|
344
|
+
},
|
|
345
|
+
jobPriorityText: {
|
|
346
|
+
color: "#fff",
|
|
347
|
+
textAlign: "center",
|
|
348
|
+
fontFamily: "sf-semibold",
|
|
349
|
+
fontSize: 13,
|
|
350
|
+
},
|
|
292
351
|
});
|
|
293
352
|
|
|
294
|
-
const mapStateToProps = state => {
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
353
|
+
const mapStateToProps = (state) => {
|
|
354
|
+
return {
|
|
355
|
+
user: state.user,
|
|
356
|
+
colourBrandingMain: Colours.getMainBrandingColourFromState(state),
|
|
357
|
+
statusTypes: state[values.reducerKey].jobstatuses,
|
|
358
|
+
hideSeen: state[values.reducerKey].hideSeen,
|
|
359
|
+
};
|
|
301
360
|
};
|
|
302
361
|
|
|
303
362
|
export default connect(mapStateToProps, {})(MaintenanceListItem);
|