Esempio n. 1
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'  # 为‘horizontal’水平  或‘vertical’ 垂直
    menu = (
        ParentItem('Users', children=[
            ChildItem(u'用户',model='user.userprofile'),
            ChildItem(model='auth.user'),
            ChildItem('User groups', 'auth.group'),
        ], icon='fa fa-users'),
        ParentItem('Right Side Menu', children=[
            ChildItem('Password change', url='admin:password_change'),
            ChildItem('Open Google', url='http://google.com', target_blank=True),

        ], align_right=True, icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 2
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem(
            'Usuarios',
            children=[
                #ChildItem('Usuarios del sistema', 'users.user'),
                ChildItem('Perfiles de usuarios', 'users.profile'),
                #ChildItem('Grupo de usuarios', 'auth.group'),
            ],
            icon='fa fa-users'),
        ParentItem('Ingreso',
                   children=[
                       ChildItem('Aperturas de la puerta', 'locks.dooropening')
                   ],
                   icon='fa fa-unlock'),
        ParentItem('Configuraciones',
                   children=[
                       ChildItem('Configuración general',
                                 'configurations.general'),
                       ChildItem('Empresas', 'configurations.entity'),
                   ],
                   icon='fa fa-cog fa-spin'),
        ParentItem('Créditos',
                   children=[
                       ChildItem('Sitio web',
                                 url='http://diegoasencio.co',
                                 target_blank=True),
                   ],
                   icon='fa fa-connectdevelop fa-spin'),
    )
Esempio n. 3
0
class SuitConfig(DjangoSuitConfig):
    ADMIN_NAME = "VirusTotal"
    layout = 'horizontal'
    menu = (
        ParentItem('Files',
                   children=[
                       ChildItem(model='virustotal.IpDomain'),
                       ChildItem(model='virustotal.files'),
                       ChildItem(model='virustotal.exeparents'),
                   ]),
        ParentItem('Ipdomain',
                   children=[
                       ChildItem(model='virustotal.ipdomain'),
                       ChildItem(model='virustotal.commfiles'),
                       ChildItem(model='virustotal.reffiles'),
                   ]),
        ParentItem('Users',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('User groups', 'auth.group'),
                   ],
                   icon='fa fa-users'),

        # ParentItem('View Site', url="/", align_right=True, icon='fa fa-cog'),
    )
Esempio n. 4
0
class SuitConfig(DjangoSuitConfig):
    menu_show_home = False

    menu = (
        ParentItem('Summary', url='/', icon='fa fa-list'),
        # ParentItem('Dashboard', url='/Dashboard', icon='fa fa-list'),
        ParentItem('Message Bank',
                   children=[
                       ChildItem('Messages', model='survey.message'),
                       ChildItem('Topics', model='survey.topic'),
                       ChildItem('Audiences', model='survey.audience'),
                       ChildItem('Language', model='survey.language'),
                       ChildItem('Sectors', model='survey.sector'),
                       ChildItem('Outputs', model='survey.output'),
                       ChildItem('Types', model='survey.type'),
                       ChildItem('Channel', model='survey.channel'),
                       ChildItem('Sources', model='survey.source'),
                   ],
                   icon='fa fa-list'),
        ParentItem('Users',
                   children=[
                       ChildItem('Users', model='auth.user'),
                       ChildItem('Groups', 'auth.group'),
                   ],
                   icon='fa fa-users'),
    )
Esempio n. 5
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem('Contents',
                   children=[ChildItem('Urls', model='app.url')],
                   icon='fa fa-link'),
        ParentItem('Users',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('User Groups', model='auth.group')
                   ],
                   icon='fa fa-users'),
        ParentItem('Settings',
                   children=[
                       ChildItem('Password change',
                                 url='admin:password_change'),
                   ],
                   align_right=True,
                   icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 6
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem(_('Usuarios del sistema'),
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem(_('Tienda'),
                   children=[
                       ChildItem(model='store.productcategory'),
                       ChildItem(model='store.productstore'),
                   ],
                   icon='fa fa-shopping-cart'),
        ParentItem(_('Inventario'),
                   children=[
                       ChildItem(model='inventory.ingredientproductprovider'),
                       ChildItem(model='inventory.ingredientproductcategory'),
                       ChildItem(model='inventory.ingredientproduct'),
                   ],
                   icon='fa fa-book'),
        ParentItem(_('Punto de Venta'),
                   children=[
                       ChildItem(model='pdv.invoice'),
                       ChildItem(model='pdv.newinvoice'),
                   ],
                   icon='fa fa-credit-card'),
    )
Esempio n. 7
0
class SunlessConfig(DjangoSuitConfig):
    menu = (
        ParentItem('명사 사전',
                   children=[
                       ChildItem(model='sunless_web.nouncate'),
                       ChildItem(model='sunless_web.noun'),
                       ChildItem(model='sunless_web.entitycate'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('번역 작업 V2',
                   children=[
                       ChildItem(model='sunless_web.entrypath'),
                       ChildItem(model='sunless_web.entry'),
                   ],
                   icon='fa fa-telegram'),
        ParentItem('사용자 관리',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem('씨봇이 관리',
                   children=[
                       ChildItem(model='sunless_web.conversation'),
                       ChildItem(model='sunless_web.patch'),
                   ],
                   icon='fa fa-telegram'),
    )

    verbose_name = '라라라'
Esempio n. 8
0
class SuitConfig(DjangoSuitConfig):
    name = 'suit'
    verbose_name = 'Django Suit'
    # Menu and header layout - horizontal or vertical
    layout = 'vertical'

    menu_show_home = False

    # Set default list per page
    list_per_page = 20

    # Show changelist top actions only if any row is selected
    toggle_changelist_top_actions = True

    # Define menu
    #: :type: list of suit.menu.ParentItem
    menu = (
        ParentItem('Sales',
                   children=[
                       ChildItem('Dashboard', url='/admin/dash/'),
                       ChildItem(model='core.order'),
                       ChildItem(model='core.client'),
                   ],
                   icon='fa fa-line-chart'),
        ParentItem('Admin',
                   children=[
                       ChildItem(model='core.template'),
                       ChildItem(model='core.package'),
                   ],
                   icon='fa fa-cog'),
    )
Esempio n. 9
0
File: apps.py Progetto: kimcg/Harim
class SuitConfig(DjangoSuitConfig):
    layout = 'horizontal'
    #layout = 'vertical'
    menu = (
        ParentItem('관리', children=[
            ChildItem(model='dtm.syscmmncdm'),
            ChildItem(model='dtm.usrcmpny'),
            ChildItem(model='dtm.usruser'),
        ], icon='fa fa-leaf'),
        ParentItem('인증 및 권한', children=[
            ChildItem('사용자', 'auth.user'),
            ChildItem('사용자 그룹', 'auth.group'),
        ], icon='fa fa-users'),
        ParentItem('관리자', children=[
            ChildItem('비밀번호 변경', url='admin:password_change'),

        ], icon='fa fa-cog'),

    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 10
0
class SuitConfig(DjangoSuitConfig):
    menu = (
        ParentItem('用户',
                   children=[
                       ChildItem(model='users.user'),
                       ChildItem('管理员组', model='auth.group'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('产品',
                   children=[
                       ChildItem(model='products.product'),
                       ChildItem(model='products.productcategory'),
                       ChildItem(model='products.warehouse'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('记工',
                   children=[
                       ChildItem(model='records.recordtailor'),
                       ChildItem(model='records.recordsew'),
                       ChildItem(model='records.recordiron'),
                       ChildItem(model='records.recordoutput'),
                   ],
                   icon='fa fa-users'),
        ParentItem('工资记录',
                   children=[
                       ChildItem(model='salary.salarylist'),
                       ChildItem(model='salary.salary'),
                   ],
                   icon='fa fa-cog'),  # align_right=True,),
    )
Esempio n. 11
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = [
        ParentItem(_('accounts'), children=[
            ChildItem(model='accounts.user'),
            ChildItem(model='auth.group'),
            ChildItem(model='accounts.WBUid'),
        ], icon='fa fa-user'),
#         ParentItem(_('organizations'), app='organizations', icon='fa fa-signal'),
#         ParentItem(_('流程'), app='vetting', icon='fa fa-signal'),
#         ParentItem(_('附件'), app='annex', icon='fa fa-signal'),
#         ParentItem(_('票据'), app='bills', icon='fa fa-signal'),
#         ParentItem(_('files'), app='files', icon='fa fa-file'),
#         ParentItem(_('客户信息'), app='customers', icon='fa fa-file'),
#         ParentItem(_('联系人'), app='contacts', icon='fa fa-file'),
#         ParentItem(_('合同'), app='contracts', icon='fa fa-file'),
#         ParentItem(_('申请单'), app='orders', icon='fa fa-file'),
#         ParentItem(_('账户'), app='payment_accounts', icon='fa fa-file'),
        ParentItem(_('Documentation'), url='/developer/', icon='fa fa-book', target_blank=True),
        ParentItem(_('API'), url='/api/v1/', icon='fa fa-wrench', target_blank=True),
    ]
    menu += get_parent_items()

    def ready(self):
        super(DjangoSuitConfig, self).ready()
Esempio n. 12
0
class SuitConfig(DjangoSuitConfig):
    menu = (
        ParentItem('Content',
                   children=[
                       ChildItem(model='cargos_main.cargo'),
                       ChildItem(model='cargos_main.cell'),
                       ChildItem(model='cargos_main.storage'),
                       ChildItem(model='cargos_main.company',
                                 label='Companies'),
                       ChildItem(model='cargos_main.category',
                                 label='Categories'),
                       ChildItem(model='cargos_main.categorization',
                                 label='Categorization')
                   ],
                   icon='fa fa-archive'),
        ParentItem('Users',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='users.employee'),
                   ],
                   icon='fa fa-users'),
        ParentItem('Notifications',
                   children=[
                       ChildItem(model='notifications.notification'),
                   ],
                   icon='fa fa-exclamation'),
        ParentItem('Right Side Menu',
                   children=[
                       ChildItem('Backup', url='backup_view'),
                       ChildItem('Password change',
                                 url='admin:password_change'),
                       ChildItem('Open Google',
                                 url='http://google.com',
                                 target_blank=True),
                   ],
                   align_right=True,
                   icon='fa fa-cog'),
    )
    layout = 'vertical'

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 13
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem('Students',
                   children=[
                       ChildItem('Students',
                                 url='/admin/sapp/studentinformation/'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('Users',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('User groups', 'auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem('Answers',
                   children=[
                       ChildItem(model='sapp.Answers'),
                       ChildItem('Answers', url='/admin/sapp/answers/'),
                   ],
                   icon='fa fa-users'),
        ParentItem('Make Questions',
                   children=[
                       ChildItem(model='sapp.Makequestion'),
                       ChildItem('Make Questions',
                                 url='/admin/sapp/makequestion/'),
                   ],
                   icon='fa fa-users'),
        ParentItem(
            'Change Password',
            children=[
                ChildItem('Password change', url='admin:password_change'),
                # ChildItem('Open Google', url='http://google.com', target_blank=True),
            ],
            align_right=True,
            icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 14
0
class JobConfig(DjangoSuitConfig):
    layout = 'horizontal'
    menu = (
        ParentItem('Jobs', url='/job/job/'),
        ParentItem('Companies', url='/job/company/'),
        ParentItem('Job Boards', url='/job/board/'),
        ParentItem('Cron Logs', url='/django_cron/cronjoblog/'),
        ParentItem('Search Terms', url='/job/searchterms/'),
    )

    def ready(self):
        # import jobs.signals  # noqa
        super(JobConfig, self).ready()
Esempio n. 15
0
class WebConfig(DjangoSuitConfig):
    menu = (
        ParentItem('Users and Groups',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='auth.group')
                   ]),
        ParentItem('Scrapy',
                   children=[
                       ChildItem(model='web.lawnature'),
                       ChildItem(model='web.settingitem')
                   ]),
    )
Esempio n. 16
0
class SuitConfig(DjangoSuitConfig):
    ##layout这个参数决定你的网页是初始样式是垂直样式还是水平样式,可选参数为‘horizontal’或‘vertical’
    layout = 'vertical'

    #
    menu = (
        ParentItem(
            '自动化管理',
            children=[
                ChildItem(model='TestModel.Column'),
                ChildItem(model='TestModel.Article'),
                ChildItem(model='TestModel.Testpage'),
                ChildItem(model='TestModel.Testcase'),
                ChildItem('自动化项目管理', url='/admin/Auto_test/column/'),
                ChildItem('Jenkins集成平台',
                          url='http://192.168.86.128:8001/',
                          target_blank=True),
                #ChildItem('页面管理', url='/admin/TestModel/testpage/'),
                #ChildItem('用例管理', url='/admin/TestModel/testcase/'),
            ],
            icon='fa fa-leaf'),

        #ParentItem('Jenkins集成平台', children=[
        #   ChildItem('Jenkins集成平台', url='http://192.168.20.62:8080/',target_blank=True),
        #], icon='fa fa-leaf'),
        ParentItem('用户管理',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('组别', 'auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem(
            '个人中心',
            children=[
                ChildItem('修改密码', url='admin:password_change'),
                #ChildItem('测试打开google', url='http://google.com', target_blank=True),
            ],
            align_right=True,
            icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 17
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem('Elementos',
                   children=[
                       ChildItem('Luminarias', 'street_lighting.luminaria'),
                       ChildItem('Postes', 'street_lighting.poste'),
                       ChildItem('Redes', 'street_lighting.red'),
                       ChildItem('Camaras y canalizaciones',
                                 'street_lighting.camara'),
                       ChildItem('Transformadores',
                                 'street_lighting.transformador'),
                   ],
                   icon='fa fa-slideshare'),
        ParentItem('Hojas de vida',
                   children=[
                       ChildItem('Usuarios', 'cv.workstate'),
                   ],
                   icon='fa fa-slideshare'),
        ParentItem('Usuarios',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('Grupos de Usuarios', 'auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem('Otras opciones',
                   children=[
                       ChildItem('Cambiar contraseña',
                                 url='admin:password_change'),
                       ChildItem('Abrir Google',
                                 url='https://google.com',
                                 target_blank=True),
                   ],
                   align_right=True,
                   icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 18
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'

    menu = (
        ParentItem('第三方登录',
                   children=[
                       ChildItem('association',
                                 url='/admin/social_django/association/'),
                       ChildItem('nonce', url='/admin/social_django/nonce/'),
                       ChildItem('user social auth',
                                 url='/admin/social_django/usersocialauth/'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('订单管理',
                   children=[
                       ChildItem('订单', model='demo.order'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('用户管理',
                   children=[
                       ChildItem(label='用户', model='auth.user'),
                       ChildItem('用户组', 'auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem('设置',
                   children=[
                       ChildItem('修改密码', url='admin:password_change'),
                       ChildItem('百度一下',
                                 url='https://www.baidu.com',
                                 target_blank=True),
                   ],
                   align_right=True,
                   icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 19
0
def get_parent_items():
    menu = []
    apps_dir = join(settings.PROJECT_PATH, 'apps')
    for dirname in next(os.walk(apps_dir))[1]:
        if dirname not in ['accounts'] and exists(join(apps_dir, '{}/admin.py'.format(dirname))):
            menu.append(ParentItem(_('{}'.format(dirname)), app='{}'.format(dirname), icon='fa fa-heart'))
    return menu
Esempio n. 20
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'

    menu = (
        ParentItem(u'资产组件',
                   children=[
                       ChildItem(model='servermanager.server'),
                       ChildItem(model='servermanager.assets'),
                       ChildItem(model='servermanager.idc'),
                       ChildItem(model='servermanager.cpu'),
                       ChildItem(model='servermanager.nic'),
                       ChildItem(model='servermanager.disk'),
                       ChildItem(model='servermanager.software'),
                       ChildItem(model='servermanager.business'),
                       ChildItem(model='servermanager.devicetype'),
                       ChildItem(model='servermanager.provider'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem(u'容器管理',
                   children=[
                       ChildItem(model='dockermanager.dockerhost'),
                       ChildItem(model='dockermanager.dockercontainer'),
                       ChildItem(model='dockermanager.dockerimage'),
                   ],
                   icon='fa fa-magnet'),
        ParentItem(u'Salt管理',
                   children=[
                       ChildItem(model='saltadmin.saltjobs'),
                       ChildItem(model='saltadmin.cmdrunlog'),
                       ChildItem(model='saltadmin.miniongroup'),
                       ChildItem(model='saltadmin.modules'),
                   ],
                   icon='fa fa-magnet'),
        ParentItem(u'用户管理',
                   children=[
                       ChildItem(u'用  户', 'webapp.suser'),
                       ChildItem(u'用户组', 'auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem(u'教学管理',
                   children=[
                       ChildItem(model='teachmanager.sysinfo'),
                       ChildItem(model='teachmanager.experinfo'),
                   ],
                   icon='fa fa-users'),
    )
Esempio n. 21
0
class SuitConfig(DjangoSuitConfig):
    verbose_name = 'HBU Online Judge Suit'
    menu = (
        ParentItem('Problem',
                   children=[
                       ChildItem(model='judge.problem'),
                       ChildItem(model='judge.problemgroup'),
                       ChildItem(model='judge.Problemtype'),
                   ],
                   icon='fa fa-question-circle'),
        ParentItem('Submission',
                   children=[
                       ChildItem(model='judge.submission'),
                       ChildItem(model='judge.language'),
                       ChildItem(model='judge.judge'),
                   ],
                   icon='fa fa-check-square-o'),
        ParentItem('Contest',
                   children=[
                       ChildItem(model='judge.contest'),
                       ChildItem(model='judge.contestparticipation'),
                       ChildItem(model='judge.contesttag'),
                   ],
                   icon='fa fa-bar-chart'),
        ParentItem('User',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='judge.profile'),
                       ChildItem(model='judge.organization'),
                       ChildItem(model='judge.organizationrequest'),
                   ],
                   icon='fa fa-user'),
        ParentItem('Site',
                   children=[
                       ChildItem(model='judge.blogpost'),
                       ChildItem(model='judge.navigationbar'),
                       ChildItem(model='judge.miscConfig'),
                       ChildItem(model='judge.license'),
                       ChildItem(model='sites.site'),
                       ChildItem(model='redirects.redirect'),
                       ChildItem(model='judge.comment'),
                       ChildItem(model='flatpages.flatpage'),
                       ChildItem(model='judge.solution'),
                   ],
                   icon='fa fa-leaf'),
    )
Esempio n. 22
0
class SuitConfig(DjangoSuitConfig):
    layout = 'horizontal'
    menu = (
        ParentItem('Auction', children=[
            ChildItem(model='auction.donation'),
            ChildItem(model='auction.lot'),
        ]),
    )
Esempio n. 23
0
class SuitConfig(DjangoSuitConfig):
    menu = (
        ParentItem('Site Content',
                   children=[
                       ChildItem(model='site_content.logo'),
                       ChildItem(model='site_content.sociallink'),
                       ChildItem(model='site_content.instagram'),
                   ]),
        ParentItem('Site Media',
                   children=[
                       ChildItem('Files', url='fb_browse'),
                   ]),
        ParentItem('Account', app='account'),
        ParentItem('Plants', app='plants'),
        ParentItem('Calendar', app='calendar'),
        ParentItem('Users',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('User groups', 'auth.group'),
                   ]),
        ParentItem('Your Account',
                   children=[
                       ChildItem('Password change',
                                 url='admin:password_change'),
                   ],
                   align_right=True),
    )

    def ready(self):
        super(SuitConfig, self).ready()
Esempio n. 24
0
class SuitConfig(DjangoSuitConfig):
    menu = (
        ParentItem('Content',
                   children=[
                       ChildItem(model='demo.country'),
                       ChildItem(model='demo.continent'),
                       ChildItem(model='demo.showcase'),
                       ChildItem('Custom view', url='/admin/custom/'),
                   ],
                   icon='fa fa-leaf'),
        ParentItem('Integrations', children=[
            ChildItem(model='demo.city'),
        ]),
        ParentItem('Users',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem('User groups', 'auth.group'),
                   ],
                   icon='fa fa-users'),
        ParentItem('Right Side Menu',
                   children=[
                       ChildItem('Password change',
                                 url='admin:password_change'),
                       ChildItem('Open Google',
                                 url='http://google.com',
                                 target_blank=True),
                   ],
                   align_right=True,
                   icon='fa fa-cog'),
    )

    def ready(self):
        super(SuitConfig, self).ready()

        # DO NOT COPY FOLLOWING LINE
        # It is only to prevent updating last_login in DB for demo app
        self.prevent_user_last_login()

    def prevent_user_last_login(self):
        """
        Disconnect last login signal
        """
        from django.contrib.auth import user_logged_in
        from django.contrib.auth.models import update_last_login
        user_logged_in.disconnect(update_last_login)
Esempio n. 25
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem('Usuarios',
                   icon='fa fa-user',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='auth.group'),
                   ]),
        ParentItem('Landing Page',
                   icon='fa fa-file',
                   children=[
                       ChildItem(model='landing' + '.AboutMe'.lower()),
                       ChildItem(model='landing' + '.Service'.lower()),
                       ChildItem(model='landing' + '.Entrepreneurial'.lower()),
                       ChildItem(model='landing' + '.TechnicalSkill'.lower()),
                       ChildItem(model='landing' +
                                 '.ProfessionalSkill'.lower()),
                       ChildItem(model='landing' + '.Education'.lower()),
                       ChildItem(model='landing' + '.WorkExperience'.lower()),
                       ChildItem(model='landing' + '.Portfolio'.lower()),
                       ChildItem(model='landing' + '.ClientReview'.lower()),
                   ]),
        ParentItem('Mensajes',
                   icon='fa fa-envelope',
                   children=[
                       ChildItem(model='landing.ContactMessage'.lower()),
                   ]),
        ParentItem('Reportes',
                   icon='fa fa-list-alt',
                   children=[
                       ChildItem(model='admin.logentry'),
                   ]),
        ParentItem(
            'Configuración',
            icon='fa fa-cog',
            children=[
                ChildItem(model='landing' + '.SiteConfig'.lower()),
                ChildItem(model='landing' + '.SocialNetwork'.lower()),
                #ChildItem(model='rest_framework_api_key.apikey'),
            ]),
    )
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = (
        ParentItem('Mi Campaña',
                   icon='fa fa-users',
                   children=[
                       ChildItem(model='campaigns.campaign'),
                       ChildItem(model='campaigns.meeting'),
                       ChildItem(model='campaigns.listpeople'),
                       ChildItem(model='campaigns.surveyed'),
                       ChildItem(model='campaigns.person'),
                       ChildItem(model='campaigns.typemeeting'),
                       ChildItem(model='campaigns.campaigncharge'),
                   ]),
        ParentItem('Ubicaciones',
                   icon='fa fa-map-marker',
                   children=[
                       ChildItem(model='locations.country'),
                       ChildItem(model='locations.region'),
                       ChildItem(model='locations.city'),
                       ChildItem(model='locations.zone'),
                       ChildItem(model='locations.neighborhood'),
                       ChildItem(model='locations.votingpost'),
                   ]),
        ParentItem('Clientes',
                   icon='fa fa-user',
                   children=[
                       ChildItem(model='users.user'),
                       ChildItem(model='auth.group'),
                   ]),
        ParentItem('Configuración',
                   icon='fa fa-cog',
                   children=[
                       ChildItem(model='configurations.politicalparty'),
                   ]),
        ParentItem(
            'Clientes',
            icon='fa fa-bug',
            children=[
                # ChildItem(model='campaigns.campaign'),
            ]),
    )
Esempio n. 27
0
class SuitConfig(DjangoSuitConfig):
    layout = 'vertical'
    menu = [
        ParentItem(AuthConfig.verbose_name,
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='auth.group'),
                   ],
                   icon='fa fa-users'),
    ]
    menu = PosterConfig.menu + GameConfig.menu + menu
Esempio n. 28
0
class PosterConfig(AppConfig):
    name = 'poster'
    verbose_name = _('poster')
    menu = [
        ParentItem(verbose_name,
                   children=[
                       ChildItem(model='poster.style'),
                       ChildItem(model='poster.poster'),
                   ],
                   icon='fa fa-leaf'),
    ]
Esempio n. 29
0
class SuitConfig(DjangoSuitConfig):
    # name = 'employees'
    menu = (
        ParentItem(
            '人员信息超级管理',
            children=[
                ChildItem(model='employees.activity'),
                # ChildItem(model='employees.employee'),
                ChildItem(model='employees.comment'),
                ChildItem(model='employees.trainingexperience'),
                ChildItem(model='employees.resume'),
                ChildItem(model='employees.workexperience'),
                ChildItem(model='employees.skill'),
                ChildItem(model='employees.education'),
                ChildItem(model='employees.contactperson'),
                ChildItem(model='employees.certification'),
                ChildItem(model='employees.idcard'),
                ChildItem(model='employees.card'),
                # ChildItem(model='employees.interview'),
                ChildItem(model='employees.project')
            ]),
        ParentItem('面试管理',
                   children=[
                       ChildItem(model='employees.interviewresume'),
                       ChildItem(model='employees.interview')
                   ],
                   icon='fa fa-leaf'),
        ParentItem('员工管理', children=[ChildItem(model='employees.employee')]),
        ParentItem('项目管理',
                   children=[ChildItem(model='employees.workproject')]),
        ParentItem('工资管理', children=[ChildItem(model='employees.salary')]),
        ParentItem('人员报表管理',
                   children=[ChildItem(model='employees.workreport')]),
        ParentItem('技术分享管理', children=[ChildItem(model='employees.meeting')]),
        ParentItem('月份工时管理',
                   children=[
                       ChildItem(model='employees.userworkproject'),
                       ChildItem(model='employees.timesheet')
                   ]),
        ParentItem('用户与权限',
                   children=[
                       ChildItem(model='auth.user'),
                       ChildItem(model='auth.group'),
                   ],
                   icon='fa fa-users'),
    )
Esempio n. 30
0
class SuitConfig(DjangoSuitConfig):
    layout = 'horizontal'
    menu = (
        ParentItem('Controle de Acesso', children=[
            ChildItem('Usuários', model='account.user'),
            ChildItem('Grupos', model='auth.group'),
        ]),
        # ParentItem('Funcionario', children=[
        #     ChildItem(model='funcionario.funcionario'),
        #     ChildItem(model='funcionario.funcao'),
        # ]),
    )