views:

72

answers:

1

Hi, I am having a little difficulty trying to wrap my head around site structures. I have quite a large asp.net site, for which:

Admins can see a user list, Each user can have many accounts, and for each account can have many items.

I can picture this as a breadcrumb trail of editing a particular item.

User List > Mr Bob > Accounts > BOB77 > Items > Item32 > Edit
  • User List = All the users
  • Mr Bob = A user the administrator has selected from the User List
  • Accounts = A list of the user's accounts
  • 12BOB = The administrator has selected the account named 12BOB
  • Items = A list of the items an account contains
  • Item32 = The item that the administrator selected
  • Edit = The action that the administrator wants to do

I can picture how this would look like if it was using ASP.NET MVC with the URL, but I am unsure how to map this out using Webforms, and in the physical filesystem.

This is what I have thought up about how I am guessing the physical structure would look like. Will this have to use session variables to achieve what I am trying to do?

  • /Users/User/Edit.aspx <- for editing a user
  • /Users/User/View.aspx <- for viewing a user
  • /Users/User/Accounts/Default.aspx <- for viewing all accounts
  • /Users/User/Accounts/Account/View.aspx <- for viewing an account
  • /Users/User/Accounts/Account/Edit.aspx <- for editing an account
  • /Users/User/Accounts/Account/Items/Default.aspx <- for viewing all items in an account
  • /Users/User/Accounts/Account/Items/Item/Edit.aspx <- for editing an item

Where can I read more about this kind of setup in a web application? Or, can someone point me in the direction of an available project that has this kind of layout?

Thanks

A: 

This seems simple, but when you want to lay out the logical structure and you're considering every element to the structure, it becomes very unclear.

This is the url format I came up with. This uses query strings instead of Session variables. Query strings are used as parameters.

Using this format I was able to make a sitemap provider which interpreted the values of the querystring and replaced the names of nodes for that page.

  • User/Edit.aspx?UserID=11111
  • User/Account/Default.aspx?UserID=11111
  • User/Account/Edit.aspx?UserID=111&AccountID=54353
  • User/Account/Item/Edit.aspx?UserID=3333&AccountID=43243&ItemID=432432

I hope this helps you, if you are in a similar situation to what I was.

Mike