[freeside-commits] freeside/httemplate/view svc_domain.cgi, 1.18, 1.19

Ivan,,, ivan at wavetail.420.am
Wed Nov 9 16:01:00 PST 2005


Update of /home/cvs/cvsroot/freeside/httemplate/view
In directory wavetail:/tmp/cvs-serv8329

Modified Files:
	svc_domain.cgi 
Log Message:
add javascript confirmation to unaudited domain deletion, add record being deleted to record deletion popup

Index: svc_domain.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/view/svc_domain.cgi,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -d -r1.18 -r1.19
--- svc_domain.cgi	15 Apr 2005 20:29:38 -0000	1.18
+++ svc_domain.cgi	10 Nov 2005 00:00:58 -0000	1.19
@@ -36,8 +36,8 @@
   ( ( $pkgnum || $custnum )
     ? ( "View this customer (#$custnum)" => "${p}view/cust_main.cgi?$custnum",
       )
-    : ( "Cancel this (unaudited) domain" =>
-          "${p}misc/cancel-unaudited.cgi?$svcnum" )
+    : ( "Delete this (unaudited) domain" =>
+          "javascript:areyousure('${p}misc/cancel-unaudited.cgi?$svcnum', 'Delete $domain and all records?' )" )
   ),
   "Main menu" => $p,
 )) %>
@@ -50,8 +50,8 @@
 <BR><BR><A HREF="<%= ${p} %>misc/whois.cgi?custnum=<%=$custnum%>;svcnum=<%=$svcnum%>;domain=<%=$domain%>">View whois information.</A>
 <BR><BR>
 <SCRIPT>
-  function areyousure(href) {
-    if ( confirm("Remove this record?") == true )
+  function areyousure(href, message) {
+    if ( confirm(message) == true )
       window.location.href = href;
   }
   function slave_areyousure() {
@@ -74,7 +74,7 @@
     <td><%= $domain_record->recdata %>
 
     <% unless ( $domain_record->rectype eq 'SOA' ) { %>
-      (<A HREF="javascript:areyousure('<%=$p%>misc/delete-domain_record.cgi?<%=$domain_record->recnum%>')">delete</A>)
+      (<A HREF="javascript:areyousure('<%=$p%>misc/delete-domain_record.cgi?<%=$domain_record->recnum%>', 'Delete \'<%= $domain_record->reczone %> <%= $type %> <%= $domain_record->recdata %>\' ?' )">delete</A>)
     <% } %>
     </td></tr>
   <% } %>



More information about the freeside-commits mailing list