public ServiceToCompany ManageServiceToCompany(ServiceToCompany serviceToCompany) { var objServiceToCompany = new ServiceToCompanyService(); switch (serviceToCompany.Method) { case "Insert": objServiceToCompany.Insert(serviceToCompany); break; case "Delete": objServiceToCompany.Delete(serviceToCompany); break; case "Update": objServiceToCompany.Update(serviceToCompany); break; case "GetAll": serviceToCompany.DataServiceToCompany = objServiceToCompany.GetAll(); break; case "GetAllDataSet": serviceToCompany.ServiceToCompanyDataSet = objServiceToCompany.GetAllServiceToCompanyDataSet(); break; case "CheckToAdd": serviceToCompany.isBool = objServiceToCompany.CheckToAdd(serviceToCompany); break; } return(serviceToCompany); }
public bool CheckToAdd(ServiceToCompany serviceToCompany) { return(ServiceToCompaniesServices.Instance.CheckToAddServiceToCompanies(serviceToCompany.idService, serviceToCompany.idCompany)); }
public void Delete(ServiceToCompany serviceToCompany) { ServiceToCompaniesServices.Instance.DeleteServiceToCompanies(serviceToCompany.idService, serviceToCompany.idCompany); }
public void Update(ServiceToCompany serviceToCompany) { ServiceToCompaniesServices.Instance.UpdateServiceToCompanies(serviceToCompany.Startdate, serviceToCompany.Enddate, serviceToCompany.Paid, serviceToCompany.Price, serviceToCompany.priceCost, serviceToCompany.idCompany, serviceToCompany.idService); }