Schedule Publish/Unpublish

Posted by Community Admin on 04-Aug-2018 16:14

Schedule Publish/Unpublish

All Replies

Posted by Community Admin on 14-Feb-2011 00:00

Hi,
In news module Schedule Publish/Unpublish with past seems has no effect, news listed by publication_date.
Thanks

Posted by Community Admin on 18-Feb-2011 00:00

Hello mkavici,

By design you cannot publish an item with a date in the past or earlier than the date created. The behaviour you describe is expected.  I will create request to be able to publish items with a date in the past and will forward it to our UX team for review.



Best wishes,
Sonya
the Telerik team

Posted by Community Admin on 03-Mar-2011 00:00

Ok,
Any advise to import to sitefinity with past news from old web site?
Thanks

Posted by Community Admin on 04-Mar-2011 00:00

Hi mkavici,

You can change the  PublicationDate programmtically after you publish the news item

var newsAll = App.WorkWith()
                 .NewsItems()
                 .Where(nI => nI.Status == ContentLifecycleStatus.Live)
                 .ForEach(nI =>
                 
                     var val = DateTime.UtcNow.AddDays(-10);                 
                     nI.PublicationDate = val ;
                 )
                 .SaveChanges();


Kind regards,
Ivan Dimitrov
the Telerik team

Posted by Community Admin on 09-Mar-2011 00:00

A handy feature would be a recurrence option that would ignore the year. For instance, for news announcements where you have a set start and end dates in a given year that you accept funding applications or holiday news items that occur on the same day(s) every year. Thank you.

Posted by Community Admin on 16-Mar-2011 00:00

Hi Darrel,

Your request has been logged and will be reviewed when we discuss improvements to the News module.
Thanks for your suggestion for improvement!

Best wishes,
Kalina
the Telerik team

Posted by Community Admin on 04-May-2011 00:00

The fact that this is "expected" behavior is ridiculous.  Obviously, there are tons of scenarios where you would want a Publication Date to show up in the past.  Importing past press releases, changing a date sort order, etc.  Fix this soon, please.

Posted by Community Admin on 04-May-2011 00:00

I'd like to have this functionality working soon as well. We are moving 20+ websites to sitefinity, all of which will have backdated news. 

Posted by Community Admin on 04-May-2011 00:00

A  more troubling behavior is that it seems to change the Publication date after you update the news post.  Wait, what?  Not cool!  

Posted by Community Admin on 11-May-2011 00:00

Hello Developer,

Thank you for contacting us.
This issue is already added in our issue tracking system. The item ID is 5774

Regards,
Antoaneta
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 12-May-2011 00:00

Does the publish/unpublish work at all in 4.0?  Even if i set it to publish on a future date it still shows up. Is there something i have to set in the control itself?
We are actaully using the Products module and if I set the date for May 23, 2011 it actually says "Scheduled publish on 23/05/11" and it shows up today.

Posted by Community Admin on 12-May-2011 00:00

after further testing, i think that if the item is published first, then you late go back in and set the publish date to the future, it doesn't unpublish it for you.  You have to unpublish it first. Then set the date to the future.....  ideally it shouldn't it "unpublish" the item if the date is reset to the future??

Posted by Community Admin on 13-May-2011 00:00

Hi Laura,

Thank you for contacting  us.
I am not able to reproduce this problem with Sitefinity 4.0, so I assume that it appears only in the Products module. I will log this bug in our system for fixing.

By design, if you open one published item and schedule it to publish in the future, the item will not be unpublished. The assumption is that you are creating a newer version of the content and you want it published in the future.
As we received various feedback on this dialog we decided to improve its behavior. In the future, when changing the date of publication, you will be able to choose whether you want the item to be unpublished or not.

Best wishes,
Antoaneta
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 16-Sep-2011 00:00

I hope this feature does make it onto some new version.

We are rebuilding a current website into sitefinity and I am creating the news items from their current site.  Of course i want the dates to be the same dates as they are from the current web site!  

So this is still not possible to put a publish date in the past? And we are using "Sitefinity 4.2.1650.0 SE"
I believe it would be a very useful feature.  Thank you.

Posted by Community Admin on 18-Sep-2011 00:00

The item ID 5774 had been marked as resolved and people still complain about that.
I really can not understand Sitefinity team. 7 month passed after I have opened this thread and there is no change yet!
Where do the Sitefinity team live? on Mars? Please come back to Earth! This problem has been solved many many years ago in many CMSes! Wordpress, Textpattern Jommla, .netnuke and many many others do this for many many years...
How can you expect people to update news date from db? so you mean that only tech people can use Sitefinity?
You do the same mistake on upgrading from 3.7 to 4.x. Still there is not a successful way to upgrade. You make your existing customers sad and keep adding new buggy features.
Really really can not understand and I'm sure nobody can understand!

Posted by Community Admin on 19-Sep-2011 00:00

This may be sill for me not to know but, where exactly do i run this code?  I think I read somewhere that all you need to do is create a page in VS with the code. Do I then put a button on the page to run it?  Is that how it works?

Posted by Community Admin on 20-Sep-2011 00:00

Hi Laura,

Yes, like you properly pointed out you can place the code in any *.aspx web form in your project and run it, the code will execute automatically.

Kind regards,
Boyan Barnev
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 20-Sep-2011 00:00

Thank you. Does it matter that we are running the site as a Web Project and not a Web Application?

I ask because of App.WorkWith() in the code.

Posted by Community Admin on 20-Sep-2011 00:00

Hi Laura,

No, you should not worry about that. App is the entry point for working with the SItefinity Fluent API, so as long as you have a reference: using Telerik.Sitefinity;  in your class, there should be no problems using the provided code sample.

Best wishes,
Boyan Barnev
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 20-Sep-2011 00:00

Hi Laura,

No, you should not worry about that. App is the entry point for working with the Sitefinity Fluent API, so as long as you have a reference: using Telerik.Sitefinity;  in your class, there should be no problems using the provided code sample.

Best wishes,
Boyan Barnev
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 20-Sep-2011 00:00

Hi all,

Just a quick follow-up. As we're currently working on implementing the feature in Sitefinity for the upcoming releases, we've prepared a short sample, that should make backdating your News (content items) easier. Please check the attached WebForm and short video demonstrating its functionality. Please feel free to modify the sample to suit your use case scenario (e.g. you can simply change  the App.WorkWith()
                            .NewsItems()
to work with any desired content items that have PublicationDate and DateCreated properties, let's say:
App.WorkWith()
                            .BlogPosts()
)



All the best,
Boyan Barnev
the Telerik team
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 02-Feb-2012 00:00

Hi,
Schedule Publish/Unpublish is still buggy!
Please check attached image. If you publish a document (not only document this also happens in other content items) at past, document is not published immediately. 
I don't know how  scheduler works but it it will wait schedule date (which is already past) the it will never be published.
Regards

Posted by Community Admin on 26-May-2014 00:00

In my case it is working for default language(en) but if any news exist in arabic but not in english then this problem produce.

using sitefinity 5.2

Posted by Community Admin on 29-May-2014 00:00

Hi,

You should first set the language in which you will modify the items. You can do that by changing the current culture. This way you will get the items in this language.

CultureInfo backupCulture = System.Threading.Thread.CurrentThread.CurrentUICulture;
CultureInfo cult = new CultureInfo("bg");
System.Threading.Thread.CurrentThread.CurrentUICulture = cult;
//Do work
System.Threading.Thread.CurrentThread.CurrentUICulture = backupCulture; // return to initial culture


Regards,
Nikola Zagorchev
Telerik
 
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
 

Posted by Community Admin on 15-Jul-2014 00:00

Hi, 

Posting news articles in the past is still not possible, right?  Please confirm.

Thanks

Posted by Community Admin on 15-Jul-2014 00:00

Taha,

Depends on your version but when you create a news item, don't hit Publish. Instead click on More Actions then Publish/Unpublish on Specific Date.  
Select that date it should be published on (in the past) and click on Save. 
It should then take you back to the News list grid page.

I noticed that in the latest version (7), after it creates the news item, it says scheduled to publish on 11/3/2013 (past date).   So I published it  (clicking on Actions, Publish) and the published date stayed as 11/3/2013. 

The Date listed in the column in the backend is the create date and not the published date so that would show as today's date. 

Posted by Community Admin on 15-Jul-2014 00:00

Hi Laura,

Thanks for your response. We're running 6.2 and I don't think the publication date remains the one set for scheduled publication. We want the news articles to have a chronological order on the frontend, using the built-in module we're ordering them by Publication Date. 

It seems like the past news articles will never be published.

Thanks for stepping in, Laura.

Posted by Community Admin on 15-Jul-2014 00:00

Looks like we can either publish this using the API, or give the user the ability to publish all past news at their set PublicationDate if that information is stored properly in the database. Or we can create a custom field and sort by this field on the frontend.

  Go to:

List Settings>Sort news

And make that "As set in the advanced mode".

 

Then Go to:

Advanced>ControlDefinition >Views >NewsFrontendList>SortExpression 

And set it to "YourSortingField DESC" for instance.

  

It should sort them properly.

 

Posted by Community Admin on 15-Jul-2014 00:00

Hello,

If you want to publish items in the past as required in a previous thread reply please follow this blog post. You can change the culture as shown in a previous reply in this thread. The items will appear as Draft but after publishing the Publication date will still be the date in the past set when created programmatically.

Regards,
Nikola Zagorchev
Telerik

 
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
 

Posted by Community Admin on 15-Jul-2014 00:00

Hi Nikola,

Ideally we don't want to do this programmatically, but when we set a specific date of publication then go back to the News and publish, the publication date is today's date rather what has been set.

Thanks

Posted by Community Admin on 15-Jul-2014 00:00

Hello,

Could you please specify on what version of Sitefinity you are testing? I tested on Sitefinity 7.0 and I was able to publish on a specific date in the past directly from the back-end.

Regards,
Nikola Zagorchev
Telerik

 
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
 

Posted by Community Admin on 15-Jul-2014 00:00

Hello Nikola,

We're working on 6.2

Thanks

Posted by Community Admin on 16-Jul-2014 00:00

Hello Taha,

I was able to create a News item with a publication date in the past using this code snippet in Sitefinity 6.2 for Spanish language:

CultureInfo backupCulture = System.Threading.Thread.CurrentThread.CurrentUICulture;
CultureInfo cult = new CultureInfo("es");
System.Threading.Thread.CurrentThread.CurrentUICulture = cult;
 
App.WorkWith().AnyContentItem<NewsItem>().CreateNew().Do(
    n =>
    
        n.Title = "Sample item in past";
        n.UrlName = "sample-item-in-past";
    )
    .Publish(new DateTime(1978, 4, 15))
    .SaveChanges();
System.Threading.Thread.CurrentThread.CurrentUICulture = backupCulture;

The item is created as Draft but after publishing its publication date remains the same as set in the code. Here is a reference.
The same could be done by using Publishing on  a specific date and state a data in the past though the back-end.

Regards,
Nikola Zagorchev
Telerik
 
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
 

This thread is closed