Commit ee185670 authored by Carsten  Rose's avatar Carsten Rose
Browse files

Start to implement Label text align

parent 90f06a05
Pipeline #1331 passed with stage
in 2 minutes and 3 seconds
......@@ -451,7 +451,7 @@ class BuildFormBootstrap extends AbstractBuildForm {
* @throws UserFormException
* @throws UserReportException
*/
private function buildPillNavigation($mode , array $pillArray, array &$json) {
private function buildPillNavigation($mode, array $pillArray, array &$json) {
$pillButton = '';
$pillDropdown = '';
$htmlDropdown = '';
......@@ -697,7 +697,7 @@ EOF;
public function buildPill(array $formElement, $htmlFormElementName, $value, array &$json) {
$html = '';
if($formElement[FE_MODE]==FE_MODE_HIDDEN){
if ($formElement[FE_MODE] == FE_MODE_HIDDEN) {
return '';
}
......@@ -807,6 +807,9 @@ EOF;
if ($wrapArray[0] != '') {
$wrapArray[0] = Support::insertAttribute($wrapArray[0], 'id', $htmlId);
$wrapArray[0] = Support::insertAttribute($wrapArray[0], 'class', $class); // might be problematic, if there is already a 'class' defined.
if ($wrapName == FE_WRAP_LABEL) {
$wrapArray[0] = Support::insertAttribute($wrapArray[0], 'style', 'text-align: right;'); // might be problematic, if there is already a 'class' defined.
}
}
return $wrapArray[0] . $htmlElement . $wrapArray[1];
......
......@@ -132,6 +132,12 @@ $UPDATE_ARRAY = array(
"ALTER TABLE `MailLog` ADD `cc` TEXT NOT NULL AFTER `receiver`, ADD `bcc` TEXT NOT NULL AFTER `cc`;",
],
'19.1.2' => [
"ALTER TABLE `Form` ADD `labelAlign` ENUM('default','left','center','right') NOT NULL DEFAULT 'default' AFTER `forwardPage`;",
"ALTER TABLE `FormElement` ADD `labelAlign` ENUM('default','left','center','right') NOT NULL DEFAULT 'default' AFTER `maxLength`;",
],
);
......
......@@ -27,6 +27,7 @@ CREATE TABLE IF NOT EXISTS `Form`
`forwardMode` ENUM ('client', 'no', 'url', 'url-skip-history', 'url-sip') NOT NULL DEFAULT 'client',
`forwardPage` VARCHAR(255) NOT NULL DEFAULT '',
`labelAlign` ENUM ('default', 'left', 'center', 'right') NOT NULL DEFAULT 'default',
`bsLabelColumns` VARCHAR(255) NOT NULL DEFAULT '',
`bsInputColumns` VARCHAR(255) NOT NULL DEFAULT '',
`bsNoteColumns` VARCHAR(255) NOT NULL DEFAULT '',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment