예제 #1
0
        public void AddStoreOwnership(string store)
        {
            StoreManagerPolicy storeOwnershipPermission =
                new StoreManagerPolicy(store, StoreManagerPolicy.StoreAction.StoreOwner);

            StorePolicies.Add(storeOwnershipPermission);
            _userDB.SaveUserStorePolicy(_userID, storeOwnershipPermission);
        }
예제 #2
0
        public void LoadPolicies(StatePolicy[] loadedStates, StoreManagerPolicy[] loadedStorePermissions)
        {
            foreach (StatePolicy loadedState in loadedStates)
            {
                StatesPolicies.Add(loadedState);
            }

            foreach (StoreManagerPolicy loadedStorePermission in loadedStorePermissions)
            {
                StorePolicies.Add(loadedStorePermission);
            }
        }