Example #1
0
        public Companies InsertUpdateCompany(Companies _companyObj)
        {
            Companies result = null;

            try
            {
                if ((_companyObj.Code) == "" || _companyObj.Code == null)
                {
                    result = _companiesRepository.InsertCompany(_companyObj);
                }
                else
                {
                    result = _companiesRepository.UpdateCompany(_companyObj);
                }
            }
            catch (Exception ex)
            {
                throw ex;
            }
            return(result);
        }