def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.label_payments = wx.StaticText(self, -1, "PAYMENTS") self.panel_payments = wx.Panel(self, -1) self.label_details = wx.StaticText(self, -1, "DETAILS") self.panel_payment_details = wx.Panel(self, -1) self.panel_buttons = panel_buttons(self, -1) self.payments_list = vListCtrl(self.panel_payments, style = wx.LC_HRULES | wx.LC_SINGLE_SEL) self.panel_payments_botttom = wx.Panel( self.panel_payments, -1) self.txt_ctrl_pay_records = wx.TextCtrl(self.panel_payments_botttom, -1, " ") self.txt_ctrl_pay_total = wx.TextCtrl(self.panel_payments_botttom, -1, "", style=wx.TE_RIGHT) self.details_list = vListCtrl(self.panel_payment_details, style = wx.LC_HRULES | wx.LC_SINGLE_SEL) self.panel_details_botttom = wx.Panel( self.panel_payment_details, -1) self.txt_ctrl_details_records = wx.TextCtrl(self.panel_details_botttom, -1, "") self.txt_ctrl_details_total = wx.TextCtrl(self.panel_details_botttom, -1, "", style=wx.TE_RIGHT) self.Bind(wx.EVT_LIST_ITEM_SELECTED, self.OnPaymentItemSelected, self.payments_list) self.Bind(wx.EVT_LIST_ITEM_SELECTED, self.OnDetailItemSelected, self.details_list) self.panel_buttons.new.Bind(wx.EVT_BUTTON, self.OnNew, self.panel_buttons.new ) self.panel_buttons.edit.Bind(wx.EVT_BUTTON, self.OnEdit, self.panel_buttons.edit ) self.panel_buttons.cancel.Bind(wx.EVT_BUTTON, self.OnCancel, self.panel_buttons.cancel ) self.Bind(wx.EVT_BUTTON, self.OnDelete, self.panel_buttons.delete) self.Bind(wx.EVT_BUTTON, self.OnSave, self.panel_buttons.save) self.Bind(wx.EVT_BUTTON, self.OnRefresh, self.panel_buttons.refresh ) tc = [self.txt_ctrl_pay_records, self.txt_ctrl_pay_total, self.txt_ctrl_details_records, self.txt_ctrl_details_total ] for t in tc: t.SetEditable(False) self.__layout() pub.subscribe(self.displayData, 'student_payments.studentselected') self.pay_records = 0 self.detail_records = 0 self.__properties() self.__layout()
def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.panel_filter_schools = wx.Panel(self, -1) self.checkbox_filter_by_school = wx.CheckBox(self.panel_filter_schools, -1, "School") self.choice_schools = wx.Choice(self.panel_filter_schools, -1, choices=[]) self.checkbox_filter_by_form = wx.CheckBox(self.panel_filter_schools, -1, "Forms") self.choice_forms = wx.Choice(self.panel_filter_schools, -1, choices=[]) self.vList = vListCtrl(self, style = wx.LC_HRULES | wx.LC_SINGLE_SEL) self.text_ctrl_record_count = wx.TextCtrl(self, -1, '') self.Bind(wx.EVT_LIST_ITEM_SELECTED, self.OnItemSelected, self.vList) self.Bind(wx.EVT_CHOICE, self.OnSelectSchool, self.choice_schools) self.Bind(wx.EVT_CHOICE, self.OnSelectForm, self.choice_forms) self.Bind(wx.EVT_CHECKBOX, self.OnCheckSchool, self.checkbox_filter_by_school) self.Bind(wx.EVT_CHECKBOX, self.OnCheckCourse, self.checkbox_filter_by_form) self.__set_properties() self.__do_layout() self.__do_main()
def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.panel_details = wx.Panel(self, -1) self.panel_buttons = panel_buttons(self, -1) self.label_details = wx.StaticText(self, -1, "DETAILS") self.details_list = vListCtrl(self.panel_details, style=wx.LC_HRULES | wx.LC_SINGLE_SEL) self.panel_details_botttom = wx.Panel(self.panel_details, -1) self.txt_ctrl_details_records = wx.TextCtrl(self.panel_details_botttom, -1, "") self.txt_ctrl_details_total = wx.TextCtrl(self.panel_details_botttom, -1, "") self.panel_buttons.new.Bind(wx.EVT_BUTTON, self.OnNew, self.panel_buttons.new) self.panel_buttons.edit.Bind(wx.EVT_BUTTON, self.OnEdit, self.panel_buttons.edit) self.panel_buttons.cancel.Bind(wx.EVT_BUTTON, self.OnCancel, self.panel_buttons.cancel) self.Bind(wx.EVT_BUTTON, self.OnDelete, self.panel_buttons.delete) self.Bind(wx.EVT_BUTTON, self.OnSave, self.panel_buttons.save) self.Bind(wx.EVT_BUTTON, self.OnRefresh, self.panel_buttons.refresh) tc = (self.txt_ctrl_details_records, self.txt_ctrl_details_total) for t in tc: t.SetEditable(False) self.__layout()
def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.panel_filter_dates = wx.Panel(self, -1) self.label_from = wx.StaticText(self.panel_filter_dates, -1, "Date") self.datepicker_ctrl_from = DateCtrl(self.panel_filter_dates, -1) self.label_to = wx.StaticText(self.panel_filter_dates, -1, "to") self.datepicker_ctrl_to = DateCtrl(self.panel_filter_dates, -1) self.label_pay_type = wx.StaticText(self.panel_filter_dates, -1, "Payment Type") self.choice_pay_type = wx.Choice(self.panel_filter_dates, -1, choices=[]) self.vList = vListCtrl(self, style = wx.LC_HRULES | wx.LC_SINGLE_SEL) self.text_ctrl_record_count = wx.TextCtrl(self, -1, '') self.Bind(wx.EVT_LIST_ITEM_SELECTED, self.OnItemSelected, self.vList) self.Bind(wx.EVT_CHOICE, self.OnSelectSaleItem, self.choice_pay_type) pub.subscribe(self.DateChange, 'DateCtrl.date_change') self.__set_properties() self.__do_layout() self.__do_main()
def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.panel_top = wx.Panel(self, -1) self.panel_bottom = wx.Panel(self, -1) self.panel_left = wx.Panel(self.panel_bottom, -1) self.panel_right = panel_student_bio(self.panel_bottom, -1) self.label_heading = wx.StaticText(self.panel_top, -1, " Current Students ") self.panel_filter = panel_filter_school_level_form(self.panel_top, -1) self.vList = vListCtrl(self.panel_left, style=wx.LC_HRULES | wx.LC_SINGLE_SEL) self.text_ctrl_records = wx.TextCtrl(self.panel_left, -1, "") # for wxMSW self.vList.Bind(wx.EVT_COMMAND_RIGHT_CLICK, self.OnRightClick) # for wxGTK self.vList.Bind(wx.EVT_RIGHT_UP, self.OnRightClick) self.Bind(wx.EVT_LIST_ITEM_SELECTED, self.OnItemSelected, self.vList) pub.subscribe(self.displayData, "filter_sch.change") self.__set_properties() self.__do_layout() self.__do_main()
def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.label_payments = wx.StaticText(self, -1, "PAYMENTS") self.panel_payments = wx.Panel(self, -1) self.label_details = wx.StaticText(self, -1, "DETAILS") self.panel_details = wx.Panel(self, -1) self.panel_buttons = panel_buttons(self, -1) self.payments_list = vListCtrl(self.panel_payments, style = wx.LC_HRULES | wx.LC_SINGLE_SEL) self.panel_payments_botttom = wx.Panel( self.panel_payments, -1) self.txt_ctrl_pay_records = wx.TextCtrl(self.panel_payments_botttom, -1, " ") self.txt_ctrl_pay_total = wx.TextCtrl(self.panel_payments_botttom, -1, " ") self.panel_details_botttom = wx.Panel( self.panel_details, -1) self.label_recipt = wx.StaticText(self.panel_details_botttom, -1, "Recipt No.") self.txt_ctrl_details_records = wx.TextCtrl(self.panel_details_botttom, -1, "") self.txt_ctrl_details_total = wx.TextCtrl(self.panel_details_botttom, -1, "") self.panel_buttons.new.Bind(wx.EVT_BUTTON, self.OnNew, self.panel_buttons.new ) self.panel_buttons.edit.Bind(wx.EVT_BUTTON, self.OnEdit, self.panel_buttons.edit ) self.panel_buttons.cancel.Bind(wx.EVT_BUTTON, self.OnCancel, self.panel_buttons.cancel ) self.Bind(wx.EVT_BUTTON, self.OnDelete, self.panel_buttons.delete) self.Bind(wx.EVT_BUTTON, self.OnSave, self.panel_buttons.save) self.Bind(wx.EVT_BUTTON, self.OnRefresh, self.panel_buttons.refresh ) pub.subscribe(self.displayData, 'registrationpayments.studentselected') tc = (self.txt_ctrl_pay_records, self.txt_ctrl_pay_total, self.txt_ctrl_details_records, self.txt_ctrl_details_total) for t in tc: t.SetEditable(False) self.__layout()
def __init__(self, *args, **kwds): kwds["style"] = wx.TAB_TRAVERSAL wx.Panel.__init__(self, *args, **kwds) self.records = 0 self.panel_top = wx.Panel(self, -1) self.panel_bottom = wx.Panel(self, -1) self.panel_left = wx.Panel(self.panel_bottom, -1) self.panel_right = wx.Panel(self.panel_bottom, -1) self.panel_bio = panel_student_bio(self.panel_right, -1) #self.button_edit = wx.Button(self.panel_right, -1, 'Edit') sizer_bio = wx.BoxSizer(wx.VERTICAL) sizer_bio.Add(self.panel_bio) #sizer_bio.Add(self.button_edit) self.panel_right.SetSizer(sizer_bio) self.label_heading = wx.StaticText(self.panel_top, -1, " Current Students ") self.panel_filter = panel_filter_school_level_form(self.panel_top, -1) self.vList = vListCtrl(self.panel_left, style = wx.LC_HRULES | wx.LC_SINGLE_SEL) self.text_ctrl_records = wx.TextCtrl(self.panel_left, -1, '') # for wxMSW self.vList.Bind(wx.EVT_COMMAND_RIGHT_CLICK, self.OnRightClick) # for wxGTK self.vList.Bind(wx.EVT_RIGHT_UP, self.OnRightClick) #self.Bind(wx.EVT_BUTTON, self.OnEdit, self.button_edit) self.Bind(wx.EVT_LIST_ITEM_SELECTED, self.OnItemSelected, self.vList) pub.subscribe(self.displayData,'filter_sch.change') self.__set_properties() self.__do_layout() self.__do_main()