Commit 4d145a17 by 涂亚平

临时上个版本 联调中

1 parent 7a010864
...@@ -217,7 +217,7 @@ public class AdministerController { ...@@ -217,7 +217,7 @@ public class AdministerController {
@PostMapping("importMember") @PostMapping("importMember")
@ApiOperation("导入学生 {companyId 公司id file}") @ApiOperation("导入学生 {companyId 公司id file}")
public ResponseVO importMember(Long companyId,@RequestParam("file") MultipartFile file){ public ResponseVO importMember(Long companyId,@RequestParam("file") MultipartFile file)throws Exception{
return ResponseData.generateCreatedResponse(0,administerService.importMember(companyId,file)); return ResponseData.generateCreatedResponse(0,administerService.importMember(companyId,file));
} }
......
...@@ -74,7 +74,7 @@ public interface AdministerService extends IService<AdministerDO> { ...@@ -74,7 +74,7 @@ public interface AdministerService extends IService<AdministerDO> {
void memberStudyLog(MemberStudyLogDTO memberStudyLogDTO)throws Exception; void memberStudyLog(MemberStudyLogDTO memberStudyLogDTO)throws Exception;
String importMember(Long companyId, MultipartFile multipartFile); String importMember(Long companyId, MultipartFile multipartFile)throws Exception;
IPage<ManageMemberVO> manageMember(ManageMemberDTO manageMemberDTO); IPage<ManageMemberVO> manageMember(ManageMemberDTO manageMemberDTO);
} }
...@@ -128,6 +128,7 @@ import java.util.HashMap; ...@@ -128,6 +128,7 @@ import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Set; import java.util.Set;
import java.util.TreeSet; import java.util.TreeSet;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicInteger;
import java.util.zip.ZipEntry; import java.util.zip.ZipEntry;
import java.util.zip.ZipOutputStream; import java.util.zip.ZipOutputStream;
...@@ -1284,7 +1285,7 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis ...@@ -1284,7 +1285,7 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis
} }
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
public String importMember(Long companyId, MultipartFile multipartFile) { public String importMember(Long companyId, MultipartFile multipartFile) throws Exception {
try { try {
...@@ -1346,10 +1347,7 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis ...@@ -1346,10 +1347,7 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis
memberDepartmentMappingDO.setDepartmentId(departmentDictDO.getId()); memberDepartmentMappingDO.setDepartmentId(departmentDictDO.getId());
memberDepartmentMappingDO.setMemberId(memberDO1.getId()); memberDepartmentMappingDO.setMemberId(memberDO1.getId());
memberDepartmentMappingMapper.insert(memberDepartmentMappingDO); memberDepartmentMappingMapper.insert(memberDepartmentMappingDO);
} }
} }
}); });
} catch (Exception e) { } catch (Exception e) {
......
...@@ -78,16 +78,18 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa ...@@ -78,16 +78,18 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa
Page pager = new Page(operatorsDTO.getPageNum(), operatorsDTO.getPageSize()); Page pager = new Page(operatorsDTO.getPageNum(), operatorsDTO.getPageSize());
//判断该用户的角色 //判断该用户的角色
Integer count = roleAdministerMappingMapper.selectCount(new QueryWrapper<RoleAdministerMappingDO>() //Integer count = roleAdministerMappingMapper.selectCount(new QueryWrapper<RoleAdministerMappingDO>()
.lambda() // .lambda()
.eq(RoleAdministerMappingDO::getAdministerId,operatorsDTO.getId()) // .eq(RoleAdministerMappingDO::getAdministerId,operatorsDTO.getId())
.eq(RoleAdministerMappingDO::getRoleId,1)); // .eq(RoleAdministerMappingDO::getRoleId,1));
// //
//if (count > 0){ //if (count > 0){
// operatorsDTO.setId(null); // operatorsDTO.setId(null);
//} //}
IPage page = this.baseMapper.operators(pager, operatorsDTO.getCompanyName(), operatorsDTO.getFieldId(),operatorsDTO.getId()); AdministerDO administerDO = administerMapper.selectById(operatorsDTO.getId());
IPage page = this.baseMapper.operators(pager, operatorsDTO.getCompanyName(), operatorsDTO.getFieldId(),administerDO.getCompanyId());
List<OperatorsVO> operatorsVOS = page.getRecords(); List<OperatorsVO> operatorsVOS = page.getRecords();
for (OperatorsVO operatorsVO : operatorsVOS) { for (OperatorsVO operatorsVO : operatorsVOS) {
//查看公司所在行业 //查看公司所在行业
......
...@@ -141,6 +141,7 @@ public class MemberServiceImpl extends ServiceImpl<MemberMapper, MemberDO> imple ...@@ -141,6 +141,7 @@ public class MemberServiceImpl extends ServiceImpl<MemberMapper, MemberDO> imple
return iPage; return iPage;
} }
@Transactional(rollbackFor = Exception.class)
public String deleteMember(MemberDO memberDO) { public String deleteMember(MemberDO memberDO) {
this.baseMapper.deleteById(memberDO.getId()); this.baseMapper.deleteById(memberDO.getId());
......
...@@ -70,6 +70,7 @@ ...@@ -70,6 +70,7 @@
t.delete_date IS NULL t.delete_date IS NULL
AND t2.delete_date IS NULL AND t2.delete_date IS NULL
and t2.end_date >=DATE_FORMAT(now(), '%Y-%m-%d') and t2.end_date >=DATE_FORMAT(now(), '%Y-%m-%d')
and t2.start_date &lt; DATE_FORMAT(now(), '%Y-%m-%d')
and t.member_id = #{memberId} and t.member_id = #{memberId}
</select> </select>
......
...@@ -40,7 +40,6 @@ ...@@ -40,7 +40,6 @@
t.delete_date IS NULL t.delete_date IS NULL
and t2.delete_date is null and t2.delete_date is null
and t3.delete_date is null and t3.delete_date is null
and role = #{role}
<if test="id != null and id != ''"> <if test="id != null and id != ''">
and t2.id = #{id} and t2.id = #{id}
</if> </if>
......
...@@ -63,6 +63,7 @@ ...@@ -63,6 +63,7 @@
WHERE WHERE
t.delete_date IS NULL t.delete_date IS NULL
AND t2.delete_date IS NULL AND t2.delete_date IS NULL
and t2.id is not null
and t.course_id = #{courseId} and t.course_id = #{courseId}
<if test="vodName != null and vodName !=''"> <if test="vodName != null and vodName !=''">
and t2.vod_name like concat('%',#{vodName} ,'%') and t2.vod_name like concat('%',#{vodName} ,'%')
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!