Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Admin page #324

Merged
merged 23 commits into from
Dec 11, 2019
Merged

Admin page #324

merged 23 commits into from
Dec 11, 2019

Conversation

efleming18
Copy link
Collaborator

No description provided.

@efleming18
Copy link
Collaborator Author

efleming18 commented Nov 27, 2019

Addition to the menu dropdown
image

What the "main" Admin screen looks like. Essentially the catalog page but with "Edit" buttons for each.
image

Edit Screen. You're able to edit Name and Price.
image

Showing that updates made on that screen are persisted:
image

The above involved invalidating the cache as soon as the item is updated.
The also involved setting up an additional user with "Admin" rights.

var itemsPerPage = Constants.ITEMS_PER_PAGE;
var brandFilterApplied = catalogModel.BrandFilterApplied;
var typesFilterApplied = catalogModel.TypesFilterApplied;
var cacheKey = string.Format(_itemsKeyTemplate, pageIndex, itemsPerPage, brandFilterApplied, typesFilterApplied);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there somewhere we can share this so the key used when reading matches the same code as the key used here when updating?

Copy link
Collaborator

@ardalis ardalis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comments.

@ardalis ardalis merged commit f3f74a3 into master Dec 11, 2019
alscoundrel pushed a commit to alscoundrel/eShopOnWeb that referenced this pull request Feb 20, 2020
* Updates based on documentation

* Getting the build passing

* Getting app functioning

* A few cleanups to confirm it's working as expected

* Fixing functional tests

* Updating dockerfile for 3.0

* Functional Tests now run sequentially

* Updating to latest version of moq

* Adding migration for post 3.0 upgrades

* Removing commented out lines

* Moving address and catalogitemordered configuration in to classes that own them

* Adding admin user

* Adding admin catalog screen

- will also only display menu option if user is logged in as an admin

* WIP - squash this

* Allow user to edit a catalog item

* Adding entry for new service

* Invalidating cache after catalog item update

- also a little bit of cleanup

* Fixing bad merge

* Removing Picture Uri and making Id readonly

* Adjusting style in menu dropdown so all options are shown

* Creating Cache helpers with unit tests
alscoundrel pushed a commit to alscoundrel/eShopOnWeb that referenced this pull request Feb 20, 2020
* Updates based on documentation

* Getting the build passing

* Getting app functioning

* A few cleanups to confirm it's working as expected

* Fixing functional tests

* Updating dockerfile for 3.0

* Functional Tests now run sequentially

* Updating to latest version of moq

* Adding migration for post 3.0 upgrades

* Removing commented out lines

* Moving address and catalogitemordered configuration in to classes that own them

* Adding admin user

* Adding admin catalog screen

- will also only display menu option if user is logged in as an admin

* WIP - squash this

* Allow user to edit a catalog item

* Adding entry for new service

* Invalidating cache after catalog item update

- also a little bit of cleanup

* Fixing bad merge

* Removing Picture Uri and making Id readonly

* Adjusting style in menu dropdown so all options are shown

* Creating Cache helpers with unit tests
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants