\
+ \
\
@@ -185,7 +185,7 @@ class SRec
document.getElementById('SRec_Add_'+this.uid).onclick = ()=>this.insertRecord();
document.getElementById('SRec_Del_'+this.uid).onclick = ()=>this.deleteRecord();
- document.getElementById('SRec_Exc_'+this.uid).onclick = ()=>this.showreport('xls');
+ document.getElementById('SRec_Exc_'+this.uid).onclick = ()=>this.showReport('xls');
document.getElementById('SRec_Rfr_'+this.uid).onclick = ()=>{this.appendFilter(); this.sendFilter(-1,0);};
}
@@ -718,45 +718,78 @@ class SRec
}else
if (columnNode.getAttribute("vt")==="i4")
{
- let table=document.createElement('table');
- table.border=0;
- table.style.cssText="width:100%;/*table-layout:fixed;*/border-spacing:0;border-collapse:collapse;";
- let newRow=table.insertRow(0); //We add a row in the created table.
- let newCell1 = newRow.insertCell(0);
- newCell1.style.cssText="padding:0px;padding-right:1px;width:100%;";
- let newCell2 = newRow.insertCell(1);
- newCell2.style.cssText="padding:0px;padding-right:1px;height:100%;";
- let newCell3 = newRow.insertCell(2);
- newCell3.style.cssText="padding:0px;width:25px;height:100%;";
+ let opt=findNode(columnNode, "options");
+ if(opt!=null) //If combobox
+ {
+ let select = document.createElement('select');
+ select.style.cssText="width: 100%;";
+ select.setAttribute("name",columnNode.getAttribute("n"));
+ select.setAttribute("id", 'filter_' + this.uid + '_' + columnNode.getAttribute("n"));
+ opt=opt.firstChild
+ while(opt!=null)
+ {
+ if(opt.nodeName=="option")
+ {
+ let option = document.createElement("option");
+ option.setAttribute("value",opt.getAttribute("val"));
+ option.appendChild(document.createTextNode(opt.getAttribute("d")));
+ select.appendChild( option );
+ }
+ opt=opt.nextSibling;
+ }
+ td2.appendChild(select);
- let input = document.createElement('input');
- input.style.cssText="width: 100%;";
- input.setAttribute("type","text");
- input.onkeydown=function(){ if(event.keyCode==13) event.keyCode=9; };
- input.setAttribute("name",columnNode.getAttribute("n"));
- if(columnNode.getAttribute("size")!=null)
- input.setAttribute("maxlength",columnNode.getAttribute("size"),0);
- input.setAttribute("value",value);
- input.setAttribute("id",'filter_'+this.uid+'_'+columnNode.getAttribute("n"));
- newCell1.appendChild( input );
+ }else {
+ let table = document.createElement('table');
+ table.border = 0;
+ table.style.cssText = "width:100%;/*table-layout:fixed;*/border-spacing:0;border-collapse:collapse;";
+ let newRow = table.insertRow(0); //We add a row in the created table.
+ let newCell1 = newRow.insertCell(0);
+ newCell1.style.cssText = "padding:0px;padding-right:1px;width:100%;";
+ let newCell2 = newRow.insertCell(1);
+ newCell2.style.cssText = "padding:0px;padding-right:1px;height:100%;";
+ let newCell3 = newRow.insertCell(2);
+ newCell3.style.cssText = "padding:0px;width:25px;height:100%;";
- let button = document.createElement('input');
- button.className='button-secondary';
- button.setAttribute("type","button");
- button.setAttribute("value","+");
- button.style.cssText="height:100%;width:22px;margin:0px;padding:0px;";
- newCell2.appendChild( button );
- button.onclick=function(inp){return function(){ inp.value=getIntVal(inp.value)+1; }}(input);
+ let input = document.createElement('input');
+ input.style.cssText = "width: 100%;";
+ input.setAttribute("type", "text");
+ input.onkeydown = function () {
+ if (event.keyCode == 13) event.keyCode = 9;
+ };
+ input.setAttribute("name", columnNode.getAttribute("n"));
+ if (columnNode.getAttribute("size") != null)
+ input.setAttribute("maxlength", columnNode.getAttribute("size"), 0);
+ input.setAttribute("value", value);
+ input.setAttribute("id", 'filter_' + this.uid + '_' + columnNode.getAttribute("n"));
+ newCell1.appendChild(input);
- button = document.createElement('input');
- button.className='button-secondary';
- button.setAttribute("type","button");
- button.setAttribute("value","-");
- button.style.cssText="height:100%;width:22px;margin:0px;padding:0px;";
- button.onclick=function(inp){return function(){ inp.value=getIntVal(inp.value)-1; }}(input);
- newCell3.appendChild( button );
+ let button = document.createElement('input');
+ button.className = 'button-secondary';
+ button.setAttribute("type", "button");
+ button.setAttribute("value", "+");
+ button.style.cssText = "height:100%;width:22px;margin:0px;padding:0px;";
+ newCell2.appendChild(button);
+ button.onclick = function (inp) {
+ return function () {
+ inp.value = getIntVal(inp.value) + 1;
+ }
+ }(input);
- td2.appendChild( table );
+ button = document.createElement('input');
+ button.className = 'button-secondary';
+ button.setAttribute("type", "button");
+ button.setAttribute("value", "-");
+ button.style.cssText = "height:100%;width:22px;margin:0px;padding:0px;";
+ button.onclick = function (inp) {
+ return function () {
+ inp.value = getIntVal(inp.value) - 1;
+ }
+ }(input);
+ newCell3.appendChild(button);
+
+ td2.appendChild(table);
+ }
}else
if (columnNode.getAttribute("vt")==="f8")
{
@@ -1437,7 +1470,7 @@ class SRec
if (error_msg!="") alert2(trt('Alert'),"ShowRecords: \n"+error_msg);
}
- showreport(ext)
+ showReport(ext)
{
if(this.rwin!=null) this.rwin.Close();
@@ -1446,7 +1479,7 @@ class SRec
this.rwin.setParent(this.win);
this.rwin.setSize(280,130);
this.rwin.setCaption(trt('Report'));
- this.rwin.setContent('| '+trt('Preparing_of_report')+' | ');
+ this.rwin.setContent('| '+trt('Preparing_of_report')+' | ');
this.appendFilter();
//Call data from server
diff --git a/metadata/dbms/tools.js b/metadata/dbms/tools.js
index bf87b64..9974634 100644
--- a/metadata/dbms/tools.js
+++ b/metadata/dbms/tools.js
@@ -191,7 +191,7 @@ function loadContent(url,obj)
}
//Вывести текст поверх окон с кнопочкой OK
-function alert2(title,text)
+function alert2(title,text,okFunc=null)
{
let win=new TWin(true);
win.BuildGUI(10,10);
@@ -209,7 +209,7 @@ function alert2(title,text)
win.setContent(html);
let obj=document.getElementById(win.uid+'_close');
- if(obj!=null) obj.onclick=function(win){return function(){ win.Close(); };}(win);
+ if(obj!=null) obj.onclick=function(win,okFunc){return function(){ win.Close(); if(okFunc!=null) okFunc(); };}(win,okFunc);
win.setSize("300px","150px");
win.setCenter();
win.shadow=true;
@@ -1209,7 +1209,7 @@ class TWin
this.tWinId=Wins.add(this);
/*
var hd='';
- hd+='';
+ hd+='';
hd+=' ';
hd+='  | ';
hd+=' | ';
@@ -1223,7 +1223,7 @@ class TWin
hd+=' ';
var str='';
- str+='';
+ str+='';
str+=' | '+hd+' | ';
str+=' ';
str+='  | ';
@@ -1232,7 +1232,7 @@ class TWin
str+=' ';
str+=' ';
str+=' | ';
- str+=' | ';
+ str+=' | ';
str+=' | ';
str+=' ';
str+=' ';
@@ -1244,8 +1244,8 @@ class TWin
*/
/*
var str='';
- str+='';
- str+=' | | | ';
+ str+='';
+ str+=' | | | ';
str+=' ';
str+='  | ';
str+=' | ';
@@ -1253,7 +1253,7 @@ class TWin
str+=' ';
str+=' ';
str+=' | ';
- str+=' | ';
+ str+=' | ';
str+=' | ';
str+=' ';
str+=' ';
@@ -1272,8 +1272,8 @@ class TWin
}
let str='';
- str+='';
- str+=' | | '+(this.disableClosing ? '' : ' ')+' |
| | ';
+ str+='';
+ str+=' | | '+(this.disableClosing ? '' : ' ')+' |
| | ';
str+=' ';
str+='  | ';
str+=' | ';
@@ -1281,7 +1281,7 @@ class TWin
str+=' ';
str+=' ';
str+=' | ';
- str+=' | ';
+ str+=' | ';
str+=' | ';
str+=' ';
str+=' ';
diff --git a/metadata/include/captcha.php b/metadata/include/captcha.php
index f6459cf..2c63972 100644
--- a/metadata/include/captcha.php
+++ b/metadata/include/captcha.php
@@ -54,4 +54,4 @@ if (isset($_REQUEST['id'])) $id = $_REQUEST['id']; else $id = '';
header ("Content-type: image/gif");
imagegif($src);
-?>
+
diff --git a/metadata/include/kcfinder/conf/config.php b/metadata/include/kcfinder/conf/config.php
index 844b9b5..1975fb0 100644
--- a/metadata/include/kcfinder/conf/config.php
+++ b/metadata/include/kcfinder/conf/config.php
@@ -23,7 +23,7 @@ $_CONFIG = array(
'disabled' => false,
'uploadURL' => "upload",
- 'uploadDir' => "O:/www/www.bigfoottrade.kz_old/shop/",
+ 'uploadDir' => "O:/www/www.rigor.kz_old/shop/",
'theme' => "default",
'types' => array(
diff --git a/metadata/include/tools.php b/metadata/include/tools.php
index f9b66e9..fe19623 100644
--- a/metadata/include/tools.php
+++ b/metadata/include/tools.php
@@ -13,10 +13,10 @@ function getScript($path)
//Функция для перевода текста без применения GetText "trt("
function trt($text)
{
- global $db;
+ global $db,$Schema;
$result='';
- $sql='select translation from main._translations where del=false and language_id='.$_SESSION["LNG"].' and identifier=\''.$text.'\';';
+ $sql='select translation from '.$Schema.'_translations where del=false and language_id='.$_SESSION["LNG"].' and identifier=\''.$text.'\';';
//$sql='select translation from main._translations where del=false and language_id=(select id from main._languages where short_name=\''.$_SESSION["LNG"].'\') and identifier=\''.$text.'\';';
$res = NULL;
try
diff --git a/metadata/tree/tree.js b/metadata/tree/tree.js
index 4fb377c..eb6273d 100644
--- a/metadata/tree/tree.js
+++ b/metadata/tree/tree.js
@@ -285,7 +285,7 @@ function TMenu(v_obj,v_scr,v_treepath) //Горизонтальное меню
pn=pn.parent;
}
//Шаблон кнопки по умолчанию
- if(str=='') str='';
+ if(str=='') str='';
str=str.replace(/\${path}/g, tn.getTreePath());
str=str.replace(/\${hash}/g, crc32(tn.getTreePath()));
@@ -417,7 +417,7 @@ function TMenu(v_obj,v_scr,v_treepath) //Горизонтальное меню
if(str!='') break;
nTmp=nTmp.parentNode;
}
- if(str=='') str='';
+ if(str=='') str='';
str=str.replace(/\${path}/g, this.m_tn[this.m_tn.length-1].getTreePath());
str=str.replace(/\${name}/g, getCdataValue(nodeTree));
str=str.replace(/\${none}/g, nodeTree.getAttribute("c")=='1' ? 'block' : 'none');
diff --git a/metadata/tree/treetools.php b/metadata/tree/treetools.php
index c30cf44..b7507e1 100644
--- a/metadata/tree/treetools.php
+++ b/metadata/tree/treetools.php
@@ -502,11 +502,8 @@ function getSiteMap($nParent,$nParams,$db,$first,$path)
}
$rСol.=''."\n";
- if($url=='')
- { $url=getHashFromPath($path.$treeid.';'.$fid.';');
- }
$result.=' '."\n";
- $result.=' http://'.$_SERVER["SERVER_NAME"].'/shop/'.$url.'.html'."\n";
+ $result.=' https://'.$_SERVER["SERVER_NAME"].$url.''."\n";
$result.=' '.$date.''."\n";
$result.=' daily'."\n";
$result.=' '."\n";
|
|