Browse Source

调整新增逻辑

master
xyiege 4 years ago
parent
commit
003970d9c7
  1. 7
      src/main/java/cn/chjyj/szwh/service/impl/ClassifyServiceImpl.java

7
src/main/java/cn/chjyj/szwh/service/impl/ClassifyServiceImpl.java

@ -31,7 +31,7 @@ public class ClassifyServiceImpl implements ClassifyService {
@Override @Override
public Map getClassifyList(Map<String, Object> qmap, int limit,int page) { public Map getClassifyList(Map<String, Object> qmap, int limit,int page) {
Map retmap =new HashMap(); Map retmap =new HashMap();
int start=page>0?(page-1)* limit:1; int start=page>0?(page-1)* limit:0;
//记录总数 //记录总数
int total =classifyMapper.countRsByMap(qmap); int total =classifyMapper.countRsByMap(qmap);
@ -134,7 +134,7 @@ public class ClassifyServiceImpl implements ClassifyService {
// ID 为返回的自编号 // ID 为返回的自编号
oplog.setLogid(classify.getId()); oplog.setLogid(classify.getId());
operationLogMapper.addLog(oplog); operationLogMapper.addLog(oplog);
} }else {
// 查找类目 // 查找类目
Classify clsfy = classifyMapper.getClassify(topClass); Classify clsfy = classifyMapper.getClassify(topClass);
if (clsfy != null) { if (clsfy != null) {
@ -148,7 +148,8 @@ public class ClassifyServiceImpl implements ClassifyService {
oplog.setLogid(classify.getId()); oplog.setLogid(classify.getId());
operationLogMapper.addLog(oplog); operationLogMapper.addLog(oplog);
} }
}
// 返回执行结果
return ret; return ret;
} }

Loading…
Cancel
Save