Commit 9a39a37b by 丁伟峰

Merge branch 'feature-dingwf-0715' into develop

2 parents a843b391 fe78a284
package com.dituhui.pea.order.dao;
import com.dituhui.pea.order.entity.OrgTeamEntity;
import org.hibernate.annotations.Where;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
......@@ -11,6 +12,7 @@ import org.springframework.stereotype.Repository;
import java.util.List;
@Repository
@Where(clause = "status = 1")
public interface OrgTeamDao extends JpaRepository<OrgTeamEntity, Integer> {
List<OrgTeamEntity> findAllByClusterId(String clusterId);
......
......@@ -204,9 +204,11 @@ public class BusinessTeamServiceImpl implements BusinessTeamService {
String engineerCode = relation.getEngineerCode();
if (newRelationsMap.containsKey(engineerCode)) {
OrgTeamEngineerEntity newRelation = newRelationsMap.get(engineerCode);
newRelation.setId(relation.getId());
newRelation.setUpdateTime(LocalDateTime.now());
newRelationsMap.put(engineerCode, newRelation);
} else {
// 新的关系不再,设置为0(删除)
relation.setStatus(0);
orgTeamEngineerDao.save(relation);
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!