use new design
This commit is contained in:
		
							parent
							
								
									6c7e017ac0
								
							
						
					
					
						commit
						baf7228a95
					
				|  | @ -173,18 +173,27 @@ $new_suff = str_replace("'", "", $new_suff); | ||||||
| $new_suff = explode(";", $new_suff); | $new_suff = explode(";", $new_suff); | ||||||
| 
 | 
 | ||||||
| include 'main_header.php'; | include 'main_header.php'; | ||||||
| 	echo "<p> </p>\n"; | 	echo '<div class="userlist-bright smallPaddingContent">'; | ||||||
| 	echo "<p>" . _("The following suffix(es) are missing in LDAP. LAM can create them for you.") . "</p>\n"; | 	echo "<form action=\"initsuff.php\" method=\"post\">\n"; | ||||||
| 	echo "<p> </p>\n"; | 	$container = new htmlTable(); | ||||||
|  | 	$container->addElement(new htmlOutputText(_("The following suffix(es) are missing in LDAP. LAM can create them for you.")), true); | ||||||
|  | 	$container->addElement(new htmlSpacer(null, '10px'), true); | ||||||
| 	// print missing suffixes
 | 	// print missing suffixes
 | ||||||
| 	for ($i = 0; $i < sizeof($new_suff); $i++) { | 	for ($i = 0; $i < sizeof($new_suff); $i++) { | ||||||
| 		echo "<p>" . $new_suff[$i] . "</p>\n"; | 		$container->addElement(new htmlOutputText($new_suff[$i]), true); | ||||||
| 	} | 	} | ||||||
| 	echo "<p> </p>\n"; | 	$container->addElement(new htmlSpacer(null, '10px'), true); | ||||||
| 	echo "<form action=\"initsuff.php\" method=\"post\">\n"; | 
 | ||||||
| 	echo "<input type=\"hidden\" name=\"new_suff\" value=\"" . implode(";", $new_suff) . "\">\n"; | 	$buttonContainer = new htmlTable(); | ||||||
| 	echo "<input type=\"submit\" name=\"add_suff\" value=\"" . _("Create") . "\">"; | 	$buttonContainer->addElement(new htmlButton('add_suff', _("Create"))); | ||||||
| 	echo "<input type=\"submit\" name=\"cancel\" value=\"" . _("Cancel") . "\">"; | 	$buttonContainer->addElement(new htmlButton('cancel', _("Cancel"))); | ||||||
|  | 	$buttonContainer->addElement(new htmlHiddenInput('new_suff', implode(";", $new_suff))); | ||||||
|  | 	$container->addElement($buttonContainer); | ||||||
|  | 	 | ||||||
|  | 	$tabindex = 1; | ||||||
|  | 	parseHtml(null, $container, array(), false, $tabindex, 'user'); | ||||||
|  | 	 | ||||||
| 	echo "</form><br>\n"; | 	echo "</form><br>\n"; | ||||||
|  | 	echo "</div>\n"; | ||||||
| include 'main_footer.php'; | include 'main_footer.php'; | ||||||
| ?>
 | ?>
 | ||||||
|  |  | ||||||
|  | @ -84,6 +84,7 @@ if (isset($_GET['showldif'])) { | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| include 'main_header.php'; | include 'main_header.php'; | ||||||
|  | echo '<div class="userlist-bright smallPaddingContent">'; | ||||||
| 
 | 
 | ||||||
| if ($_FILES['inputfile'] && ($_FILES['inputfile']['size'] > 0)) { | if ($_FILES['inputfile'] && ($_FILES['inputfile']['size'] > 0)) { | ||||||
| 	$selectedModules = explode(',', $_POST['selectedModules']); | 	$selectedModules = explode(',', $_POST['selectedModules']); | ||||||
|  | @ -191,16 +192,13 @@ if ($_FILES['inputfile'] && ($_FILES['inputfile']['size'] > 0)) { | ||||||
| 				$_SESSION['mass_scope'] = $_POST['scope']; | 				$_SESSION['mass_scope'] = $_POST['scope']; | ||||||
| 				$_SESSION['mass_selectedModules'] = $selectedModules; | 				$_SESSION['mass_selectedModules'] = $selectedModules; | ||||||
| 				// show links for upload and LDIF export
 | 				// show links for upload and LDIF export
 | ||||||
| 				echo "<h1 align=\"center\">" . _("LAM has checked your input and is now ready to create the accounts.") . "</h1>\n"; | 				echo "<div class=\"title\">\n"; | ||||||
|  | 				echo "<h2 class=\"titleText\">" . _("LAM has checked your input and is now ready to create the accounts.") . "</h2>\n"; | ||||||
|  | 				echo "</div>"; | ||||||
| 				echo "<p> </p>\n"; | 				echo "<p> </p>\n"; | ||||||
| 				echo "<table align=\"center\" width=\"80%\"><tr>\n"; | 					echo "<a href=\"massDoUpload.php\">" . _("Upload accounts to LDAP") . "</a>"; | ||||||
| 					echo "<td align=\"center\" width=\"50%\">\n"; | 					echo "    "; | ||||||
| 					echo "<a href=\"massDoUpload.php\"><b>" . _("Upload accounts to LDAP") . "</b></a>"; | 					echo "<a href=\"massBuildAccounts.php?showldif=true\">" . _("Show LDIF file") . "</a>"; | ||||||
| 					echo "</td>\n"; |  | ||||||
| 					echo "<td align=\"center\" width=\"50%\">\n"; |  | ||||||
| 					echo "<a href=\"massBuildAccounts.php?showldif=true\"><b>" . _("Show LDIF file") . "</b></a>"; |  | ||||||
| 					echo "</td>\n"; |  | ||||||
| 				echo "</tr></table>\n"; |  | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
|  | @ -210,6 +208,7 @@ else { | ||||||
| 	echo '<br><a href="masscreate.php">' . _('Back') . '</a>'; | 	echo '<br><a href="masscreate.php">' . _('Back') . '</a>'; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | echo '</div>'; | ||||||
| include 'main_footer.php'; | include 'main_footer.php'; | ||||||
| 
 | 
 | ||||||
| ?>
 | ?>
 | ||||||
|  | @ -58,6 +58,7 @@ if (!isset($_SESSION['loggedIn']) || ($_SESSION['loggedIn'] !== true)) { | ||||||
| setlanguage(); | setlanguage(); | ||||||
| 
 | 
 | ||||||
| include 'main_header.php'; | include 'main_header.php'; | ||||||
|  | echo '<div class="userlist-bright smallPaddingContent">'; | ||||||
| 
 | 
 | ||||||
| // create accounts
 | // create accounts
 | ||||||
| $accounts = unserialize($_SESSION['ldap']->decrypt($_SESSION['mass_accounts'])); | $accounts = unserialize($_SESSION['ldap']->decrypt($_SESSION['mass_accounts'])); | ||||||
|  | @ -67,7 +68,9 @@ if (($_SESSION['mass_counter'] < sizeof($accounts)) || !isset($_SESSION['mass_po | ||||||
| 	if ($maxTime > 60) $maxTime = 60; | 	if ($maxTime > 60) $maxTime = 60; | ||||||
| 	if ($maxTime <= 0) $maxTime = 60; | 	if ($maxTime <= 0) $maxTime = 60; | ||||||
| 	$refreshTime = $maxTime + 7; | 	$refreshTime = $maxTime + 7; | ||||||
| 	echo "<h1>" . _("LDAP upload in progress. Please wait.") . "</h1>\n"; | 	echo "<div class=\"title\">\n"; | ||||||
|  | 	echo "<h2 class=\"titleText\">" . _("LDAP upload in progress. Please wait.") . "</h2>\n"; | ||||||
|  | 	echo "</div>"; | ||||||
| 	echo "<table align=\"center\" width=\"80%\" style=\"border-color: grey\" border=\"2\" cellspacing=\"0\" rules=\"none\">\n"; | 	echo "<table align=\"center\" width=\"80%\" style=\"border-color: grey\" border=\"2\" cellspacing=\"0\" rules=\"none\">\n"; | ||||||
| 	echo "<tr><td bgcolor=\"blue\" width=\"" . ($_SESSION['mass_counter'] * 100) / sizeof($accounts) . "%\"> </td>"; | 	echo "<tr><td bgcolor=\"blue\" width=\"" . ($_SESSION['mass_counter'] * 100) / sizeof($accounts) . "%\"> </td>"; | ||||||
| 	echo "<td bgcolor=\"grey\" width=\"" . (100 - (($_SESSION['mass_counter'] * 100) / sizeof($accounts))) . "%\"> </td></tr>\n"; | 	echo "<td bgcolor=\"grey\" width=\"" . (100 - (($_SESSION['mass_counter'] * 100) / sizeof($accounts))) . "%\"> </td></tr>\n"; | ||||||
|  | @ -117,20 +120,25 @@ if (($_SESSION['mass_counter'] < sizeof($accounts)) || !isset($_SESSION['mass_po | ||||||
| 	echo "<script type=\"text/javascript\">\n"; | 	echo "<script type=\"text/javascript\">\n"; | ||||||
| 	echo "top.location.href = \"massDoUpload.php\";\n"; | 	echo "top.location.href = \"massDoUpload.php\";\n"; | ||||||
| 	echo "</script>\n"; | 	echo "</script>\n"; | ||||||
| 	include 'main_footer.php'; |  | ||||||
| } | } | ||||||
| // all accounts have been created
 | // all accounts have been created
 | ||||||
| else { | else { | ||||||
| 	$_SESSION['cache']->refresh_cache(true); | 	$_SESSION['cache']->refresh_cache(true); | ||||||
| 	echo "<h1>" . _("LDAP upload has finished") . "</h1>\n"; | 	echo "<div class=\"title\">\n"; | ||||||
|  | 	echo "<h2  class=\"titleText\">" . _("LDAP upload has finished") . "</h2>\n"; | ||||||
|  | 	echo "</div>"; | ||||||
| 	if (sizeof($_SESSION['mass_errors']) > 0) { | 	if (sizeof($_SESSION['mass_errors']) > 0) { | ||||||
| 		echo "<h2>" . _("There were errors while uploading:") . "</h2>\n"; | 		echo "<div class=\"subTitle\">\n"; | ||||||
|  | 		echo "<h4  class=\"subTitleText\">" . _("There were errors while uploading:") . "</h4>\n"; | ||||||
|  | 		echo "</div>"; | ||||||
| 		for ($i = 0; $i < sizeof($_SESSION['mass_errors']); $i++) { | 		for ($i = 0; $i < sizeof($_SESSION['mass_errors']); $i++) { | ||||||
| 			call_user_func_array('StatusMessage', $_SESSION['mass_errors'][$i]); | 			call_user_func_array('StatusMessage', $_SESSION['mass_errors'][$i]); | ||||||
|  | 			echo "<br>"; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
|  | } | ||||||
|  | echo '</div>'; | ||||||
| include 'main_footer.php'; | include 'main_footer.php'; | ||||||
| } |  | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| ?>
 | ?>
 | ||||||
|  | @ -68,7 +68,7 @@ if (isset($_GET['getCSV'])) { | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| include 'main_header.php'; | include 'main_header.php'; | ||||||
| echo '<div class="smallPaddingContent">'; | echo '<div class="userlist-bright smallPaddingContent">'; | ||||||
| 
 | 
 | ||||||
| // get possible types and remove those which do not support file upload
 | // get possible types and remove those which do not support file upload
 | ||||||
| $types = $_SESSION['config']->get_ActiveTypes(); | $types = $_SESSION['config']->get_ActiveTypes(); | ||||||
|  | @ -108,7 +108,9 @@ if (isset($_POST['type'])) { | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| // show start page
 | // show start page
 | ||||||
| echo "<h1>" . _("Account creation via file upload") . "</h1>\n"; | echo "<div class=\"title\">\n"; | ||||||
|  | echo "<h2 class=\"titleText\">" . _("Account creation via file upload") . "</h2>\n"; | ||||||
|  | echo "</div>"; | ||||||
| echo "<p> </p>\n"; | echo "<p> </p>\n"; | ||||||
| 
 | 
 | ||||||
| echo "<p>\n"; | echo "<p>\n"; | ||||||
|  | @ -117,13 +119,6 @@ echo "</p>\n"; | ||||||
| 
 | 
 | ||||||
| echo "<p> </p>\n"; | echo "<p> </p>\n"; | ||||||
| 
 | 
 | ||||||
| echo '<script type="text/javascript">'; |  | ||||||
| echo 'function changeVisibleModules(element) {'; |  | ||||||
| echo 'jQuery(\'div.typeOptions\').toggle(false);'; |  | ||||||
| echo 'jQuery(\'div#\' + element.options[element.selectedIndex].value).toggle();'; |  | ||||||
| echo '}'; |  | ||||||
| echo '</script>'; |  | ||||||
| 
 |  | ||||||
| echo "<form enctype=\"multipart/form-data\" action=\"masscreate.php\" method=\"post\">\n"; | echo "<form enctype=\"multipart/form-data\" action=\"masscreate.php\" method=\"post\">\n"; | ||||||
| 
 | 
 | ||||||
| echo "<table style=\"border-color: grey\" cellpadding=\"10\" border=\"0\" cellspacing=\"0\">\n"; | echo "<table style=\"border-color: grey\" cellpadding=\"10\" border=\"0\" cellspacing=\"0\">\n"; | ||||||
|  | @ -199,6 +194,10 @@ echo "<table style=\"border-color: grey\" cellpadding=\"10\" border=\"0\" cellsp | ||||||
| 		jQuery(document).ready(function() { | 		jQuery(document).ready(function() { | ||||||
| 			jQuery('#okButton').button(); | 			jQuery('#okButton').button(); | ||||||
| 		}); | 		}); | ||||||
|  | 		function changeVisibleModules(element) { | ||||||
|  | 			jQuery('div.typeOptions').toggle(false); | ||||||
|  | 			jQuery('div#' + element.options[element.selectedIndex].value).toggle(); | ||||||
|  | 		} | ||||||
| 		</script> | 		</script> | ||||||
| 		<?php | 		<?php | ||||||
| 	echo "</td></tr>\n"; | 	echo "</td></tr>\n"; | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue