@@ -52,40 +52,48 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
5252 } ) ;
5353 this . _form . add ( lastName , this . tr ( "Last Name" ) , null , "lastName" ) ;
5454
55+
5556 const email = new qx . ui . form . TextField ( ) . set ( {
5657 required : true
5758 } ) ;
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 ;
6568 }
6669
6770 const phone = new qx . ui . form . TextField ( ) ;
6871 this . _form . add ( phone , this . tr ( "Phone Number" ) , null , "phone" ) ;
6972
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 ;
8187 }
8288
89+
8390 const address = new qx . ui . form . TextField ( ) . set ( {
8491 required : true
8592 } ) ;
8693 doubleSpaced . push ( address ) ;
8794 this . _form . add ( address , this . tr ( "Address" ) , null , "address" ) ;
8895
96+
8997 const city = new qx . ui . form . TextField ( ) . set ( {
9098 required : true
9199 } ) ;
@@ -96,6 +104,7 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
96104 } ) ;
97105 this . _form . add ( postalCode , this . tr ( "Postal code" ) , null , "postalCode" ) ;
98106
107+
99108 const country = new qx . ui . form . SelectBox ( ) . set ( {
100109 required : true
101110 } ) ;
@@ -117,58 +126,67 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
117126 } ) ;
118127 this . _form . add ( country , this . tr ( "Country" ) , null , "country" ) ;
119128
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 ) ;
163180 } ) ;
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+ }
168189
169- const description = new qx . ui . form . TextField ( ) ;
170- doubleSpaced . push ( description ) ;
171- this . _form . add ( description , this . tr ( "Description" ) , null , "description" ) ;
172190
173191 const hear = new qx . ui . form . SelectBox ( ) ;
174192 [ {
@@ -193,6 +211,7 @@ qx.Class.define("osparc.auth.ui.RequestAccount", {
193211 doubleSpaced . push ( hear ) ;
194212 this . _form . add ( hear , this . tr ( "How did you hear about us?" ) , null , "hear" ) ;
195213
214+
196215 // accept links
197216 // Privacy Policy link
198217 let ppLink = osparc . CookiePolicy . getS4LPrivacyPolicyLink ( "our privacy policy" ) ;
0 commit comments