Пример #1
0
        public string Data_Select_Role_ReadByParam(string cxdata)
        {
            token = appClass.CRM_Gettoken();
            CRM_HG_ROLE model = Newtonsoft.Json.JsonConvert.DeserializeObject <CRM_HG_ROLE>(cxdata);

            CRM_HG_ROLE[] data = crmModels.HG_ROLE.ReadByParam(model, token);
            return(Newtonsoft.Json.JsonConvert.SerializeObject(data));
        }
Пример #2
0
        public int Data_Insert_Role_RightRole(string data, string rightdata)
        {
            token = appClass.CRM_Gettoken();
            CRM_HG_ROLE model = Newtonsoft.Json.JsonConvert.DeserializeObject <CRM_HG_ROLE>(data);
            int         i     = crmModels.HG_ROLE.Create(model, token);

            CRM_HG_RIGHTList[] rightmodel = Newtonsoft.Json.JsonConvert.DeserializeObject <CRM_HG_RIGHTList[]>(rightdata);
            for (int j = 0; j < rightmodel.Length; j++)
            {
                int x = crmModels.HG_ROLE.Create_ROLERIGHT(i, rightmodel[j].RIGHTID, token);
                if (x <= 0)
                {
                    return(0);
                }
            }
            return(i);
        }
Пример #3
0
 public CRM_HG_ROLE[] ReadByParam(CRM_HG_ROLE model, string ptoken)
 {
     return(client.ReadByParam(model, ptoken));
 }
Пример #4
0
 public int Update(CRM_HG_ROLE model, string ptoken)
 {
     return(client.Update(model, ptoken));
 }