Esempio n. 1
0
        public static Entity.Respose.OLUserResponse getOLSchoolUserId(Entity.MsSQL.T_Organiza _orga, string _username, string _password)
        {
            Untity.HelperMethod p = new Untity.HelperMethod();
            string path           = HelperAppSet.getAppSetting("olschoolpath");
            string fullpath       = path + "/Member/GetUserId?classid=" + _orga.ClassId + "&UserName="******"&PWD=" + _password;
            string json           = p.Get(fullpath);

            Entity.Respose.GTXResult      result = Untity.HelperJson.DeserializeObject <Entity.Respose.GTXResult>(json);
            Entity.Respose.OLUserResponse rep    = Untity.HelperJson.DeserializeObject <Entity.Respose.OLUserResponse>(Untity.HelperDataCvt.objToString(result.Data));
            return(rep);
        }
Esempio n. 2
0
        //网校接口调课程
        public static List <Entity.Respose.olschoolsubject> GetOLSchoolAllList()
        {
            HelperMethod p        = new HelperMethod();
            string       path     = HelperAppSet.getAppSetting("olschoolpath");
            string       fullpath = path + "/Member/GetOrgCourse?classid=9";
            var          hrr      = HttpHelper.Singleton.HttpGet(fullpath);
            string       json     = hrr.Result.Data;

            Entity.Respose.GTXResult result = Untity.HelperJson.DeserializeObject <Entity.Respose.GTXResult>(json);
            return(Untity.HelperJson.DeserializeObject <List <Entity.Respose.olschoolsubject> >(HelperDataCvt.objToString(result.Data)));
        }
Esempio n. 3
0
        public static bool IsBuyAll(Entity.MsSQL.T_Organiza _orga, string _ids, string _username, ref string error)
        {
            HelperMethod p = new HelperMethod();
            //string path = HelperAppSet.getAppSetting("olschoolpath");
            //string classid = HelperAppSet.getAppSetting("classid");
            string path     = HelperAppSet.getAppSetting("olschoolpath");
            string fullpath = path + "/Member/IsBuyAll?classid=" + _orga.ClassId + "&UserName="******"&Ids=" + _ids;
            string json     = p.Get(fullpath);

            Entity.Respose.GTXResult result = Untity.HelperJson.DeserializeObject <Entity.Respose.GTXResult>(json);
            if (HelperDataCvt.objToString(result.Data).Contains("未购买"))
            {
                error = HelperDataCvt.objToString(result.Data);
                return(false);
            }
            else
            {
                return(true);
            }
        }