您的位置:首页 > 其它

标准附件,如果上传了没有保存.怎么检查他是否上传了附件

2016-07-06 14:48 309 查看

String[]sPkValues=newString[]{pk1_value,pk2_value,pk3_value,pk4_value,pk5_value};

//验证缓存和DB
publicbooleanattachmentExistsInCache(OAApplicationModuleam,StringEntityName,

StringPklValue){

String[]sPkValue=newString[]{PklValue};
returnOAAttachmentServerUtils.attachmentExistsInCacheOrDb(am,EntityName,sPkValue);

}

//仅验证DB

publicbooleanattachmentExistsInCache(OAApplicationModuleam,StringEntityName,
StringPklValue){

String[]sPkValue=newString[]{PklValue};
returnOAAttachmentServerUtils.attachmentExists(am,EntityName,sPkValue);

}

//vo.setAssociationConsistent(true)方法应该是会去查询缓存中的数据

if(associationConsistent){
vo.setAssociationConsistent(associationConsistent);

}

setAssociationConsistent

publicvoidsetAssociationConsistent(booleanconsistent)

Setstheassociation-consistentflagforthisRowSet.
Association-consistentmodeallowstheusertoseedatathatincludeschangesnotyetpostedtodatabase,butatthecostofdegradedperformance.

Whenassociation-consistencyisontheRowSetwillreflectrowswithmodifiedforeignkeys,newlycreatedrows,andremoved(deleted)rows.Whenassociation-consistencyisofftheusermustpostpendingchangestodatabasetomakethemvisible.

ThismethodisrelevantonlyifthisRowSetwasonereturnedfromacalltoanentityassociationaccessor.


                                            
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: