Querying ContentItem after a Post

Topics: Core, Customizing Orchard
Aug 20, 2013 at 3:02 PM
I have hit a roadblock, and now I'm looking for the community to help out.
Just some background info, I'm not leveraging any of Orchard's Repository (Not using ContentPartRecord), since I piggy back off my own WCF webservices for all my Business Objects.

Whenever I query a content item within my controller after a post action (ie: I hit the submit button), I am getting null.

So, here's my sequence:
1) Instantiate a Part via _contentManager.New<MyPart>("MyPartType") //OK - no issue
2) Bind necessary Part to my WCF in MyPartHandler //OK - no issue
3) Pages gets display with the binded data //OK - no issue
4) Do a submit, my [HttpPost] controller gets called //OK - no issue
5) Within the post controller, try to Query the part via IEnumerable<MyPart> contentItems = contentManger.Query().ForType("MyPartType").List(); //Issues HERE

Question:
1) Since i'm creating an instance of an item with a type ("MyPartType"), don't orchard persist it in session somewhere ?
2) Am I doing it wrong in my query?
Aug 21, 2013 at 5:17 PM
Any takers?
Coordinator
Aug 22, 2013 at 2:15 AM
1) No.
Aug 22, 2013 at 3:44 AM
So, when we do a query sequence 5, is it hitting the dB?
Coordinator
Aug 22, 2013 at 4:02 AM
It is hitting the database, but there is nothing there.