-
Notifications
You must be signed in to change notification settings - Fork 2
/
form-row-children-dd.jigx
91 lines (85 loc) · 3.38 KB
/
form-row-children-dd.jigx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
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
title: Form with Row and Children Components
description: Jig to display a form with rows & children components
type: jig.default
header:
type: component.jig-header
options:
height: medium
children:
type: component.image
options:
source:
uri: =@ctx.datasources.cleaning-services-dd.image
actions:
- children:
- type: action.execute-entity
options:
title: Update Service
provider: DATA_PROVIDER_LOCAL
entity: default/cleaning-services-updates
method: update
data:
id: =@ctx.datasources.cleaning-services-dd.id
service: =@ctx.components.cleaning_serv_tf.state.value
area: =@ctx.components.cleaning_serv_area_tf.state.value
time: =@ctx.components.cleaning_serv_time_num.state.value
indoor: =@ctx.components.cleaning_serv_indoor_checkbox.state.value
description: =@ctx.components.cleaning_serv_desc_tf.state.value
hourlyRate: =@ctx.components.cleaning_serv_hourly_tf.state.value
onceOffRate: =@ctx.components.cleaning_serv_once_tf.state.value
onSuccess:
title: Service Updated
description: Your service was updated successfully.
children:
- type: component.form
options:
isDiscardChangesAlertEnabled: false
children:
- type: component.field-row
options:
children:
- type: component.text-field
instanceId: cleaning_serv_tf
options:
label: Service
value: =@ctx.datasources.cleaning-services-dd.service
- type: component.text-field
instanceId: cleaning_serv_area_tf
options:
label: Area
value: =@ctx.datasources.cleaning-services-dd.area
- type: component.field-row
options:
children:
- type: component.number-field
instanceId: cleaning_serv_time_num
options:
label: Time
value: =@ctx.datasources.cleaning-services-dd.time & ' minutes'
keyboardType: number-pad
- type: component.checkbox
instanceId: cleaning_serv_indoor_checkbox
options:
label: Indoor
value: =@ctx.datasources.cleaning-services-dd.indoor
- type: component.field-row
options:
children:
- type: component.text-field
instanceId: cleaning_serv_desc_tf
options:
label: Description
value: =@ctx.datasources.cleaning-services-dd.description
- type: component.field-row
options:
children:
- type: component.text-field
instanceId: cleaning_serv_hourly_tf
options:
label: Hourly Rate
value: =@ctx.datasources.cleaning-services-dd.hourlyrate != null ? @ctx.datasources.cleaning-services-dd.hourlyrate:'N/A'
- type: component.text-field
instanceId: cleaning_serv_once_tf
options:
label: Once Off Rate
value: =@ctx.datasources.cleaning-services-dd.onceoffrate != null ? @ctx.datasources.cleaning-services-dd.onceoffrate:'N/A'