[kupu-dev] Kupu and anonymous content submission

Vitalie Cherpec vitalie at gmail.com
Sat Dec 2 11:07:38 CET 2006


I've solved the problem. I've modified 2 files:

kupu/plone/kupu_plone_layer/wysiwyg_support.pt
kupu/plone/plonelibrarytool.py

The patch is attached maybe someone will need it.

There is a function call( lower() ) on None object returned by getProperty() in
plonelibrarytool.py, my solution:

         user = pm.getAuthenticatedMember()
-        if user.getProperty('wysiwyg_editor').lower() != 'kupu':
+       if not pm.isAnonymousUser() and
user.getProperty('wysiwyg_editor', '').lower() != 'kupu':
             return False


                                   Vitalie



On 11/30/06, Duncan Booth <duncan.booth at suttoncourtenay.org.uk> wrote:
> "Vitalie Cherpec" <vitalie at gmail.com> wrote:
>
> >   I've customized that script, but when I do submit content as
> > anonymous, that script isn't called (I've inserted a trace line at the
> > begin).
>
> There are some other calls to isKupuEnabled, but I didn't think they would
> be affected.
>
> >
> >   I've observed that I can't access  the following kupu files as
> >   anonymous
> > user (it requires login):
> >
> >
> > /kupulibraries.xml
> > /kupumyitems.xml
> > /kupurecentitems.xml
> > and
> > kupucollection.xml
> >
> You need to give anonymous the "Kupu: Query libraries" permission.
>
>
> _______________________________________________
> kupu-dev mailing list
> kupu-dev at codespeak.net
> http://codespeak.net/mailman/listinfo/kupu-dev
>


-- 

                    Vitalie Cherpec
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kupu_anonymous_submit.patch
Type: text/x-patch
Size: 2919 bytes
Desc: not available
Url : http://codespeak.net/pipermail/kupu-dev/attachments/20061202/ec797285/attachment.bin 


More information about the kupu-dev mailing list