Pick up information for the current session out of view

2015-08-28 Thread Aurélio Moreira
I'm friends with the problem, I'm recording some data in the session, and I need to catch them out of view, I tried to create a session using the following code: s = SessionStore() s["dado1"] = dado1 s["dado2"] = dado2 But friends as I do to get this information in another file? If you assign

Moderator and publishing workflow implementation in Django

2015-08-28 Thread Mayank Sharma
For the new web application I decided to learn Django and dig deeper into this framework. I am working on a web application which has "News Apps" which accepts Title(CharField), Description(TextField) and Date (DateField). Once the draft is created by the news editor, it requires moderator (in-

Re: Moderator and publishing workflow implementation in Django

2015-08-28 Thread Shawn Milochik
One easy solution: Add an "approved_by" field, which is a ForeignKey to User. Let it be null by default. When it's approved, save the User who approved it. Then, whenever you're doing an ORM query to grab all stories to display, just filter on approved_by being not_null. Alternatively, you can ad

Re: Pick up information for the current session out of view

2015-08-28 Thread Dheerendra Rathor
what do you mean by another file? Please be specific. On Fri, 28 Aug 2015 at 18:28 Aurélio Moreira wrote: > I'm friends with the problem, I'm recording some data in the session, and > I need to catch them out of view, I tried to create a session using the > following code: > > > s = SessionStore

Re: Moderator and publishing workflow implementation in Django

2015-08-28 Thread Dheerendra Rathor
Django has auth apps (Admin) and it also has user groups, permissions. What you asking is quite simple, you can add your editor and moderator on admin site, can write custom actions to do on news articles. On Fri, 28 Aug 2015 at 20:53 Shawn Milochik wrote: > One easy solution: > > Add an "approv

A view drop down having values filtered from models

2015-08-28 Thread Thiliban V
Hie, I'm trying to do this. A view with Three drop down lists like - - The values in the list should be from model values. Or a separate things. I just want to capture the results and store the results in a db. so far I've messed up with this example http://www.w3.org/TR/xhtml1/DTD/xhtml1-st

Problem in using CSS and JavaScript in my django Project

2015-08-28 Thread Sumit Chansouliya
Hi All I am learning Django . I am facing problem to load CSS and JavaScript file in my Project.I Have done all setting of static files and they are loading but browser is not taking CSSand JS files showing error "Resource interpreted as Stylesheet but transferred with MIME type aplication/x-

Best Practices for transferring email form data to web server

2015-08-28 Thread pythonista
I have created a form that works fine for GETS and POSTS through the browser. I have embedded the form with a GET (action) in the email, and the data gets transferred to the server as expected. The email POST looks like it needs a csrf token. Is there anyway to generate this and embed it on t