no commit message
This commit is contained in:
@@ -471,7 +471,7 @@ var inputtwo={
|
||||
if(!da || da.length==0)return;
|
||||
var o2 = $(o1),lefta=o2.offset(),i,len=da.length,ds=[],zl=10,j=0;
|
||||
$('#completelist').remove();
|
||||
var str= '<div id="completelist" style="position:absolute;z-index:9;left:'+lefta.left+'px;top:'+(lefta.top+29)+'px;background:white;border:1px var(--main-color) solid;box-shadow: 0px 0px 5px rgb(0,0,0,0.3)"></div>';
|
||||
var str= '<div id="completelist" style="position:absolute;z-index:9;left:'+lefta.left+'px;top:'+(lefta.top+29)+'px;background:white;border:1px var(--main-color) solid;border-radius:5px;box-shadow: 0px 0px 5px rgb(0,0,0,0.3)"></div>';
|
||||
var val= strreplace(o1.value);
|
||||
if(val){
|
||||
for(i=0;i<len;i++)if(da[i].name.indexOf(val)>-1 || (da[i].subname && da[i].subname.indexOf(val)>-1)){
|
||||
@@ -497,7 +497,7 @@ var inputtwo={
|
||||
if(j>=zl)break;
|
||||
}
|
||||
if(len>zl){
|
||||
str+='<div style="padding:5px 10px;background:#eeeeee">总记录'+len+'条';
|
||||
str+='<div style="padding:5px 10px;background:rgba(0,0,0,0.1)">总记录'+len+'条';
|
||||
if(p>1)str+=' <a href="javascript:;" class="zhu" onclick="c.autocompleteshows(\''+zl+'\','+(p-1)+')"><上页</a>';
|
||||
if(j==zl)str+=' <a href="javascript:;" class="zhu" onclick="c.autocompleteshows(\''+zl+'\','+(p+1)+')">下页></a>';
|
||||
str+='</div>';
|
||||
|
||||
75
webmain/flow/input/inputjs/mode_custprice.js
Normal file
75
webmain/flow/input/inputjs/mode_custprice.js
Normal file
@@ -0,0 +1,75 @@
|
||||
//流程模块【custprice.报价单】下录入页面自定义js页面,初始函数
|
||||
function initbodys(){
|
||||
|
||||
//记录原来选择的
|
||||
c.daossdts=[];
|
||||
c.onselectdatabefore=function(){
|
||||
this.daossdts = this.getsubdata(0);
|
||||
}
|
||||
|
||||
//这个是很复杂的叠加关系,时间久了谁也不知道是干嘛用的
|
||||
c.onselectdataall=function(fid,seld,sna,sid){
|
||||
if(!seld || !sna)return;
|
||||
var da = [];
|
||||
if(!seld[0]){
|
||||
da[0]=seld;
|
||||
}else{
|
||||
da = seld;
|
||||
}
|
||||
var nam = this.getxuandoi(fid),snua;
|
||||
var dao=this.daossdts,i,j,bo,d,oi=parseFloat(nam[1]),oii=-1;
|
||||
for(i=0;i<da.length;i++){
|
||||
d = da[i];
|
||||
bo = false;
|
||||
for(j=0;j<dao.length;j++)if(dao[j].aid==d.value)bo=true;
|
||||
oii++;
|
||||
if(!bo){
|
||||
if(oii>0){
|
||||
snua= ''+nam[3]+''+nam[0]+'_'+(oi+oii)+'';
|
||||
if(!form(snua) || form(snua).value!=''){
|
||||
nam = this.insertrow(0,{},true);
|
||||
}else{
|
||||
nam[1]=parseFloat(nam[1])+1;
|
||||
}
|
||||
}
|
||||
this.setrowdata(nam[0],nam[1],{
|
||||
unit:d.unit,
|
||||
price:d.price,
|
||||
temp_aid:d.name,
|
||||
aid:d.value
|
||||
});
|
||||
|
||||
}else{
|
||||
oii--;
|
||||
if(i==0){
|
||||
this.setrowdata(nam[0],nam[1],{
|
||||
unit:'',
|
||||
price:'0',
|
||||
temp_aid:'',
|
||||
aid:'0'
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
function changesubmit(){
|
||||
if(get('tablesub0')){
|
||||
var da = c.getsubdata(0),d1;
|
||||
for(var i=0;i<da.length;i++){
|
||||
d1 = da[i];
|
||||
if(!d1.aid)return '行['+(i+1)+']必须选择物品';
|
||||
if(d1.count<=0)return '行['+(i+1)+']数量必须大于0';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function eventaddsubrows(xu,oj){
|
||||
c.setrowdata(xu,oj,{
|
||||
aid:'0'
|
||||
});
|
||||
}
|
||||
@@ -13,4 +13,8 @@ function changesubmit(d){
|
||||
if(!d.rankings)len2=0;
|
||||
if(len2!=len1)return '多部门和多职位的数量不一致';
|
||||
}
|
||||
|
||||
js.setoption('userjson','');
|
||||
js.setoption('deptjson','');
|
||||
js.setoption('groupjson','');
|
||||
}
|
||||
Reference in New Issue
Block a user