Esempio n. 1
0
    def clousureForAction(self, item):

        define_action = Link(
            'Define Action',
            url_for('admin.toolbox.access.action.create',
                    permission_id=item.id)).setIcon('fa-plus')

        delete = Link(
            'Delete',
            url_for('admin.toolbox.access.permission.list_delete',id=item.id)
        ).setIcon('fa-trash-alt')\
         .setAjaxMethod('DELETE')\
         .setConfirm('Do you really delete?')

        edit = Link(
            'Edit', url_for('admin.toolbox.access.permission.edit',
                            id=item.id)).setIcon('fa-edit')

        link = Link('Actions', '#')
        link.appendChildren([define_action, delete, edit])
        return link.build()
Esempio n. 2
0
File: type.py Progetto: algha/tarim
 def CommandBar(self):
     links = []
     if hasattr(self.type, 'id'):
         links.append(Link('Delete').setMethod('delete')),
     links.append(Link('Save').setMethod('save'))
     return links
Esempio n. 3
0
File: type.py Progetto: algha/tarim
 def CommandBar(self):
     links = [
         Link('Add New', url_for('admin.toolbox.type.create')),
     ]
     return links
Esempio n. 4
0
 def CommandBar(self):
     links = [
         Link('Add New', url_for('admin.toolbox.access.permission.create')),
     ]
     return  links
Esempio n. 5
0
File: tags.py Progetto: algha/tarim
 def CommandBar(self):
     links = []
     links.append(Link('Delete').setMethod('delete')),
     links.append(Link('Save').setMethod('save'))
     return links
Esempio n. 6
0
 def CommandBar(self):
     links = [
         Link('Create',url_for('admin.category.create'))
     ]
     return links
Esempio n. 7
0
 def CommandBar(self):
     children = [Link('Logout', url_for('admin.logout'))]
     links = [Link('Add New', '#'), Link.withChildren('User', children)]
     return links
Esempio n. 8
0
 def CommandBar(self):
     links = []
     links.append(
         Link('Create',
              url_for('admin.toolbox.field.create', id=self.type.id)))
     return []
Esempio n. 9
0
 def CommandBar(self):
     links = [
         Link('Add New', url_for('admin.user.create')),
     ]
     return links
Esempio n. 10
0
File: field.py Progetto: algha/tarim
 def buttonGroup(self):
     return [
         Link('Create field').loadModalAsync('getField', 'asyncGetField',
                                             'saveField')
     ]
Esempio n. 11
0
 def CommandBar(self):
     links = []
     links.append(
         Link('Create', url_for('admin.post.create', type=self.type)))
     return links