///<Summary> ///Update ///This method updates one CustomerDemographics record in the store ///</Summary> ///<returns> ///void ///</returns> ///<parameters> ///BOCustomerDemographics ///</parameters> public virtual void Update() { Doing(this); IDAOCustomerDemographics daoCustomerDemographics = _iCustomerDemographicsRepository.New(); RegisterDataObject(_iCustomerDemographicsRepository, _iCustomerDemographicsRepository.BaseData(daoCustomerDemographics)); BeginTransaction(_iCustomerDemographicsRepository, "updateBOCustomerDemographics"); try { daoCustomerDemographics.CustomerTypeID = _customerTypeID; daoCustomerDemographics.CustomerDesc = _customerDesc; daoCustomerDemographics.CtrVersion = _ctrVersion; _iCustomerDemographicsRepository.Update(daoCustomerDemographics); CommitTransaction(_iCustomerDemographicsRepository); Done(this); _customerTypeID = daoCustomerDemographics.CustomerTypeID; _customerDesc = daoCustomerDemographics.CustomerDesc; _ctrVersion = daoCustomerDemographics.CtrVersion; _isDirty = false; } catch (Exception ex) { Failed(this, ex); RollbackTransaction(_iCustomerDemographicsRepository, "updateBOCustomerDemographics"); Handle(this, ex); } }
///<Summary> ///Constructor ///This constructor initializes the business object from its respective data object ///</Summary> ///<returns> ///void ///</returns> ///<parameters> ///DAOCustomerDemographics ///</parameters> protected internal BOCustomerDemographics(IDAOCustomerDemographics daoCustomerDemographics) { try { _customerTypeID = daoCustomerDemographics.CustomerTypeID; _customerDesc = daoCustomerDemographics.CustomerDesc; _ctrVersion = daoCustomerDemographics.CtrVersion; } catch { throw; } }
///<Summary> ///Initializer ///Initializer using primary key(s) ///</Summary> ///<returns> ///void ///</returns> ///<parameters> ///string customerTypeID ///</parameters> public void Init(string customerTypeID) { try { IDAOCustomerDemographics daoCustomerDemographics = _iCustomerDemographicsRepository.SelectOne(customerTypeID); _customerTypeID = daoCustomerDemographics.CustomerTypeID; _customerDesc = daoCustomerDemographics.CustomerDesc; _ctrVersion = daoCustomerDemographics.CtrVersion; } catch { throw; } }
///<Summary> ///Delete ///This method deletes one CustomerDemographics record from the store ///</Summary> ///<returns> ///void ///</returns> ///<parameters> /// ///</parameters> public virtual void Delete() { Doing(this); IDAOCustomerDemographics daoCustomerDemographics = _iCustomerDemographicsRepository.New(); RegisterDataObject(_iCustomerDemographicsRepository, _iCustomerDemographicsRepository.BaseData(daoCustomerDemographics)); BeginTransaction(_iCustomerDemographicsRepository, "deleteBOCustomerDemographics"); try { daoCustomerDemographics.CustomerTypeID = _customerTypeID; _iCustomerDemographicsRepository.Delete(daoCustomerDemographics); CommitTransaction(_iCustomerDemographicsRepository); Done(this); } catch (Exception ex) { Failed(this, ex); RollbackTransaction(_iCustomerDemographicsRepository, "deleteBOCustomerDemographics"); Handle(this, ex); } }
public virtual void Delete(IDAOCustomerDemographics daoCustomerDemographics) { daoCustomerDemographics.Delete(); }
public virtual void Update(IDAOCustomerDemographics daoCustomerDemographics) { daoCustomerDemographics.Update(); }
public virtual void Insert(IDAOCustomerDemographics daoCustomerDemographics) { daoCustomerDemographics.Insert(); }
public virtual IzNorthwindRestApiConn_BaseData BaseData(IDAOCustomerDemographics daoCustomerDemographics) { return((IzNorthwindRestApiConn_BaseData)(DAOCustomerDemographics)daoCustomerDemographics); }