Exemplo n.º 1
0
        /// <summary>
        /// 初始化地址列表
        /// </summary>
        protected void initList()
        {
            Eyousoft_yhq.BLL.GYSticket bll = new Eyousoft_yhq.BLL.GYSticket();

            #region 查询实体
            Eyousoft_yhq.Model.GysTicketSer serchModel = new Eyousoft_yhq.Model.GysTicketSer();
            serchModel.OpertorID = HuiYuanInfo.UserID;
            serchModel.cusName = Utils.GetQueryStringValue("cusName");
            serchModel.cusMob = Utils.GetQueryStringValue("cusMob");
            serchModel.tickNO = Utils.GetQueryStringValue("GysTicket");
            pageIndex = UtilsCommons.GetPagingIndex("Page");
            #endregion

            var list = bll.GetList(pageSize, pageIndex, ref recordCount, serchModel);

            if (list != null && list.Count > 0)
            {
                rpTicket.DataSource = list;
                rpTicket.DataBind();
                BindPage();
                NoMsg.Visible = false;
            }
            else
            {

                rpTicket.Visible = false;
                NoMsg.Text = "<tr><td align=\"center\" colspan=\"7\">没有相关数据!</td></tr>";

            }
        }
Exemplo n.º 2
0
        /// <summary>
        /// 消费
        /// </summary>
        /// <returns></returns>
        protected void setOrderState()
        {
            string id        = Utils.GetQueryStringValue("id");
            string ordertype = Utils.GetQueryStringValue("ordertype");
            string mobNo     = Utils.GetQueryStringValue("appMob");

            if (ordertype == "order")
            {
                bool result = new Eyousoft_yhq.BLL.Order().setConSumState(id, HuiYuanInfo.UserID, fangshi, mobNo);

                Response.Clear();
                Response.Write(UtilsCommons.AjaxReturnJson(result ? "1" : "0", result ? "操作成功" : "操作失败"));
                Response.End();
            }
            else if (ordertype == "torder")
            {
                var model = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
                model.orderState = Eyousoft_yhq.Model.TickOrderState.已出票;
                model.payState   = Eyousoft_yhq.Model.PaymentState.已支付;
                bool result = new Eyousoft_yhq.BLL.GYSticket().Update(model);

                Response.Clear();
                Response.Write(UtilsCommons.AjaxReturnJson(result ? "1" : "0", result ? "操作成功" : "操作失败"));
                Response.End();
            }
        }
Exemplo n.º 3
0
        /// <summary>
        /// 保存操作
        /// </summary>
        /// <param name="dotype"></param>
        /// <param name="aid"></param>
        /// <returns></returns>
        protected string save(string dotype, string aid)
        {
            Eyousoft_yhq.Model.GYSticket model = new Eyousoft_yhq.Model.GYSticket();
            model.CusName     = Utils.GetFormValue(contactname.UniqueID);
            model.CusSex      = (sexType)Utils.GetInt(Utils.GetFormValue(dl_sex.UniqueID));
            model.CusMob      = Utils.GetFormValue(contactmob.UniqueID);
            model.PlaneTicket = Utils.GetFormValue(contacticket.UniqueID);
            model.Remark      = Utils.GetFormValue(remark.UniqueID);
            model.OpertorID   = HuiYuanInfo.UserID;
            string msg = "";

            if (dotype == "add")
            {
                msg = new Eyousoft_yhq.BLL.GYSticket().Add(model) ? Utils.AjaxReturnJson("1", "新增成功!") : Utils.AjaxReturnJson("0", "新增失败!");
            }
            else
            {
                model.ID = aid;
                var Tmodel = new Eyousoft_yhq.BLL.GYSticket().GetModel(model.ID);
                if (Tmodel != null)
                {
                    model.payState   = Tmodel.payState;
                    model.orderState = Tmodel.orderState;
                }
                msg = new Eyousoft_yhq.BLL.GYSticket().Update(model) ? Utils.AjaxReturnJson("1", "修改成功!") : Utils.AjaxReturnJson("0", "修改失败!");
            }
            return(msg);
        }
Exemplo n.º 4
0
        /// <summary>
        /// 初始化地址列表
        /// </summary>
        protected void initList()
        {
            Eyousoft_yhq.BLL.GYSticket bll = new Eyousoft_yhq.BLL.GYSticket();

            #region 查询实体
            Eyousoft_yhq.Model.GysTicketSer serchModel = new Eyousoft_yhq.Model.GysTicketSer();
            serchModel.OpertorID = HuiYuanInfo.UserID;
            serchModel.cusName   = Utils.GetQueryStringValue("cusName");
            serchModel.cusMob    = Utils.GetQueryStringValue("cusMob");
            serchModel.tickNO    = Utils.GetQueryStringValue("GysTicket");
            pageIndex            = UtilsCommons.GetPagingIndex("Page");
            #endregion

            var list = bll.GetList(pageSize, pageIndex, ref recordCount, serchModel);

            if (list != null && list.Count > 0)
            {
                rpTicket.DataSource = list;
                rpTicket.DataBind();
                BindPage();
                NoMsg.Visible = false;
            }
            else
            {
                rpTicket.Visible = false;
                NoMsg.Text       = "<tr><td align=\"center\" colspan=\"7\">没有相关数据!</td></tr>";
            }
        }
Exemplo n.º 5
0
 /// <summary>
 /// 保存操作
 /// </summary>
 /// <param name="dotype"></param>
 /// <param name="aid"></param>
 /// <returns></returns>
 protected string save(string dotype, string aid)
 {
     Eyousoft_yhq.Model.GYSticket model = new Eyousoft_yhq.Model.GYSticket();
     model.CusName = Utils.GetFormValue(contactname.UniqueID);
     model.CusSex = (sexType)Utils.GetInt(Utils.GetFormValue(dl_sex.UniqueID));
     model.CusMob = Utils.GetFormValue(contactmob.UniqueID);
     model.PlaneTicket = Utils.GetFormValue(contacticket.UniqueID);
     model.Remark = Utils.GetFormValue(remark.UniqueID);
     model.OpertorID = HuiYuanInfo.UserID;
     string msg = "";
     if (dotype == "add")
     {
         msg = new Eyousoft_yhq.BLL.GYSticket().Add(model) ? Utils.AjaxReturnJson("1", "新增成功!") : Utils.AjaxReturnJson("0", "新增失败!");
     }
     else
     {
         model.ID = aid;
         var Tmodel = new Eyousoft_yhq.BLL.GYSticket().GetModel(model.ID);
         if (Tmodel != null)
         {
             model.payState = Tmodel.payState;
             model.orderState = Tmodel.orderState;
         }
         msg = new Eyousoft_yhq.BLL.GYSticket().Update(model) ? Utils.AjaxReturnJson("1", "修改成功!") : Utils.AjaxReturnJson("0", "修改失败!");
     }
     return msg;
 }
Exemplo n.º 6
0
        /// <summary>
        /// 删除操作
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        protected string deleteAddressById(string id)
        {
            string msg = "";

            msg = new Eyousoft_yhq.BLL.GYSticket().Delete(id) ? Utils.AjaxReturnJson("1", "删除成功!") : Utils.AjaxReturnJson("0", "删除失败!");
            return(msg);
        }
Exemplo n.º 7
0
 /// <summary>
 /// 显示订单信息
 /// </summary>
 protected void initPage()
 {
     string id = Utils.GetQueryStringValue("id");
     string ordertype = Utils.GetQueryStringValue("ordertype");
     if (ordertype == "order")
     {
         var model = new Eyousoft_yhq.BLL.Order().GetModel(id);
         if (model == null)
         {
             lblxiaofei.Text = "未找到此订单!";
             xiaofei.Visible = isXF.Visible = false;
             return;
         }
         if (model.XiaoFei == Eyousoft_yhq.Model.XFstate.已消费 && model.AvailNum <= 0)
         {
             lblxiaofei.Text = "此订单已消费!";
             xiaofei.Visible = isXF.Visible = false;
             return;
         }
         else if (DateTime.Compare(model.ZCodeViaDate, DateTime.Now) < 0)
         {
             lblxiaofei.Text = "此订单已过期!";
             xiaofei.Visible = isXF.Visible = false;
             return;
         }
         else
         {
             cusName.Value = model.MemberName;
             cusMob.Value = model.MemberTel;
             proName.Value = model.ProductName;
             if (model.JIESUAN == Eyousoft_yhq.Model.JSfangshi.预付 &&
                 model.PayState == Eyousoft_yhq.Model.PaymentState.已支付) fangshi = model.JIESUAN;
             lblxiaofei.Visible = false;
         }
     }
     else
     {
         var model = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
         if (model == null)
         {
             lblxiaofei.Text = "未找到此订单!";
             xiaofei.Visible = isXF.Visible = false;
             return;
         }
         if (model.orderState == Eyousoft_yhq.Model.TickOrderState.已出票)
         {
             lblxiaofei.Text = "此订单已出票!";
             xiaofei.Visible = isXF.Visible = false;
             return;
         }
         else
         {
             cusName.Value = model.CusName;
             cusMob.Value = model.CusMob;
             proName.Value = "机票:" + model.PlaneTicket;
             lblxiaofei.Visible = false;
         }
     }
 }
Exemplo n.º 8
0
        /// <summary>
        /// 初始化编辑地址信息
        /// </summary>
        /// <param name="id"></param>
        protected void initPage(string id)
        {
            Eyousoft_yhq.BLL.GYSticket bll = new Eyousoft_yhq.BLL.GYSticket();

            var model = bll.GetModel(id);
            if (model != null)
            {
                contactname.Value = model.CusName;
                if (dl_sex.Items.FindByText(model.CusSex.ToString()) != null)
                    this.dl_sex.Items.FindByText(model.CusSex.ToString()).Selected = true;
                contactmob.Value = model.CusMob;
                contacticket.Value = model.PlaneTicket;
                remark.Value = model.Remark;
            }
        }
Exemplo n.º 9
0
        /// <summary>
        /// 初始化编辑地址信息
        /// </summary>
        /// <param name="id"></param>
        protected void initPage(string id)
        {
            Eyousoft_yhq.BLL.GYSticket bll = new Eyousoft_yhq.BLL.GYSticket();

            var model = bll.GetModel(id);

            if (model != null)
            {
                contactname.Value = model.CusName;
                if (dl_sex.Items.FindByText(model.CusSex.ToString()) != null)
                {
                    this.dl_sex.Items.FindByText(model.CusSex.ToString()).Selected = true;
                }
                contactmob.Value   = model.CusMob;
                contacticket.Value = model.PlaneTicket;
                remark.Value       = model.Remark;
            }
        }
Exemplo n.º 10
0
        /// <summary>
        /// 初始化列表
        /// </summary>
        protected void initList()
        {
            Eyousoft_yhq.BLL.GYSticket bll = new Eyousoft_yhq.BLL.GYSticket();

            #region 查询实体
            Eyousoft_yhq.Model.GysTicketSer serchModel = new Eyousoft_yhq.Model.GysTicketSer();
            serchModel.cusName = Utils.GetQueryStringValue("cusName");
            serchModel.cusMob  = Utils.GetQueryStringValue("cusMob");
            serchModel.tickNO  = Utils.GetQueryStringValue("GysTicket");
            pageIndex          = UtilsCommons.GetPagingIndex("Page");
            #endregion

            var list = bll.GetList(pageSize, pageIndex, ref recordCount, serchModel);

            if (list != null && list.Count > 0)
            {
                rpTicket.DataSource = list;
                rpTicket.DataBind();
                BindPage();
                litMsg.Visible = false;
            }
        }
Exemplo n.º 11
0
        /// <summary>
        /// 初始化列表
        /// </summary>
        protected void initList()
        {
            Eyousoft_yhq.BLL.GYSticket bll = new Eyousoft_yhq.BLL.GYSticket();

            #region 查询实体
            Eyousoft_yhq.Model.GysTicketSer serchModel = new Eyousoft_yhq.Model.GysTicketSer();
            serchModel.cusName = Utils.GetQueryStringValue("cusName");
            serchModel.cusMob = Utils.GetQueryStringValue("cusMob");
            serchModel.tickNO = Utils.GetQueryStringValue("GysTicket");
            pageIndex = UtilsCommons.GetPagingIndex("Page");
            #endregion

            var list = bll.GetList(pageSize, pageIndex, ref recordCount, serchModel);

            if (list != null && list.Count > 0)
            {
                rpTicket.DataSource = list;
                rpTicket.DataBind();
                BindPage();
                litMsg.Visible = false;
            }
        }
Exemplo n.º 12
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string id = EyouSoft.Common.Utils.GetQueryStringValue("id");
            string tp = EyouSoft.Common.Utils.GetQueryStringValue("tp");

            if (tp == "1")
            {
                var order = new Eyousoft_yhq.BLL.Order().GetModel(id);
                if (order == null)
                {
                    ZXING.Text = "未找到此订单!";
                    return;
                }
                else
                {
                    string data = "order|" + order.OrderID + "|产品名称:" + order.ProductName + "|会员姓名:" + order.MemberName;
                    ZXING.Text = string.Format("<img src={0} />", EyouSoft.Common.Utils.CreateZxingCode(data));
                }
            }
            else if (tp == "2")
            {
                var order = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
                if (order == null)
                {
                    ZXING.Text = "未找到此订单!"; return;
                }
                else
                {
                    string data = "torder|" + order.ID + "|机票编号:" + order.PlaneTicket + "|客户姓名:" + order.CusName;
                    ZXING.Text = string.Format("<img src={0} />", EyouSoft.Common.Utils.CreateZxingCode(data));
                }
            }
            else
            {
                ZXING.Text = "未找到此订单!";
            }
        }
Exemplo n.º 13
0
 /// <summary>
 /// 删除操作
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 protected string deleteAddressById(string id)
 {
     string msg = "";
     msg = new Eyousoft_yhq.BLL.GYSticket().Delete(id) ? Utils.AjaxReturnJson("1", "删除成功!") : Utils.AjaxReturnJson("0", "删除失败!");
     return msg;
 }
Exemplo n.º 14
0
        protected void Page_Load(object sender, EventArgs e)
        {
            var model = EyouSoft.Common.Page.HuiyuanPage.GetUserInfo();
            if (model == null) return;
            Mark = model.IsAdmin;
            string id = Utils.GetQueryStringValue("id");
            string ordertype = Utils.GetQueryStringValue("ordertype");

            if (Utils.GetQueryStringValue("chk") == "1")
            {
                if (ordertype == "order")
                {
                    var order = new Eyousoft_yhq.BLL.Order().GetModel(id);
                    Response.Clear();
                    if (order == null)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("2", "未找到订单"));
                    }
                    else if (order.XiaoFei == Eyousoft_yhq.Model.XFstate.已消费 && order.AvailNum <= 0)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("1", "此订单已消费"));
                    }
                    else if (order.PayState == Eyousoft_yhq.Model.PaymentState.未支付)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("3", "此订单未支付"));
                    }
                    else if (order.XiaoFei == Eyousoft_yhq.Model.XFstate.未消费 && order.PayState == Eyousoft_yhq.Model.PaymentState.已支付)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("0", "有效订单"));
                    }
                    else if (order.XiaoFei == Eyousoft_yhq.Model.XFstate.已消费 && order.AvailNum > 0)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("0", "有效订单"));
                    }
                    else
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("999", "订单信息错误"));
                    }
                    Response.End();
                }
                else if (ordertype == "torder")
                {
                    var order = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
                    Response.Clear();
                    if (order == null)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("2", "未找到订单"));
                    }
                    else if (order.payState == Eyousoft_yhq.Model.PaymentState.未支付)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("3", "此订单未支付"));
                    }
                    else if (order.orderState == Eyousoft_yhq.Model.TickOrderState.已出票)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("1", "此订单已出票"));
                    }
                    else
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("0", "有效订单"));
                    }
                    Response.End();
                }
                else if (ordertype == "jp")
                {
                    Eyousoft_yhq.Model.MJiPiaoBaoCun jpModel = new Eyousoft_yhq.BLL.BJiPiaoBaoCun().GetModelByCode(id);

                    if (jpModel == null)
                    {
                        Utils.RCWE(UtilsCommons.AjaxReturnJson("2", "未找到此订单2"));
                    }
                    else if (jpModel.payState != Eyousoft_yhq.Model.TickOrderPayState.已出票)
                    {
                        Utils.RCWE(UtilsCommons.AjaxReturnJson("4", "未出票"));
                    }
                    else if (jpModel.payState == Eyousoft_yhq.Model.TickOrderPayState.已出票)
                    {
                        Utils.RCWE(UtilsCommons.AjaxReturnJson("99", "有效订单"));
                    }
                    else
                    {
                        UtilsCommons.AjaxReturnJson("99", "test");
                    }
                }

            }
        }
Exemplo n.º 15
0
        /// <summary>
        /// 显示订单信息
        /// </summary>
        protected void initPage()
        {
            string id        = Utils.GetQueryStringValue("id");
            string ordertype = Utils.GetQueryStringValue("ordertype");

            if (ordertype == "order")
            {
                var model = new Eyousoft_yhq.BLL.Order().GetModel(id);
                if (model == null)
                {
                    lblxiaofei.Text = "未找到此订单!";
                    xiaofei.Visible = isXF.Visible = false;
                    return;
                }
                if (model.XiaoFei == Eyousoft_yhq.Model.XFstate.已消费 && model.AvailNum <= 0)
                {
                    lblxiaofei.Text = "此订单已消费!";
                    xiaofei.Visible = isXF.Visible = false;
                    return;
                }
                else if (DateTime.Compare(model.ZCodeViaDate, DateTime.Now) < 0)
                {
                    lblxiaofei.Text = "此订单已过期!";
                    xiaofei.Visible = isXF.Visible = false;
                    return;
                }
                else
                {
                    cusName.Value = model.MemberName;
                    cusMob.Value  = model.MemberTel;
                    proName.Value = model.ProductName;
                    if (model.JIESUAN == Eyousoft_yhq.Model.JSfangshi.预付 &&
                        model.PayState == Eyousoft_yhq.Model.PaymentState.已支付)
                    {
                        fangshi = model.JIESUAN;
                    }
                    lblxiaofei.Visible = false;
                }
            }
            else
            {
                var model = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
                if (model == null)
                {
                    lblxiaofei.Text = "未找到此订单!";
                    xiaofei.Visible = isXF.Visible = false;
                    return;
                }
                if (model.orderState == Eyousoft_yhq.Model.TickOrderState.已出票)
                {
                    lblxiaofei.Text = "此订单已出票!";
                    xiaofei.Visible = isXF.Visible = false;
                    return;
                }
                else
                {
                    cusName.Value      = model.CusName;
                    cusMob.Value       = model.CusMob;
                    proName.Value      = "机票:" + model.PlaneTicket;
                    lblxiaofei.Visible = false;
                }
            }
        }
Exemplo n.º 16
0
        protected void Page_Load(object sender, EventArgs e)
        {
            var model = EyouSoft.Common.Page.HuiyuanPage.GetUserInfo();

            if (model == null)
            {
                return;
            }
            Mark = model.IsAdmin;
            string id        = Utils.GetQueryStringValue("id");
            string ordertype = Utils.GetQueryStringValue("ordertype");

            if (Utils.GetQueryStringValue("chk") == "1")
            {
                if (ordertype == "order")
                {
                    var order = new Eyousoft_yhq.BLL.Order().GetModel(id);
                    Response.Clear();
                    if (order == null)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("2", "未找到订单"));
                    }
                    else if (order.XiaoFei == Eyousoft_yhq.Model.XFstate.已消费 && order.AvailNum <= 0)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("1", "此订单已消费"));
                    }
                    else if (order.PayState == Eyousoft_yhq.Model.PaymentState.未支付)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("3", "此订单未支付"));
                    }
                    else if (order.XiaoFei == Eyousoft_yhq.Model.XFstate.未消费 && order.PayState == Eyousoft_yhq.Model.PaymentState.已支付)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("0", "有效订单"));
                    }
                    else if (order.XiaoFei == Eyousoft_yhq.Model.XFstate.已消费 && order.AvailNum > 0)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("0", "有效订单"));
                    }
                    else
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("999", "订单信息错误"));
                    }
                    Response.End();
                }
                else if (ordertype == "torder")
                {
                    var order = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
                    Response.Clear();
                    if (order == null)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("2", "未找到订单"));
                    }
                    else if (order.payState == Eyousoft_yhq.Model.PaymentState.未支付)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("3", "此订单未支付"));
                    }
                    else if (order.orderState == Eyousoft_yhq.Model.TickOrderState.已出票)
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("1", "此订单已出票"));
                    }
                    else
                    {
                        Response.Write(UtilsCommons.AjaxReturnJson("0", "有效订单"));
                    }
                    Response.End();
                }
                else if (ordertype == "jp")
                {
                    Eyousoft_yhq.Model.MJiPiaoBaoCun jpModel = new Eyousoft_yhq.BLL.BJiPiaoBaoCun().GetModelByCode(id);

                    if (jpModel == null)
                    {
                        Utils.RCWE(UtilsCommons.AjaxReturnJson("2", "未找到此订单2"));
                    }
                    else if (jpModel.payState != Eyousoft_yhq.Model.TickOrderPayState.已出票)
                    {
                        Utils.RCWE(UtilsCommons.AjaxReturnJson("4", "未出票"));
                    }
                    else if (jpModel.payState == Eyousoft_yhq.Model.TickOrderPayState.已出票)
                    {
                        Utils.RCWE(UtilsCommons.AjaxReturnJson("99", "有效订单"));
                    }
                    else
                    {
                        UtilsCommons.AjaxReturnJson("99", "test");
                    }
                }
            }
        }
Exemplo n.º 17
0
        /// <summary>
        /// 消费
        /// </summary>
        /// <returns></returns>
        protected void setOrderState()
        {
            string id = Utils.GetQueryStringValue("id");
            string ordertype = Utils.GetQueryStringValue("ordertype");
            string mobNo = Utils.GetQueryStringValue("appMob");
            if (ordertype == "order")
            {
                bool result = new Eyousoft_yhq.BLL.Order().setConSumState(id, HuiYuanInfo.UserID, fangshi, mobNo);

                Response.Clear();
                Response.Write(UtilsCommons.AjaxReturnJson(result ? "1" : "0", result ? "操作成功" : "操作失败"));
                Response.End();
            }
            else if (ordertype == "torder")
            {

                var model = new Eyousoft_yhq.BLL.GYSticket().GetModel(id);
                model.orderState = Eyousoft_yhq.Model.TickOrderState.已出票;
                model.payState = Eyousoft_yhq.Model.PaymentState.已支付;
                bool result = new Eyousoft_yhq.BLL.GYSticket().Update(model);

                Response.Clear();
                Response.Write(UtilsCommons.AjaxReturnJson(result ? "1" : "0", result ? "操作成功" : "操作失败"));
                Response.End();
            }
        }