• List装form


    List<MemberPrivilegeForm> formlist = new ArrayList<MemberPrivilegeForm>();
            int status = 0;//状态 0:正常 1:锁定
            List<MemberPrivilege> mplist = this.memberPrivilegeService.listObjectTwo(status, shop_id, startPage, endPageSize, orderby);
    
            for(MemberPrivilege mp:mplist){
                String name = "";
                String levelLimit = mp.getLevel_limit();// 适用会员等级   id1,id2…
                int id = Integer.parseInt(levelLimit);
                if(id==0){
                    name="全部会员";
                }else{
                    MemberLevel level = this.memberLevelService.getObject(id);
                    if(level!=null){
                        name = level.getLevel_name();
                    }
                }
                int memberPrivilegeId= mp.getMember_privilege_id();// 特权设置ID
                int shopId = mp.getShop_id();// 店铺ID
                String privilegeName = mp.getPrivilege_name();// 特权名称
                String startTime = mp.getStart_time();// 有效開始时间
                String endTime = mp.getEnd_time();// 有效结束时间
                int privilegeType = mp.getPrivilege_type();// 特权类型
                String privilegeValue = mp.getPrivilege_value();// 特权值
                String privilegeInfo = mp.getPrivilege_info();// 特权说明
                int statuss = mp.getStatus();// 状态
    
                MemberPrivilegeForm form = new MemberPrivilegeForm();
    
                form.setMemberPrivilegeId(memberPrivilegeId);
                form.setShopId(shopId);
                form.setPrivilegeName(privilegeName);
                form.setStartTime(startTime);
                form.setEndTime(endTime);
                form.setPrivilegeType(privilegeType);
                form.setPrivilegeValue(privilegeValue);
                form.setPrivilegeInfo(privilegeInfo);
                form.setStatuss(statuss);
                form.setName(name);
                formlist.add(form);
            }
  • 相关阅读:
    leecode4:寻找两个正序数组的中位数
    leecode3:无重复字符的最长子串
    leecode2:两数相加
    KMP字符串模式匹配
    01迷宫问题
    汉诺塔问题
    微服务-基于Grpc的进程通信-Grpc异常捕获RpcException(4-4)
    React-Antd Pro增删改查
    HTTP 请求
    创业路上-1
  • 原文地址:https://www.cnblogs.com/yfceshi/p/7258742.html
Copyright © 2020-2023  润新知