예제 #1
0
        /// <summary>
        /// 个人入驻商家信息
        /// </summary>
        /// <returns></returns>
        public ActionResult Steps1()
        {
            long   CompanyRegionId         = 0;
            long   BusinessLicenceRegionId = 0;
            string RefuseReason            = "";
            var    step1 = ShopApplication.GetShopProfileSteps1(CurrentSellerManager.ShopId, out CompanyRegionId, out BusinessLicenceRegionId, out RefuseReason);

            ViewBag.CompanyRegionIds         = RegionApplication.GetRegionPath((int)CompanyRegionId);
            ViewBag.BusinessLicenceRegionIds = RegionApplication.GetRegionPath((int)BusinessLicenceRegionId);
            ViewBag.RefuseReason             = RefuseReason;

            long uid = ShopApplication.GetShopManagers(CurrentSellerManager.ShopId);
            //管理员信息
            var model = MemberApplication.GetMembers(uid);

            step1.RealName = model.RealName;
            Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(uid);
            step1.MemberEmail = mMemberAccountSafety.Email;
            step1.MemberPhone = mMemberAccountSafety.Phone;

            //温馨提示
            ModelState.AddModelError("Phone", "多个联系方式用,号分隔");
            ModelState.AddModelError("ContactPhone", "多个联系方式用,号分隔");
            return(View(step1));
        }
예제 #2
0
        public JsonResult verificationCode(string pluginId, string code)
        {
            long uid = ShopApplication.GetShopManagers(CurrentSellerManager.ShopId);

            Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(uid);
            string destination = "";

            if (pluginId.Equals("Himall.Plugin.Message.Email"))
            {
                destination = mMemberAccountSafety.Email;
            }
            else
            {
                destination = mMemberAccountSafety.Phone;
            }

            int result = MemberApplication.CheckCode(pluginId, code, destination, uid);

            if (result > 0)
            {
                return(Json(new Result()
                {
                    success = true
                }));
            }
            else
            {
                return(Json(new Result()
                {
                    success = false
                }));
            }
        }
예제 #3
0
        public ActionResult Weixin()
        {
            long uid = ShopApplication.GetShopManagers(CurrentSellerManager.ShopId);

            Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(uid);
            ViewBag.MemberEmail = mMemberAccountSafety.Email;
            ViewBag.MemberPhone = mMemberAccountSafety.Phone;
            return(View());
        }
        /// <summary>
        /// 提现申请页面初始
        /// </summary>
        /// <returns></returns>
        public ActionResult ApplyWithDraw()
        {
            Himall.Model.ShopInfo.ShopStage Stage = Himall.Model.ShopInfo.ShopStage.Agreement;
            var shop = ShopApplication.GetShopProfileStep2(CurrentSellerManager.ShopId, out Stage);

            Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(CurrentUser.Id);
            ViewBag.MemberEmail = mMemberAccountSafety.Email;
            ViewBag.MemberPhone = mMemberAccountSafety.Phone;
            return(View(shop));
        }
예제 #5
0
        /// <summary>
        /// 个人或企业账户信息
        /// </summary>
        /// <returns></returns>
        public ActionResult Step3()
        {
            var modelShop = ShopApplication.GetShop(CurrentSellerManager.ShopId);

            #region 个人/企业信息
            long   companyRegionId         = 0;
            long   businessLicenceRegionId = 0;
            string refuseReason            = "";
            if (modelShop.BusinessType.Equals(Himall.CommonModel.ShopBusinessType.Personal))
            {
                var step1 = ShopApplication.GetShopProfileSteps1(CurrentSellerManager.ShopId, out companyRegionId, out businessLicenceRegionId, out refuseReason);
                ViewBag.CompanyRegionIds = RegionApplication.GetRegionPath((int)companyRegionId);
                ViewBag.RefuseReason     = refuseReason;
                ViewBag.fullName         = RegionApplication.GetFullName((int)companyRegionId);

                long uid   = ShopApplication.GetShopManagers(CurrentSellerManager.ShopId);
                var  model = MemberApplication.GetMembers(uid);
                step1.RealName = model.RealName;
                Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(uid);
                step1.MemberEmail = mMemberAccountSafety.Email;
                step1.MemberPhone = mMemberAccountSafety.Phone;

                ModelState.AddModelError("Phone", "多个联系方式用,号分隔");
                ModelState.AddModelError("ContactPhone", "多个联系方式用,号分隔");
                return(View("Steps3", step1));
            }
            else
            {
                var step1 = ShopApplication.GetShopProfileStep1(CurrentSellerManager.ShopId, out companyRegionId, out businessLicenceRegionId, out refuseReason);
                ViewBag.CompanyRegionIds = RegionApplication.GetRegionPath((int)companyRegionId);
                ViewBag.RefuseReason     = refuseReason;
                ViewBag.fullName         = RegionApplication.GetFullName((int)companyRegionId);

                long uid   = ShopApplication.GetShopManagers(CurrentSellerManager.ShopId);
                var  model = MemberApplication.GetMembers(uid);
                step1.RealName = model.RealName;
                Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(uid);
                step1.MemberEmail = mMemberAccountSafety.Email;
                step1.MemberPhone = mMemberAccountSafety.Phone;

                ModelState.AddModelError("Phone", "多个联系方式用,号分隔");
                ModelState.AddModelError("ContactPhone", "多个联系方式用,号分隔");
                return(View(step1));
            }
            #endregion
        }
예제 #6
0
        /// <summary>
        /// 提现申请页面初始
        /// </summary>
        /// <returns></returns>
        public ActionResult ApplyWithDraw()
        {
            Entities.ShopInfo.ShopStage Stage = Entities.ShopInfo.ShopStage.Agreement;
            var shop = ShopApplication.GetShopProfileStep2(CurrentSellerManager.ShopId, out Stage);

            Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(MemberApplication.GetMemberUserIdOrShop(CurrentUser, CurrentSellerManager));

            ViewBag.MemberEmail = mMemberAccountSafety.Email;
            ViewBag.MemberPhone = mMemberAccountSafety.Phone;
            var siteSetting = SiteSettingApplication.SiteSettings;

            ViewBag.CanAlipay       = siteSetting.Withdraw_AlipayEnable;
            ViewBag.CanWXpay        = siteSetting.IsOpenH5;//微信提现需要绑定了微信支付才可以
            ViewBag.WithDrawMinimum = siteSetting.ShopWithDrawMinimum;
            ViewBag.WithDrawMaximum = siteSetting.ShopWithDrawMaximum;
            return(View(shop));
        }
예제 #7
0
        /// <summary>
        /// 获取可提现金额
        /// </summary>
        /// <returns></returns>
        public object GetWithdraw()
        {
            CheckShopManageLogin();;

            //获取诊所账户信息
            DTO.ShopAccount shopAccount = BillingApplication.GetShopAccount(CurrentShop.Id);


            //获取站点配置信息
            var siteSetting = SiteSettingApplication.GetSiteSettings();
            //获取加盟商账户余额
            var balance = 0m;

            if (shopAccount != null)
            {
                balance = shopAccount.Balance;
            }

            //判断诊所是否绑定银行卡
            bool IsBindBank = true;

            if (string.IsNullOrWhiteSpace(CurrentShop.BankAccountNumber))
            {
                IsBindBank = false;
            }
            var user = MemberApplication.GetMemberByName(CurrentUser.UserName);

            Himall.DTO.MemberAccountSafety mMemberAccountSafety = MemberApplication.GetMemberAccountSafety(user.Id);
            return(Json(new
            {
                success = true,                                                                 //状态
                msg = "",
                Balance = balance,                                                              //诊所账户余额
                RealMoney = (MAX_WithDraw_Money - balance) <= 0 ? MAX_WithDraw_Money : balance, //实际可提现金额  //实际可提现金额
                BankAccountName = CurrentShop.BankAccountName,                                  //银行开户名
                BankAccountNumber = CurrentShop.BankAccountNumber,                              //银行账号
                BankName = CurrentShop.BankName,                                                //开户银行名称
                IsBindBank = IsBindBank,                                                        //诊所是否绑定银行卡号 true=已绑定
                Phone = mMemberAccountSafety.Phone,                                             // 手机号码
                BankBranch = CurrentShop.BankName                                               //开户银行支行完整名称
            }));
        }
예제 #8
0
        /// <summary>
        /// 获取会员认证情况
        /// </summary>
        /// <param name="UserId">会员ID</param>
        /// <returns></returns>
        public static Himall.DTO.MemberAccountSafety GetMemberAccountSafety(long UserId)
        {
            Himall.DTO.MemberAccountSafety model = new Himall.DTO.MemberAccountSafety();
            model.UserId = UserId;
            List <Himall.Model.MemberContactsInfo> lmMemberContactsInfo = MessageApplication.GetMemberContactsInfo(UserId);

            foreach (Himall.Model.MemberContactsInfo item in lmMemberContactsInfo)
            {
                if (item.ServiceProvider.Contains("SMS"))
                {
                    model.Phone     = item.Contact;
                    model.BindPhone = true;
                }
                else if (item.ServiceProvider.Contains("Email"))
                {
                    model.Email     = item.Contact;
                    model.BindEmail = true;
                }
            }

            return(model);
        }