|  | @@ -3,10 +3,7 @@ package com.ym.mec.biz.service.impl;
 | 
											
												
													
														|  |  import com.ym.mec.biz.dal.dao.StudentInstrumentDao;
 |  |  import com.ym.mec.biz.dal.dao.StudentInstrumentDao;
 | 
											
												
													
														|  |  import com.ym.mec.biz.dal.dao.SysConfigDao;
 |  |  import com.ym.mec.biz.dal.dao.SysConfigDao;
 | 
											
												
													
														|  |  import com.ym.mec.biz.dal.dto.MaintenancePayDto;
 |  |  import com.ym.mec.biz.dal.dto.MaintenancePayDto;
 | 
											
												
													
														|  | -import com.ym.mec.biz.dal.entity.StudentInstrument;
 |  | 
 | 
											
												
													
														|  | -import com.ym.mec.biz.dal.entity.StudentPaymentOrder;
 |  | 
 | 
											
												
													
														|  | -import com.ym.mec.biz.dal.entity.SysUserCashAccount;
 |  | 
 | 
											
												
													
														|  | -import com.ym.mec.biz.dal.entity.SysUserCashAccountDetail;
 |  | 
 | 
											
												
													
														|  | 
 |  | +import com.ym.mec.biz.dal.entity.*;
 | 
											
												
													
														|  |  import com.ym.mec.biz.dal.enums.*;
 |  |  import com.ym.mec.biz.dal.enums.*;
 | 
											
												
													
														|  |  import com.ym.mec.biz.service.*;
 |  |  import com.ym.mec.biz.service.*;
 | 
											
												
													
														|  |  import com.ym.mec.common.dal.BaseDAO;
 |  |  import com.ym.mec.common.dal.BaseDAO;
 | 
											
										
											
												
													
														|  | @@ -50,6 +47,8 @@ public class StudentInstrumentServiceImpl extends BaseServiceImpl<Long, StudentI
 | 
											
												
													
														|  |      private SysUserCashAccountDetailService sysUserCashAccountDetailService;
 |  |      private SysUserCashAccountDetailService sysUserCashAccountDetailService;
 | 
											
												
													
														|  |      @Autowired
 |  |      @Autowired
 | 
											
												
													
														|  |      private SysMessageService sysMessageService;
 |  |      private SysMessageService sysMessageService;
 | 
											
												
													
														|  | 
 |  | +    @Autowired
 | 
											
												
													
														|  | 
 |  | +    private GoodsService goodsService;
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      private final Logger logger = LoggerFactory.getLogger(this.getClass());
 |  |      private final Logger logger = LoggerFactory.getLogger(this.getClass());
 | 
											
												
													
														|  |  
 |  |  
 | 
											
										
											
												
													
														|  | @@ -239,4 +238,17 @@ public class StudentInstrumentServiceImpl extends BaseServiceImpl<Long, StudentI
 | 
											
												
													
														|  |          }
 |  |          }
 | 
											
												
													
														|  |          return false;
 |  |          return false;
 | 
											
												
													
														|  |      }
 |  |      }
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    @Override
 | 
											
												
													
														|  | 
 |  | +    public StudentInstrument addStudentInstrument(StudentInstrument studentInstrument) {
 | 
											
												
													
														|  | 
 |  | +        Goods goods = goodsService.get(studentInstrument.getGoodsId());
 | 
											
												
													
														|  | 
 |  | +        studentInstrument.setGoodsCategoryId(goods.getGoodsCategoryId());
 | 
											
												
													
														|  | 
 |  | +        studentInstrument.setGoodsCategoryName(goods.getGoodsCategoryName());
 | 
											
												
													
														|  | 
 |  | +        studentInstrument.setGoodsName(goods.getName());
 | 
											
												
													
														|  | 
 |  | +        studentInstrument.setGoodsBrand(goods.getBrand());
 | 
											
												
													
														|  | 
 |  | +        studentInstrument.setSpecification(goods.getSpecification());
 | 
											
												
													
														|  | 
 |  | +        studentInstrument.setGoodsImg(goods.getImage());
 | 
											
												
													
														|  | 
 |  | +        studentInstrumentDao.insert(studentInstrument);
 | 
											
												
													
														|  | 
 |  | +        return studentInstrument;
 | 
											
												
													
														|  | 
 |  | +    }
 | 
											
												
													
														|  |  }
 |  |  }
 |