public static bool insertInvoicePO(APCEntities APCContext, Invoice invoice, PO po) { try { Invoice_PO invoicePO = new Invoice_PO(); invoicePO.Invoice = invoice; invoicePO.PO = po; APCContext.AddToInvoice_PO(invoicePO); po.Invoiced = true; APCContext.SaveChanges(); return(true); } catch (Exception e) { return(false); } }
public static bool insertInvoicePO(APCEntities APCContext, Invoice invoice, PO po) { try { Invoice_PO invoicePO = new Invoice_PO(); invoicePO.Invoice = invoice; invoicePO.PO = po; APCContext.AddToInvoice_PO(invoicePO); po.Invoiced = true; APCContext.SaveChanges(); return true; } catch(Exception e) { return false; } }