Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional ASP.NET MVC 1.0 ISBN: 978-0-470-38461-9
This is the forum to discuss the Wrox book Professional ASP.NET MVC 1.0 by Rob Conery, Scott Hanselman, Phil Haack, Scott Guthrie; ISBN: 978-0-470-38461-9
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional ASP.NET MVC 1.0 ISBN: 978-0-470-38461-9 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old March 23rd, 2010, 11:33 AM
Friend of Wrox
Points: 2,376, Level: 20
Points: 2,376, Level: 20 Points: 2,376, Level: 20 Points: 2,376, Level: 20
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: , , Australia.
Posts: 596
Thanks: 1
Thanked 3 Times in 3 Posts
Question MVC Related collection help needed

Hi All,
I have been huge fan of p2p wrox for many years and have found and contributed to many solutions over the years, but some time ago.

I am now in need of further assistance and of cource wrox is the first place i would go.
It appears the site is more book focused now and I dont have the MVC book of this thread.
I am also using MVC 2.

I feel my question is quite stupid, but I cant get my head around it.

I have an entity 'Person' wheich inherits derectly from a generic entity called 'Entity'
this shouldn't have any effect but I mention for clarity.

The person object has a detail page that has its own detail plus a collection of ajax links that populate an area reserved for the related entities of a person.
eg. Clicking the Notes tab populate an area with a list of notes for that person.
ie. via
Code:
 
Ajax.ActionLink("Notes", "Notes", new AjaxOptions { UpdateTargetId = "dataContainer", InsertionMode = InsertionMode.Replace })
That shows a list of notes for that person nicely.

ahead of that list I have an 'Add Note' link which is intended to add another note to Person's Note collection.

How do I bind the new note form to add a note and as well assign it to the Person it is being applied to.

I either end up with a person view that does't know about its notes or a notes view that has no person attached.

the schema is

Person
blah

Note
Blah

PersonNote
PersonGuid
NoteGuid

You know the bottom line is I dont even know what to ask???

Can anyone give me some direction as to the best practice to add a Note to a Person onone page.
It has to be done in partial views so I can display the notes below the Person.
If a new note is added, I want it added to a partial view below the Person data display.

Any advise would be greatly appreciated.

Thanks for all the support I have gained from wrox over the years.
Appologetic for my abesnce in the last few years.
I bet peter lanoi and Imar spanjeers are still assisting us noobs.

I'd love a relavant link.

Many Thanks,
Rod

P.S.
using nhibernate.
Code:
<bagname="Notes"table="AT_NAR_PersonNote"lazy="false" >
<keycolumn="PersonGUID"></key>
<many-to-manyclass="AgileThought.ERP.Domain.Common.Note"column="NoteGUID">
</many-to-many>
</bag>
__________________
======================================
"They say, best men are molded out of faults,
And, for the most, become much more the better
For being a little bad."
--Shakespeare
======================================

Last edited by rodmcleay; March 23rd, 2010 at 12:27 PM.
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
MVC tedr BOOK: ASP.NET MVC Website Programming Problem Design Solution ISBN: 9780470410950 4 February 5th, 2010 10:43 AM
TheBeerHouse MVC preview ASP.NET MVC Website Programming Problem Design Solution jminatel BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 5 July 18th, 2009 09:16 AM
Ready for TheBeerHouse MVC? jminatel BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 3 May 29th, 2009 01:31 PM
mvc datta123 Struts 1 October 26th, 2006 11:00 AM
MVC in j2ee and struts suresh_j2ee Servlets 2 December 29th, 2004 04:10 AM



All times are GMT -4. The time now is 09:32 PM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.