|
|
@ -9,6 +9,7 @@ import com.yxt.anrui.portal.biz.appsubsetversion.AppSubsetVersionService; |
|
|
|
import com.yxt.anrui.portal.biz.banner.BannerService; |
|
|
|
import com.yxt.anrui.portal.biz.flow.FlowableService; |
|
|
|
import com.yxt.anrui.portal.biz.formnotice.FormNoticeService; |
|
|
|
import com.yxt.anrui.portal.biz.sysmobilemenurole.SysMobileMenuRoleService; |
|
|
|
import com.yxt.anrui.portal.biz.sysuser.SysUserService; |
|
|
|
import com.yxt.anrui.terminal.api.supplychain.baseInfo.AppScmBaseInfoFeign; |
|
|
|
import com.yxt.anrui.terminal.api.supplychain.baseInfo.AppScmBaseInfoQuery; |
|
|
@ -60,6 +61,8 @@ public class AppIndexRest implements AppIndexFeign { |
|
|
|
private AppScmBaseInfoFeign appScmBaseInfoFeign; |
|
|
|
@Autowired |
|
|
|
private AppIndexService appIndexService; |
|
|
|
@Autowired |
|
|
|
private SysMobileMenuRoleService sysMobileMenuRoleService; |
|
|
|
|
|
|
|
@Override |
|
|
|
public ResultBean<AppIndexVo> index(String userSid) { |
|
|
@ -164,24 +167,37 @@ public class AppIndexRest implements AppIndexFeign { |
|
|
|
appScmBaseInfoQuery.setUserSid(userSid); |
|
|
|
indexCountVo = appScmBaseInfoFeign.getToDoNum(appScmBaseInfoQuery); |
|
|
|
} |
|
|
|
//查询该用户是否有权限
|
|
|
|
List<String> stringList = sysMobileMenuRoleService.selectMenuList(userSid, item.getAppSid()); |
|
|
|
int count = 0; |
|
|
|
if (indexCountVo.getSuccess()) { |
|
|
|
AppScmBaseInfoVo appScmBaseInfoVo = indexCountVo.getData(); |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getInspectedCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getInspectedCarNum()).intValue(); |
|
|
|
if (stringList.contains(AppIndexEnum.AppMenu.YC.getRemarks())) { |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getInspectedCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getInspectedCarNum()).intValue(); |
|
|
|
} |
|
|
|
} |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getInspectinoCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getInspectinoCarNum()).intValue(); |
|
|
|
if (stringList.contains(AppIndexEnum.AppMenu.XJ.getRemarks())) { |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getInspectinoCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getInspectinoCarNum()).intValue(); |
|
|
|
} |
|
|
|
} |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getMoveCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getMoveCarNum()).intValue(); |
|
|
|
if (stringList.contains(AppIndexEnum.AppMenu.YK.getRemarks())) { |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getMoveCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getMoveCarNum()).intValue(); |
|
|
|
} |
|
|
|
} |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getStorageCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getStorageCarNum()).intValue(); |
|
|
|
if (stringList.contains(AppIndexEnum.AppMenu.SC.getRemarks())) { |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getStorageCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getStorageCarNum()).intValue(); |
|
|
|
} |
|
|
|
} |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getInventoryCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getInventoryCarNum()).intValue(); |
|
|
|
if (stringList.contains(AppIndexEnum.AppMenu.PK.getRemarks())) { |
|
|
|
if (StringUtils.isNotBlank(appScmBaseInfoVo.getInventoryCarNum())) { |
|
|
|
count = count + Integer.valueOf(appScmBaseInfoVo.getInventoryCarNum()).intValue(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
item.setCornerNum(String.valueOf(count)); |
|
|
|
} else { |
|
|
|