Commit f17933b56bec4e30c022bf9731ef0cf5572312cf
1 parent
a1b4df6a41
Exists in
master
and in
1 other branch
update code
Showing 2 changed files with 9 additions and 9 deletions
platform-dal/src/main/java/com/lyms/platform/query/BabyModelQuery.java
View file @
f17933b
| ... | ... | @@ -5,6 +5,7 @@ |
| 5 | 5 | import com.lyms.platform.common.dao.operator.MongoCondition; |
| 6 | 6 | import com.lyms.platform.common.dao.operator.MongoOper; |
| 7 | 7 | import com.lyms.platform.common.dao.operator.MongoQuery; |
| 8 | +import com.lyms.platform.common.utils.StringUtils; | |
| 8 | 9 | import org.bson.types.ObjectId; |
| 9 | 10 | import org.springframework.data.mongodb.core.query.Criteria; |
| 10 | 11 | |
| 11 | 12 | |
| 12 | 13 | |
| 13 | 14 | |
| ... | ... | @@ -264,21 +265,21 @@ |
| 264 | 265 | condition=condition.and("communityId", null, MongoOper.IS); |
| 265 | 266 | } |
| 266 | 267 | |
| 267 | - if(null!=mcertNo){ | |
| 268 | + if(StringUtils.isEmpty(name)){ | |
| 268 | 269 | condition=condition.and("mcertNo", mcertNo, MongoOper.IS); |
| 269 | 270 | } |
| 270 | - if(null!=cardNo){ | |
| 271 | + if(StringUtils.isEmpty(name)){ | |
| 271 | 272 | condition=condition.and("cardNo", cardNo, MongoOper.IS); |
| 272 | 273 | } |
| 273 | 274 | |
| 274 | - if(null!=vcCardNo){ | |
| 275 | + if(StringUtils.isEmpty(name)){ | |
| 275 | 276 | condition=condition.and("vcCardNo", vcCardNo, MongoOper.IS); |
| 276 | 277 | } |
| 277 | 278 | |
| 278 | 279 | if(null!=hospitalId){ |
| 279 | 280 | condition=condition.and("hospitalId", hospitalId, MongoOper.IS); |
| 280 | 281 | } |
| 281 | - if(null!=diagnose){ | |
| 282 | + if(StringUtils.isEmpty(name)){ | |
| 282 | 283 | condition=condition.and("diagnose", diagnose, MongoOper.LIKE); |
| 283 | 284 | } |
| 284 | 285 | |
| 285 | 286 | |
| 286 | 287 | |
| 287 | 288 | |
| ... | ... | @@ -305,17 +306,17 @@ |
| 305 | 306 | } |
| 306 | 307 | |
| 307 | 308 | |
| 308 | - if (null != parentId) { | |
| 309 | + if (StringUtils.isEmpty(name)) { | |
| 309 | 310 | condition = condition.and("parentid", parentId, MongoOper.IS); |
| 310 | 311 | } |
| 311 | - if (null != mphone) { | |
| 312 | + if (StringUtils.isEmpty(name)) { | |
| 312 | 313 | condition = condition.and("mphone", mphone, MongoOper.IS); |
| 313 | 314 | } |
| 314 | - if (null != mname) { | |
| 315 | + if (StringUtils.isEmpty(name)) { | |
| 315 | 316 | condition = condition.and("mname", mname, MongoOper.IS); |
| 316 | 317 | } |
| 317 | 318 | |
| 318 | - if (null != name) { | |
| 319 | + if (StringUtils.isEmpty(name)) { | |
| 319 | 320 | condition = condition.and("name", name, MongoOper.IS); |
| 320 | 321 | } |
| 321 | 322 |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyBookbuildingController.java
View file @
f17933b