QRCode lib
This commit is contained in:
@ -42,6 +42,9 @@ class SRec
|
||||
this.uid=getUID();
|
||||
this.request = new TRequest(this);
|
||||
SRec_mas[this.uid]=this;
|
||||
|
||||
this.onUpdate=null; //For call set function
|
||||
this.onInsert=null; //For call set function
|
||||
}
|
||||
|
||||
applyReq(req,fn,node,xmldoc)
|
||||
@ -56,7 +59,7 @@ class SRec
|
||||
let smallText = '';
|
||||
let pos1=fullText.indexOf('[[');
|
||||
let pos2=fullText.indexOf(']]');
|
||||
if(pos1>0 && pos2>0 && pos1<pos2) smallText=fullText.substring(pos1+2, pos2);
|
||||
if(pos1>=0 && pos2>=0 && pos1<pos2) smallText=fullText.substring(pos1+2, pos2);
|
||||
|
||||
if(fullText.indexOf("id456[[")>=0){ //Если есть идентификатор того что это перезапись
|
||||
let okFunc=()=>{
|
||||
@ -1583,17 +1586,21 @@ class SRec
|
||||
erec.opener=this;
|
||||
erec.eRecNo(this.nodeMetadata,-1);
|
||||
erec.win.setParent(this.win);
|
||||
|
||||
if(this.onInsert!=null) this.onInsert(erec);
|
||||
}
|
||||
|
||||
updateRecord(id)
|
||||
{
|
||||
if(this.f_State=="0") //editing
|
||||
{
|
||||
let eRec = new EdtRec("");
|
||||
eRec.win.setParent(this.win);
|
||||
eRec.opener=this;
|
||||
eRec.eRecNo(this.nodeMetadata,id);
|
||||
let erec = new EdtRec("");
|
||||
erec.win.setParent(this.win);
|
||||
erec.opener=this;
|
||||
erec.eRecNo(this.nodeMetadata,id);
|
||||
//e.win.setLeftTop(pageX-10,pageY-10);
|
||||
|
||||
if(this.onInsert!=null) this.onUpdate(erec);
|
||||
}else
|
||||
if(this.f_State=="1") //select one record
|
||||
{
|
||||
@ -1613,11 +1620,13 @@ class SRec
|
||||
this.opener.setFilterObject(this.f_TypeName, this.f_PropName, id, filter);
|
||||
this.win.Close();
|
||||
}else{
|
||||
let eRec = new EdtRec("");
|
||||
eRec.win.setParent(this.win);
|
||||
eRec.opener=this;
|
||||
eRec.eRecNo(this.nodeMetadata,id);
|
||||
let erec = new EdtRec("");
|
||||
erec.win.setParent(this.win);
|
||||
erec.opener=this;
|
||||
erec.eRecNo(this.nodeMetadata,id);
|
||||
//e.win.setLeftTop(pageX-10,pageY-10);
|
||||
|
||||
if(this.onInsert!=null) this.onUpdate(erec);
|
||||
}
|
||||
}else
|
||||
if(this.f_State=="2") //Multiple choice (on the records of ticking TODO is not implemented)
|
||||
|
||||
Reference in New Issue
Block a user