1
2
3
4
5
6
7 import wx
8
9
10 import gettext
11
12
13
14 from Gnumed.wxpython.gmEMRStructWidgets import cEncounterTypePhraseWheel
15 from Gnumed.wxpython.gmDateTimeInput import cFuzzyTimestampInput
16 from Gnumed.wxpython.gmCodingWidgets import cGenericCodesPhraseWheel
17 from Gnumed.wxpython.gmPraxisWidgets import cPraxisBranchPhraseWheel
18
19
20
23
24 kwds["style"] = wx.NO_BORDER | wx.TAB_TRAVERSAL
25 wx.ScrolledWindow.__init__(self, *args, **kwds)
26 self._LBL_instructions = wx.StaticText(self, wx.ID_ANY, _("Edit the details for the encounter below:"))
27 self._LBL_patient = wx.StaticText(self, wx.ID_ANY, "")
28 self._PRW_encounter_type = cEncounterTypePhraseWheel(self, wx.ID_ANY, "", style=wx.NO_BORDER)
29 self._PRW_location = cPraxisBranchPhraseWheel(self, wx.ID_ANY, "", style=wx.NO_BORDER)
30 self._PRW_start = cFuzzyTimestampInput(self, wx.ID_ANY, "", style=wx.NO_BORDER)
31 self._PRW_end = cFuzzyTimestampInput(self, wx.ID_ANY, "", style=wx.NO_BORDER)
32 self._TCTRL_rfe = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.NO_BORDER)
33 self._PRW_rfe_codes = cGenericCodesPhraseWheel(self, wx.ID_ANY, "", style=wx.NO_BORDER)
34 self._TCTRL_aoe = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.NO_BORDER)
35 self._PRW_aoe_codes = cGenericCodesPhraseWheel(self, wx.ID_ANY, "", style=wx.NO_BORDER)
36
37 self.__set_properties()
38 self.__do_layout()
39
40
42
43 self.SetScrollRate(10, 10)
44 self._LBL_patient.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, 0, ""))
45 self._PRW_encounter_type.SetToolTipString(_("Select the type of encounter."))
46 self._PRW_location.SetToolTipString(_("Select the praxis branch where this encounter took place."))
47 self._TCTRL_rfe.SetToolTipString(_("Enter the Reason For Encounter here. This is the patient's initial request or purpose of visit which led to the encounter."))
48 self._PRW_rfe_codes.SetToolTipString(_("Codes relevant to the Reason for Encounter\nseparated by \";\"."))
49 self._TCTRL_aoe.SetToolTipString(_("Enter the Encounter Summary here. This is your final assessment of the total encounter across all relevant episodes."))
50 self._PRW_aoe_codes.SetToolTipString(_("Codes relevant to the Assessment of Encounter\nseparated by \";\"."))
51
52
54
55 __szr_main = wx.BoxSizer(wx.VERTICAL)
56 __gszr_encounter_details = wx.FlexGridSizer(9, 2, 2, 5)
57 __szr_patient = wx.BoxSizer(wx.HORIZONTAL)
58 __szr_main.Add(__szr_patient, 0, wx.EXPAND, 0)
59 __szr_main.Add(self._LBL_instructions, 0, wx.TOP | wx.EXPAND, 3)
60 __lbl_patient = wx.StaticText(self, wx.ID_ANY, _("Patient"))
61 __gszr_encounter_details.Add(__lbl_patient, 0, wx.ALIGN_CENTER_VERTICAL, 10)
62 __gszr_encounter_details.Add(self._LBL_patient, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
63 __lbl_type = wx.StaticText(self, wx.ID_ANY, _("Type"))
64 __gszr_encounter_details.Add(__lbl_type, 0, wx.ALIGN_CENTER_VERTICAL, 0)
65 __gszr_encounter_details.Add(self._PRW_encounter_type, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
66 __lbl_location = wx.StaticText(self, wx.ID_ANY, _("Location"))
67 __gszr_encounter_details.Add(__lbl_location, 0, wx.ALIGN_CENTER_VERTICAL, 0)
68 __gszr_encounter_details.Add(self._PRW_location, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
69 __lbl_start = wx.StaticText(self, wx.ID_ANY, _("Started"))
70 __gszr_encounter_details.Add(__lbl_start, 0, wx.ALIGN_CENTER_VERTICAL, 0)
71 __gszr_encounter_details.Add(self._PRW_start, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
72 __lbl_end = wx.StaticText(self, wx.ID_ANY, _("Ended"))
73 __gszr_encounter_details.Add(__lbl_end, 0, wx.ALIGN_CENTER_VERTICAL, 0)
74 __gszr_encounter_details.Add(self._PRW_end, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
75 __lbl_rfe = wx.StaticText(self, wx.ID_ANY, _("Purpose"))
76 __gszr_encounter_details.Add(__lbl_rfe, 0, wx.ALIGN_CENTER_VERTICAL, 0)
77 __gszr_encounter_details.Add(self._TCTRL_rfe, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
78 __lbl_codes_rfe = wx.StaticText(self, wx.ID_ANY, _("Codes"))
79 __gszr_encounter_details.Add(__lbl_codes_rfe, 0, wx.ALIGN_CENTER_VERTICAL, 0)
80 __gszr_encounter_details.Add(self._PRW_rfe_codes, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
81 __lbl_aoe = wx.StaticText(self, wx.ID_ANY, _("Summary"))
82 __gszr_encounter_details.Add(__lbl_aoe, 0, wx.ALIGN_CENTER_VERTICAL, 0)
83 __gszr_encounter_details.Add(self._TCTRL_aoe, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
84 __lbl_codes_aoe = wx.StaticText(self, wx.ID_ANY, _("Codes"))
85 __gszr_encounter_details.Add(__lbl_codes_aoe, 0, wx.ALIGN_CENTER_VERTICAL, 0)
86 __gszr_encounter_details.Add(self._PRW_aoe_codes, 0, wx.EXPAND | wx.ALIGN_CENTER_VERTICAL, 0)
87 __gszr_encounter_details.AddGrowableCol(1)
88 __szr_main.Add(__gszr_encounter_details, 0, wx.TOP | wx.EXPAND, 3)
89 self.SetSizer(__szr_main)
90 __szr_main.Fit(self)
91
92
93
94