Commit d59f809f by qwmqiuwenmin

fix

parent 384ba231
...@@ -4,7 +4,7 @@ import com.gic.haoban.manage.api.dto.MemberUnionidRelatedDTO; ...@@ -4,7 +4,7 @@ import com.gic.haoban.manage.api.dto.MemberUnionidRelatedDTO;
public interface MemberUnionidRelatedApiService { public interface MemberUnionidRelatedApiService {
MemberUnionidRelatedDTO getByMemberId(String staffId, String memberId); MemberUnionidRelatedDTO getByUnionId(String staffId, String memberId);
String addMemberUnionidRelated(MemberUnionidRelatedDTO dto); String addMemberUnionidRelated(MemberUnionidRelatedDTO dto);
......
...@@ -18,7 +18,7 @@ public interface MemberUnionidRelatedMapper { ...@@ -18,7 +18,7 @@ public interface MemberUnionidRelatedMapper {
int updateByPrimaryKey(MemberUnionidRelated record); int updateByPrimaryKey(MemberUnionidRelated record);
MemberUnionidRelatedDTO getByMemberId(@Param("wxUserId")String wxUserId, @Param("memberId")String memberId); MemberUnionidRelatedDTO getByUnionId(@Param("wxUserId")String wxUserId, @Param("unionid")String unionid);
void deleteByUnionidAndUserId(@Param("unionid")String unionid,@Param("wxUserId") String wxUserId); void deleteByUnionidAndUserId(@Param("unionid")String unionid,@Param("wxUserId") String wxUserId);
} }
\ No newline at end of file
...@@ -4,7 +4,7 @@ import com.gic.haoban.manage.api.dto.MemberUnionidRelatedDTO; ...@@ -4,7 +4,7 @@ import com.gic.haoban.manage.api.dto.MemberUnionidRelatedDTO;
public interface MemberUnionRelatedService { public interface MemberUnionRelatedService {
MemberUnionidRelatedDTO getByMemberId(String wxUserId, String memberId); MemberUnionidRelatedDTO getByUnionId(String wxUserId, String unionid);
String addMemberUnionidRelated(MemberUnionidRelatedDTO dto); String addMemberUnionidRelated(MemberUnionidRelatedDTO dto);
......
...@@ -20,8 +20,8 @@ public class MemberUnionRelatedServiceImpl implements MemberUnionRelatedService ...@@ -20,8 +20,8 @@ public class MemberUnionRelatedServiceImpl implements MemberUnionRelatedService
private MemberUnionidRelatedMapper mapper; private MemberUnionidRelatedMapper mapper;
@Override @Override
public MemberUnionidRelatedDTO getByMemberId(String wxUserId, String memberId) { public MemberUnionidRelatedDTO getByUnionId(String wxUserId, String unionid) {
return mapper.getByMemberId(wxUserId,memberId); return mapper.getByUnionId(wxUserId,unionid);
} }
@Override @Override
......
package com.gic.haoban.manage.service.service.out.impl; package com.gic.haoban.manage.service.service.out.impl;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -8,7 +9,6 @@ import com.gic.haoban.manage.api.service.MemberUnionidRelatedApiService; ...@@ -8,7 +9,6 @@ import com.gic.haoban.manage.api.service.MemberUnionidRelatedApiService;
import com.gic.haoban.manage.service.entity.TabHaobanStaff; import com.gic.haoban.manage.service.entity.TabHaobanStaff;
import com.gic.haoban.manage.service.service.MemberUnionRelatedService; import com.gic.haoban.manage.service.service.MemberUnionRelatedService;
import com.gic.haoban.manage.service.service.StaffService; import com.gic.haoban.manage.service.service.StaffService;
import com.gic.member.api.service.MemberService;
@Service @Service
public class MemberUnionidRelatedApiServiceImpl implements MemberUnionidRelatedApiService{ public class MemberUnionidRelatedApiServiceImpl implements MemberUnionidRelatedApiService{
...@@ -17,21 +17,19 @@ public class MemberUnionidRelatedApiServiceImpl implements MemberUnionidRelatedA ...@@ -17,21 +17,19 @@ public class MemberUnionidRelatedApiServiceImpl implements MemberUnionidRelatedA
private MemberUnionRelatedService memberUnionRelatedService; private MemberUnionRelatedService memberUnionRelatedService;
@Autowired @Autowired
private StaffService staffService; private StaffService staffService;
@Autowired @Autowired
private MemberService memberService; private com.gic.enterprise.api.service.StoreGroupService gicDepartmentService;
@Override @Override
public MemberUnionidRelatedDTO getByMemberId(String staffId, String memberId) { public MemberUnionidRelatedDTO getByUnionId(String staffId, String unionid) {
TabHaobanStaff staff = staffService.selectById(staffId); TabHaobanStaff staff = staffService.selectById(staffId);
if(staff == null){ if(staff == null){
return null; return null;
} }
return memberUnionRelatedService.getByMemberId(staff.getWxUserId(),memberId); return memberUnionRelatedService.getByUnionId(staff.getWxUserId(),unionid);
} }
@Override @Override
public String addMemberUnionidRelated(MemberUnionidRelatedDTO dto) { public String addMemberUnionidRelated(MemberUnionidRelatedDTO dto) {
// String unionid = dto.getUnionid();
// String memberId = memberService.getMemberIdByUnion(unionid, entMicroSignal);
// dto.setMemberId(memberId);
return memberUnionRelatedService.addMemberUnionidRelated(dto); return memberUnionRelatedService.addMemberUnionidRelated(dto);
} }
@Override @Override
......
...@@ -140,13 +140,13 @@ ...@@ -140,13 +140,13 @@
where member_unionid_related_id = #{memberUnionidRelatedId,jdbcType=VARCHAR} where member_unionid_related_id = #{memberUnionidRelatedId,jdbcType=VARCHAR}
</update> </update>
<select id="getByMemberId" resultMap="BaseResultMap" parameterType="java.lang.String" > <select id="getByUnionId" resultMap="BaseResultMap" parameterType="java.lang.String" >
select select
<include refid="Base_Column_List" /> <include refid="Base_Column_List" />
from tab_haoban_member_unionid_related from tab_haoban_member_unionid_related
where wx_user_id = #{wxUserId} where wx_user_id = #{wxUserId}
and status_flag = 1 and status_flag = 1
and member_id = #{memberId} and unionid = #{unionid}
</select> </select>
<update id="deleteByUnionidAndUserId" parameterType="com.gic.haoban.manage.service.entity.MemberUnionidRelated" > <update id="deleteByUnionidAndUserId" parameterType="com.gic.haoban.manage.service.entity.MemberUnionidRelated" >
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment