Changes for page test
Last modified by Jip-jan Alunkel on March 13, 19:02
From version 114.26
edited by Jip-jan Alunkel
on March 13, 15:34
on March 13, 15:34
Change comment:
Updated class property
To version 114.32
edited by Jip-jan Alunkel
on March 13, 16:01
on March 13, 16:01
Change comment:
Updated class property
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -11,6 +11,7 @@ 11 11 "label" : "Main complaint", 12 12 "aria-label" : "Enter the main complaint", 13 13 "placeholder" : "$services.localization.render('cases.wordgroup.main_complaint.placeholder')", 14 + "data-decimals": 2, 14 14 "data-pattern" : "^[a-zA-ZÀ-ÖÙ-öù-ÿĀ-žḀ-ỿ]+[a-zA-ZÀ-ÖÙ-öù-ÿĀ-žḀ-ỿ0-9- ]*$", 15 15 "data-error-response-type" : "use_label_definite_1", 16 16 "data-auto-first-capital" : "true", ... ... @@ -24,6 +24,10 @@ 24 24 "help-block" : 'This will be used as the title of your case. The first character must be a letter. For example:<br />- "Otitis Media in 13 year old boy" or<br />- "Cataract in 72 year old paraplegic woman"' 25 25 }) 26 26 #set($attrMap = { 28 + "id" : '', 29 + "type" : '', 30 + "required" : '', 31 + "label" : '', 27 27 "aria-label": '', 28 28 "date-min": '', 29 29 "date-max": '', ... ... @@ -32,6 +32,7 @@ 32 32 "placeholder": '', 33 33 "textarea-rows": '', 34 34 "value": '', 40 + "data-decimals": '', 35 35 "data-error-response-type": '', 36 36 "data-opener": '', 37 37 "data-pattern": '', ... ... @@ -56,9 +56,21 @@ 56 56 }) 57 57 #foreach($attr in $attrMap.keySet()) 58 58 #if($elementDataObj.containsKey("$!attr")) 59 - #set($elemAttrVal = $elementDataObj["$attr"]) 60 - #set($attrMap["$!attr"] = "$attr = '$elemAttrVal'") 61 - $attrMap[$attr].replace("'",'"')<br /> 65 + #if($attr == "required") 66 + #if($elementDataObj["$attr"] == "true") 67 + #set($attrMap["$!attr"] = " aria-required='true' required='required'") 68 + #else 69 + #set($attrMap["$!attr"] = " aria-required='false'") 70 + #end 71 + #elseif($attr == "data-decimals") 72 + #if($attrMap["$!attr"] != 0) 73 + #set($attrMap["data-decimals"] = " data-decimals='${attrMap[$attr]}'") 74 + #end 75 + #else 76 + #set($elemAttrVal = $elementDataObj["$attr"]) 77 + #set($attrMap["$!attr"] = "$attr = '$elemAttrVal'") 78 + $attrMap[$attr].replace("'",'"')<br /> 79 + #end 62 62 #end 63 63 #end 64 64 ##$attrMap