Commit f7df5e6a by 墨竹

feat:根据企业id查询门店权限

parent f752d0b8
......@@ -15,7 +15,7 @@ public interface StaffApiService {
List<StaffDTO> listByIds(List<String> staffIds);
List<StaffDTO> listByWxUserId(String wxUserId,String wxEnterpriseId);
List<StaffDTO> listByWxUserId(String wxUserId, String wxEnterpriseId);
StaffDTO selectByNationcodeAndPhoneNumber(String wxEnterpriseId, String nationcode, String phoneNumber);
......@@ -24,7 +24,7 @@ public interface StaffApiService {
List<StaffDepartmentRelatedDTO> listStaffDepartmentByStaffId(String staffId);
Page<StaffDTO> pageStaff(List<String> departmentId, Integer activeFlag,
String keyword, BasePageInfo pageInfo, Integer relationFlag,String wxEnterpriseId);
String keyword, BasePageInfo pageInfo, Integer relationFlag, String wxEnterpriseId);
@Deprecated
void del(String staffDepartmentStaffRelatedId);
......@@ -142,6 +142,7 @@ public interface StaffApiService {
/**
* 获取超管
*
* @param wxEnterpriseId
* @return
*/
......@@ -257,19 +258,20 @@ public interface StaffApiService {
* @author mozhu
* @date 2022-05-25 15:37:24
*/
List<String> getHaoBanStoreRolesByClerkId(String clerkId,String wxEnterpriseId);
List<String> getHaoBanStoreRolesByClerkId(String clerkId, String wxEnterpriseId);
/**
* 门店筛选器id和好办企业门店交集
*
* @param storeWidgetId 存储部件id
* @param wxEnterpriseId wx企业标识
* @param enterpriseId 企业标识
* @return {@link List }<{@link String }>
* @author mozhu
* @date 2022-05-09 16:34:56
* @date 2022-05-31 09:35:42
*/
List<String> getHaoBanStoreRolesByStoreWidgetId(String storeWidgetId,String enterpriseId);
List<String> getHaoBanStoreRolesByStoreWidgetId(String storeWidgetId, String wxEnterpriseId, String enterpriseId);
/**
......@@ -282,7 +284,7 @@ public interface StaffApiService {
* @author mozhu
* @date 2022-05-18 14:19:11
*/
boolean isFlagByStoreIdAndEnterpriseId(String storeId,String enterpriseId,String wxEnterpriseId);
boolean isFlagByStoreIdAndEnterpriseId(String storeId, String enterpriseId, String wxEnterpriseId);
/**
......@@ -305,6 +307,6 @@ public interface StaffApiService {
* @author mozhu
* @date 2022-05-30 11:46:08
*/
List<String> getHaoBanStoreRolesByEnterpriseId(String enterpriseId,String wxEnterpriseId);
List<String> getHaoBanStoreRolesByEnterpriseId(String enterpriseId, String wxEnterpriseId);
}
......@@ -1331,13 +1331,8 @@ public class StaffApiServiceImpl implements StaffApiService {
}
@Override
public List<String> getHaoBanStoreRolesByStoreWidgetId(String storeWidgetId, String enterpriseId) {
TabHaobanWxEnterpriseRelated enterpriseRelated = wxEnterpriseRelatedMapper.findOneByEnterpriseId(enterpriseId);
if (enterpriseRelated == null) {
//商户未关联好办
return Collections.emptyList();
}
List<String> enterpriseIdStoreIds = storeRangeService.listStoreIdByWxEnterpriseId(enterpriseRelated.getWxEnterpriseId(), enterpriseId);
public List<String> getHaoBanStoreRolesByStoreWidgetId(String storeWidgetId, String wxEnterpriseId, String enterpriseId) {
List<String> enterpriseIdStoreIds = storeRangeService.listStoreIdByWxEnterpriseId(wxEnterpriseId, enterpriseId);
List<String> storeWidgetIdStoreIds = getStoreWidgetIdStoreIds(storeWidgetId, enterpriseId);
//取交集
Sets.SetView<String> intersection = Sets.intersection(Sets.newHashSet(enterpriseIdStoreIds), Sets.newHashSet(storeWidgetIdStoreIds));
......
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