dropdowns
This commit is contained in:
@@ -59,28 +59,29 @@ var EcmDropdownEditor_save = function(dom, container) {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
var doms = EcmDropdownEditor_parseArrays(dom);
|
var doms = EcmDropdownEditor_parseArrays(dom);
|
||||||
var params = new Array;
|
var params = [];
|
||||||
params[0] = dom; //name of list
|
params[0] = dom; //name of list
|
||||||
params[1] = doms;//list of values
|
params[1] = doms;//list of values
|
||||||
// AJAX call
|
// AJAX call
|
||||||
jQuery.ajax({
|
jQuery.ajax({
|
||||||
type : 'POST',
|
type : "POST",
|
||||||
url : 'index.php?entryPoint=HandleEcmAjax',
|
url : "index.php?entryPoint=HandleEcmAjax",
|
||||||
data : {
|
data : {
|
||||||
ecmclass : 'EcmDropdownEditor',
|
ecmclass : "EcmDropdownEditor",
|
||||||
job : 'saveDom',
|
job : "saveDom",
|
||||||
params : utf8_to_b64(JSON.stringifyNoSecurity(params)),
|
params : utf8_to_b64(JSON.stringifyNoSecurity(params)),
|
||||||
},
|
},
|
||||||
dataType : 'json',
|
dataType : "json",
|
||||||
async : false,
|
async : false,
|
||||||
success : function(response) {
|
success : function() {
|
||||||
var div = $('[name='+container+']');
|
setTimeout(function() {
|
||||||
div.hide();
|
|
||||||
EcmDropdownEditor_refreshField(container);
|
EcmDropdownEditor_refreshField(container);
|
||||||
return;
|
var div = $("[name="+container+"]");
|
||||||
|
div.hide();
|
||||||
|
}, 3000);
|
||||||
},
|
},
|
||||||
error : function(xhr, ajaxOptions, thrownError) {
|
error : function(xhr, ajaxOptions, thrownError) {
|
||||||
console.log(thrownError);
|
window.console.log(thrownError);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -94,16 +95,17 @@ var EcmDropdownEditor_refreshField = function(container) {
|
|||||||
params[1] = container;//list of values
|
params[1] = container;//list of values
|
||||||
// AJAX call
|
// AJAX call
|
||||||
jQuery.ajax({
|
jQuery.ajax({
|
||||||
type : 'POST',
|
type : "POST",
|
||||||
url : 'index.php?entryPoint=HandleEcmAjax',
|
url : "index.php?entryPoint=HandleEcmAjax",
|
||||||
data : {
|
data : {
|
||||||
ecmclass : 'EcmDropdownEditor',
|
ecmclass : "EcmDropdownEditor",
|
||||||
job : 'refreshField',
|
job : "refreshField",
|
||||||
params : utf8_to_b64(JSON.stringifyNoSecurity(params)),
|
params : utf8_to_b64(JSON.stringifyNoSecurity(params)),
|
||||||
},
|
},
|
||||||
dataType : 'json',
|
dataType : "json",
|
||||||
async : false,
|
async : false,
|
||||||
success : function(response) {
|
success : function(response) {
|
||||||
|
console.log('EditedDropdown', response);
|
||||||
var tmp = container.split("___");
|
var tmp = container.split("___");
|
||||||
$('form[name=EditView]').find('select[name='+tmp[0]+']').html(response[0]);
|
$('form[name=EditView]').find('select[name='+tmp[0]+']').html(response[0]);
|
||||||
return;
|
return;
|
||||||
|
|||||||
3
include/language/en_us.EcmDropdownEditor.php
Normal file → Executable file
3
include/language/en_us.EcmDropdownEditor.php
Normal file → Executable file
@@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
// created: 2025-08-13 12:56:45
|
// created: 2025-08-30 09:18:40
|
||||||
$customDoms = array (
|
$customDoms = array (
|
||||||
'ecmproducts_attribute_dom' =>
|
'ecmproducts_attribute_dom' =>
|
||||||
array (
|
array (
|
||||||
@@ -321,6 +321,7 @@ $customDoms = array (
|
|||||||
'end_of_line' => 'Non Active',
|
'end_of_line' => 'Non Active',
|
||||||
'active' => 'Active',
|
'active' => 'Active',
|
||||||
'new' => 'New',
|
'new' => 'New',
|
||||||
|
'e8d1191e-2c7b-c24d-88e2-68b2bd076498' => 'test',
|
||||||
),
|
),
|
||||||
'ecmsales_status_dom' =>
|
'ecmsales_status_dom' =>
|
||||||
array (
|
array (
|
||||||
|
|||||||
3
include/language/pl_pl.EcmDropdownEditor.php
Normal file → Executable file
3
include/language/pl_pl.EcmDropdownEditor.php
Normal file → Executable file
@@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
// created: 2025-08-13 12:56:45
|
// created: 2025-08-30 09:18:40
|
||||||
$customDoms = array (
|
$customDoms = array (
|
||||||
'ecmproducts_attribute_dom' =>
|
'ecmproducts_attribute_dom' =>
|
||||||
array (
|
array (
|
||||||
@@ -322,6 +322,7 @@ $customDoms = array (
|
|||||||
'end_of_line' => 'Nieaktywny',
|
'end_of_line' => 'Nieaktywny',
|
||||||
'active' => 'Aktywny',
|
'active' => 'Aktywny',
|
||||||
'new' => 'Nowość',
|
'new' => 'Nowość',
|
||||||
|
'e8d1191e-2c7b-c24d-88e2-68b2bd076498' => 'test',
|
||||||
),
|
),
|
||||||
'ecmsales_status_dom' =>
|
'ecmsales_status_dom' =>
|
||||||
array (
|
array (
|
||||||
|
|||||||
Reference in New Issue
Block a user