public static void AddSupplier(ISupplierView supplierView)
        {
            var supplier = new tbl_Sup
               {
               SupLastname = supplierView.SupLastname,
               SupFirstname = supplierView.SupFirstname,
               SupUsr_ = supplierView.SupUsrId,
               SupNumber = supplierView.SupNumber,
               SupContactname = supplierView.SupContactname,
               SupIscompany = supplierView.SupIsCompany
               };

               MerpDatabase().tbl_Sup.AddObject(supplier);
               MerpDatabase().SaveChanges();
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Deprecated Method for adding a new object to the tbl_Sup EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddTotbl_Sup(tbl_Sup tbl_Sup)
 {
     base.AddObject("tbl_Sup", tbl_Sup);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Create a new tbl_Sup object.
 /// </summary>
 /// <param name="sup_">Initial value of the Sup_ property.</param>
 public static tbl_Sup Createtbl_Sup(global::System.Int32 sup_)
 {
     tbl_Sup tbl_Sup = new tbl_Sup();
     tbl_Sup.Sup_ = sup_;
     return tbl_Sup;
 }