You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.1 KiB
38 lines
1.1 KiB
1 year ago
|
using System;
|
||
|
using System.Collections.Generic;
|
||
|
using System.Linq;
|
||
|
using System.Text;
|
||
|
using System.Threading.Tasks;
|
||
|
using CK.SCP.Models;
|
||
|
using CK.SCP.Models.ScpEntity;
|
||
|
|
||
|
|
||
|
namespace CK.SCP.Controller
|
||
|
{
|
||
|
public class InvoiceDetailController
|
||
|
{
|
||
|
public static List<V_BillInvoiceDetail> GetDataByBillInvoiceDetail(string billnum)
|
||
|
{
|
||
|
using (ScpEntities db = EntitiesFactory.CreateScpInstance())
|
||
|
{
|
||
|
return db.V_BillInvoiceDetail.Where(p => p.BillNum == billnum).ToList();
|
||
|
}
|
||
|
}
|
||
|
|
||
|
public static V_BillInvoiceDetail GetDataByBillInvoiceDetailModel(string billnum)
|
||
|
{
|
||
|
using (ScpEntities db = EntitiesFactory.CreateScpInstance())
|
||
|
{
|
||
|
return db.V_BillInvoiceDetail.SingleOrDefault(p => p.BillNum == billnum);
|
||
|
}
|
||
|
}
|
||
|
public static V_BillInvoiceDetail GetDataByBillInvoiceDetailBillNum(string id)
|
||
|
{
|
||
|
using (ScpEntities db = EntitiesFactory.CreateScpInstance())
|
||
|
{
|
||
|
return db.V_BillInvoiceDetail.SingleOrDefault(p => p.BillNum == id);
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|