当前位置: 首页>>代码示例>>Python>>正文


Python BasePersonRoleEditor.setup_slaves方法代码示例

本文整理汇总了Python中stoqlib.gui.templates.persontemplate.BasePersonRoleEditor.setup_slaves方法的典型用法代码示例。如果您正苦于以下问题:Python BasePersonRoleEditor.setup_slaves方法的具体用法?Python BasePersonRoleEditor.setup_slaves怎么用?Python BasePersonRoleEditor.setup_slaves使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在stoqlib.gui.templates.persontemplate.BasePersonRoleEditor的用法示例。


在下文中一共展示了BasePersonRoleEditor.setup_slaves方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: setup_slaves

# 需要导入模块: from stoqlib.gui.templates.persontemplate import BasePersonRoleEditor [as 别名]
# 或者: from stoqlib.gui.templates.persontemplate.BasePersonRoleEditor import setup_slaves [as 别名]
 def setup_slaves(self):
     BasePersonRoleEditor.setup_slaves(self)
     self.details_slave = TransporterDataSlave(self.store,
                                               self.model,
                                               visual_mode=self.visual_mode)
     slave = self.main_slave.get_person_slave()
     slave.attach_slave('person_status_holder', self.details_slave)
开发者ID:Joaldino,项目名称:stoq,代码行数:9,代码来源:personeditor.py

示例2: setup_slaves

# 需要导入模块: from stoqlib.gui.templates.persontemplate import BasePersonRoleEditor [as 别名]
# 或者: from stoqlib.gui.templates.persontemplate.BasePersonRoleEditor import setup_slaves [as 别名]
    def setup_slaves(self):
        BasePersonRoleEditor.setup_slaves(self)

        user_status = UserStatusSlave(self.store, self.model,
                                      visual_mode=self.visual_mode)
        self.main_slave.attach_person_slave(user_status)

        passwd_fields = not self.edit_mode
        self.user_details = UserDetailsSlave(self.store, self.model,
                                             show_password_fields=passwd_fields,
                                             visual_mode=self.visual_mode)
        tab_text = _('User Details')
        self.main_slave._person_slave.attach_custom_slave(self.user_details,
                                                          tab_text)

        tab_child = self.main_slave._person_slave.custom_tab
        notebook = self.main_slave._person_slave.person_notebook
        notebook.reorder_child(tab_child, position=self.USER_TAB_POSITION)
        notebook.set_current_page(self.USER_TAB_POSITION)

        tab_text = _('Branch Access')
        self.user_branches = UserBranchAccessSlave(self.store, self.model)
        # XXX: workaround border being to large
        self.user_branches.vbox1.set_border_width(0)
        self.main_slave._person_slave.attach_extra_slave(self.user_branches,
                                                         tab_text)
开发者ID:romaia,项目名称:stoq,代码行数:28,代码来源:personeditor.py

示例3: setup_slaves

# 需要导入模块: from stoqlib.gui.templates.persontemplate import BasePersonRoleEditor [as 别名]
# 或者: from stoqlib.gui.templates.persontemplate.BasePersonRoleEditor import setup_slaves [as 别名]
    def setup_slaves(self):
        from .opticalslave import MedicDetailsSlave
        BasePersonRoleEditor.setup_slaves(self)

        tab_text = _('Medic Details')
        self.medic_details_slave = MedicDetailsSlave(self.store, self.model,
                                                     visual_mode=self.visual_mode)
        self.main_slave._person_slave.add_extra_tab(tab_text,
                                                    self.medic_details_slave)
开发者ID:hackedbellini,项目名称:stoq,代码行数:11,代码来源:opticaleditor.py

示例4: setup_slaves

# 需要导入模块: from stoqlib.gui.templates.persontemplate import BasePersonRoleEditor [as 别名]
# 或者: from stoqlib.gui.templates.persontemplate.BasePersonRoleEditor import setup_slaves [as 别名]
    def setup_slaves(self):
        BasePersonRoleEditor.setup_slaves(self)
        self.status_slave = ClientStatusSlave(self.store, self.model,
                                              visual_mode=self.visual_mode)
        self.main_slave.attach_person_slave(self.status_slave)

        credit_slave = ClientCreditSlave(self.store, self.model,
                                         visual_mode=self.visual_mode)
        self.main_slave._person_slave.add_extra_tab('Credit Details',
                                                    credit_slave)
开发者ID:leandrorchaves,项目名称:stoq,代码行数:12,代码来源:personeditor.py


注:本文中的stoqlib.gui.templates.persontemplate.BasePersonRoleEditor.setup_slaves方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。