|
|
|
|
@ -17,6 +17,7 @@ import org.apache.commons.compress.utils.Lists;
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
import com.flossom.system.service.IWxModeService;
|
|
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 模式列Service业务层处理
|
|
|
|
|
@ -299,6 +300,7 @@ public class WxModeServiceImpl implements IWxModeService
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
// 保存换挡时间设置
|
|
|
|
|
wxModeGearMapper.deleteWxModeGearByModeId(wxMode.getId());
|
|
|
|
|
if(CollectionUtils.isNotEmpty(wxMode.getModeGear())) {
|
|
|
|
|
List<WxModeGear> modeGearList = wxMode.getModeGear();
|
|
|
|
|
for (WxModeGear wxModeGear: modeGearList) {
|
|
|
|
|
@ -308,8 +310,6 @@ public class WxModeServiceImpl implements IWxModeService
|
|
|
|
|
wxModeGear.setCreateBy(SecurityUtils.getLoginUser().getUsername());
|
|
|
|
|
wxModeGear.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|
wxModeGearMapper.insertWxModeGear(wxModeGear);
|
|
|
|
|
} else {
|
|
|
|
|
wxModeGearMapper.updateWxModeGear(wxModeGear);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@ -322,8 +322,6 @@ public class WxModeServiceImpl implements IWxModeService
|
|
|
|
|
wxModeGear.setCreateBy(SecurityUtils.getLoginUser().getUsername());
|
|
|
|
|
wxModeGear.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|
wxModeGearMapper.insertWxModeGear(wxModeGear);
|
|
|
|
|
} else {
|
|
|
|
|
wxModeGearMapper.updateWxModeGear(wxModeGear);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@ -336,8 +334,6 @@ public class WxModeServiceImpl implements IWxModeService
|
|
|
|
|
wxModeGear.setCreateBy(SecurityUtils.getLoginUser().getUsername());
|
|
|
|
|
wxModeGear.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|
wxModeGearMapper.insertWxModeGear(wxModeGear);
|
|
|
|
|
} else {
|
|
|
|
|
wxModeGearMapper.updateWxModeGear(wxModeGear);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
@ -351,8 +347,12 @@ public class WxModeServiceImpl implements IWxModeService
|
|
|
|
|
* @return 结果
|
|
|
|
|
*/
|
|
|
|
|
@Override
|
|
|
|
|
@Transactional
|
|
|
|
|
public int deleteWxModeByIds(Long[] ids)
|
|
|
|
|
{
|
|
|
|
|
for (Long modeId : ids) {
|
|
|
|
|
wxModeGearMapper.deleteWxModeGearByModeId(modeId);
|
|
|
|
|
}
|
|
|
|
|
return wxModeMapper.deleteWxModeByIds(ids);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|