Guest User

Untitled

a guest
Jun 17th, 2018
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
TCL 3.75 KB | None | 0 0
  1. ad_form -name voidcancel -has_submit 0 -export {stage response_id report_id site_addr current_user_id} -form {                                                                                
  2. {void:text(submit) {label "Void Locate"} {html {onclick "goto_confirm('void','$response_id')"}}}                                                                                              
  3. {cancel:text(submit) {label "Cancel Locate"} {html {onclick "goto_confirm('cancel','$response_id')"}} {after_html { *No changes can be made to Cancelled locates<br><br>}}}                  
  4. }                                                                                                                                                                                            
  5. if {($stage ne "0") && $response_id ne ""} {                                                                                                                                                  
  6. ad_form -extend -name voidcancel -form {                                                                                                                                                      
  7. {email:text(submit) {label "Email"}}                                                                                                                                                          
  8. {print:text(submit) {label "Print"} {html {onclick "window.location='ll-display?response_id=$response_id&flag=print';return false"}}}                                                        
  9. } -on_submit {                                                                                                                                                                                
  10. if {$void ne ""} {                                                                                                                                                                            
  11. db_dml do_update "UPDATE yy_linelocate SET status = 'false' WHERE response_id = :response_id"                                                                                                
  12. ad_returnredirect -message "Locate has been marked as void" "/mirs/vujax/forms/linelocate-report?response_id=$response_id"                                                                    
  13. ad_script_abort                                                                                                                                                                              
  14. }                                                                                                                                                                                            
  15.                                                                                                                                                                                              
  16. if {$email ne ""} {                                                                                                                                                                          
  17. db_dml do_update "UPDATE yy_linelocate SET last_email_time = now(),last_email_user = $current_user_id WHERE response_id = :response_id"                                                      
  18. ad_returnredirect "/mirs/vujax/display_report?report_id=$report_id&$site=$site_addr&$response_param=$response_id&$flag_param=email"                                                          
  19. }                                                                                                                                                                                            
  20. }                                                                                                                                                                                            
  21. }
Add Comment
Please, Sign In to add comment