Update 2024-01-19: css for optgroup select2, update option+optgroup from json, sub-modul menu with base url.
This commit is contained in:
@@ -366,6 +366,9 @@ table * .b { font-weight: bold !important; }
|
|||||||
table * .l { text-align: left !important; }
|
table * .l { text-align: left !important; }
|
||||||
table * .r { text-align: right !important; }
|
table * .r { text-align: right !important; }
|
||||||
table * .c { text-align: center !important; }
|
table * .c { text-align: center !important; }
|
||||||
|
table * .i { font-style: italic; }
|
||||||
|
table * .s { font-size: .65em; }
|
||||||
|
table * .bi { font-weight: bold; font-style: italic; }
|
||||||
table * .wr { white-space: normal !important; }
|
table * .wr { white-space: normal !important; }
|
||||||
table * .nwr { white-space: nowrap !important; }
|
table * .nwr { white-space: nowrap !important; }
|
||||||
table * .awr, table * .awr-400 { white-space: nowrap !important; max-width: 300px; overflow: hidden; text-overflow: ellipsis; }
|
table * .awr, table * .awr-400 { white-space: nowrap !important; max-width: 300px; overflow: hidden; text-overflow: ellipsis; }
|
||||||
@@ -375,6 +378,18 @@ table * .nb { border: 0 !important; }
|
|||||||
|
|
||||||
ul.dtr-details li.hidden { visibility: hidden !important; display: none !important; }
|
ul.dtr-details li.hidden { visibility: hidden !important; display: none !important; }
|
||||||
|
|
||||||
|
/******************************** Select2 ********************************/
|
||||||
|
|
||||||
|
.select2-results__option[role="group"] {
|
||||||
|
padding-left: 0 !important;
|
||||||
|
}
|
||||||
|
.select2-results__group {
|
||||||
|
/*background-color: var(--bs-gray-200, #9da5b1);*/
|
||||||
|
color: var(--bs-black, #000) !important;
|
||||||
|
text-transform: uppercase;
|
||||||
|
font-weight: bolder !important;
|
||||||
|
}
|
||||||
|
|
||||||
/******************************** Autocomplete ********************************/
|
/******************************** Autocomplete ********************************/
|
||||||
|
|
||||||
.bootstrap-autocomplete.dropdown-menu{
|
.bootstrap-autocomplete.dropdown-menu{
|
||||||
|
|||||||
+16
-5
@@ -4,9 +4,9 @@
|
|||||||
Desc. : JS - Fonia Custom Class v3
|
Desc. : JS - Fonia Custom Class v3
|
||||||
Created By : Siau Pheng ([email protected]).
|
Created By : Siau Pheng ([email protected]).
|
||||||
Created Date : June 19th, 2009.
|
Created Date : June 19th, 2009.
|
||||||
Last Modified : December 30th, 2023.
|
Last Modified : January 18th, 2024.
|
||||||
|
|
||||||
(c) 2009 - 2023, 3FONIA Software; WWW.3FONIA.COM.
|
(c) 2009 - 2024, 3FONIA Software; WWW.3FONIA.COM.
|
||||||
|
|
||||||
*******************************************************************/
|
*******************************************************************/
|
||||||
|
|
||||||
@@ -234,6 +234,7 @@ var FoniaJS = {
|
|||||||
}.bind(this));
|
}.bind(this));
|
||||||
},
|
},
|
||||||
genWinToolBut: function(menu) {//oke
|
genWinToolBut: function(menu) {//oke
|
||||||
|
if (!menu) return '';
|
||||||
var smenu = '';
|
var smenu = '';
|
||||||
if (typeof menu === 'object'){
|
if (typeof menu === 'object'){
|
||||||
var ma = ' me-sm-2'; smenu = '<div class="col-12 col-sm-6 my-0 mx-sm-0 text-center text-sm-start">';
|
var ma = ' me-sm-2'; smenu = '<div class="col-12 col-sm-6 my-0 mx-sm-0 text-center text-sm-start">';
|
||||||
@@ -256,6 +257,7 @@ var FoniaJS = {
|
|||||||
return smenu;
|
return smenu;
|
||||||
},
|
},
|
||||||
genToolButton: function(menu) {//oke
|
genToolButton: function(menu) {//oke
|
||||||
|
if (!menu) return '';
|
||||||
var smenu = '';
|
var smenu = '';
|
||||||
if (typeof menu === 'object'){
|
if (typeof menu === 'object'){
|
||||||
var ma = ' me-sm-2'; smenu = '<div class="row mt-2 my-sm-2 justify-content-sm-between"><div class="col-sm-6 text-center text-sm-start">';
|
var ma = ' me-sm-2'; smenu = '<div class="row mt-2 my-sm-2 justify-content-sm-between"><div class="col-sm-6 text-center text-sm-start">';
|
||||||
@@ -706,17 +708,26 @@ Request.JSONF = function(options){//oke
|
|||||||
/*if (ini.css) {
|
/*if (ini.css) {
|
||||||
optIni.prop('disabled', ini.css=='disabled');
|
optIni.prop('disabled', ini.css=='disabled');
|
||||||
}*/
|
}*/
|
||||||
|
if (!optIni) return;
|
||||||
if (ini.avalue) {
|
if (ini.avalue) {
|
||||||
optIni.empty().trigger('change');
|
optIni.empty();
|
||||||
|
var o_group = 0;
|
||||||
$(ini.avalue).each(function(n, i) {
|
$(ini.avalue).each(function(n, i) {
|
||||||
|
if (i.optgroup) {
|
||||||
|
if (0 < o_group++) optIni.append('</optgroup>');
|
||||||
|
optIni.append('<optgroup label="'+i.optgroup+'">');
|
||||||
|
return;
|
||||||
|
}
|
||||||
optIni.append($('<option>', {
|
optIni.append($('<option>', {
|
||||||
value: i.value, text: i.html || '\u00A0', label: i.text || '', 'olabel': i.label || ''
|
value: i.value, text: i.html || '\u00A0', label: i.text || '', 'olabel': i.label || ''
|
||||||
})).trigger('change');
|
}));
|
||||||
});
|
});
|
||||||
|
if (o_group > 0) optIni.append('</optgroup>');
|
||||||
}
|
}
|
||||||
if (ini.value) {
|
if (ini.value) {
|
||||||
optIni.val(ini.value).trigger('change');
|
optIni.val(ini.value);
|
||||||
}
|
}
|
||||||
|
optIni.trigger('change');
|
||||||
};
|
};
|
||||||
var make_table = function(ini){//oke
|
var make_table = function(ini){//oke
|
||||||
var divData = $('#'+ini.id).empty();
|
var divData = $('#'+ini.id).empty();
|
||||||
|
|||||||
+14
-1
@@ -117,14 +117,27 @@ final class App {
|
|||||||
$href1 = $this->apps['WEB_PATH'].'../';
|
$href1 = $this->apps['WEB_PATH'].'../';
|
||||||
$href2 = "";
|
$href2 = "";
|
||||||
} else {
|
} else {
|
||||||
|
$_prot = 'http';
|
||||||
|
$_host = $_SERVER['HTTP_HOST'];
|
||||||
|
if (isset($_SERVER['HTTPS'])) {
|
||||||
|
$_prot = ($_SERVER['HTTPS'] && $_SERVER['HTTPS'] != "off") ? "https" : "http";
|
||||||
|
}
|
||||||
|
$_prot .= "://";
|
||||||
if ($this->apps['PARENT_SUB']==true) {
|
if ($this->apps['PARENT_SUB']==true) {
|
||||||
|
$href1 = $_prot;
|
||||||
|
$href2 = ".". $_host;
|
||||||
|
} else {
|
||||||
|
$href1 = $_prot . $_host .'/';
|
||||||
|
$href2 = "";
|
||||||
|
}
|
||||||
|
/*if ($this->apps['PARENT_SUB']==true) {
|
||||||
$tmp_url = parse_url($this->apps['PARENT_SITE']);
|
$tmp_url = parse_url($this->apps['PARENT_SITE']);
|
||||||
$href1 = $tmp_url['scheme'] . "://";
|
$href1 = $tmp_url['scheme'] . "://";
|
||||||
$href2 = ".".$tmp_url['host'];
|
$href2 = ".".$tmp_url['host'];
|
||||||
} else {
|
} else {
|
||||||
$href1 = $this->apps['PARENT_SITE'].'/';
|
$href1 = $this->apps['PARENT_SITE'].'/';
|
||||||
$href2 = "";
|
$href2 = "";
|
||||||
}
|
}*/
|
||||||
}
|
}
|
||||||
foreach ($this->auser['MENU_MODUL'] as $modul) {
|
foreach ($this->auser['MENU_MODUL'] as $modul) {
|
||||||
$href = $href1.$modul['APP_PATH'].$href2;
|
$href = $href1.$modul['APP_PATH'].$href2;
|
||||||
|
|||||||
+4
-5
@@ -6,9 +6,9 @@
|
|||||||
Desc. : v3 - Form Generator (jQuery & Bootstrap)
|
Desc. : v3 - Form Generator (jQuery & Bootstrap)
|
||||||
Created By : Siau Pheng ([email protected]).
|
Created By : Siau Pheng ([email protected]).
|
||||||
Created Date : February 27th, 2008.
|
Created Date : February 27th, 2008.
|
||||||
Last Modified : July 5th, 2023.
|
Last Modified : January 19th, 2024.
|
||||||
|
|
||||||
(c) 2008 - 2023, 3FONIA Software; WWW.3FONIA.COM.
|
(c) 2008 - 2024, 3FONIA Software; WWW.3FONIA.COM.
|
||||||
|
|
||||||
*******************************************************************/
|
*******************************************************************/
|
||||||
|
|
||||||
@@ -43,15 +43,14 @@ final class Form {
|
|||||||
$_val2 = $val[0];
|
$_val2 = $val[0];
|
||||||
if ($bgroup) {
|
if ($bgroup) {
|
||||||
if (1==$val[1]) {
|
if (1==$val[1]) {
|
||||||
if (0<$n_group++) $tout .= '</optgroup>';
|
if (0 < $n_group++) $tout .= '</optgroup>';
|
||||||
$tout .= '<optgroup label="'.$_val2.'">';
|
$tout .= '<optgroup label="'.$_val2.'">';
|
||||||
//$n_group++;
|
continue;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$olabel = (isset($val[1])) ? ' olabel="'.$val[1].'"' : "";
|
$olabel = (isset($val[1])) ? ' olabel="'.$val[1].'"' : "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($bgroup && $val[1]==1) continue;
|
|
||||||
$tout .= '<option value="'.$key.'"'.$olabel;
|
$tout .= '<option value="'.$key.'"'.$olabel;
|
||||||
$aval = array($tvalue);
|
$aval = array($tvalue);
|
||||||
if ($bmulti==true) $aval = explode(",", ($tvalue ?? "0"));
|
if ($bmulti==true) $aval = explode(",", ($tvalue ?? "0"));
|
||||||
|
|||||||
Reference in New Issue
Block a user