File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -140,8 +140,8 @@ class RichText(models.Model):
140140** Full list of variables in template context:**
141141- `block_model` (lowercase of modelname - " richtext" )
142142- `block_unique_id` (unique string)
143- - `block_content` (block data from db
144- - `as_list`
143+ - `block_content` (block data from db)
144+ - `as_list` (boolean)
145145- `options` ([block options](# block-options))
146146
147147** 6 . Add StreamField to your model in your application**
Original file line number Diff line number Diff line change 55
66setuptools .setup (
77 name = "django-streamfield" ,
8- version = "1.2.1 " ,
8+ version = "1.2.2 " ,
99 author = "Yury Lapshinov" ,
1010 author_email = "y.raagin@gmail.com" ,
1111 description = "StreamField for native Django Admin or with Grappelli" ,
Original file line number Diff line number Diff line change 11name = "streamfield"
2- VERSION = '1.2.1 '
2+ VERSION = '1.2.2 '
Original file line number Diff line number Diff line change 11from importlib import import_module
22from django .urls import include , path
33from django .conf import settings
4+ from django .contrib .auth .decorators import login_required
45
56from . import views
67
1718 if not model ._meta .abstract :
1819 block_path = path (
1920 'admin-instance/%s/<int:pk>' % model .__name__ .lower (),
20- views .admin_instance_class (model ).as_view (),
21+ login_required ( views .admin_instance_class (model ).as_view () ),
2122 name = 'admin-instance'
2223 )
2324 else :
2425 block_path = path (
2526 'abstract-block/%s/' % model .__name__ .lower (),
26- views .abstract_block_class (model ).as_view (),
27+ login_required ( views .abstract_block_class (model ).as_view () ),
2728 name = 'abstract-block'
2829 )
2930
Original file line number Diff line number Diff line change 11Django == 2.2.9
2- django-grappelli == 2.13.1
2+ django-grappelli == 2.13.3
You can’t perform that action at this time.
0 commit comments