What about to add a page copied signal?!

50 views
Skip to first unread message

Philippe O. Wagner

unread,
Jul 27, 2016, 8:30:37 AM7/27/16
to django CMS developers
Hi all

We are missing a signal that will be fired after a page was copied using page.copy_page
Would this be helpful for anybody else?


czpython

unread,
Jul 27, 2016, 10:45:49 AM7/27/16
to django CMS developers
Hello Philippe,

I've not had a case where a signal for this is needed.

I'm not against adding it there's an interest by the community but it would require some refactoring on the cms core,
this is because the cms uses copy_page in some internal actions like publishing a page and so it wouldn't be good to trigger
the signal then.

Daniele Procida

unread,
Jul 28, 2016, 10:59:35 AM7/28/16
to django CMS developers
What is the exact use-case? Is it:

* a user-triggered copy action via the web interface
* a copy invoked via the CMS's APIs, by an external application
* a copy action triggered by publishing a page
* something else?

I can imagine that you might want it in one of the first two cases, but not the third, for example, but I don't think the mechanism actually distinguishes between the different ways it might be called.

Daniele

Philippe O. Wagner

unread,
Jul 29, 2016, 4:09:10 AM7/29/16
to django CMS developers
We extended the CMS with a tagging functionality.

For example a client has tagged project pages (planning, funded, completed, type a, type b, type c). 
This allows us to group pages (all type a projects, all funded or all planned) and link to pages that are in different page trees. 

However, to create a new project page an old one is copied and adapted by the client (= user-triggered copy action via the web interface ). With the current setup all tags are then lost. 

Philippe O. Wagner

unread,
Aug 23, 2016, 5:26:03 PM8/23/16
to django CMS developers
Could we work together to get this into the LTS? This would help us in mid- and long-term. 

czpython

unread,
Aug 23, 2016, 5:56:56 PM8/23/16
to django CMS developers
Hello Philippe,

We are in the process of steering the djangoCMS core away from signals.
Although I did mention we might consider implementing your suggestion, it's now clear to us that signals are causing too many problems.

Regarding your specific issue, I think a better way to solve it is using PageExtensions to add the tags to a page.
The cms will take care of the logic behind copying your extensions over to new pages as needed.

Let me know how it goes,
Paulo

John-Scott

unread,
Aug 23, 2016, 6:17:07 PM8/23/16
to django CMS developers
FYI, the PageExtensions link was broken (missing the 'l' in the 'html' file extension), here's the correct url => http://docs.django-cms.org/en/release-3.3.x/how_to/extending_page_title.html

Iacopo Spalletti

unread,
Aug 24, 2016, 1:10:05 AM8/24/16
to django-cms...@googlegroups.com
If you're interested in tagging cms page, you may want to have a look at
this https://github.com/nephila/djangocms-page-tags page extension for
reference.
It may not suit your needs, but you can get some inspiration out of it


On 23/08/2016 23:56, czpython wrote:
> Hello Philippe,
>
> We are in the process of steering the djangoCMS core away from signals.
> Although I did mention we might consider implementing your suggestion,
> it's now clear to us that signals are causing too many problems.
>
> Regarding your specific issue, I think a better way to solve it is using
> PageExtensions
> <http://docs.django-cms.org/en/release-3.3.x/how_to/extending_page_title.htm>
> --
> Message URL: *MailScanner has detected definite fraud in the website at
> "groups.google.com". Do /not/ trust this website:*
> https://groups.google.com/d/msg/django-cms-developers/topic-id/message-id <https://groups.google.com/d/msg/django-cms-developers/topic-id/message-id>
> Unsubscribe: send a message to
> django-cms-devel...@googlegroups.com
> ---
> You received this message because you are subscribed to the Google
> Groups "django CMS developers" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to django-cms-devel...@googlegroups.com
> <mailto:django-cms-devel...@googlegroups.com>.
> To view this discussion on the web, visit *MailScanner has detected
> definite fraud in the website at "groups.google.com". Do /not/ trust
> this website:*
> https://groups.google.com/d/msgid/django-cms-developers/5aeccfcd-8ba3-4148-95e3-82800de7bd0d%40googlegroups.com
> <https://groups.google.com/d/msgid/django-cms-developers/5aeccfcd-8ba3-4148-95e3-82800de7bd0d%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit *MailScanner has detected definite fraud in the
> website at "groups.google.com". Do /not/ trust this website:*
> https://groups.google.com/d/optout <https://groups.google.com/d/optout>.


--
Iacopo Spalletti

Nephila s.a.s. - Firenze
Telefono: +39 055 5357189
Assistenza Tecnica: +39 055 3985730
http://nephi.la

signature.asc
Reply all
Reply to author
Forward
0 new messages