responsive settings

This commit is contained in:
Roland Gruber 2017-12-17 12:03:43 +01:00
parent b6d130ce14
commit 07b885a2ad
1 changed files with 7 additions and 20 deletions

View File

@ -2251,36 +2251,23 @@ class sambaSamAccount extends baseModule implements passwordService {
} }
/** /**
* Returns a list of self service configuration settings. * {@inheritDoc}
* * @see baseModule::getSelfServiceSettings()
* Calling this method does not require the existence of an enclosing {@link accountContainer}.<br>
* <br>
* The name attributes are used as keywords to load
* and save settings. We recommend to use the module name as prefix for them
* (e.g. posixAccount_homeDirectory) to avoid naming conflicts.
*
* @param selfServiceProfile $profile currently edited profile
* @return htmlElement meta HTML object
*
* @see baseModule::get_metaData()
* @see htmlElement
*/ */
public function getSelfServiceSettings($profile) { public function getSelfServiceSettings($profile) {
$selfServiceContainer = new htmlTable(); $selfServiceContainer = new htmlResponsiveRow();
// domain suffix // domain suffix
$selfServiceDomainSuffix = new htmlTableExtendedInputField(_('Domain suffix'), 'sambaSamAccount_domainSuffix'); $selfServiceDomainSuffix = new htmlResponsiveInputField(_('Domain suffix'), 'sambaSamAccount_domainSuffix', null, array('domainSuffix', get_class($this)));
$selfServiceContainer->addElement($selfServiceDomainSuffix); $selfServiceContainer->add($selfServiceDomainSuffix, 12);
$selfServiceContainer->addElement(new htmlHelpLink('domainSuffix', get_class($this)), true);
// password history // password history
$historyOptions = array( $historyOptions = array(
_('yes - ordered ascending') => 'yes_deleteLast', _('yes - ordered ascending') => 'yes_deleteLast',
_('yes - ordered descending') => 'yes_deleteFirst', _('yes - ordered descending') => 'yes_deleteFirst',
_('no') => 'no' _('no') => 'no'
); );
$historySelect = new htmlTableExtendedSelect('sambaSamAccount_history', $historyOptions, array('yes_deleteLast'), _("Password history")); $historySelect = new htmlResponsiveSelect('sambaSamAccount_history', $historyOptions, array('yes_deleteLast'), _("Password history"), array('history', get_class($this)));
$historySelect->setHasDescriptiveElements(true); $historySelect->setHasDescriptiveElements(true);
$selfServiceContainer->addElement($historySelect); $selfServiceContainer->add($historySelect, 12);
$selfServiceContainer->addElement(new htmlHelpLink('history', get_class($this)), true);
return $selfServiceContainer; return $selfServiceContainer;
} }