Skip to content

Commit b523f89

Browse files
committed
Magic has view/update
1 parent 2f1b202 commit b523f89

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

magic.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,13 +160,13 @@ def sync_from_magic(project_db):
160160
create_file(project_url, os.path.join(root, 'admin_%s_update.html' % name))
161161
create_file(project_url, os.path.join(root, 'admin_%s_list.html' % name))
162162

163-
if not model_db['admin_only']:
164-
create_file(project_url, os.path.join(root, '%s_update.html' % name))
165-
166-
if model_db['public_view'] or not model_db['admin_only']:
163+
if model_db['has_view']:
167164
create_file(project_url, os.path.join(root, '%s_view.html' % name))
168165
create_file(project_url, os.path.join(root, '%s_list.html' % name))
169166

167+
if model_db['has_update']:
168+
create_file(project_url, os.path.join(root, '%s_update.html' % name))
169+
170170

171171
###############################################################################
172172
# Main

0 commit comments

Comments
 (0)