//========================================
 //RecordCostumer() save the information of the
 //costumer who is purchasing items
 //========================================
 public void recordCustomer(int id)
 {
     saleLineItems      = new List <SaleLine>();
     purchaser          = c_Info.Search(id);
     count.OrderCounter = count.OrderCounter + 1;
 }
Example #2
0
 /// <summary>
 /// 新增客户表,和地址表
 /// </summary>
 /// <param name="c"></param>
 /// <param name="d"></param>
 /// <returns></returns>
 public static int Get_kehuinsert(customer c)
 {
     return(KLdal.Get_kehuinsert(c));
 }
Example #3
0
 /// <summary>
 /// 修改
 /// </summary>
 /// <param name="c"></param>
 /// <param name="d"></param>
 /// <returns></returns>
 public static int Get_kehuUpdate(customer c)
 {
     return(KLdal.Get_kehuUpdate(c));
 }
Example #4
0
 //=======================================
 //Update existing costumer
 //=======================================
 public void updateCustomer(customer obj)
 {
     customer.updateCostumer(data);
 }
Example #5
0
 //=======================================
 //Add new costumer to file
 //=======================================
 public void addCustomer(customer obj)
 {
     obj.Payables = 0;
     data.Add(obj);
     customer.addCostumer(obj);
 }
Example #6
0
 /// <summary>
 /// 修改
 /// </summary>
 /// <param name="cu"></param>
 /// <returns></returns>
 public int updatecustomer(customer cu)
 {
     return(new customerDAL().updatecustomer(cu));
 }
Example #7
0
        public customer query(customer cu)
        {
            string sql = " and ID=" + cu.ID;

            return(new customerDAL().selcustomer(sql)[0]);
        }
Example #8
0
        /// <summary>
        /// 登录
        /// </summary>
        /// <param name="cu"></param>
        /// <returns></returns>
        public customer selcustomer(customer cu)
        {
            string sql = " and Account = '" + cu.Account + "' and [password] = '" + cu.Pssword + "'";

            return(new customerDAL().selcustomer(sql)[0]);
        }