Exemplo n.º 1
0
        public Paging <List <QW_SigninAreasModel> > GetSigninAreasList(string filter, int start, int limit)
        {
            List <Filter>     filters = JsonConvert.DeserializeObject <List <Filter> >(filter);
            QW_SigninAreasBLL bll     = new QW_SigninAreasBLL();

            return(bll.GetSigninAreasList(filters, start, limit));
        }
Exemplo n.º 2
0
        public HttpResponseMessage DeletePatrolAreas(int signinareaid)
        {
            QW_SigninAreasBLL bll        = new QW_SigninAreasBLL();
            int result                   = bll.DeleteSigninAreas(signinareaid);
            HttpResponseMessage response = Request.CreateResponse(HttpStatusCode.OK);

            if (result > 0)
            {
                response.Content = new StringContent("{\"success\":true}", Encoding.GetEncoding("UTF-8"), "text/html");
            }
            else
            {
                response.Content = new StringContent("{\"success\":false}", Encoding.GetEncoding("UTF-8"), "text/html");
            }
            return(response);
        }
Exemplo n.º 3
0
        public HttpResponseMessage EditSigninAreas()
        {
            HttpRequestBase     request = ((HttpContextWrapper)this.Request.Properties["MS_HttpContext"]).Request;
            QW_SigninAreasModel model   = new QW_SigninAreasModel();

            if (!string.IsNullOrEmpty(request.Form["signinareaid"]))
            {
                model.signinareaid = Convert.ToInt32(request.Form["signinareaid"]);
            }
            if (!string.IsNullOrEmpty(request.Form["sszd"]))
            {
                model.sszd = Convert.ToInt32(request.Form["sszd"]);
            }
            if (!string.IsNullOrEmpty(request.Form["ssbc"]))
            {
                model.ssbc = Convert.ToInt32(request.Form["ssbc"]);
            }
            model.name = request.Form["name"];
            if (!string.IsNullOrEmpty(request.Form["start_stime"]))
            {
                model.start_stime = Convert.ToDateTime(request.Form["start_stime"]);
            }
            if (!string.IsNullOrEmpty(request.Form["start_etime"]))
            {
                model.start_etime = Convert.ToDateTime(request.Form["start_etime"]);
            }
            if (!string.IsNullOrEmpty(request.Form["end_stime"]))
            {
                model.end_stime = Convert.ToDateTime(request.Form["end_stime"]);
            }
            if (!string.IsNullOrEmpty(request.Form["end_etime"]))
            {
                model.end_etime = Convert.ToDateTime(request.Form["end_etime"]);
            }
            model.explain      = request.Form["explain"];
            model.grometry     = request.Form["grometry"];
            model.createtime   = DateTime.Now;
            model.createuserid = Convert.ToInt32(request.Form["userid"]);

            QW_SigninAreasBLL bll        = new QW_SigninAreasBLL();
            int result                   = bll.EditSigninAreas(model);
            HttpResponseMessage response = Request.CreateResponse(HttpStatusCode.OK);

            response.Content = new StringContent("{\"success\":true}", Encoding.GetEncoding("UTF-8"), "text/html");
            return(response);
        }
Exemplo n.º 4
0
        public List <QW_SigninAreasModel> GetSigninAreasCom(int sszd, int ssbc)
        {
            QW_SigninAreasBLL bll = new QW_SigninAreasBLL();

            return(bll.GetSigninAreasCom(sszd, ssbc));
        }
Exemplo n.º 5
0
        public Paging <List <QW_SigninAreasModel> > GetSigninAreasList(int start, int limit)
        {
            QW_SigninAreasBLL bll = new QW_SigninAreasBLL();

            return(bll.GetSigninAreasList(null, start, limit));
        }