Пример #1
0
        /// <summary>
        /// 获取资源类别最大级数
        /// </summary>
        /// <returns></returns>
        internal string GetMaxResLbLayer()
        {
            string[] parameters = new string[0];
            var      result     = RESTFulService.Invoke(CurState, assembly, className, "GetMaxResLbLayer", true, parameters);

            return(result);
        }
Пример #2
0
 /// <summary>
 /// 保存合同状态
 /// </summary>
 /// <param name="value"></param>
 /// <param name="htId"></param>
 internal void SaveHtState(int value, string htId)
 {
     string[] parameters = new string[2];
     parameters[0] = value.ToString();
     parameters[1] = htId;
     var result = RESTFulService.Invoke(CurState, assembly, className, "SaveHtState", true, parameters);
 }
Пример #3
0
 /// <summary>
 /// 终止合同
 /// </summary>
 /// <param name="htNm"></param>
 internal void StopHt(string htNm)
 {
     string[] parameters = new string[1];
     parameters[0] = htNm;
     var result = RESTFulService.Invoke(CurState, assembly, className, "StopHt", true,
                                        parameters);
 }
Пример #4
0
        /// <summary>
        /// 资源编号是否有合同信息
        /// </summary>
        /// <param name="resCode"></param>
        /// <returns></returns>
        internal string GetHtByRescourceCode(string resCode)
        {
            string[] parameters = new string[1];
            parameters[0] = resCode;
            var result = RESTFulService.Invoke(CurState, assembly, className, "GetHtByRescourceCode", true, parameters);

            return(result);
        }
Пример #5
0
        /// <summary>
        /// 获取当前资源类别最大的资源编号
        /// </summary>
        /// <param name="resTypeCode"></param>
        /// <param name="hsdwbh"></param>
        /// <param name="isSeelp"></param>
        /// <returns></returns>
        internal string GetMaxResCode(string resTypeCode, string hsdwbh, bool isSeelp)
        {
            string[] parameters = new string[3];
            parameters[0] = resTypeCode;
            parameters[1] = hsdwbh;
            parameters[2] = Serializer.Serialize(isSeelp);
            var result = RESTFulService.Invoke(CurState, assembly, className, "GetMaxResCode", true, parameters);

            return(result);
        }
Пример #6
0
        public void Check()
        {
            var    response   = RESTFulService.Get(IP138, 5000);
            string regPattern = @"\[(\S*)]";
            var    match      = RegexHelper.GetMatch(response, regPattern);

            if (match.Success)
            {
                var ip = match.Groups[1].Value;
                if (!string.IsNullOrEmpty(ip))
                {
                    if (string.IsNullOrEmpty(IPCache.IP) || ip != IPCache.IP)
                    {
                        this.SendEmail("New IP:" + ip);
                        IPCache.IP = ip;
                    }
                }
            }
        }
Пример #7
0
 /// <summary>
 /// 根据资源的有效时间更新资源状态和合同状态
 /// </summary>
 internal void UpdateResAndHtStateByEndTime()
 {
     string[] parameters = new string[0];
     var      result     = RESTFulService.Invoke(CurState, assembly, className, "UpdateResAndHtStateByEndTime", true,
                                                 parameters);
 }