From 08923c6d95dc8f0f415de94e1d4e3230cdcf7a8e Mon Sep 17 00:00:00 2001 From: houzhongjian <houzhongyi@126.com> Date: 星期四, 14 十一月 2024 15:42:58 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/pre/service/impl/MmModelArithSettingsServiceImpl.java | 21 ++++++++++++++------- 1 files changed, 14 insertions(+), 7 deletions(-) diff --git a/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/pre/service/impl/MmModelArithSettingsServiceImpl.java b/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/pre/service/impl/MmModelArithSettingsServiceImpl.java index fff6acd..e84ba70 100644 --- a/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/pre/service/impl/MmModelArithSettingsServiceImpl.java +++ b/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/pre/service/impl/MmModelArithSettingsServiceImpl.java @@ -1,10 +1,14 @@ package com.iailab.module.model.mcs.pre.service.impl; +import com.baomidou.dynamic.datasource.annotation.DSTransactional; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.iailab.framework.common.service.impl.BaseServiceImpl; +import com.iailab.module.model.mcs.pre.dao.MmItemTypeDao; import com.iailab.module.model.mcs.pre.dao.MmModelArithSettingsDao; import com.iailab.module.model.mcs.pre.entity.MmModelArithSettingsEntity; import com.iailab.module.model.mcs.pre.service.MmModelArithSettingsService; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.util.CollectionUtils; @@ -15,24 +19,27 @@ * @date 2021年04月27日 9:24 */ @Service -public class MmModelArithSettingsServiceImpl extends BaseServiceImpl<MmModelArithSettingsDao, MmModelArithSettingsEntity> +public class MmModelArithSettingsServiceImpl extends ServiceImpl<MmModelArithSettingsDao, MmModelArithSettingsEntity> implements MmModelArithSettingsService { + + @Autowired + private MmModelArithSettingsDao mmModelArithSettingsDao; @Override public void saveList(List<MmModelArithSettingsEntity> list) { QueryWrapper<MmModelArithSettingsEntity> queryWrapper = new QueryWrapper(); queryWrapper.eq("modelid", list.get(0).getModelid()); - baseDao.delete(queryWrapper); + mmModelArithSettingsDao.delete(queryWrapper); list.forEach(item -> { item.setId(UUID.randomUUID().toString()); }); - baseDao.insertList(list); + mmModelArithSettingsDao.insertList(list); } public List<MmModelArithSettingsEntity> getByModelid(String modelid) { Map<String, Object> params = new HashMap<>(1); params.put("modelid", modelid); - List<MmModelArithSettingsEntity> list = baseDao.getMmModelArithSettings(params); + List<MmModelArithSettingsEntity> list = mmModelArithSettingsDao.getMmModelArithSettings(params); if (CollectionUtils.isEmpty(list)) { return new ArrayList<>(); @@ -42,8 +49,8 @@ @Override public List<MmModelArithSettingsEntity> getByModelId(String modelId) { - QueryWrapper<MmModelArithSettingsEntity> queryWrapper = new QueryWrapper(); - queryWrapper.eq("modelid", modelId); - return baseDao.selectList(queryWrapper); + Map<String, Object> params = new HashMap<>(); + params.put("modelid", modelId); + return mmModelArithSettingsDao.getMmModelArithSettings(params); } } -- Gitblit v1.9.3