Ver Fonte

修改新旧管理端标识

xie.kaifeng há 9 meses atrás
pai
commit
43a7e88445
19 ficheiros alterados com 47 adições e 27 exclusões
  1. 2 2
      mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/InvestorController.java
  2. 1 1
      mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/OrderQueryController.java
  3. 11 4
      mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/OrganController.java
  4. 0 2
      mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/SystemRoleController.java
  5. 1 1
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/IOrganService.java
  6. 1 1
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/IUseraccountService.java
  7. 1 0
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/OrganServiceImpl.java
  8. 1 0
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/OrganSonServiceService.java
  9. 1 0
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/SystemRoleServiceImpl.java
  10. 1 0
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/SystemmanagerServiceImpl.java
  11. 13 12
      mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/UseraccountServiceImpl.java
  12. 2 2
      mtp3-century/src/main/resources/mapper/AccounttradeconfigMapper.xml
  13. 1 0
      mtp3-century/src/main/resources/mapper/SystemmanagerMapper.xml
  14. 1 0
      mtp3-century/src/main/resources/mapper/SystemmanagerroleMapper.xml
  15. 1 1
      mtp3-century/src/main/resources/mapper/WskhUserinfoMapper.xml
  16. 1 0
      mtp3-interface/src/main/java/com/muchinfo/mtp3interface/mapper/ISystemmanagerroleMapper.java
  17. 4 0
      mtp3-pojos/src/main/java/com/muchinfo/mtp3pojos/entity/Systemmanager.java
  18. 3 0
      mtp3-pojos/src/main/java/com/muchinfo/mtp3pojos/entity/Systemmanagerrole.java
  19. 1 1
      mtp3-pojos/src/main/java/com/muchinfo/mtp3pojos/vo/organ/AccountRiskConfigResult.java

+ 2 - 2
mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/InvestorController.java

@@ -275,8 +275,8 @@ public class InvestorController {
     @ApiOperation("交易商管理-->个性化管理-->交易商分组管理-->获取所选客户信息对应风险率")
     @ApiResponse(code = 200, message = "成功", response = AjaxResult.class)
     @RequestMapping(method = RequestMethod.GET, value = "/getRiskRatioTypeForMarketer")
-    public AjaxResult<Riskratiotype> getRiskRatioTypeForMarketer(Integer customertype, HttpServletRequest request) {
-        return iUseraccountService.getRiskRatioTypeForMarketer(customertype, request);
+    public AjaxResult<Riskratiotype> getRiskRatioTypeForMarketer(Integer customertype, Integer riskcontrolmode, HttpServletRequest request) {
+        return iUseraccountService.getRiskRatioTypeForMarketer(customertype, riskcontrolmode, request);
     }
 
     @ApiOperation("交易商管理-->个性化管理-->交易商分组管理-->新增/修改")

+ 1 - 1
mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/OrderQueryController.java

@@ -115,7 +115,7 @@ public class OrderQueryController {
     }
 
     @RequestMapping(method = RequestMethod.GET, value = "/monitorddjkCount")
-    @ApiOperation("订单管理--> 订单监控 --> 获取总数")
+    @ApiOperation("订单管理--> 订单监控 --> 获取总数")
     @ApiResponse(code = 200, message = "成功", response = AjaxResult.class)
     public AjaxResult<MonitorddjkCountResult> monitorddjkCount(MonitorddjkParam param, HttpServletRequest request) {
         return iOrderQueryService.monitorddjkCount(param, request);

+ 11 - 4
mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/OrganController.java

@@ -8,6 +8,7 @@ import com.muchinfo.mtp3common.utils.JsonUtils;
 import com.muchinfo.mtp3century.utils.AjaxResult;
 import com.muchinfo.mtp3common.vo.PageResult;
 import com.muchinfo.mtp3pojos.entity.Accountriskconfig;
+import com.muchinfo.mtp3pojos.entity.Accounttradeconfig;
 import com.muchinfo.mtp3pojos.entity.Systemmanager;
 import com.muchinfo.mtp3pojos.vo.SystemRoleVo;
 import com.muchinfo.mtp3pojos.vo.investor.InvestorInitBZResult;
@@ -270,8 +271,14 @@ public class OrganController {
     @ApiOperation("会员机构管理-->机构管理-->风控个性化设置--> 新增")
     @RequestMapping(method = RequestMethod.POST, value = "/addaccountriskconfig")
     @ApiResponse(code = 200, message = "成功", response = AjaxResult.class)
-    private AjaxResult addaccountriskconfig(@RequestBody AccountRiskConfigAddParam vo, HttpServletRequest request) {
-        return iOrganService.addaccountriskconfig(vo, request);
+    private AjaxResult addaccountriskconfig(@RequestBody String vo, HttpServletRequest request) {
+        try {
+            AccountRiskConfigAddParam current = JsonUtils.toBean(CenturyDecryptUtil.decryptForJson(vo, request), AccountRiskConfigAddParam.class);
+            return iOrganService.addaccountriskconfig(current, request);
+        } catch (Exception e) {
+            log.error("风控个性化设置新增失败,失败原因:" + Arrays.toString(e.getStackTrace()));
+            return AjaxResult.error(Constants.Error_Code_Design, MessageType.MESSAGE_ERROR_CODE_SYSTEM002.getCode(), request.getHeader("Accept-Language"));
+        }
     }
 
     @ApiOperation("会员机构管理-->机构管理-->风控个性化设置--> 修改")
@@ -304,14 +311,14 @@ public class OrganController {
     @ApiOperation("会员机构管理-->机构管理-->账户个性化设置--> 获取树结构")
     @RequestMapping(method = RequestMethod.GET, value = "/createTree")
     @ApiResponse(code = 200, message = "成功", response = AjaxResult.class)
-    private AjaxResult createTree(HttpServletRequest request) {
+    private AjaxResult<AccountTradeConfigTreeVo> createTree(HttpServletRequest request) {
         return iOrganService.createTree(request);
     }
 
     @ApiOperation("会员机构管理-->机构管理-->账户个性化设置--> 详情")
     @RequestMapping(method = RequestMethod.GET, value = "/tradeConfigView")
     @ApiResponse(code = 200, message = "成功", response = AjaxResult.class)
-    private AjaxResult tradeConfigView(PersonalizationDelParam param, HttpServletRequest request) {
+    private AjaxResult<Accounttradeconfig> tradeConfigView(PersonalizationDelParam param, HttpServletRequest request) {
         //这个是投资者的userid ,获取投资者的分组ID
         param.setMemberuserid(0L);
         param.setRuletype(1);

+ 0 - 2
mtp3-century/src/main/java/com/muchinfo/mtp3century/controller/SystemRoleController.java

@@ -81,6 +81,4 @@ public class SystemRoleController {
     private AjaxResult<SystemRoleVo> queryDetail(Integer autoId, HttpServletRequest request) {
         return iSystemRoleService.queryDetail(autoId, request);
     }
-
-
 }

+ 1 - 1
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/IOrganService.java

@@ -64,7 +64,7 @@ public interface IOrganService {
 
     AjaxResult editorgan(OrganAddSonOrganParam param, HttpServletRequest request);
 
-    AjaxResult createTree(HttpServletRequest request);
+    AjaxResult<AccountTradeConfigTreeVo> createTree(HttpServletRequest request);
 
     AjaxResult<Accounttradeconfig> tradeConfigView(PersonalizationDelParam param, HttpServletRequest request);
 

+ 1 - 1
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/IUseraccountService.java

@@ -39,7 +39,7 @@ public interface IUseraccountService extends IService<Useraccount> {
 
     PageResult<InvestorPersonalizedResult> queryPersonalized(String groupname, Integer pageNum, Integer pageSize, HttpServletRequest request);
 
-    AjaxResult<Riskratiotype> getRiskRatioTypeForMarketer(Integer customertype, HttpServletRequest request);
+    AjaxResult<Riskratiotype> getRiskRatioTypeForMarketer(Integer customertype, Integer riskcontrolmode,HttpServletRequest request);
 
     AjaxResult addPersonalized(InvestorPersonalizedAddParam param, HttpServletRequest request);
 

+ 1 - 0
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/OrganServiceImpl.java

@@ -1239,6 +1239,7 @@ public class OrganServiceImpl implements IOrganService {
         //先按类型
         Map<Integer, List<Accounttradeconfig>> type = new HashMap<>();
         for (Accounttradeconfig fig : list) {
+            fig.setAccountname(iUseraccountMapper.selectOrganName(fig.getUserid()));
             Integer key = fig.getTradetype();
             if (type.containsKey(key)) {
                 type.get(key).add(fig);

+ 1 - 0
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/OrganSonServiceService.java

@@ -1217,6 +1217,7 @@ public class OrganSonServiceService implements IOrganSonService {
         us.setModifytime(new Date());
         us.setPassword(EncryptionUtils.encryptSHA(us.getLogincode() + lPwd));
         us.setPwdexpdate(new Date());
+        us.setSystemtype(2);
         us.setManagertype(1);
         iSystemmanagerMapper.insert(us);
 

+ 1 - 0
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/SystemRoleServiceImpl.java

@@ -159,5 +159,6 @@ public class SystemRoleServiceImpl implements ISystemRoleService {
         systemmanagerrole.setModifytime(new Date());
         systemmanagerrole.setRolestatus(SysEnums.SysStatus.ok.getCode());
         systemmanagerrole.setSensitivefields(systemRoleVo.getSensitivefields());
+        systemmanagerrole.setSystemtype(2);
     }
 }

+ 1 - 0
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/SystemmanagerServiceImpl.java

@@ -275,6 +275,7 @@ public class SystemmanagerServiceImpl extends ServiceImpl<ISystemmanagerMapper,
             //设置所属机构
             user.setAreauserid(systemmanager.getAreauserid());
             user.setPwdexpdate(new Date());
+            user.setSystemtype(2);
             user.setLoginstatus(SysEnums.LoginStatus.loginout.getCode());
             user.setReletype(systemmanager.getReletype());
             user.setLoginfailnum(0);

+ 13 - 12
mtp3-century/src/main/java/com/muchinfo/mtp3century/service/impl/UseraccountServiceImpl.java

@@ -816,10 +816,10 @@ public class UseraccountServiceImpl extends ServiceImpl<IUseraccountMapper, User
     }
 
     @Override
-    public AjaxResult<Riskratiotype> getRiskRatioTypeForMarketer(Integer customertype, HttpServletRequest request) {
+    public AjaxResult<Riskratiotype> getRiskRatioTypeForMarketer(Integer customertype, Integer riskcontrolmode, HttpServletRequest request) {
         Riskratiotype riskRatioType = iRiskratiotypeMapper.selectOne(new QueryWrapper<Riskratiotype>()
                 .eq("customertype", customertype)
-                .eq("riskcontrolmode", 1));
+                .eq("riskcontrolmode", riskcontrolmode));
 
         if (Objects.nonNull(riskRatioType)) {
             BigDecimal cNum = new BigDecimal(100);
@@ -862,17 +862,19 @@ public class UseraccountServiceImpl extends ServiceImpl<IUseraccountMapper, User
                         .multiply(cNum).setScale(2, RoundingMode.HALF_UP));
             }
 
-            List<Market> marketList = iMarketMapper.selectList(new QueryWrapper<Market>().in(StringUtils.isNotBlank(riskRatioType.getCutmarginseq()), "marketid",
-                    Arrays.stream(riskRatioType.getCutmarginseq().split(",")).filter(s -> !s.trim().isEmpty()).map(Long::valueOf).collect(Collectors.toList())));
-            StringBuilder stringBuilder = new StringBuilder();
-            for (int i = 0; i < marketList.size(); i++) {
-                if (i == marketList.size() - 1) {
-                    stringBuilder.append(marketList.get(i).getMarketname());
-                } else {
-                    stringBuilder.append(marketList.get(i).getMarketname()).append(",");
+            if(StringUtils.isNotBlank(riskRatioType.getCutmarginseq())){
+                List<Market> marketList = iMarketMapper.selectList(new QueryWrapper<Market>().in("marketid",
+                        Arrays.stream(riskRatioType.getCutmarginseq().split(",")).filter(s -> !s.trim().isEmpty()).map(Long::valueOf).collect(Collectors.toList())));
+                StringBuilder stringBuilder = new StringBuilder();
+                for (int i = 0; i < marketList.size(); i++) {
+                    if (i == marketList.size() - 1) {
+                        stringBuilder.append(marketList.get(i).getMarketname());
+                    } else {
+                        stringBuilder.append(marketList.get(i).getMarketname()).append(",");
+                    }
                 }
+                riskRatioType.setMarkets(stringBuilder.toString());
             }
-            riskRatioType.setMarkets(stringBuilder.toString());
         }
         return AjaxResult.success(Constants.Success_Code_Design, MessageType.MESSAGE_CODE_SYSTEM001.getCode(), request.getHeader("Accept-Language"), riskRatioType);
     }
@@ -1508,7 +1510,6 @@ public class UseraccountServiceImpl extends ServiceImpl<IUseraccountMapper, User
         Map<Integer, List<Accounttradeconfig>> type = new HashMap<>();
         for (Accounttradeconfig fig : list) {
             fig.setAccountname(iUseraccountMapper.selectOrganName(fig.getUserid()));
-            fig.setGoodsname(iGoodsMapper.selectOne(new QueryWrapper<Goods>().eq("goodsid", fig.getGoodsid())).getGoodsname());
             Integer key = fig.getTradetype();
             if (type.containsKey(key)) {
                 type.get(key).add(fig);

+ 2 - 2
mtp3-century/src/main/resources/mapper/AccounttradeconfigMapper.xml

@@ -26,13 +26,13 @@
 
 
     <select id="getListForTree"  resultType="com.muchinfo.mtp3pojos.entity.Accounttradeconfig">
-        select a.*,( select g.goodsname from goods g   where g.goodsid=a.goodsid ) goodsnamess from accounttradeconfig a
+        select a.*,( select g.goodsname from goods g   where g.goodsid=a.goodsid ) goodsname from accounttradeconfig a
         <where>
             <if test="areauserid != null ">
                 and memberuserid = #{areauserid}
             </if>
         </where>
-        order by userid,goodsnamess asc
+        order by userid,goodsname asc
     </select>
 
 

+ 1 - 0
mtp3-century/src/main/resources/mapper/SystemmanagerMapper.xml

@@ -55,6 +55,7 @@
         <where>
             1=1
             and t.managertype = 1
+            and t.systemtype = 2
             <if test="systemParam.managerStatus != null ">
                 and t.managerstatus=#{systemParam.managerStatus,jdbcType=INTEGER}
             </if>

+ 1 - 0
mtp3-century/src/main/resources/mapper/SystemmanagerroleMapper.xml

@@ -68,6 +68,7 @@
             <if test="systemRoleVo.modifierid != null  ">
                 and smr.modifierid = #{systemRoleVo.modifierid,jdbcType=INTEGER}
             </if>
+            and smr.systemtype = 2
         </where>
         order by smr.rolestatus,smr.autoid,smr.rolename
     </select>

+ 1 - 1
mtp3-century/src/main/resources/mapper/WskhUserinfoMapper.xml

@@ -194,7 +194,7 @@
     </select>
     <select id="accountriskconfig" resultType="com.muchinfo.mtp3pojos.vo.organ.AccountRiskConfigResult">
 
-        select a.*,u.accountname,u.memberuserid,t.ismarketaccount from AccountRiskConfig a
+        select a.*,u.accountname as username,u.memberuserid,t.ismarketaccount from AccountRiskConfig a
         left join useraccount u on a.userid = u.userid
         left join taaccount t on a.accountid=t.accountid
         <where>

+ 1 - 0
mtp3-interface/src/main/java/com/muchinfo/mtp3interface/mapper/ISystemmanagerroleMapper.java

@@ -24,5 +24,6 @@ public interface ISystemmanagerroleMapper extends BaseMapper<Systemmanagerrole>
     List<Systemmanagerrole> getRoleLsitByUserid(@Param("autoid") Long autoid);
 
     IPage<SystemRoleVo> selectByPage(IPage<SystemRoleVo> page, @Param("systemRoleVo") SystemRoleVo systemRoleVo);
+
     List<SystemRoleVo> selectByPage( @Param("systemRoleVo") SystemRoleVo systemRoleVo);
 }

+ 4 - 0
mtp3-pojos/src/main/java/com/muchinfo/mtp3pojos/entity/Systemmanager.java

@@ -112,6 +112,10 @@ public class Systemmanager extends Model<Systemmanager> implements UserDetails,S
     @TableField("MANAGERTYPE")
     private Integer managertype;
 
+    @ApiModelProperty(value = "系统类型 - 1:旧管理端 2:新管理端")
+    @TableField("SYSTEMTYPE")
+    private Integer systemtype;
+
     @TableField(exist = false)
     private List<GrantedAuthority> authorities;
 

+ 3 - 0
mtp3-pojos/src/main/java/com/muchinfo/mtp3pojos/entity/Systemmanagerrole.java

@@ -64,6 +64,9 @@ public class Systemmanagerrole extends Model<Systemmanagerrole> {
     @TableField("MODIFIERID")
     private Long modifierid;
 
+    @ApiModelProperty(value = "系统类型 - 1:旧管理端 2:新管理端")
+    @TableField("SYSTEMTYPE")
+    private Integer systemtype;
 
     @Override
     public Serializable pkVal() {

+ 1 - 1
mtp3-pojos/src/main/java/com/muchinfo/mtp3pojos/vo/organ/AccountRiskConfigResult.java

@@ -18,7 +18,7 @@ public class AccountRiskConfigResult {
     private Long userid;
 
     @ApiModelProperty(value = "会员名称")
-    private Long username;
+    private String username;
 
     @ApiModelProperty(value = "资金账户")
     private Long accountid;