Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

models.py:74-75: Add MatrixBlock to the admin panel.... #934

Closed
0pdd opened this issue Jul 4, 2019 · 6 comments · Fixed by #941
Closed

models.py:74-75: Add MatrixBlock to the admin panel.... #934

0pdd opened this issue Jul 4, 2019 · 6 comments · Fixed by #941
Assignees
Labels
1 burning issue 30 mins middle-sized issue. Usually a part of feature or a fix cleanup everything that do project stronger, flexible, reusable

Comments

@0pdd
Copy link
Collaborator

0pdd commented Jul 4, 2019

The puzzle 880-c9d8b5dc from #880 has to be resolved:

# @todo #880:30m Add MatrixBlock to the admin panel.
# Inline it on Category Edit page.

The puzzle was created by Artemiy on 04-Jul-19.

Estimate: 30 minutes, role: DEV.

If you have any technical questions, don't ask me, submit new tickets instead. The task will be "done" when the problem is fixed and the text of the puzzle is removed from the source code. Here is more about PDD and about me.

@0pdd
Copy link
Collaborator Author

0pdd commented Jul 4, 2019

@artemiyds2 @duker33 please pay attention to this new issue.

0pdd referenced this issue Jul 4, 2019
* Create CatalogBlock model and add sublime's configs to .gitignore

* Remove related todo

* Review fixes

* Rework MatrixBlock tests
@ArtemijRodionov ArtemijRodionov added 1 burning issue 30 mins middle-sized issue. Usually a part of feature or a fix cleanup everything that do project stronger, flexible, reusable labels Jul 4, 2019
@ArtemijRodionov ArtemijRodionov self-assigned this Jul 4, 2019
@ArtemijRodionov
Copy link
Contributor

ArtemijRodionov commented Jul 5, 2019

Inline it on Category Edit page.

Django can't inline MatrixBlock -> Category -> CategoryPage relation into CategoryPageAdmin. We could use nested-inline package or change relation from category to page to reduce the nesting level.

But it seems for me it doesn't have a sense to inline MatrixBlock to CategoryPage, because not every page has a MatrixBlock. I'd say only several pages can have them.

So creation of separate admin model instead more appropriate.

@duker33 What do you think? Will be OK just create a separate admin model?

@ArtemijRodionov
Copy link
Contributor

It'll look so:

изображение

изображение

@duker33
Copy link
Contributor

duker33 commented Jul 5, 2019

@artemiy312 , let's leave your decision since it's simple. If users will complain we'll think about it

ArtemijRodionov added a commit that referenced this issue Jul 6, 2019
* Add MatrixBlock to admin panel. Localize fields

* Delete todos

* Recompile translate. Edit in_pack colModel

* Create todo to fix i18n
@0pdd
Copy link
Collaborator Author

0pdd commented Jul 6, 2019

@0pdd the puzzle #942 is still not solved.

@0pdd
Copy link
Collaborator Author

0pdd commented Sep 24, 2019

@0pdd the only puzzle #942 is solved here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1 burning issue 30 mins middle-sized issue. Usually a part of feature or a fix cleanup everything that do project stronger, flexible, reusable
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants