Hi

I've got an issue when trying to inject custom field featured_image into 
base type "Page",
After I made changes in settings.py as below, when I execute
py manage.py makemigrations

It doesn't recognize my injection and show message: No changes detected.
And when I tried to run server, initialization went well, but once I hit 
the home page it thrown exception saying

django.db.utils.OperationalError: (1054, "Unknown column 
'pages_page.featured_image' in 'field list'")

Obviously field "featured_image" has been injected dynamically in 
mezzanine.boot, but the database is not sync since I can't generate 
migration.

Anyone who knows what I missed here?
What is the right way to do field injection? I've reviewed 
page http://mezzanine.jupo.org/docs/model-customization.html but can't 
figure out why.

#settings.py
EXTRA_MODEL_FIELDS = (
    (
        "mezzanine.pages.models.Page.featured_image",
        "mezzanine.core.fields.FileField",
        ("Header image",),
        {"blank": True,
         "null": True,
         "upload_to": "page_header",
         "format": "Image",
         "max_length": 255},
    ),
)


Thanks in advance,
Thales


-- 
You received this message because you are subscribed to the Google Groups 
"Mezzanine Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to