Fix CSS
This commit is contained in:
parent
206caec290
commit
2f8ee92c51
@ -34,6 +34,11 @@ class FormWebsite
|
|||||||
*/
|
*/
|
||||||
public $error;
|
public $error;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* var int A number of lines
|
||||||
|
*/
|
||||||
|
public $num;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
@ -220,11 +225,11 @@ class FormWebsite
|
|||||||
* @param string $action Action on page that use this select list
|
* @param string $action Action on page that use this select list
|
||||||
* @param string $morecss More CSS
|
* @param string $morecss More CSS
|
||||||
* @param array $excludeids Exclude some ID in list
|
* @param array $excludeids Exclude some ID in list
|
||||||
* @return string HTML select component with list of type of containers
|
* @return string HTML select component with list of block containers
|
||||||
*/
|
*/
|
||||||
public function selectContainer($website, $htmlname = 'pageid', $pageid = 0, $showempty = 0, $action = '', $morecss = 'minwidth200', $excludeids = null)
|
public function selectContainer($website, $htmlname = 'pageid', $pageid = 0, $showempty = 0, $action = '', $morecss = 'minwidth200', $excludeids = null)
|
||||||
{
|
{
|
||||||
global $langs;
|
$this->num = 0;
|
||||||
|
|
||||||
$atleastonepage = (is_array($website->lines) && count($website->lines) > 0);
|
$atleastonepage = (is_array($website->lines) && count($website->lines) > 0);
|
||||||
|
|
||||||
@ -273,6 +278,8 @@ class FormWebsite
|
|||||||
$out .= '>';
|
$out .= '>';
|
||||||
$out .= $valueforoption;
|
$out .= $valueforoption;
|
||||||
$out .= '</option>';
|
$out .= '</option>';
|
||||||
|
|
||||||
|
++$this->num;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$out .= '</select>';
|
$out .= '</select>';
|
||||||
|
|||||||
@ -97,10 +97,7 @@ if (!empty($conf->global->THEME_DARKMODEENABLED)) {
|
|||||||
body {
|
body {
|
||||||
<?php if (GETPOST('optioncss', 'aZ09') == 'print') { ?>
|
<?php if (GETPOST('optioncss', 'aZ09') == 'print') { ?>
|
||||||
background-color: #FFFFFF;
|
background-color: #FFFFFF;
|
||||||
<?php } else { ?>
|
|
||||||
background: var(--colorbackbody);
|
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
color: var(--colortext);
|
|
||||||
font-size: <?php print is_numeric($fontsize) ? $fontsize.'px' : $fontsize; ?>;
|
font-size: <?php print is_numeric($fontsize) ? $fontsize.'px' : $fontsize; ?>;
|
||||||
line-height: 1.4;
|
line-height: 1.4;
|
||||||
font-family: <?php print $fontlist ?>;
|
font-family: <?php print $fontlist ?>;
|
||||||
@ -5398,6 +5395,9 @@ input.select2-input {
|
|||||||
{
|
{
|
||||||
background-color: var(--colorbackvmenu1);
|
background-color: var(--colorbackvmenu1);
|
||||||
}
|
}
|
||||||
|
.select2-container--default .select2-selection--single {
|
||||||
|
background-color: var(--colorbackbody);
|
||||||
|
}
|
||||||
#blockvmenusearch .select2-container--default .select2-selection--single .select2-selection__placeholder {
|
#blockvmenusearch .select2-container--default .select2-selection--single .select2-selection__placeholder {
|
||||||
color: var(--colortextbackvmenu);
|
color: var(--colortextbackvmenu);
|
||||||
}
|
}
|
||||||
@ -5506,6 +5506,8 @@ input.select2-input {
|
|||||||
/*background-color: var(--colorbackvmenu1);
|
/*background-color: var(--colorbackvmenu1);
|
||||||
border: 1px solid var(--colorbackvmenu1); */
|
border: 1px solid var(--colorbackvmenu1); */
|
||||||
box-shadow: 1px 2px 10px var(--colorbackvmenu1);
|
box-shadow: 1px 2px 10px var(--colorbackvmenu1);
|
||||||
|
background-color: var(--colorbackbody);
|
||||||
|
color: var(--colortext);
|
||||||
}
|
}
|
||||||
.select2-dropdown-open {
|
.select2-dropdown-open {
|
||||||
background-color: var(--colorbackvmenu1);
|
background-color: var(--colorbackvmenu1);
|
||||||
|
|||||||
@ -25,7 +25,7 @@ if (!defined('ISLOADEDBYSTEELSHEET')) die('Must be call by steelsheet'); ?>
|
|||||||
.info-box.info-box-sm {
|
.info-box.info-box-sm {
|
||||||
min-height: 80px;
|
min-height: 80px;
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
background: #fff;
|
/* background: #fff; */
|
||||||
}
|
}
|
||||||
.opened-dash-board-wrap .info-box.info-box-sm {
|
.opened-dash-board-wrap .info-box.info-box-sm {
|
||||||
border-radius: 0 0 0 20px;
|
border-radius: 0 0 0 20px;
|
||||||
|
|||||||
@ -2518,27 +2518,33 @@ if (!GETPOST('hide_websitemenu'))
|
|||||||
|
|
||||||
if ($action != 'addcontainer')
|
if ($action != 'addcontainer')
|
||||||
{
|
{
|
||||||
print '<span class="websiteselection">';
|
|
||||||
print $formwebsite->selectContainer($website, 'pageid', $pageid, 0, $action, 'maxwidth200onsmartphone');
|
|
||||||
print '</span>';
|
|
||||||
|
|
||||||
$urltocreatenewpage = $_SERVER["PHP_SEFL"].'?action=createcontainer&website='.$website->ref;
|
|
||||||
|
|
||||||
$out = '';
|
$out = '';
|
||||||
if (!empty($conf->use_javascript_ajax)) {
|
|
||||||
$out .= '<script language="javascript">';
|
$s = $formwebsite->selectContainer($website, 'pageid', $pageid, 0, $action, 'maxwidth200onsmartphone');
|
||||||
$out .= 'jQuery(document).ready(function () {';
|
|
||||||
$out .= ' jQuery("#pageid").change(function () {';
|
if ($formwebsite->num > 0) {
|
||||||
$out .= ' console.log("We select "+jQuery("#pageid option:selected").val());';
|
$out .= '<span class="websiteselection">';
|
||||||
$out .= ' if (jQuery("#pgeid option:selected").val() == \'-2\') {';
|
$out .= $s;
|
||||||
$out .= ' window.location.href = "'.$urltocreatenewpage.'";';
|
$out .= '</span>';
|
||||||
$out .= ' } else {';
|
|
||||||
$out .= ' window.location.href = "'.$_SERVER["PHP_SEFL"].'?website='.$website->ref.'&pageid="+jQuery("#pageid option:selected").val();';
|
$urltocreatenewpage = $_SERVER["PHP_SEFL"].'?action=createcontainer&website='.$website->ref;
|
||||||
$out .= ' }';
|
|
||||||
$out .= ' });';
|
if (!empty($conf->use_javascript_ajax)) {
|
||||||
$out .= '});';
|
$out .= '<script language="javascript">';
|
||||||
$out .= '</script>';
|
$out .= 'jQuery(document).ready(function () {';
|
||||||
|
$out .= ' jQuery("#pageid").change(function () {';
|
||||||
|
$out .= ' console.log("We select "+jQuery("#pageid option:selected").val());';
|
||||||
|
$out .= ' if (jQuery("#pgeid option:selected").val() == \'-2\') {';
|
||||||
|
$out .= ' window.location.href = "'.$urltocreatenewpage.'";';
|
||||||
|
$out .= ' } else {';
|
||||||
|
$out .= ' window.location.href = "'.$_SERVER["PHP_SEFL"].'?website='.$website->ref.'&pageid="+jQuery("#pageid option:selected").val();';
|
||||||
|
$out .= ' }';
|
||||||
|
$out .= ' });';
|
||||||
|
$out .= '});';
|
||||||
|
$out .= '</script>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
print $out;
|
print $out;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -2579,9 +2585,9 @@ if (!GETPOST('hide_websitemenu'))
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ($pagepreviousid) print '<a class="valignmiddle" href="'.$_SERVER['PHP_SELF'].'?website='.urlencode($object->ref).'&pageid='.$pagepreviousid.'&action='.$action.'">'.img_previous($langs->trans("PreviousContainer")).'</a>';
|
if ($pagepreviousid) print '<a class="valignmiddle" href="'.$_SERVER['PHP_SELF'].'?website='.urlencode($object->ref).'&pageid='.$pagepreviousid.'&action='.$action.'">'.img_previous($langs->trans("PreviousContainer")).'</a>';
|
||||||
else print '<span class="valignmiddle opacitymedium">'.img_previous($langs->trans("PreviousContainer")).'</span>';
|
else print '<span class="valignmiddle opacitymedium">'.img_previous($langs->trans("Previous")).'</span>';
|
||||||
if ($pagenextid) print '<a class="valignmiddle" href="'.$_SERVER['PHP_SELF'].'?website='.urlencode($object->ref).'&pageid='.$pagenextid.'&action='.$action.'">'.img_next($langs->trans("NextContainer")).'</a>';
|
if ($pagenextid) print '<a class="valignmiddle" href="'.$_SERVER['PHP_SELF'].'?website='.urlencode($object->ref).'&pageid='.$pagenextid.'&action='.$action.'">'.img_next($langs->trans("NextContainer")).'</a>';
|
||||||
else print '<span class="valignmiddle opacitymedium">'.img_next($langs->trans("NextContainer")).'</span>';
|
else print '<span class="valignmiddle opacitymedium">'.img_next($langs->trans("Next")).'</span>';
|
||||||
|
|
||||||
$websitepage = new WebSitePage($db);
|
$websitepage = new WebSitePage($db);
|
||||||
if ($pageid > 0 && ($action == 'preview' || $action == 'createfromclone' || $action == 'createpagefromclone'))
|
if ($pageid > 0 && ($action == 'preview' || $action == 'createfromclone' || $action == 'createpagefromclone'))
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user