google-code-export / django-page-cms

Automatically exported from code.google.com/p/django-page-cms
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Enhancement: Add Support for publication start and end date/time #25

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It would be nice if a person could work on a page and then set it to go
live at a certain date/time or end at a certain date/time.  This would be
good for promotions, events, etc.

I have attached a patch to implement this functionality.  It was created by
using an svn diff from the base of the project.

thanks,

Brian Morgan

Original issue reported on code.google.com by homebre...@gmail.com on 17 Nov 2008 at 8:07

Attachments:

GoogleCodeExporter commented 9 years ago
Hello!

I am not sure if everyone need this functionality. Maybe can we include this in 
a
optional way?

Original comment by batiste....@gmail.com on 18 Nov 2008 at 10:51

GoogleCodeExporter commented 9 years ago
How granular would you like it to be?  One setting to control the whole thing, 
or one
setting to allow future dating and another setting to allow end dating?  I'd be 
happy
to code it up either way.

Original comment by homebre...@gmail.com on 18 Nov 2008 at 2:40

GoogleCodeExporter commented 9 years ago
I think that both options could be interesting. But if you don't have the time 
to
code both it doesn't matter, I will include it anyway.

Original comment by batiste....@gmail.com on 18 Nov 2008 at 4:53

GoogleCodeExporter commented 9 years ago
I added two settings:

PAGE_SHOW_START_DATE
PAGE_SHOW_END_DATE

These settings show or hide those fields in the admin and alter the model save 
so
that if PAGE_SHOW_START_DATE is False and the publication_date is in the 
future, it
will just set it to now.  If PAGE_SHOW_END_DATE is False and 
publication_end_date is
not None, it will set it to None on a save.

I have attached an updated patch.

I plan on making some other mods that I would like to submit patches for.  Is 
there a
developer Google Group or somewhere that I could discuss these changes to 
assure they
will make it upstream?  I really don't want to maintain a fork :-)

Original comment by homebre...@gmail.com on 18 Nov 2008 at 9:40

Attachments:

GoogleCodeExporter commented 9 years ago
Thx a lot for your work. I have applied your patch

http://code.google.com/p/django-page-cms/source/detail?r=207

And I also have given you a SVN access to the project.

I will test your features deeper as soon as I can get more time for it.  

Original comment by batiste....@gmail.com on 18 Nov 2008 at 10:18

GoogleCodeExporter commented 9 years ago
And the google group is here:

http://groups.google.com/group/django-page-cms

Original comment by batiste....@gmail.com on 18 Nov 2008 at 10:18