版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)
文檔簡介
importjava.io.InputStream;importimportimportjava.util.ArrayList;importjava.util.Date;importjava.util.List;importimportimportimportimportimportimport.apache.poi.ss.usermodel.Cell;importimportimportimportimport.springframework.stereotype.Controller;importimport.springframework.web.bind.annotation.RequestMap;import.springframework.web.multipart.MultipartFile;importimport.springframework.web.servlet.ModelAndView;importcom.hiveview.newicp.core.message.ExceptionEnum;importcom.hiveview.newicp.core.pojo.base.Data;importimportcom.hiveview.newicp.core.pojo.vo.vip.blueray.AlbumVo;importimportcom.hiveview.newicp.core.util.DateUtil;@RequestMap(value="/import")publicclassImportController{AlbumServiceAlbumDaoDao@RequestMap(value=publicModelAndViewtoPage(HttpServletRequestreq,HttpServletResponserespones){ModelAndViewmav=newModelAndView("/vip/blueray/importList");return}publicstaticStringgetFileExtName(StringfileName) StringextName="";if(fileName!=null&&!"".equals(fileName)){inti=fileName.lastIndexOf(".");if(i>0)extName=fileName.substring(i+1,}}return}@RequestMap(value=publicDatainitImport(finalHttpServletRequestrequest,finalHttpServletResponse{Datadata=newMultipartRequestmultipartRequest=(MultipartRequest)request;Map<String,MultipartFile>map=multipartRequest.getFileMap();for(Stringkey:map.keySet()){MultipartFilemultipartFile=map.get(key);booleanbool=importData(multipartFile);if(bool){}else}}}return}publicbooleanimportData(MultipartFile tryStringfileName=multipartFile.getOriginalFilename();InputStreamis=multipartFile.getInputStream();Workbookbook=null;if(fileName!=null)fileName=fileName.toLowerCase();if(fileName.indexOf(".xlsx")>-1){book=new}elsebook=new}}Sheetsheet= map= intallNum=//IntegercpId=for(inti=2;i<=allNum;i++){Rowrow=sheet.getRow(i);if(row!=null){for(intsetnum=0;setnum<row.getLastCellNum();setnum++){if(row.getCell(setnum)!=null){}}}
if(cell!=null)Albumalbum= &&!album.getAlbumName().equals("0")){//cpId=List<Blueray>list=newArrayList<Blueray>(); RowRow=sheet.getRow(k);if(Row!=null){ if(Row.getCell(setnum)!=null){}}}Bluerayvedio=get(Row);}}}}}}Integersuc=execData(mapAlbum,mapif(suc>0)return}elsereturn}}catch(Exceptione)}return}publicIntegerexecData(Map<Integer,Album>mapAlbum,Map<Integer,List<Blueray>>{tryif(mapAlbum!=null&&mapAlbum.size()>0)List<AlbumVo>listAlbum=newMap<Integer,Album>addAlbum=newTreeMap<Integer,Album>();AlbumalbumPo=newAlbum();IntegeralbumCount=this.albumDao.getCount(albumPo);listAlbum=for(Integerhash:mapAlbum.keySet()){Albumap=mapAlbum.get(hash);for(AlbumVoav:listAlbum){updateAlbum.put(hash,ap);}}}for(Integerhash:mapAlbum.keySet()){if(updateAlbum.get(hash)==null){}} if(bool) >listPo=map.get(key);if(listPo.size()>0){ Po=newBlueray//
for vp:listPo)vp.setCp
}}if(addList.size()>0)}}}}for(Integerkey:addAlbum.keySet()) List<Blueray>list=map >addList=newArrayList<Blueray>();for(Bluerayvp:list){vp.setCp}if(addList.size()>0)}}}}catch(Exceptione)}return}publicAlbumgetAlbum(Rowrow) Albumalbum=newAlbum();try{if(row.getCell(0)!=null){}else}StringtimeStr="";doublevalue=Dated=DateFormatformater=newSimpleDateFormat("yyyy-MM-ddHH:mm:ss");timeStr=formater.format(d);}catch(Exceptione)}return}publicBluerayget(Row =newBlueray();try{Stringperiods=returnStringValue(row.getCell(23));}.set}catch(Exceptione)}return}publicbooleanisEmpry(Stringstr){return}publicStringreturnValue(Cellcell){if(cell==null){return}elseif(cell.getStringCellValue().trim().equals("")){return"0";}elsereturn}}}publicStringreturnStringValue(Cellcell){if(cell==null){return}elseif(cell.getStringCellValue().trim().equals("")){return"";}elsereturn}}}publicStringgetCell(Cellcell)DecimalFormatdf=newDecimalFormat("#");if(cell==null)returncase}caseHSSFCell.CELL_TYPE_STRING:returncell.getStringCellValue();casereturncell.getCellFormula();casereturncasereturncell.getBooleanCellValue()+"";caseHSSFCell.CELL_TYPE_ERROR:}return}}packageimportimportimport.springframework.str .Controllr;importimport.springframework.web.bind.annotation.RequestMap;import.springframework.web.bind.annotation.ResponseBody;importimportcom.hiveview.newicp.core.pojo.base.Data;importimportimportcom.hiveview.newicp.core.service.nocache.vip.blueray.AlbumService;極清專輯類的描述:AlbumController作者:qyb郵箱:qinyanbin@創(chuàng)建日期:20151116日publicclassAlbumControllerprivateAlbumServicealbumService;:toPagejsp::ModelAndView創(chuàng)建人:qyb日期:201511163:20:17:@RequestMap(value=ModelAndViewmav=newModelAndView("vip/blueray/albumList");returnmav;}*:getList::qyb*期:201511163:22:42:@RequestMap(value="/getList")publicScriptPage<AlbumVo>getList(HttpServletRequestrequest,Albumalbum,AjaxPageajaxPage){ScriptPage<AlbumVo>scriptPage=null;try{}catch(Exceptione)//}return}:update::Data:qyb日期:20151116日3:24:11:@RequestMap(value="/update")publicDataupdate(HttpServletRequestrequest,Albumalbum){Datadata=newData();intresult=0;try{result=this.albumService.update(album);if(result>0){}else}}catch(Exceptione)}return}@RequestMap(value="/updateEffective")publicStringupdateEffective(HttpServletRequestrequest,Albumalbum){Datadata=newData();intresult=0;try{Stringid=request.getParameter("albumId");AlbumalbumObj=albumService.getListById(album);if(!StringUtils.isEmpty(state)){result=albumService.updateEffective(albumObj);}}catch(Exceptione)}if(result>0)}else}return}@RequestMap(value="/add")publicDataadd(HttpServletRequestrequest,Albumalbum){Datadata=newData();intresult=0;try{result=this.albumService.saveAlbum(album);if(result>0){}else}}catch(Exceptione)}return}publicDatagetAlbumByPartnerId(StringpartnerId){Datadata=newData();tryList<AlbumVo>albumList=albumService.getAlbumByPartnerId(partnerId);if(null!=albumList&&albumList.size()>0){}}catch(Exceptione){}return}publicList<CpListVo>getPartnerName(){List<CpListVo>partnerList=null;try{partnerList=}catch(Exceptione)}return}}packageimportjava.util.HashMap;importjava.util.List;importimport.springframework.cache.annotation.Cacheable;import.springframework.stereotype.Service;import.springframework.util.StringUtils;importcom.hiveview.newicp.core.pojo.po.cache.Search;importimportimportcom.hiveview.newicp.core.util.PinyinUtil;publicclassSearchServiceImplextendsBaseServiceimplementsSearchService{returnnull;}Map<String,Object>params=newHashMap<String,Object>();return}privateSetDaodao;publicList<SearchVo>so(Stringrecord_name,List<Integer>record_types,Integerselect_model,Integercast_id,Integerpage_number,Searchcondition=newif(record_types!=null&&!record_types.isEmpty()){}if(record_name!=
}condition=conditionPagin(condition,page_size,page_number);returndao.so(condition);}publicIntegersoCount(Stringrecord_name,List<Integer>record_types,Integerselect_model,Integercast_id){Searchcondition=newif(record_types!=null&&!record_types.isEmpty()){}if
return}return}}packageimportimportjava.util.Collections;importjava.util.List;import.springframework. s.factory.annotatin.Autowired;import.springframework.cache.annotation.Cacheable;importimportcom.hivevi importcom.hiveview.newicp.core.dao.app.AppDao;importcom.hiveview.newicp.core.dao.cloud.searc importcom.hiveview.newicp.core.dao.cpdata.SetDao;importcom.hiveview.newicp.core.pojo.po.cloud.searc importcom.hiveview.newicp.core.pojo.vo.cache.AppLastestVo;import importcom.hiveview.newicp.core.pojo.vo.cloud. importcom.hiveview.newicp.core.pojo.vo.cpdata.SetVo;import @author2015615搜索public ApiServiceImpl privateAppDaoappDao;privateSetDao Type,IntegerpageSize,IntegerpageNum){1:,2:應(yīng)用,3教育,4:豎圖,5:橫= VoSRV= //如果大于-1if Type()>0) Type()< .getPageIndex(): .getPageSize(): Integercount=thi if(list2.size()>0)List<Integer>ids=newArrayList<Integer>();for( Vosrv:list2){}switch case case case= case
List< case
List< }}}}else//for(inti=1;i<6;i++) Integercount2=thi if(list2.size()>0)List<Integer>ids=newArrayList<Integer>();for( Vosrv:list2){}switch case case case case
List< caseList< }}}}return}}packageimportjava.util.HashMap;importjava.util.Map;import*@author@sincev1.02015418@seepublicclassConstantpublicstaticfinalStringiqiyiConf;publicstaticfinalStringiqiyiServer;publicstaticfinalStringiqiyiChn;publicstaticfinalStringiqiyiSet;publicstaticfinalStringiqiyiSetInfo;publicstaticfinalStringiqiyi;publicstaticfinalStringiqiyiPageSize;publicstaticfinalStringiqiyiChnFull;publicstaticfinalStringiqiyiChnTuijian;staticiqiyiConf=iqiyiChn=ProperManager.getRB(iqiyiConf,"iqiyi_chn");iqiyiSet=ProperManager.getRB(iqiyiConf,"iqiyi_set");iqiyiSetInfo=ProperManager.getRB(iqiyiConf,iqiyiChnFull=ProperManager.getRB(iqiyiConf,"iqiyi_chn_full");}/**springcatchrediskeystart*APIredis//////// //Redis //////////列表接//相關(guān)接////////// ////publicstaticfinalStringR_K_CATCH_SO=//publicstaticfinalStringR_K_CATCH_SO_Count=//////publicstaticfinalStringR_K_CATCH_getAPPListCount="r_k_catch_getAPPListCount";publicstaticfinalStringR_K_CATCH_getAPPList1="r_k_catch_getAPPList1";//黑白接//應(yīng)用接//應(yīng)用總publicstaticfinalStringR_K_CATCH_getTopList="r_k_catch_getTopList";//添//vippublicstaticfinalStringR_K_CATCH_vip_Home=//添//vip搜索 //添// //獲取// //// //籃球*APIredis/**云屏-獲得云屏幕列表-緩存key=/**-緩存key/**=/**-緩存key- /**--key /**--緩存key/**--key /**云屏-獲得云屏幕應(yīng)用分類列表-緩存key /**云屏-獲得云屏幕應(yīng)用列表-緩存key /**云屏-獲得云屏幕應(yīng)用分類列表-緩存key /**云屏-獲得云屏幕應(yīng)用列表-緩存key /**--key /**--key /**--key /**-EPG接口-緩存key /**云屏-獲取搜索列表-緩存key /**云屏-獲得云屏幕應(yīng)用列表-緩存key /**云屏-獲得云屏幕位內(nèi)容列表-緩存key /**springcatchrediskeyend//publicstaticfinalIntegerpullIncrement=//publicstaticfinalIntegerpullFull=//publicstaticfinalStringCODE_SUCCESS=//publicstaticfinalStringCODE_ERROR=//publicstaticfinalStringNULL_ERROR=tokenpublicstaticfinalStringTOKEN_ERROR=//publicstaticfinalStringIP_ERROR=//頻publicstaticfinalStringTIME_ERROR=publicstaticfinalStringVIP_ERROR=publicstaticfinalStringERROR_ALBUM_NOT_NULL=publicstaticfinalIntegerAllIDsPageSize=* * * *ID放入publicstaticfinalStringR_K_QIYI_FULL=*ID放入publicstaticfinalStringR_K_QIYI_FULL_ID=*publicstaticfinalStringR_K_QIYI__SET=*publicstaticfinalStringR_K_QIYI_="R_K_QIYI_*publicstaticfinalStringR_K_QIYI_SET_LIST="R_K_QIYI_*publicstaticfinalStringR_K_QIYI_SET_TAG="R_K_QIYI_publicstaticfinalStringR_K_QIYI_MailQueue=* * * * * *** * *同步第下線數(shù) *同步第數(shù)據(jù)類型0.更新1.新publicstaticfinalIntegerTHIRD_PARTY_DATA_DELETE_SYNC_TYPE_ADD=1;*ID *ID *IDpublicstaticfinalStringUPLOATH_IMG=publicstaticfinalStringUPLOATH_APK=publicstaticfinalStringUPLOATH_EXCEL=publicstaticfinalStringWEB_APK_PATH=publicstaticfinalStringSysnc_VIP_Task=*判斷內(nèi)publicstaticfinalStringIP_IsGroupServer=publicstaticfinalStringIP_IsGroupUser=publicstaticfinalStringVERSION=*VIPredis-publicstaticfinalStringR_K_SET_UPDATE_VIP="r_k_*VIPredis-publicstaticfinalStringR_K_SET_DELETE_VIP="r_k_*CNTV二級欄目與VIP熱詞關(guān)系redis- Strin_CATEGORY_MAP_VIP *CNTV二級欄目與VIP熱詞關(guān)系失敗redis- publicstaticMap<Object,Object>map=newHashMap<Object, getTvList接口/**VIP-key/**VIP獲取專題列總數(shù)-key /**VIP-緩存key /**VIP-keypublicstaticfinalStringR_K_CATCH_vip_activity_list=/**VIP-key /**VIP3.-緩存key /**VIP3.1.1-key /**VIP根據(jù)頻道獲取熱詞列表-key/**VIP獲取熱詞內(nèi)容列表-緩存key /**VIP獲取熱詞內(nèi)容列表總數(shù)-key /**國內(nèi)VIP-獲取點播列表緩存key /**國內(nèi)VIP-獲取點播列表總數(shù)緩存key /**國內(nèi)VIP-獲取點播列表緩存key /**國內(nèi)VIP-獲取點播列表總數(shù)緩存key /**VIP獲取專輯列表-key/**VIP獲取專輯列表總數(shù)-緩存key /**VIPke
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 產(chǎn)品質(zhì)量持續(xù)改進(jìn)培訓(xùn)課件
- 電子產(chǎn)品回收處理標(biāo)準(zhǔn)
- 單病種臨床路徑管理制度
- 智能小區(qū)物聯(lián)網(wǎng)應(yīng)用系統(tǒng)
- 《Excel數(shù)據(jù)獲取與處理實戰(zhàn)》 課件 陳青 第3、4章 數(shù)據(jù)的輸入、工作表的格式化
- 溶劑泄露應(yīng)急處置
- GMP基礎(chǔ)知識培訓(xùn)
- 病從口入教案反思
- 胸腔閉式引流器的護(hù)理
- 城市娛樂設(shè)施建筑平房施工合同
- 鄉(xiāng)村振興戰(zhàn)略項目經(jīng)費績效評價指標(biāo)體系及分值表
- 構(gòu)造柱工程施工技術(shù)交底
- 讀《學(xué)校與社會明日之學(xué)?!酚懈?/a>
- 醫(yī)院科室質(zhì)量與安全管理小組工作記錄本目錄
- 斷路器失靈保護(hù)及遠(yuǎn)跳詳解
- 300字方格紙模板
- 草訣百韻歌原文及解釋
- 鋼網(wǎng)架防火涂料施工方案
- 肺癌的護(hù)理常規(guī)(PPT課件)
- 農(nóng)村商業(yè)銀行信貸業(yè)務(wù)發(fā)展規(guī)劃-2019年文檔
- 一汽大眾供應(yīng)商物流管理評價標(biāo)準(zhǔn)
評論
0/150
提交評論