public ObjectResultEx GetPhoneCode(SimpleParam <String> Param) { String Code = ValidateCode.CreateCode(); CacheFactory.Cache().WriteCaches(Code, "PhoneCode", 5); String Contents = $"你的手机验证码是:{Code},请在5分钟内输入,如非本人操作,请忽略此短信。"; return(ObjectResultEx.Instance(PhoneSMS.SendPhoneMsg(Param.Parameter, Contents), 1, RetrunMessge.SUCCESS, HttpCode.Success)); //return ObjectResultEx.Instance(Code, 1, RetrunMessge.SUCCESS, HttpCode.Success); }
public ObjectResultEx SendPhoneMsg(SimpleParam <String> Phone, SimpleParam <String> Msg) { return(ObjectResultEx.Instance(PhoneSMS.SendPhoneMsg(Phone.Id, Msg.Parameter), 1, RetrunMessge.SUCCESS, HttpCode.Success)); //return ObjectResultEx.Instance(Code, 1, RetrunMessge.SUCCESS, HttpCode.Success); }