public ComboBoxResult SetSingleSelect2Data(int Id, string SqlProcSet) { SqlParameter SqlParameterDocId = new SqlParameter("@Ids", Id); ComboBoxResult ProductJson = _unitOfWork.SqlQuery <ComboBoxResult>(" " + SqlProcSet + " @Ids ", SqlParameterDocId).FirstOrDefault(); return(ProductJson); }
public JsonResult SetFilterFormat(String Ids) { ComboBoxResult ProductJson = new ComboBoxResult(); ProductJson.id = Ids; ProductJson.text = Ids; return(Json(ProductJson)); }
public ComboBoxResult SetReferenceDocIds(int Id, int DocTypeId) { SqlParameter SqlParameterDocId = new SqlParameter("@DocId", Id); SqlParameter SqlParameterDocTypeId = new SqlParameter("@DocTypeId", DocTypeId); ComboBoxResult ComboBoxResult = db.Database.SqlQuery <ComboBoxResult>("" + ConfigurationManager.AppSettings["DataBaseSchema"] + ".spSetHelpListReferenceDocIds" + " @DocTypeId, @DocId", SqlParameterDocTypeId, SqlParameterDocId).FirstOrDefault(); return(ComboBoxResult); }
public JsonResult SetSingleJobOrderLine(int Ids) { ComboBoxResult JobOrderJson = new ComboBoxResult(); var JobOrderLine = _DyeingService.GetJobOrderLine(Ids); JobOrderJson.id = JobOrderLine.id; JobOrderJson.text = JobOrderLine.text; return(Json(JobOrderJson)); }
public JsonResult SetSingleBuyerSpecification3(string Ids) { ComboBoxResult ProductJson = (from b in db.SaleEnquiryLineExtended where b.BuyerSpecification3 == Ids select new ComboBoxResult { id = b.BuyerSpecification3, text = b.BuyerSpecification3, }).FirstOrDefault(); return(Json(ProductJson)); }
public JsonResult SetSingleProdOrderLine(int Ids) { ComboBoxResult ProdOrderJson = new ComboBoxResult(); var ProdOrderLine = _RecipeHeaderService.GetProdOrderLine(Ids); ProdOrderJson.id = ProdOrderLine.id; ProdOrderJson.text = ProdOrderLine.text; return(Json(ProdOrderJson)); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <LedgerAccount> LedgerAccounts = from pr in _LedgerAccountRepository.Instance where pr.LedgerAccountId == Id select pr; ProductJson.id = LedgerAccounts.FirstOrDefault().LedgerAccountId.ToString(); ProductJson.text = LedgerAccounts.FirstOrDefault().LedgerAccountName; return(ProductJson); }
public JsonResult SetSingleBuyerProduct(int Ids) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <ViewProductBuyer> prod = from p in db.ViewProductBuyer where p.ProductId == Ids select p; ProductJson.id = prod.FirstOrDefault().ProductId.ToString(); ProductJson.text = prod.FirstOrDefault().ProductName; return(Json(ProductJson)); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Person> Jobworkers = from pr in _unitOfWork.Repository <Person>().Instance where pr.PersonID == Id select pr; ProductJson.id = Jobworkers.FirstOrDefault().PersonID.ToString(); ProductJson.text = Jobworkers.FirstOrDefault().Name; return(ProductJson); }
public ComboBoxResult GetTask(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Tasks> Tasks = from tr in _TaskRepository.Instance where tr.TaskId == Id select tr; ProductJson.id = Tasks.FirstOrDefault().TaskId.ToString(); ProductJson.text = Tasks.FirstOrDefault().TaskTitle; return(ProductJson); }
public ComboBoxResult GetRole(string Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <_Roles> Roles = from p in _RoleRepository.Instance where p.Id == Id select p; ProductJson.id = Roles.FirstOrDefault().Id; ProductJson.text = Roles.FirstOrDefault().Name; return(ProductJson); }
public ComboBoxResult GetUserById(string Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <_Users> users = from p in _UserRepository.Instance where p.Id == Id select p; ProductJson.id = users.FirstOrDefault().Id.ToString(); ProductJson.text = users.FirstOrDefault().UserName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <BinLocation> BinLocations = from pr in _BinLocationRepository.Instance where pr.BinLocationId == Id select pr; ProductJson.id = BinLocations.FirstOrDefault().BinLocationId.ToString(); ProductJson.text = BinLocations.FirstOrDefault().BinLocationName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Dimension2> Dimension2s = from pr in _Dimension2Repository.Instance where pr.Dimension2Id == Id select pr; ProductJson.id = Dimension2s.FirstOrDefault().Dimension2Id.ToString(); ProductJson.text = Dimension2s.FirstOrDefault().Dimension2Name; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Product> Products = from pr in _productRepository.Instance where pr.ProductId == Id select pr; ProductJson.id = Products.FirstOrDefault().ProductId.ToString(); ProductJson.text = Products.FirstOrDefault().ProductName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <PaymentMode> PaymentModes = from pr in _PaymentModeRepository.Instance where pr.PaymentModeId == Id select pr; ProductJson.id = PaymentModes.FirstOrDefault().PaymentModeId.ToString(); ProductJson.text = PaymentModes.FirstOrDefault().PaymentModeName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <CostCenter> CostCenters = from pr in _CostCenterRepository.Instance where pr.CostCenterId == Id select pr; ProductJson.id = CostCenters.FirstOrDefault().CostCenterId.ToString(); ProductJson.text = CostCenters.FirstOrDefault().CostCenterName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <PersonRateGroup> PersonRateGroups = from pr in _PersonRateGroupRepository.Instance where pr.PersonRateGroupId == Id select pr; ProductJson.id = PersonRateGroups.FirstOrDefault().PersonRateGroupId.ToString(); ProductJson.text = PersonRateGroups.FirstOrDefault().PersonRateGroupName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Gate> Gates = from pr in _GateRepository.Instance where pr.GateId == Id select pr; ProductJson.id = Gates.FirstOrDefault().GateId.ToString(); ProductJson.text = Gates.FirstOrDefault().GateName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Area> Areas = from pr in _AreaRepository.Instance where pr.AreaId == Id select pr; ProductJson.id = Areas.FirstOrDefault().AreaId.ToString(); ProductJson.text = Areas.FirstOrDefault().AreaName; return(ProductJson); }
public ComboBoxResult GetValue(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <DocumentCategory> DocumentCategorys = from pr in _documentCategoryRepository.Instance where pr.DocumentCategoryId == Id select pr; ProductJson.id = DocumentCategorys.FirstOrDefault().DocumentCategoryId.ToString(); ProductJson.text = DocumentCategorys.FirstOrDefault().DocumentCategoryName; return(ProductJson); }
public ComboBoxResult GetEmployee(int Id) { ComboBoxResult ProductJson = new ComboBoxResult(); IEnumerable <Person> Employees = from p in _EmployeeRepository.Instance join t in _unitOfWork.Repository <Person>().Instance on p.PersonID equals t.PersonID where t.PersonID == Id select t; ProductJson.id = Employees.FirstOrDefault().PersonID.ToString(); ProductJson.text = Employees.FirstOrDefault().Name; return(ProductJson); }
public JsonResult SetSingleSaleInvoiceLine(int Ids) { ComboBoxResult SaleInvoiceJson = new ComboBoxResult(); var SaleInvoiceLine = from L in db.SaleInvoiceLine join H in db.SaleInvoiceHeader on L.SaleInvoiceHeaderId equals H.SaleInvoiceHeaderId into SaleInvoiceHeaderTable from SaleInvoiceHeaderTab in SaleInvoiceHeaderTable.DefaultIfEmpty() where L.SaleInvoiceLineId == Ids select new { SaleInvoiceLineId = L.SaleInvoiceLineId, SaleInvoiceNo = L.Product.ProductName }; SaleInvoiceJson.id = SaleInvoiceLine.FirstOrDefault().ToString(); SaleInvoiceJson.text = SaleInvoiceLine.FirstOrDefault().SaleInvoiceNo; return(Json(SaleInvoiceJson)); }