Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/django/23.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/google-sheets/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Django FeinCMS:type object';报告格式';没有属性'_feincms(内容)类型';_Django_Django Cms_Feincms - Fatal编程技术网

Django FeinCMS:type object';报告格式';没有属性'_feincms(内容)类型';

Django FeinCMS:type object';报告格式';没有属性'_feincms(内容)类型';,django,django-cms,feincms,Django,Django Cms,Feincms,FeinCms在我的旧django-1.8上运行良好,但当我将它升级到django-2.0时,我遇到了这个错误。我只是被困在这里 型号: class MyForm(create_base_model()): name = models.CharField(max_length=255, default='New Report', unique=True) title = models.CharField(max_length=255) # Attach content type

FeinCms在我的旧django-1.8上运行良好,但当我将它升级到django-2.0时,我遇到了这个错误。我只是被困在这里

型号:

class MyForm(create_base_model()):
    name = models.CharField(max_length=255, default='New Report', unique=True)
    title = models.CharField(max_length=255)

# Attach content types to Report
report = ReportForm()
report.register_regions(
('main', 'Main content'),
)

map(report.create_content_type, CONTENT_TYPES) # CONTENT_TYPES are my custom content types
from feincms.admin.item_editor import ItemEditor
admin.site.register(MyForm, ItemEditor)
管理员:

class MyForm(create_base_model()):
    name = models.CharField(max_length=255, default='New Report', unique=True)
    title = models.CharField(max_length=255)

# Attach content types to Report
report = ReportForm()
report.register_regions(
('main', 'Main content'),
)

map(report.create_content_type, CONTENT_TYPES) # CONTENT_TYPES are my custom content types
from feincms.admin.item_editor import ItemEditor
admin.site.register(MyForm, ItemEditor)