jquery注入页面

msyndra 2011-01-22

//加载已建立关系的上传数据列表,由上传组件使用页面调用

functionattachmentList(divId,objectId,objectType,flag){

varseqIdsValue=JQ("#attach_seqIds_"+divId).value==null?"":JQ("#attach_seqIds_"+divId).value;

vardelSeqIdsValue=JQ("#attach_delSeqIds_"+divId).value==null?"":JQ("#attach_delSeqIds_"+divId).value;

JQ.ajax({

url:"/spi/attachment/upload.shtml?objectid="+objectId+"&objectType="+objectType+"&seqIds="+seqIdsValue+"&delSeqIds="+delSeqIdsValue+"&flag="+flag+"&divid="+divId,

cache:false,

data:"",

success:function(html){

vardivname="#"+divId+"_c1";

JQ(divName).html(html);

}

});

}

//加载上传控件form及未建立关系的上传数据列表,由上传组件使用页面调用

functionuploadAttachment(divId,objectId,objectType,flag){

varseqIdsValue=JQ("#attach_seqIds_"+divId).value==null?"":JQ("#attach_seqIds_"+divId).value;

vardelSeqIdsValue=JQ("#attach_delSeqIds_"+divId).value==null?"":JQ("#attach_delSeqIds_"+divId).value;

JQ.ajax({

url:"/spi/attachment/uploadattachment.shtml?objectid="+objectId+"&objectType="+objectType+"&seqIds="+seqIdsValue+"&delSeqIds="+delSeqIdsValue+"&flag="+flag+"&divid="+divId,

cache:false,

data:"",

success:function(html){

vardivname="#"+divId+"_c2";

JQ(divName).html(html);

}

});

}

相关推荐