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


Python SaleListToolbar.edit方法代码示例

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


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

示例1: SalesApp

# 需要导入模块: from stoqlib.gui.slaves.saleslave import SaleListToolbar [as 别名]
# 或者: from stoqlib.gui.slaves.saleslave.SaleListToolbar import edit [as 别名]
class SalesApp(ShellApp):

    app_title = _('Sales')
    gladefile = 'sales_app'
    search_spec = SaleView
    search_label = _('matching:')
    report_table = SalesReport

    cols_info = {Sale.STATUS_INITIAL: 'open_date',
                 Sale.STATUS_CONFIRMED: 'confirm_date',
                 Sale.STATUS_PAID: 'close_date',
                 Sale.STATUS_ORDERED: 'open_date',
                 Sale.STATUS_CANCELLED: 'cancel_date',
                 Sale.STATUS_QUOTE: 'open_date',
                 Sale.STATUS_RETURNED: 'return_date',
                 Sale.STATUS_RENEGOTIATED: 'close_date'}

    action_permissions = {
        "SalesPrintInvoice": ('app.sales.print_invoice', PermissionManager.PERM_SEARCH),
    }

    def __init__(self, window, store=None):
        self.summary_label = None
        self._visible_date_col = None
        ShellApp.__init__(self, window, store=store)

    #
    # Application
    #

    def create_actions(self):
        group = get_accels('app.sales')
        actions = [
            # File
            ("SaleQuote", None, _("Sale quote..."), '',
             _('Create a new quote for a sale')),
            ("WorkOrderQuote", None, _("Sale with work order..."), '',
             _('Create a new quote for a sale with work orders')),
            ("LoanNew", None, _("Loan...")),
            ("LoanClose", None, _("Close loan...")),

            # Search
            ("SearchSoldItemsByBranch", None, _("Sold items by branch..."),
             group.get("search_sold_items_by_branch"),
             _("Search for sold items by branch")),
            ("SearchSalesByPaymentMethod", None,
             _("Sales by payment method..."),
             group.get("search_sales_by_payment")),
            ("SearchSalesPersonSales", None,
             _("Total sales made by salesperson..."),
             group.get("search_salesperson_sales"),
             _("Search for sales by payment method")),
            ("SearchProduct", STOQ_PRODUCTS, _("Products..."),
             group.get("search_products"),
             _("Search for products")),
            ("SearchService", STOQ_SERVICES, _("Services..."),
             group.get("search_services"),
             _("Search for services")),
            ("SearchDelivery", STOQ_DELIVERY, _("Deliveries..."),
             group.get("search_deliveries"),
             _("Search for deliveries")),
            ("SearchClient", STOQ_CLIENTS, _("Clients..."),
             group.get("search_clients"),
             _("Search for clients")),
            ("SearchClientCalls", None, _("Client Calls..."),
             group.get("search_client_calls"),
             _("Search for client calls")),
            ("SearchCreditCheckHistory", None,
             _("Client credit check history..."),
             group.get("search_credit_check_history"),
             _("Search for client check history")),
            ("SearchCommission", None, _("Commissions..."),
             group.get("search_commissions"),
             _("Search for salespersons commissions")),
            ("LoanSearch", None, _("Loans..."),
             group.get("search_loans")),
            ("LoanSearchItems", None, _("Loan items..."),
             group.get("search_loan_items")),
            ("ReturnedSaleSearch", None, _("Returned sales..."),
             group.get("returned_sales")),
            ("SearchUnconfirmedSaleItems", None, _("Unconfirmed sale items..."),
             group.get("search_reserved_product"),
             _("Search for unconfirmed sale items")),
            ("SearchClientsWithSale", None, _("Clients with sales..."),
             None,
             _("Search for regular clients")),
            ("SearchClientsWithCredit", None, _("Clients with credit..."),
             None,
             _("Search for clients that have credit")),
            ("SearchSoldItemsByClient", None, _("Sold items by client..."),
             None,
             _("Search for products sold by client")),


            # Sale
            ("SaleMenu", None, _("Sale")),

            ("SalesCancel", None, _("Cancel...")),
            ("ChangeClient", gtk.STOCK_EDIT, _("Change client...")),
            ("SalesPrintInvoice", gtk.STOCK_PRINT, _("_Print invoice...")),
#.........这里部分代码省略.........
开发者ID:dionimf,项目名称:stoq,代码行数:103,代码来源:sales.py


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