コード例 #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string strId = Request.QueryString["Id"];

            int id = Convert.ToInt32(strId);

            order = CraftsManDataHelper.GetCraftsManOrderById(id);
        }
コード例 #2
0
        public static CraftsManOrder GetCraftsManOrder(long id)
        {
            using (var dc = new RentooloEntities())
            {
                CraftsManOrder item = dc.CraftsManOrder.FirstOrDefault(x => x.Id == id);

                return(item);
            }
        }
コード例 #3
0
        public static long AddCraftsManOrder(CraftsManOrder item)
        {
            using (var dc = new RentooloEntities())
            {
                var result = dc.CraftsManOrder.Add(item);

                var res = dc.SaveChanges();

                return(result.Id);
            }
        }