|
@@ -821,18 +821,39 @@ public class AuthServiceImpl implements IAuthService {
|
|
|
}
|
|
}
|
|
|
boolean isDoorKeeper = StringUtils.isNotBlank(roleName) && roleName.contains("门卫");
|
|
boolean isDoorKeeper = StringUtils.isNotBlank(roleName) && roleName.contains("门卫");
|
|
|
boolean isForkliftDriver = StringUtils.isNotBlank(roleName) && roleName.contains("铲车司机");
|
|
boolean isForkliftDriver = StringUtils.isNotBlank(roleName) && roleName.contains("铲车司机");
|
|
|
|
|
+ boolean isBuyer = StringUtils.isNotBlank(roleName) && roleName.contains("买家");
|
|
|
if (isDoorKeeper) {
|
|
if (isDoorKeeper) {
|
|
|
return buildDoorKeeperTabBar();
|
|
return buildDoorKeeperTabBar();
|
|
|
}
|
|
}
|
|
|
if (isForkliftDriver) {
|
|
if (isForkliftDriver) {
|
|
|
return buildForkliftDriverTabBar();
|
|
return buildForkliftDriverTabBar();
|
|
|
}
|
|
}
|
|
|
|
|
+ if (isBuyer) {
|
|
|
|
|
+ return buildBuyerTabBar();
|
|
|
|
|
+ }
|
|
|
if (flag == 1) {
|
|
if (flag == 1) {
|
|
|
return buildDefaultDriverTabBar();
|
|
return buildDefaultDriverTabBar();
|
|
|
}
|
|
}
|
|
|
return List.of();
|
|
return List.of();
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ private List<LoginResVo1.TabBarItem> buildBuyerTabBar() {
|
|
|
|
|
+ List<LoginResVo1.TabBarItem> items = new ArrayList<>();
|
|
|
|
|
+ items.add(buildTabBarItem(
|
|
|
|
|
+ "商城",
|
|
|
|
|
+ "static/tabbar/mall.png",
|
|
|
|
|
+ "static/tabbar/mall_select.png",
|
|
|
|
|
+ "pages/mall/index"
|
|
|
|
|
+ ));
|
|
|
|
|
+ items.add(buildTabBarItem(
|
|
|
|
|
+ "贸易订单",
|
|
|
|
|
+ "static/tabbar/trade.png",
|
|
|
|
|
+ "static/tabbar/trade_select.png",
|
|
|
|
|
+ "pages/tradeOrder/index"
|
|
|
|
|
+ ));
|
|
|
|
|
+ return items;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
private List<LoginResVo1.TabBarItem> buildDoorKeeperTabBar() {
|
|
private List<LoginResVo1.TabBarItem> buildDoorKeeperTabBar() {
|
|
|
List<LoginResVo1.TabBarItem> items = new ArrayList<>();
|
|
List<LoginResVo1.TabBarItem> items = new ArrayList<>();
|
|
|
items.add(buildTabBarItem(
|
|
items.add(buildTabBarItem(
|