Foren
WebContent: Configure auto-expiration by default
Dennis Greiffenberg, geändert vor 14 Jahren.
WebContent: Configure auto-expiration by default
Regular Member Beiträge: 222 Beitrittsdatum: 30.04.07 Neueste Beiträge
Hi all,
Liferay's default behaviour is as follows: WebContent is infinitely valid (once approved). This can be changed on individual basis (i.e. per WebContent). Once the appropriate selectbox is deactivated, a date-field becomes active. The default expiration time for an article is one year in advance.
My question is as follows: Can the default behaviour configured the otherway round. So WebContent, by default, does expire? And if so: Can the period be tweaked as well, say I don't want content to be valid for a years time but only for four weeks?
...or is that something that I would have to change by means of programming?
And if so: Where?
Any hint / help is greatly appreciated!
Best regards,
Dennis
Liferay's default behaviour is as follows: WebContent is infinitely valid (once approved). This can be changed on individual basis (i.e. per WebContent). Once the appropriate selectbox is deactivated, a date-field becomes active. The default expiration time for an article is one year in advance.
My question is as follows: Can the default behaviour configured the otherway round. So WebContent, by default, does expire? And if so: Can the period be tweaked as well, say I don't want content to be valid for a years time but only for four weeks?
...or is that something that I would have to change by means of programming?
And if so: Where?
Any hint / help is greatly appreciated!
Best regards,
Dennis
Zankar Shah, geändert vor 14 Jahren.
RE: WebContent: Configure auto-expiration by default
Regular Member Beiträge: 106 Beitrittsdatum: 03.10.07 Neueste Beiträge
You will have to definitely change the JSP to get your requirement. If you have downloaded liferay source, you can go to portal-web/docroot/html/portlet/journal. The source JSPs are there. If you want to change that you can use hooks for that purpose
Fernando Garcia, geändert vor 11 Jahren.
RE: WebContent: Configure auto-expiration by default
New Member Beiträge: 13 Beitrittsdatum: 12.04.11 Neueste Beiträge
Hi Dennis
I'm facing the same problem and I was wondering if you solved the problem and how you did it ?
Thanks
I'm facing the same problem and I was wondering if you solved the problem and how you did it ?
Thanks
Dennis Greiffenberg, geändert vor 11 Jahren.
RE: WebContent: Configure auto-expiration by default
Regular Member Beiträge: 222 Beitrittsdatum: 30.04.07 Neueste Beiträge
Hi Fernando,
I think I never really finished this one off (the post is quite some time ago.. ;-) ), but I guess Zankar's suggestion is the right way to follow...
Best regards,
Dennis
I think I never really finished this one off (the post is quite some time ago.. ;-) ), but I guess Zankar's suggestion is the right way to follow...
Best regards,
Dennis
Josh Dezike, geändert vor 11 Jahren.
RE: WebContent: Configure auto-expiration by default
New Member Beitrag: 1 Beitrittsdatum: 09.08.12 Neueste Beiträge
Fernando Garcia, geändert vor 11 Jahren.
RE: WebContent: Configure auto-expiration by default
New Member Beiträge: 13 Beitrittsdatum: 12.04.11 Neueste Beiträge
Hi Dennis.
To change the expiration and review date you need to modify ext-model-hints like this:
To change the expiration and review date you need to modify ext-model-hints like this:
<model-hints>
<model name="com.liferay.portlet.journal.model.JournalArticle">
<field name="expirationDate" type="Date">
<hint name="default-month-delta">3</hint>
</field>
</model>
</model-hints>
Dennis Greiffenberg, geändert vor 11 Jahren.
RE: WebContent: Configure auto-expiration by default
Regular Member Beiträge: 222 Beitrittsdatum: 30.04.07 Neueste Beiträge
Cool!
Thanks for that information!
Best regards,
Dennis
Thanks for that information!
Best regards,
Dennis
Matthias Travis, geändert vor 11 Jahren.