| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.aps.common.core.utils.DateUtils; |
| | | import com.aps.common.core.utils.uuid.IdUtils; |
| | | import com.aps.core.domain.ApsGasPipingPlanTemp; |
| | | import com.aps.core.domain.ApsPartPlan; |
| | |
| | | import com.aps.core.mapper.ApsGasPipingPlanMapper; |
| | | import com.aps.core.domain.ApsGasPipingPlan; |
| | | import com.aps.core.service.IApsGasPipingPlanService; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | /** |
| | | * 气体管路计划管理Service业务层处理 |
| | |
| | | public int insertApsGasPipingPlan(ApsGasPipingPlan apsGasPipingPlan) |
| | | { |
| | | apsGasPipingPlan.setId(IdUtils.fastUUID()); |
| | | apsGasPipingPlan.setCreateTime(DateUtils.getNowDate()); |
| | | return apsGasPipingPlanMapper.insertApsGasPipingPlan(apsGasPipingPlan); |
| | | } |
| | | |
| | |
| | | return apsGasPipingPlanMapper.deleteApsGasPipingPlanById(id); |
| | | } |
| | | |
| | | @Transactional |
| | | @Override |
| | | public int confirmGasPiping(ApsGasPipingPlanTemp apsGasPipingPlanTemp) { |
| | | //删除所有计划 |
| | | apsGasPipingPlanMapper.removeAllPlans(); |
| | | //查询临时表数据 |
| | | List<ApsGasPipingPlanTemp> apsGasPipingPlanTemps=apsGasPipingPlanTempMapper.selectApsGasPipingPlanTempList(apsGasPipingPlanTemp); |
| | | int count=0; |
| | |
| | | if (count==apsGasPipingPlanTemps.size()) { |
| | | apsGasPipingPlanTempMapper.deleteApsGasPipingPlanTempByIds(ids); |
| | | } |
| | | return 0; |
| | | return 1; |
| | | } |
| | | } |