google-code-export / django-grappelli

Automatically exported from code.google.com/p/django-grappelli
0 stars 0 forks source link

tiny_mce HTMLField won't save data #143

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create a model with a tinymce.models.HTMLField
2. Load the admin page for that model.
3. Use tinymce to make some content.
4. Save.

What is the expected output? What do you see instead?
I expect the markup to be saved into the HTMLField. Instead, it is
discarded. If I enter content through the shell, it will display in the
tinymce window. However, nothing ever gets saved back into the database.

What version of the product are you using? On what operating system?
r692. Firefox.

Original issue reported on code.google.com by alexander.j.robbins@gmail.com on 15 Dec 2009 at 10:46

GoogleCodeExporter commented 9 years ago
Some other version information
Django 1.1.1
django-tinymce 1.5

Original comment by alexander.j.robbins@gmail.com on 15 Dec 2009 at 10:50

GoogleCodeExporter commented 9 years ago
not sure how this is related to grappelli. we didn´t change the way data is 
going to
be stored to the database.
btw: you´re talking about a textfield, right? if not, what is 
"tinymce.models.HTMLField"?

Original comment by sehmaschine on 15 Dec 2009 at 10:57

GoogleCodeExporter commented 9 years ago
django-tinymce provides a model field that automatically uses the tinymce 
widget 
whenever it is displayed using a model admin. That field works unless I apply 
the 
grappelli javascript config to the text field. Once I apply the 
tinymce_setup.js the 
field's look changes (much better). However, the field also stops saving its 
data.

Perhaps I should just specify my field as a text field and include the tinymce 
code in 
the media attribute of the modelform instead?

HTMLField doc:
http://django-tinymce.googlecode.com/svn/tags/release-
1.5/docs/.build/html/usage.html#the-htmlfield-model-field-type

Original comment by alexander.j.robbins@gmail.com on 16 Dec 2009 at 1:35

GoogleCodeExporter commented 9 years ago
as far as I know, joost doesn´t develop django-tinymce anymore. so I´m not 
sure it´s
a good idea to us it right now.
however, this has to be a tinymce-issue. I personally never used 
django-tinymce, so
I´m not sure what´s happening here. 

Original comment by sehmaschine on 16 Dec 2009 at 1:43

GoogleCodeExporter commented 9 years ago
Ok, I'll stop using django-tinymce and just include the tinymce javascript 
directly in the 
modeladmin Media. I'll let you know how that goes. Thanks for the quick 
responses!

Original comment by alexander.j.robbins@gmail.com on 16 Dec 2009 at 1:51

GoogleCodeExporter commented 9 years ago
Yeah, that fixed it. It looks like django-tinymce is just too out of date.

Thanks for your help!

Original comment by alexander.j.robbins@gmail.com on 16 Dec 2009 at 2:19

GoogleCodeExporter commented 9 years ago
alright. I´m glad it works ...

Original comment by sehmaschine on 16 Dec 2009 at 2:24