Commit 8125652e06d37ac0ce5affa567daa531e96b4b49

Authored by jiangjiazhi
1 parent 707c5a4f44

分娩作废产检劵

Showing 3 changed files with 62 additions and 0 deletions

platform-biz-patient-service/src/main/java/com/lyms/platform/biz/dal/IAntExRecordMDao.java View file @ 8125652
  1 +package com.lyms.platform.biz.dal;
  2 +
  3 +import com.lyms.platform.common.dao.operator.MongoQuery;
  4 +import com.lyms.platform.pojo.AntExPRecordModel;
  5 +import com.lyms.platform.pojo.AntExRecordModel;
  6 +
  7 +/**
  8 + * Created by Administrator on 2017/1/13 0013.
  9 + */
  10 +public interface IAntExRecordMDao {
  11 +
  12 +
  13 + Integer count(MongoQuery mongoQuery);
  14 +
  15 + /**
  16 + * 增加一条记录
  17 + *
  18 + * @return
  19 + */
  20 + AntExPRecordModel addOneRecord(AntExPRecordModel record);
  21 +
  22 + /**
  23 + * 根据id删除数据
  24 + *
  25 + * @param id
  26 + */
  27 + void deleteById(String id);
  28 +}
platform-biz-patient-service/src/main/java/com/lyms/platform/biz/dal/impl/AntExRecordMDaoImpl.java View file @ 8125652
  1 +package com.lyms.platform.biz.dal.impl;
  2 +
  3 +import com.lyms.platform.biz.dal.IAntExRecordMDao;
  4 +import com.lyms.platform.common.dao.BaseMongoDAOImpl;
  5 +import com.lyms.platform.common.dao.operator.MongoCondition;
  6 +import com.lyms.platform.common.dao.operator.MongoOper;
  7 +import com.lyms.platform.common.dao.operator.MongoQuery;
  8 +import com.lyms.platform.pojo.AntExPRecordModel;
  9 +import com.lyms.platform.pojo.AntExRecordModel;
  10 +import org.springframework.stereotype.Repository;
  11 +
  12 +/**
  13 + *
  14 + *
  15 + * Created by Administrator on 2017/1/13 0013.
  16 + */
  17 +@Repository("antExRecordMDao")
  18 +public class AntExRecordMDaoImpl extends BaseMongoDAOImpl<AntExPRecordModel>implements IAntExRecordMDao {
  19 + @Override
  20 + public Integer count(MongoQuery mongoQuery) {
  21 + return (int)count(mongoQuery.convertToMongoQuery());
  22 + }
  23 +
  24 + @Override
  25 + public AntExPRecordModel addOneRecord(AntExPRecordModel record) {
  26 + return save(record);
  27 + }
  28 +
  29 + @Override
  30 + public void deleteById(String id) {
  31 + delete(new MongoQuery(new MongoCondition("id", id, MongoOper.IS)).convertToMongoQuery());
  32 + }
  33 +}
platform-dal/src/main/java/com/lyms/platform/beans/SerialIdEnum.java View file @ 8125652
... ... @@ -48,6 +48,7 @@
48 48 VisitModel("VisitModel", 97531000430L),
49 49 PatientTicketId("PatientTicketId", 97531000440L),
50 50 PatientCheckTicket("PatientCheckTicket", 97531000450L),
  51 + AntExPRecordModel("AntExPRecordModel", 97531000451L),
51 52 last("last", 97531009990L);
52 53 private String cname;
53 54 private Long cid;