liusheng
2024-09-18 722fa40345f1fc650eaeae4a721c3ae4106d92a8
smartor/src/main/java/com/smartor/service/impl/HeLibraryServiceImpl.java
@@ -1,22 +1,20 @@
package com.smartor.service.impl;
import java.util.List;
import com.ruoyi.common.exception.base.BaseException;
import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.DtoConversionUtils;
import com.smartor.domain.HeLibrary;
import com.smartor.domain.HeLibraryTag;
import com.smartor.domain.HeLibraryVO;
import com.smartor.domain.TempDetpRelevance;
import com.smartor.mapper.HeLibraryMapper;
import com.smartor.mapper.HeLibraryTagMapper;
import com.smartor.mapper.TempDetpRelevanceMapper;
import com.smartor.service.IHeLibraryService;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
 * 宣教资料库Service业务层处理
@@ -32,9 +30,6 @@
    @Autowired
    private HeLibraryTagMapper heLibraryTagMapper;
    @Autowired
    private TempDetpRelevanceMapper tempDetpRelevanceMapper;
    /**
     * 查询宣教资料库
@@ -103,14 +98,13 @@
     */
    @Override
    public Integer saveOrUpdateScript(HeLibraryVO heLibraryVO) {
        Integer i = null;
        HeLibrary heLibrary = DtoConversionUtils.sourceToTarget(heLibraryVO, HeLibrary.class);
        if (heLibraryVO.getIsoperation() != null && heLibraryVO.getIsoperation() == 1) {
            //新增
            i = heLibraryMapper.insertHeLibrary(heLibrary);
            heLibraryMapper.insertHeLibrary(heLibrary);
        } else if (heLibraryVO.getIsoperation() != null && heLibraryVO.getIsoperation() == 2) {
            //修改
            i = heLibraryMapper.updateHeLibrary(heLibrary);
            heLibraryMapper.updateHeLibrary(heLibrary);
        }
        log.info("新增或修改宣教详情的id为:{}", heLibrary.getId());
//
@@ -146,7 +140,7 @@
//            }
//        }
        return i;
        return heLibrary.getId().intValue();
    }
    @Override