@@ -52,40 +52,48 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
52
52
} ) ;
53
53
this . _form . add ( lastName , this . tr ( "Last Name" ) , null , "lastName" ) ;
54
54
55
+
55
56
const email = new qx . ui . form . TextField ( ) . set ( {
56
57
required : true
57
58
} ) ;
58
- if (
59
- osparc . product . Utils . isProduct ( "s4lacad" ) ||
60
- osparc . product . Utils . isProduct ( "s4ldesktopacad" )
61
- ) {
62
- this . _form . add ( email , this . tr ( "University Email" ) , qx . util . Validate . email ( ) , "email" ) ;
63
- } else {
64
- this . _form . add ( email , this . tr ( "Email" ) , qx . util . Validate . email ( ) , "email" ) ;
59
+ switch ( osparc . product . Utils . getProductName ( ) ) {
60
+ case "s4l" :
61
+ case "tis" :
62
+ this . _form . add ( email , this . tr ( "Email" ) , qx . util . Validate . email ( ) , "email" ) ;
63
+ break ;
64
+ case "s4lacad" :
65
+ case "s4ldesktopacad" :
66
+ this . _form . add ( email , this . tr ( "University Email" ) , qx . util . Validate . email ( ) , "email" ) ;
67
+ break ;
65
68
}
66
69
67
70
const phone = new qx . ui . form . TextField ( ) ;
68
71
this . _form . add ( phone , this . tr ( "Phone Number" ) , null , "phone" ) ;
69
72
70
- if (
71
- osparc . product . Utils . isProduct ( "s4lacad" ) ||
72
- osparc . product . Utils . isProduct ( "s4ldesktopacad" )
73
- ) {
74
- const university = new qx . ui . form . TextField ( ) ;
75
- doubleSpaced . push ( university ) ;
76
- this . _form . add ( university , this . tr ( "University" ) , null , "university" ) ;
77
- } else {
78
- const company = new qx . ui . form . TextField ( ) ;
79
- doubleSpaced . push ( company ) ;
80
- this . _form . add ( company , this . tr ( "Company Name" ) , null , "company" ) ;
73
+
74
+ const organization = new qx . ui . form . TextField ( ) ;
75
+ doubleSpaced . push ( organization ) ;
76
+ switch ( osparc . product . Utils . getProductName ( ) ) {
77
+ case "s4l" :
78
+ this . _form . add ( organization , this . tr ( "Company Name" ) , null , "company" ) ;
79
+ break ;
80
+ case "s4lacad" :
81
+ case "s4ldesktopacad" :
82
+ this . _form . add ( organization , this . tr ( "University" ) , null , "university" ) ;
83
+ break ;
84
+ case "tis" :
85
+ this . _form . add ( organization , this . tr ( "Organization" ) , null , "organization" ) ;
86
+ break ;
81
87
}
82
88
89
+
83
90
const address = new qx . ui . form . TextField ( ) . set ( {
84
91
required : true
85
92
} ) ;
86
93
doubleSpaced . push ( address ) ;
87
94
this . _form . add ( address , this . tr ( "Address" ) , null , "address" ) ;
88
95
96
+
89
97
const city = new qx . ui . form . TextField ( ) . set ( {
90
98
required : true
91
99
} ) ;
@@ -96,6 +104,7 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
96
104
} ) ;
97
105
this . _form . add ( postalCode , this . tr ( "Postal code" ) , null , "postalCode" ) ;
98
106
107
+
99
108
const country = new qx . ui . form . SelectBox ( ) . set ( {
100
109
required : true
101
110
} ) ;
@@ -117,58 +126,67 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
117
126
} ) ;
118
127
this . _form . add ( country , this . tr ( "Country" ) , null , "country" ) ;
119
128
120
- const application = new qx . ui . form . SelectBox ( ) ;
121
- [ {
122
- id : "Antenna_Design_for_Wireless_Communication" ,
123
- label : "Antenna Design for Wireless Communication"
124
- } , {
125
- id : "Bioelectronics,_Electroceuticals_and_Neuroprosthetics" ,
126
- label : "Bioelectronics, Electroceuticals & Neuroprosthetics"
127
- } , {
128
- id : "Safety_and_Efficacy_Assessment" ,
129
- label : "Safety & Efficacy Assessment"
130
- } , {
131
- id : "Exposure_and_Compliance" ,
132
- label : "Exposure & Compliance"
133
- } , {
134
- id : "Focused_Ultrasound" ,
135
- label : "Focused Ultrasound"
136
- } , {
137
- id : "In_Silico_Trials" ,
138
- label : "In <i>Silico</i> Trials"
139
- } , {
140
- id : "Implant_Design" ,
141
- label : "Implant Design"
142
- } , {
143
- id : "Magnetic_Resonance_Imaging" ,
144
- label : "Magnetic Resonance Imaging"
145
- } , {
146
- id : "Neurostimulation" ,
147
- label : "Neurostimulation"
148
- } , {
149
- id : "Personalized_Medicine" ,
150
- label : "Personalized Medicine"
151
- } , {
152
- id : "Thermal_Therapies" ,
153
- label : "Thermal Therapies"
154
- } , {
155
- id : "Wireless_Power_Transfer_Systems" ,
156
- label : "Wireless Power Transfer Systems"
157
- } , {
158
- id : "Vascular_Flow_and_Perfusion" ,
159
- label : "Vascular Flow & Perfusion"
160
- } ] . forEach ( appData => {
161
- const lItem = new qx . ui . form . ListItem ( appData . label , null , appData . id ) . set ( {
162
- rich : true
129
+
130
+ if (
131
+ osparc . product . Utils . isProduct ( "s4l" ) ||
132
+ osparc . product . Utils . isProduct ( "s4lacad" ) ||
133
+ osparc . product . Utils . isProduct ( "s4ldesktopacad" )
134
+ ) {
135
+ const application = new qx . ui . form . SelectBox ( ) ;
136
+ [ {
137
+ id : "Antenna_Design_for_Wireless_Communication" ,
138
+ label : "Antenna Design for Wireless Communication"
139
+ } , {
140
+ id : "Bioelectronics,_Electroceuticals_and_Neuroprosthetics" ,
141
+ label : "Bioelectronics, Electroceuticals & Neuroprosthetics"
142
+ } , {
143
+ id : "Safety_and_Efficacy_Assessment" ,
144
+ label : "Safety & Efficacy Assessment"
145
+ } , {
146
+ id : "Exposure_and_Compliance" ,
147
+ label : "Exposure & Compliance"
148
+ } , {
149
+ id : "Focused_Ultrasound" ,
150
+ label : "Focused Ultrasound"
151
+ } , {
152
+ id : "In_Silico_Trials" ,
153
+ label : "In <i>Silico</i> Trials"
154
+ } , {
155
+ id : "Implant_Design" ,
156
+ label : "Implant Design"
157
+ } , {
158
+ id : "Magnetic_Resonance_Imaging" ,
159
+ label : "Magnetic Resonance Imaging"
160
+ } , {
161
+ id : "Neurostimulation" ,
162
+ label : "Neurostimulation"
163
+ } , {
164
+ id : "Personalized_Medicine" ,
165
+ label : "Personalized Medicine"
166
+ } , {
167
+ id : "Thermal_Therapies" ,
168
+ label : "Thermal Therapies"
169
+ } , {
170
+ id : "Wireless_Power_Transfer_Systems" ,
171
+ label : "Wireless Power Transfer Systems"
172
+ } , {
173
+ id : "Vascular_Flow_and_Perfusion" ,
174
+ label : "Vascular Flow & Perfusion"
175
+ } ] . forEach ( appData => {
176
+ const lItem = new qx . ui . form . ListItem ( appData . label , null , appData . id ) . set ( {
177
+ rich : true
178
+ } ) ;
179
+ application . add ( lItem ) ;
163
180
} ) ;
164
- application . add ( lItem ) ;
165
- } ) ;
166
- doubleSpaced . push ( application ) ;
167
- this . _form . add ( application , this . tr ( "Application" ) , null , "application" ) ;
181
+ doubleSpaced . push ( application ) ;
182
+ this . _form . add ( application , this . tr ( "Application" ) , null , "application" ) ;
183
+
184
+
185
+ const description = new qx . ui . form . TextField ( ) ;
186
+ doubleSpaced . push ( description ) ;
187
+ this . _form . add ( description , this . tr ( "Description" ) , null , "description" ) ;
188
+ }
168
189
169
- const description = new qx . ui . form . TextField ( ) ;
170
- doubleSpaced . push ( description ) ;
171
- this . _form . add ( description , this . tr ( "Description" ) , null , "description" ) ;
172
190
173
191
const hear = new qx . ui . form . SelectBox ( ) ;
174
192
[ {
@@ -193,6 +211,7 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
193
211
doubleSpaced . push ( hear ) ;
194
212
this . _form . add ( hear , this . tr ( "How did you hear about us?" ) , null , "hear" ) ;
195
213
214
+
196
215
// accept links
197
216
// Privacy Policy link
198
217
let ppLink = osparc . CookiePolicy . getS4LPrivacyPolicyLink ( "our privacy policy" ) ;
0 commit comments