Exemple #1
0
        public void DeleteData(ModelNotifiedForEmployeeTerritories modelNotifiedForEmployeeTerritories, out string error)
        {
            EmployeeTerritoriesGenericREST EmployeeTerritoriesGenericREST = new EmployeeTerritoriesGenericREST(wpfConfig);
            DeleteEmployeeTerritoriesView  deleteEmployeeTerritoriesView  = new DeleteEmployeeTerritoriesView();

            Cloner.CopyAllTo(typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories, typeof(DeleteEmployeeTerritoriesView), deleteEmployeeTerritoriesView);
            EmployeeTerritoriesGenericREST.Delete(deleteEmployeeTerritoriesView, out error);
        }
Exemple #2
0
        public void AddData(ModelNotifiedForEmployeeTerritories modelNotifiedForEmployeeTerritories, out string error)
        {
            EmployeeTerritoriesGenericREST EmployeeTerritoriesGenericREST = new EmployeeTerritoriesGenericREST(wpfConfig);
            CreateEmployeeTerritoriesView  createEmployeeTerritoriesView  = new CreateEmployeeTerritoriesView();

            Cloner.CopyAllTo(typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories, typeof(CreateEmployeeTerritoriesView), createEmployeeTerritoriesView);
            EmployeeTerritoriesGenericREST.Insert(createEmployeeTerritoriesView, out error);
        }
Exemple #3
0
        public void SaveData(ModelNotifiedForEmployeeTerritories modelNotifiedForEmployeeTerritories, out string error)
        {
            EmployeeTerritoriesGenericREST EmployeeTerritoriesGenericREST = new EmployeeTerritoriesGenericREST(wpfConfig);
            UpdateEmployeeTerritoriesView  updateEmployeeTerritoriesView  = new UpdateEmployeeTerritoriesView();

            Cloner.CopyAllTo(typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories, typeof(UpdateEmployeeTerritoriesView), updateEmployeeTerritoriesView);
            EmployeeTerritoriesGenericREST.Update(updateEmployeeTerritoriesView, out error);
        }
Exemple #4
0
        public void DeleteData(ModelNotifiedForEmployeeTerritories modelNotifiedForEmployeeTerritories, out string error)
        {
            EmployeeTerritoriesBsn  bsn    = new EmployeeTerritoriesBsn(wpfConfig);
            EmployeeTerritoriesInfo dbItem = new EmployeeTerritoriesInfo();

            Cloner.CopyAllTo(typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories, typeof(EmployeeTerritoriesInfo), dbItem);
            bsn.DeleteByID(dbItem, out error);
        }
Exemple #5
0
        public ModelNotifiedForEmployeeTerritories GetEmployeeTerritoriesByID(int EmployeeID, string TerritoryID, out string error)
        {
            error = null;
            EmployeeTerritoriesGenericREST      EmployeeTerritoriesGenericREST      = new EmployeeTerritoriesGenericREST(wpfConfig);
            GetEmployeeTerritoriesView          getEmployeeTerritoriesView          = EmployeeTerritoriesGenericREST.GetByPK <GetEmployeeTerritoriesView>(EmployeeID, TerritoryID, out error)[0];
            ModelNotifiedForEmployeeTerritories modelNotifiedForEmployeeTerritories = new ModelNotifiedForEmployeeTerritories();

            Cloner.CopyAllTo(typeof(GetEmployeeTerritoriesView), getEmployeeTerritoriesView, typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories);
            return(modelNotifiedForEmployeeTerritories);
        }
Exemple #6
0
        public ModelNotifiedForEmployeeTerritories GetEmployeeTerritoriesByID(int EmployeeID, string TerritoryID, out string error)
        {
            error = null;
            EmployeeTerritoriesBsn              bsn    = new EmployeeTerritoriesBsn(wpfConfig);
            EmployeeTerritoriesInfo             dbItem = bsn.GetValueByID(EmployeeID, TerritoryID);
            ModelNotifiedForEmployeeTerritories item   = new ModelNotifiedForEmployeeTerritories();

            Cloner.CopyAllTo(typeof(EmployeeTerritoriesInfo), dbItem, typeof(ModelNotifiedForEmployeeTerritories), item);
            return(item);
        }
Exemple #7
0
        public void AddData(ModelNotifiedForEmployeeTerritories modelNotifiedForEmployeeTerritories, out string error)
        {
            EmployeeTerritoriesBsn  bsn    = new EmployeeTerritoriesBsn(wpfConfig);
            EmployeeTerritoriesInfo dbItem = new EmployeeTerritoriesInfo();

            Cloner.CopyAllTo(typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories, typeof(EmployeeTerritoriesInfo), dbItem);
            bsn.InsertOne(dbItem, out error);
            modelNotifiedForEmployeeTerritories.NewItem = false;
            Cloner.CopyAllTo(typeof(EmployeeTerritoriesInfo), dbItem, typeof(ModelNotifiedForEmployeeTerritories), modelNotifiedForEmployeeTerritories);
        }