| | |
| | | import com.ld.igds.inout.dto.InoutData; |
| | | import com.ld.igds.inout.dto.InoutParam; |
| | | import com.ld.igds.inout.service.InoutService; |
| | | import com.ld.igds.models.InoutLossOver; |
| | | import com.ld.igds.util.DateUtil; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.commons.lang3.time.DateFormatUtils; |
| | |
| | | import com.bstek.bdf2.core.business.IUser; |
| | | import com.bstek.bdf2.core.orm.hibernate.HibernateDao; |
| | | import com.bstek.dorado.data.provider.Page; |
| | | import com.ld.igds.models.MLossOver; |
| | | import com.ld.igds.util.ContextUtil; |
| | | |
| | | @Component |
| | |
| | | @Autowired |
| | | private InoutService inoutService; |
| | | |
| | | public void pageData(Page<MLossOver> page, Map<String, Object> param) |
| | | public void pageData(Page<InoutLossOver> page, Map<String, Object> param) |
| | | throws Exception { |
| | | String hql = " from " + MLossOver.class.getName() |
| | | String hql = " from " + InoutLossOver.class.getName() |
| | | + " where companyId=:companyId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | |
| | | } |
| | | |
| | | @Transactional(rollbackOn = Exception.class) |
| | | public void saveData(MLossOver data) throws Exception { |
| | | public void saveData(InoutLossOver data) throws Exception { |
| | | Session session = this.getSessionFactory().openSession(); |
| | | data.setUpdateTime(new Date()); |
| | | data.setUpdateUser(ContextUtil.getLoginUserCName()); |
| | |
| | | } |
| | | } |
| | | |
| | | private String addInoutDataByLossOver(MLossOver lossOver){ |
| | | private String addInoutDataByLossOver(InoutLossOver lossOver){ |
| | | if (null == lossOver.getSubmitTime()) { |
| | | lossOver.setSubmitTime(new Date()); |
| | | } |
| | |
| | | } |
| | | |
| | | @Transactional(rollbackOn = Exception.class) |
| | | public String delData(MLossOver data) throws Exception { |
| | | public String delData(InoutLossOver data) throws Exception { |
| | | Session session = this.getSessionFactory().openSession(); |
| | | try { |
| | | if (null != data.getId()) { |
| | |
| | | return null; |
| | | } |
| | | |
| | | private void delInoutDataByLossOver(MLossOver lossOver) { |
| | | private void delInoutDataByLossOver(InoutLossOver lossOver) { |
| | | InoutParam param = new InoutParam(); |
| | | param.setCompanyId(lossOver.getCompanyId()); |
| | | param.setId(lossOver.getId()); |