123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using MySystem.MainModels;
- namespace MySystem
- {
- public class RelationClass
- {
- public static string GetUserLevelSetInfo(int key)
- {
- UserLevelSet item = UserLevelSetDbconn.Instance.GetList().FirstOrDefault(m => m.Id == key);
- if (item != null)
- {
- return item.Name;
- }
- return "K1";
- }
- public static string GetUsersInfo(int key)
- {
- Users item = UsersDbconn.Instance.Get(key) ?? new Users();
- return item.RealName;
- }
- public static string GetConsumersInfo(int key)
- {
- Consumers item = ConsumersDbconn.Instance.Get(key) ?? new Consumers();
- return item.NickName;
- }
- #region 获取产品名称
- public static string GetKqProductBrandInfo(int key)
- {
- WebCMSEntities db = new WebCMSEntities();
- KqProducts pro = db.KqProducts.FirstOrDefault(m => m.Id == key);
- db.Dispose();
- if (pro != null)
- {
- return pro.Name;
- }
- return "";
- }
- #endregion
- #region 收支明细变动类型
- public static string GetChangeTypeInfo(int key)
- {
- if (key == 1) return "达标奖励";
- return "";
- }
- #endregion
- #region 机具类型
- public static string GetPosSnTypeInfo(int key)
- {
- if (key == 0) return "兑换码";
- if (key == 1) return "循环码";
- return "";
- }
- #endregion
- #region 订单状态
- public static string GetOrderStatusInfo(int key)
- {
- if (key == 0) return "待付款";
- if (key == 1) return "待发货";
- if (key == 2) return "已完成";
- if (key == 3) return "已发货";
- return "";
- }
- #endregion
- #region 机具兑换申请状态
- public static string GetMachineApplyStatusInfo(int key)
- {
- if (key == 0) return "待审核";
- if (key == 1) return "申请成功";
- if (key == 2) return "申请失败";
- return "";
- }
- #endregion
- #region 组队申请状态
- public static string GetTeamOfferApplyStatusInfo(int key)
- {
- if (key == 0) return "待审核";
- if (key == 1) return "审核通过";
- if (key == 2) return "审核失败";
- if (key == 3) return "组队成功";
- if (key == 4) return "组队失败";
- return "";
- }
- #endregion
- #region 商户激活类型
- public static string GetMerchantActTypeInfo(int key)
- {
- if (key == 0) return "正常激活";
- if (key == 1) return "首次已激活MPOS";
- if (key == 2) return "首次已激活KPOS";
- if (key == 3) return "循环机划拨激活";
- return "";
- }
- #endregion
- }
- }
|