From: Atif G. <ma...@us...> - 2001-03-18 00:39:20
|
Update of /cvsroot/ispman/ispman-web/cgi-bin/tmpl/customerMan In directory usw-pr-cvs1:/tmp/cvs-serv30344/ispman-web/cgi-bin/tmpl/customerMan Modified Files: editUsers.tmpl summary.tmpl Added Files: editUserMenu.tmpl Log Message: Misc changes in the CustomerMan interface. I think I will restart working on the customer interface. Also a back to configurration Menu link as suggested by Donald. Added a default .htaccess file in the cgi-bin directory. --- NEW FILE --- <html> <head> <LINK HREF="/css/customerman.css" REL="stylesheet" TYPE="text/css"> </head> <body> <perl>$message</perl> <script> function Delete(vhost){ if (confirm("Are you sure you want to permanently delete this virtualhost?")) self.location="<perl>$r->url</perl>?mode=deleteVhost&cn="+vhost; //alert("<perl>$r->url</perl>?mode=deleteVhost&vhost="+vhost); } function addUser(){ self.location="<perl>$r->url</perl>?mode=addDomainUser"; } function editUser(user){ self.location="<perl>$r->url</perl>?mode=editDomainUser&user="+user; } function deleteUser(user){ self.location="<perl>$r->url</perl>?mode=deleteDomainUser&user="+user; } function changePass(user){ if (pass=window.prompt("Please enter new password", "")){ self.location="<perl>$r->url</perl>?mode=changeDomainUserPass&user="+user+"&pass="+pass; } } </script> <font face="Arial"> <perl> $r->param("message") </perl> <P> <form> <table border=1> <perl> $text=""; my $user=$r->param("user"); $text.="<tr><td> $user</td>"; $text.=qq|<td><input type="button" value="Edit" onClick="editUser('$user')"></td>|; $text.=qq|<td><input type="button" value="Change pass" onClick="changePass('$user')"></td>|; $text.=qq|<td><input type="button" value="Delete" onClick="deleteUser('$user')"></td>|; $text.="</tr>"; $text </perl> </table> </form> Index: editUsers.tmpl =================================================================== RCS file: /cvsroot/ispman/ispman-web/cgi-bin/tmpl/customerMan/editUsers.tmpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** editUsers.tmpl 2001/01/12 23:10:49 1.1 --- editUsers.tmpl 2001/03/18 00:41:31 1.2 *************** *** 10,21 **** <script> ! function Delete(vhost){ ! if (confirm("Are you sure you want to permanently delete this virtualhost?")) ! self.location="<perl>$r->url</perl>?mode=deleteVhost&cn="+vhost; ! //alert("<perl>$r->url</perl>?mode=deleteVhost&vhost="+vhost); ! ! } ! function addUser(){ ! self.location="<perl>$r->url</perl>?mode=addDomainUser"; } </script> --- 10,15 ---- <script> ! function editUser(user){ ! parent.userinfo.location="<perl>$r->url</perl>?mode=editDomainUser&user="+user; } </script> *************** *** 31,57 **** <P> - <A HREF="javascript:addUser()">Add User</a> - <BR> <form> ! <SELECT NAME="users"> ! <option value=''>Select User</option> ! <option value=''> </option> - - <perl> $text=""; my $users=$customer->getDomainUsers(); for my $user(keys %$users) { ! $text.="<option value='$user'> $user</option>"; } $text </perl> ! </select> ! <input type=button value=" Delete " onClick="Delete(this.form.vhosts.options[this.form.vhosts.selectedIndex].value)"> </form> - - - - - --- 25,40 ---- <P> <form> ! <table border=1> <perl> $text=""; my $users=$customer->getDomainUsers(); for my $user(keys %$users) { ! $text.=qq|<tr><td> <a href='#' onClick="editUser('$user')">$user</a></td>|; ! $text.="</tr>"; } $text </perl> ! </table> </form> Index: summary.tmpl =================================================================== RCS file: /cvsroot/ispman/ispman-web/cgi-bin/tmpl/customerMan/summary.tmpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** summary.tmpl 2001/01/26 03:02:04 1.1 --- summary.tmpl 2001/03/18 00:41:31 1.2 *************** *** 1,3 **** ! <body text="#000000" topmargin="10" leftmargin="0" maginwidth=0 marginheight=10 bgcolor="#ffffff" > --- 1,3 ---- ! <body text="#000000" topmargin="10" leftmargin="0" maginwidth=0 marginheight=10 bgcolor="#9abbd6" > |