---
# System prepended metadata

title: New Masterclass Material V9
tags: [Ucommerce]

---

#  New Masterclass Material V9
###### tags: `Ucommerce`
###### 13/05/2020
## Video 1
- Create template for class, so the customers end up with nice project
- Need to create doctype without a template.
- Prefix doctype with "MasterClass"
- Add it in content
- Talk about the best of breed approach. You can use Umbraco however you like. Ucommerce does not tie any structure in Umbraco so you're free to apply your own best practices.
- So when making your site you're partially using the Umbraco system to set up the pages, and Ucommerce to pull the data you need.
- Make controller - needs to inherrit and renderMVCcontroller
- Make method called index
- return type needs to be actionresult
- in views folder make new folder called MasterClass home. This is because of the MVC convention. Where we the controller to the correspondant folder under view, and by extension the view file there.
- make cshtml file
- Now you have a website :smile: 

Notes on installing:
- Make sure packages are compatible
- Install the right kind of Database
- Rebuild after installing packages
- Ship some of the setup in the repo

## Video 2
- under controllers make new surface controller called CategoryNavigationController
- Make new partial view for it.
- make category navigation viewmodel. that sets name of category
- add url to for-each in the CategoryNavigationController by following Category-Navigation documentation article
- first resolve urlService by using ObjectFactory.Instance.Resolve
- second resolve ctalogContext in the same way
- use these to get the Url _urlService.GetUrl(catalogContext)
- create url string on CategoryViewModel
- change span to link in Index.cshtml with new url added
- (remember to build)
- Next step is to create a category page
- Create new MasterClassCategoryController
- Create new document type MasterClassCategory
- Add child node type MasterClassHome
- Make a new Content Page for the new Category Document Type
- New View in MasterCkassCategory Folder
- 
- Change DefaultCategoryRewrite rule from catalog.aspx to category.aspx
- Inherit RenderMVCController from MasterClassCategoryController
- Now we need to build up the category page
- In the MasterClassCategoryController add image, displayname, and description, like in the Category-Page documentation page
- Add @model.Name in the MasterClassCategory View .cshtml file from CategoryViewModel
- Modify MasterClassCategoryController to return View(new CategoryViewModel)
- put name on the new CategoryViewModel