| | |
| | | import cn.gistack.resource.entity.QieTuEntity; |
| | | import cn.gistack.resource.feign.IOssClient; |
| | | import cn.gistack.sm.skPanorama.entity.ParamEntity; |
| | | import cn.gistack.sm.skPanorama.entity.SkPicCountEntity; |
| | | import cn.gistack.sm.skPanorama.utils.Img4JavaUtil; |
| | | import cn.gistack.sm.skPanorama.utils.PanoramaUtilDict; |
| | | import cn.gistack.sm.skPanoramaState.entity.SkPanoramaStateEntity; |
| | |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperation(value = "分页", notes = "传入skPanorama") |
| | | public R<IPage<SkPanoramaVO>> page(SkPanoramaVO skPanorama, Query query) { |
| | | IPage<SkPanoramaVO> pages = skPanoramaService.selectSkPanoramaPage(Condition.getPage(query), skPanorama); |
| | | public R<IPage<SkPicCountEntity>> page(SkPicCountEntity skPanorama, Query query) { |
| | | Integer current = query.getCurrent(); |
| | | Integer size = query.getSize(); |
| | | IPage<SkPicCountEntity> page = Condition.getPage(query); |
| | | |
| | | // System.err.println("current:"+current); |
| | | // System.err.println("size:"+size); |
| | | Integer startIndex = (current -1) * size; |
| | | Integer endIndex = current * size; |
| | | |
| | | IPage<SkPicCountEntity> pages = skPanoramaService.selectPageR( page,startIndex, endIndex, skPanorama); |
| | | return R.data(pages); |
| | | } |
| | | |
| | |
| | | List<SkPanoramaStateEntity> updateList = new ArrayList<>(); |
| | | List<SkPanoramaStateEntity> addList = new ArrayList<>(); |
| | | if (stateLsit != null && stateLsit.size()>0) { |
| | | // for (SkPanoramaStateEntity item :stateLsit) { |
| | | // Long id = item.getId(); |
| | | // if (id != null) { |
| | | // // 更新 |
| | | // updateList.add(item); |
| | | // } else { |
| | | // // 新增 |
| | | // addList.add(item); |
| | | // } |
| | | // } |
| | | // boolean b = true; |
| | | // if (addList != null) { |
| | | // b = skPanoramaStateService.saveBatch(addList); |
| | | // } |
| | | // if (updateList != null) { |
| | | // b = skPanoramaStateService.saveOrUpdateBatch(updateList); |
| | | // } |
| | | |
| | | boolean b =skPanoramaStateService.saveOrUpdateBatch(stateLsit); |
| | | |
| | | return R.status(b); |