S
shapper
Hello,
I have three tables: Post, PostTags and Tags.
I created a Post wrapper named: PostPaper. PostPaper has two
properties: Post and Tags. Tags are the tags associated to the Post.
When I Insert, Update or Delete a post I also need to Insert, Update
or Delete the tags associated to this.
My question is:
Should I place the Update, Delete and Insert LINQ code in my Post
wrapper (PostPaper) in my my PostController?
If I place it on my post wrapper then on my PostController I would
just have, for example: PostPaper.Insert() ...
The other approach would be to have all code in PostController and
PostPaper would have only the properties Post and Tags.
Thanks,
Miguel
I have three tables: Post, PostTags and Tags.
I created a Post wrapper named: PostPaper. PostPaper has two
properties: Post and Tags. Tags are the tags associated to the Post.
When I Insert, Update or Delete a post I also need to Insert, Update
or Delete the tags associated to this.
My question is:
Should I place the Update, Delete and Insert LINQ code in my Post
wrapper (PostPaper) in my my PostController?
If I place it on my post wrapper then on my PostController I would
just have, for example: PostPaper.Insert() ...
The other approach would be to have all code in PostController and
PostPaper would have only the properties Post and Tags.
Thanks,
Miguel