X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Ftr-select-reason.html;h=35659755367a88a677a7b689c1a50b2e8b361427;hb=251d07aa41b6830a0a2f2a51c14fa94586d843c2;hp=4051e7d20d78bd9e3a9f5c16d8e2f94fe98c64a8;hpb=c648976f0b7975f2328ebd7ba8c711fad0ca4195;p=freeside.git diff --git a/httemplate/elements/tr-select-reason.html b/httemplate/elements/tr-select-reason.html index 4051e7d20..356597553 100755 --- a/httemplate/elements/tr-select-reason.html +++ b/httemplate/elements/tr-select-reason.html @@ -1,149 +1,233 @@ +<%doc> + +Example: + + include( '/elements/tr-select-reason.html', + + #required + 'field' => 'reasonnum', + 'reason_class' => 'C', # currently 'C', 'R', 'F', 'S' or 'X' + # for cancel, credit, refund, suspend or void credit + + #recommended + 'cgi' => $cgi, #easiest way for things to be properly "sticky" on errors + + #optional + 'control_button' => 'element_name', #button to be enabled when a reason is + #selected + 'id' => 'element_id', + + #deprecated ways to keep things "sticky" on errors + # (requires duplicate code in each using file to parse cgi params) + 'curr_value' => $curr_value, + 'curr_value' => { + 'typenum' => $typenum, + 'reason' => $reason, + }, + + ) + +%doc> + +% # note style improvements. +% # - no more conditionally included code here +% # - callers are not expected to pass javascript fragments +% # - no redundant checking of ACLs or parameters +% # - form fields are grouped for easy management +% # - use the standard select-table widget instead of ad hoc crap -