Esempio n. 1
0
if (option('auth_ldap_enable')) {
    // ===== LDAP groups
    $section = 'ldap';
    $this->form->add_section($section, lang('departments_ldap_groups'), lang('departments_ldap_groups_hint'));
    // ----- LDAP groups
    $name = 'ldap_groups[]';
    $content = '<select name="ldap_groups[]" tabindex="' . tab_index() . '" id="ldap_groups[]" size="20" multiple="multiple" class="text-input" style="width: 350px">';
    $content .= '<option value="">(None)</option>';
    foreach ($ldap_groups as $lg_id => $lg_name) {
        $selected = array_key_exists($lg_id, element('ldap_groups', $department, array())) ? 'selected="selected"' : '';
        $content .= '<option value="' . $lg_id . '" ' . $selected . '>' . $lg_name . '</option>' . "\n";
    }
    $content .= '</select>';
    $this->form->add_input(array('section' => $section, 'name' => $name, 'content' => $content));
}
$this->form->add_button(form_button(array('type' => 'submit', 'class' => 'primary', 'text' => lang('save'), 'tab_index' => tab_index())));
echo form_open(current_url(), array('id' => 'department_set_form'));
echo $this->form->render();
echo '</form>';
?>


<script>
Q.push(function() {
	
	$.fn.colorPicker.defaults.colors = [
		"FCE94F", "EDD400", "C4A000", "FCAF3E", "F57900", "CE5C00",
		"E9B96E", "C17D11", "8F5902", "8AE234", "73D216", "4E9A06",
		"729FCF", "3465A4", "204A87", "AD7FA8", "75507B", "5C3566",
		"EF2929", "CC0000", "A40000", "EEEEEC", "BABDB6", "2E3436"
	];
Esempio n. 2
0
								<?php 
    echo form_dropdown('fields[' . $index . ']', $destination_fields, '', 'tabindex="' . tab_index() . '" class="ftext-input" style="margin: 0"');
    ?>
							</td>
						</tr>
						<?php 
}
?>
					</tbody>
					
				</table>
				
			</div>
			
		</div>
		
		<div class="row submit">
			<div class="grid_9 offset_3 text-right">
				<?php 
echo form_button(array('type' => 'submit', 'class' => 'blue right', 'text' => lang('next'), 'tab_index' => tab_index()));
?>
				<?php 
echo form_button(array('type' => 'link', 'url' => 'users/import/cancel', 'class' => 'grey right', 'text' => lang('cancel'), 'tab_index' => tab_index()));
?>
			</div>
		</div>
		
	</div>

</form>
Esempio n. 3
0
</td>
			</tr>
			
			<?php 
}
?>
			
		</tbody>
		
	</table>
	
	
	<div class="row submit">
			<div class="grid_9 offset_3 text-right">
				<?php 
echo form_button(array('type' => 'link', 'url' => 'users/import/finish', 'class' => 'blue right', 'text' => lang('next'), 'tab_index' => tab_index()));
?>
			</div>
		</div>
		
	
</div>

<script>
Q.push(function() {
	$(".action-statuses").on("click", "span", function(e) {
		var status = $(this).data("action");
		var all_rows = $("tr[data-action]");
		if (status.length === 0) {
			all_rows.show();
			return;
Esempio n. 4
0
				<label for="username"><?php 
echo lang('username');
?>
</label>
				<?php 
echo form_input(array('name' => 'username', 'id' => 'username', 'size' => 30, 'maxlength' => 104, 'tabindex' => tab_index(), 'value' => set_value('username', '')));
?>

				<label for="password"><?php 
echo lang('password');
?>
</label>
				<?php 
echo form_password(array('name' => 'password', 'id' => 'password', 'size' => 30, 'maxlength' => 104, 'tabindex' => tab_index()));
?>

				<br>
				
				<?php 
echo form_button(array('type' => 'submit', 'class' => 'primary', 'text' => lang('login'), 'tab_index' => tab_index()));
?>

			</div>
			
		</div>

		<div class="one-third column">&nbsp;</div>

	</div>

</form>
Esempio n. 5
0
// ===== Defaults
$section = 'defaults';
$this->form->add_section($section, lang('users_import_defaults'), lang('users_import_defaults_hint'));
// ----- Password
$name = 'password';
$this->form->add_input(array('section' => $section, 'name' => $name, 'label' => lang('password'), 'content' => form_input(array('name' => $name, 'id' => $name, 'class' => 'text-input', 'size' => 30, 'max_length' => 100, 'autocomplete' => 'off', 'tabindex' => tab_index()))));
// ----- Group
$name = 'g_id';
$this->form->add_input(array('section' => $section, 'name' => $name, 'label' => lang('users_group'), 'content' => form_dropdown($name, $groups, '', 'tabindex="' . tab_index() . '" id="' . $name . '" class="text-input" ')));
// ----- Department
$local_departments = array('' => '');
$local_departments += $departments;
$name = 'd_id';
$this->form->add_input(array('section' => $section, 'name' => $name, 'label' => lang('users_import_department'), 'content' => form_dropdown($name, $local_departments, '', 'tabindex="' . tab_index() . '" id="' . $name . '" class="text-input" ')));
// ----- Email domain
$name = 'email_domain';
$default = end(explode('@', $this->session->userdata('u_email')));
$this->form->add_input(array('section' => $section, 'name' => $name, 'label' => lang('users_import_email_domain'), 'content' => form_input(array('name' => $name, 'id' => $name, 'class' => 'text-input', 'size' => 30, 'max_length' => 100, 'tabindex' => tab_index(), 'value' => $default))));
// ----- Enable account
$name = 'u_enabled';
$value = '1';
$content = form_hidden($name, '0');
$content .= '<label class="check">';
$content .= form_checkbox(array('name' => $name, 'id' => $name . '_1', 'tabindex' => tab_index(), 'value' => $value, 'checked' => FALSE));
$content .= '<strong>' . lang('users_import_enable_account') . '</strong>';
$content .= '</label><br>';
$this->form->add_input(array('section' => $section, 'name' => $name, 'content' => $content));
$this->form->add_button(form_button(array('type' => 'submit', 'class' => 'blue', 'text' => lang('next'), 'tab_index' => tab_index())));
echo form_open_multipart(current_url(), array('id' => 'user_import_1_form'));
echo $this->form->render();
echo '</form>';