1 | using System;
|
---|
2 | using System.Drawing;
|
---|
3 | using System.Collections;
|
---|
4 | using System.ComponentModel;
|
---|
5 | using System.Windows.Forms;
|
---|
6 | using System.Data;
|
---|
7 | using System.Diagnostics;
|
---|
8 | using IndianHealthService.BMXNet;
|
---|
9 |
|
---|
10 | namespace IndianHealthService.ClinicalScheduling
|
---|
11 | {
|
---|
12 | /// <summary>
|
---|
13 | /// Summary description for DCheckIn.
|
---|
14 | /// </summary>
|
---|
15 | public class DCheckIn : System.Windows.Forms.Form
|
---|
16 | {
|
---|
17 | /// <summary>
|
---|
18 | /// Required designer variable.
|
---|
19 | /// </summary>
|
---|
20 | private System.ComponentModel.Container components = null;
|
---|
21 |
|
---|
22 | public DCheckIn()
|
---|
23 | {
|
---|
24 | //
|
---|
25 | // Required for Windows Form Designer support
|
---|
26 | //
|
---|
27 | InitializeComponent();
|
---|
28 |
|
---|
29 | //
|
---|
30 | // TODO: Add any constructor code after InitializeComponent call
|
---|
31 | //
|
---|
32 | }
|
---|
33 |
|
---|
34 |
|
---|
35 | #region Fields
|
---|
36 | private System.Windows.Forms.Panel pnlPageBottom;
|
---|
37 | private System.Windows.Forms.Button cmdCancel;
|
---|
38 | private System.Windows.Forms.Button cmdOK;
|
---|
39 | private System.Windows.Forms.Panel pnlDescription;
|
---|
40 | private System.Windows.Forms.GroupBox grpDescriptionResourceGroup;
|
---|
41 | private System.Windows.Forms.Label lblDescriptionResourceGroup;
|
---|
42 | private System.Windows.Forms.Label label1;
|
---|
43 | private System.Windows.Forms.DateTimePicker dtpCheckIn;
|
---|
44 | private System.Windows.Forms.Label lblAlready;
|
---|
45 | private System.Windows.Forms.Label label3;
|
---|
46 | private System.Windows.Forms.Label lblPatientName;
|
---|
47 | private System.Windows.Forms.Label label2;
|
---|
48 | private System.Windows.Forms.ComboBox cboProvider;
|
---|
49 | private System.Windows.Forms.ComboBox cboStopCode;
|
---|
50 | private System.Windows.Forms.Label lblStopCode;
|
---|
51 | private System.Windows.Forms.CheckBox chkRoutingSlip;
|
---|
52 | private System.Windows.Forms.GroupBox grpPCCPlus;
|
---|
53 | private System.Windows.Forms.ComboBox cboPCCPlusClinic;
|
---|
54 | private System.Windows.Forms.Label label4;
|
---|
55 | private System.Windows.Forms.ComboBox cboPCCPlusForm;
|
---|
56 | private System.Windows.Forms.Label label5;
|
---|
57 | private System.Windows.Forms.CheckBox chkPCCOutGuide;
|
---|
58 |
|
---|
59 | private string m_sPatientName;
|
---|
60 | private DateTime m_dCheckIn;
|
---|
61 | private string m_sProvider;
|
---|
62 | private string m_sProviderIEN;
|
---|
63 | private string m_sStopCode;
|
---|
64 | private string m_sStopCodeIEN;
|
---|
65 | private CGDocumentManager m_DocManager;
|
---|
66 | private DataSet m_dsGlobal;
|
---|
67 | private DataTable m_dtProvider;
|
---|
68 | private DataView m_dvCS;
|
---|
69 | private bool m_bProviderRequired;
|
---|
70 | private DataTable m_dtClinic;
|
---|
71 | private DataTable m_dtForm;
|
---|
72 | private DataView m_dvClinic;
|
---|
73 | private DataView m_dvForm;
|
---|
74 | private bool m_bInit;
|
---|
75 | public bool m_bPrintRouteSlip;
|
---|
76 | private DateTime m_dAuxTime;
|
---|
77 |
|
---|
78 | /*
|
---|
79 | * PCC Variables
|
---|
80 | */
|
---|
81 | private bool m_bPCC;
|
---|
82 | private string m_sPCCClinicIEN;
|
---|
83 | private string m_sPCCFormIEN;
|
---|
84 | private bool m_bPCCOutGuide;
|
---|
85 |
|
---|
86 | #endregion Fields
|
---|
87 |
|
---|
88 | #region Properties
|
---|
89 |
|
---|
90 | /// <summary>
|
---|
91 | /// Returns string representation of internal entry number of Provider in PROVIDER File
|
---|
92 | /// </summary>
|
---|
93 | public string ProviderIEN
|
---|
94 | {
|
---|
95 | get
|
---|
96 | {
|
---|
97 | return this.m_sProviderIEN;
|
---|
98 | }
|
---|
99 | }
|
---|
100 |
|
---|
101 | /// <summary>
|
---|
102 | /// Returns string representation of IEN of Clinic in VEN EHP CLINIC file
|
---|
103 | /// </summary>
|
---|
104 | public string PCCClinicIEN
|
---|
105 | {
|
---|
106 | get
|
---|
107 | {
|
---|
108 | return this.m_sPCCClinicIEN;
|
---|
109 | }
|
---|
110 | }
|
---|
111 |
|
---|
112 | /// <summary>
|
---|
113 | /// Returns string representation of IEN of template entry in VEN PCC TEMPLATE
|
---|
114 | /// </summary>
|
---|
115 | public string PCCFormIEN
|
---|
116 | {
|
---|
117 | get
|
---|
118 | {
|
---|
119 | return m_sPCCFormIEN;
|
---|
120 | }
|
---|
121 | }
|
---|
122 |
|
---|
123 | /// <summary>
|
---|
124 | /// Returns 'true' if outguide to be printed; otherwise returns 'false'
|
---|
125 | /// </summary>
|
---|
126 | public string PCCOutGuide
|
---|
127 | {
|
---|
128 | get
|
---|
129 | {
|
---|
130 | string sRet = (this.m_bPCCOutGuide == true) ? "true" : "false";
|
---|
131 | return sRet;
|
---|
132 | }
|
---|
133 | }
|
---|
134 |
|
---|
135 | /// <summary>
|
---|
136 | /// Returns string representation of IEN of CLINIC STOP
|
---|
137 | /// </summary>
|
---|
138 | public string ClinicStopIEN
|
---|
139 | {
|
---|
140 | get
|
---|
141 | {
|
---|
142 | return this.m_sStopCodeIEN;
|
---|
143 | }
|
---|
144 | }
|
---|
145 |
|
---|
146 | /// <summary>
|
---|
147 | /// Returns 'true' if routing slip to be printed; otherwise 'false'
|
---|
148 | /// </summary>
|
---|
149 | public string PrintRouteSlip
|
---|
150 | {
|
---|
151 | get
|
---|
152 | {
|
---|
153 | string sRet = (this.m_bPrintRouteSlip == true) ? "true" : "false";
|
---|
154 | return sRet;
|
---|
155 | }
|
---|
156 | }
|
---|
157 |
|
---|
158 | /// <summary>
|
---|
159 | /// Appointment checkin time
|
---|
160 | /// </summary>
|
---|
161 | public DateTime CheckInTime
|
---|
162 | {
|
---|
163 | get
|
---|
164 | {
|
---|
165 | return m_dCheckIn;
|
---|
166 | }
|
---|
167 | set
|
---|
168 | {
|
---|
169 | m_dCheckIn = value;
|
---|
170 | }
|
---|
171 | }
|
---|
172 |
|
---|
173 | /// <summary>
|
---|
174 | /// Appointment end time
|
---|
175 | /// </summary>
|
---|
176 | public DateTime AuxTime
|
---|
177 | {
|
---|
178 | get
|
---|
179 | {
|
---|
180 | return m_dAuxTime;
|
---|
181 | }
|
---|
182 | set
|
---|
183 | {
|
---|
184 | m_dAuxTime = value;
|
---|
185 | }
|
---|
186 | }
|
---|
187 | #endregion Properties
|
---|
188 |
|
---|
189 | #region Methods
|
---|
190 |
|
---|
191 | /// <summary>
|
---|
192 | /// Fill memeber variables before showing dialog
|
---|
193 | /// </summary>
|
---|
194 | /// <param name="a">Appointment</param>
|
---|
195 | /// <param name="docManager">Document Manager</param>
|
---|
196 | /// <param name="sDefaultProvider">Default provider</param>
|
---|
197 | /// <param name="bProviderRequired">not used</param>
|
---|
198 | /// <param name="bGeneratePCCPlus">not used</param>
|
---|
199 | /// <param name="bMultCodes">not used</param>
|
---|
200 | /// <param name="sStopCode">Stop Code</param>
|
---|
201 | public void InitializePage(CGAppointment a, CGDocumentManager docManager,
|
---|
202 | string sDefaultProvider, bool bProviderRequired, bool bGeneratePCCPlus,
|
---|
203 | bool bMultCodes, string sStopCode, int nHospLoc)
|
---|
204 | {
|
---|
205 | m_bInit = true;
|
---|
206 | m_DocManager = docManager;
|
---|
207 | m_dsGlobal = m_DocManager.GlobalDataSet;
|
---|
208 | int nFind = 0;
|
---|
209 |
|
---|
210 | //Provider processing
|
---|
211 | m_bProviderRequired = bProviderRequired; //not used in VISTA --remove
|
---|
212 |
|
---|
213 | //smh new code
|
---|
214 | //if the resource is linked to a valid hospital location, grab this locations providers
|
---|
215 | //from the provider multiple and put them in the combo box.
|
---|
216 | if (nHospLoc != 0)
|
---|
217 | {
|
---|
218 | //RPC BSDX HOSP LOC PROVIDERS returns Table w/ Columns:
|
---|
219 | //HOSPITAL_LOCATION_ID^BMXIEN (ie Prov IEN)^NAME^DEFALUT
|
---|
220 | string sCommandText = "BSDX HOSP LOC PROVIDERS^" + nHospLoc;
|
---|
221 | m_dtProvider = docManager.RPMSDataTable(sCommandText, "ClinicProviders");
|
---|
222 | m_dtProvider.DefaultView.Sort = "NAME ASC";
|
---|
223 |
|
---|
224 | cboProvider.DataSource = m_dtProvider;
|
---|
225 | cboProvider.DisplayMember = "NAME";
|
---|
226 | cboProvider.ValueMember = "BMXIEN";
|
---|
227 |
|
---|
228 | //Add None to the top of the list
|
---|
229 | DataRow drProv = m_dtProvider.NewRow();
|
---|
230 | drProv.BeginEdit();
|
---|
231 | drProv["HOSPITAL_LOCATION_ID"] = 0;
|
---|
232 | drProv["NAME"] = "<None>";
|
---|
233 | drProv["BMXIEN"] = 0;
|
---|
234 | drProv.EndEdit();
|
---|
235 | m_dtProvider.Rows.InsertAt(drProv, 0);
|
---|
236 | cboProvider.SelectedIndex = 0;
|
---|
237 |
|
---|
238 | //Find default provider--search for Yes in Field DEFAULT
|
---|
239 | DataRow[] nRow = m_dtProvider.Select("DEFAULT='YES'", "NAME ASC");
|
---|
240 | if (nRow.Length > 0) nFind = m_dtProvider.Rows.IndexOf(nRow[0]);
|
---|
241 | cboProvider.SelectedIndex = nFind;
|
---|
242 | }
|
---|
243 | else
|
---|
244 | {
|
---|
245 | m_dtProvider = m_dsGlobal.Tables["Provider"];
|
---|
246 | m_dtProvider.DefaultView.Sort = "NAME ASC";
|
---|
247 |
|
---|
248 | cboProvider.DataSource = m_dtProvider;
|
---|
249 | cboProvider.DisplayMember = "NAME";
|
---|
250 | cboProvider.ValueMember = "BMXIEN";
|
---|
251 |
|
---|
252 | //Add None to the top of the list
|
---|
253 | DataRow drProv = m_dtProvider.NewRow();
|
---|
254 | drProv.BeginEdit();
|
---|
255 | drProv["NAME"] = "<None>";
|
---|
256 | drProv["BMXIEN"] = 0;
|
---|
257 | drProv.EndEdit();
|
---|
258 | m_dtProvider.Rows.InsertAt(drProv, 0);
|
---|
259 | cboProvider.SelectedIndex = 0;
|
---|
260 | }
|
---|
261 |
|
---|
262 |
|
---|
263 | //Stop code processing
|
---|
264 | this.lblStopCode.Visible = false;
|
---|
265 | this.cboStopCode.Visible = false;
|
---|
266 | m_dvCS = new DataView(m_dsGlobal.Tables["ClinicStop"]);
|
---|
267 | m_dvCS.Sort = "NAME ASC";
|
---|
268 | m_sStopCode = sStopCode;
|
---|
269 | m_sStopCodeIEN = "";
|
---|
270 | if (m_sStopCode != "")
|
---|
271 | {
|
---|
272 | //Get the IEN of the clinic stop code
|
---|
273 | nFind = m_dvCS.Find((string)m_sStopCode);
|
---|
274 | Debug.Assert(nFind > -1);
|
---|
275 | if (nFind > -1)
|
---|
276 | {
|
---|
277 | m_sStopCodeIEN = m_dvCS[nFind].Row["BMXIEN"].ToString();
|
---|
278 | }
|
---|
279 | }
|
---|
280 |
|
---|
281 | if (bMultCodes == true)
|
---|
282 | {
|
---|
283 | this.lblStopCode.Visible = true;
|
---|
284 | this.cboStopCode.Visible = true;
|
---|
285 | cboStopCode.DataSource = m_dvCS;
|
---|
286 | cboStopCode.DisplayMember = "NAME";
|
---|
287 | cboStopCode.ValueMember = "BMXIEN";
|
---|
288 | if (m_sStopCode != "")
|
---|
289 | {
|
---|
290 | nFind = m_dvCS.Find((string)m_sStopCode);
|
---|
291 | cboStopCode.SelectedIndex = nFind;
|
---|
292 | }
|
---|
293 | }
|
---|
294 |
|
---|
295 | m_bPCC = bGeneratePCCPlus;
|
---|
296 | PCCPlus();
|
---|
297 |
|
---|
298 | m_sPatientName = a.PatientName;
|
---|
299 | if (a.CheckInTime.Ticks != 0)
|
---|
300 | {
|
---|
301 | m_dCheckIn = a.CheckInTime;
|
---|
302 | dtpCheckIn.Enabled = false;
|
---|
303 | this.cboProvider.Enabled = false;
|
---|
304 | lblAlready.Visible = true;
|
---|
305 | }
|
---|
306 | else
|
---|
307 | {
|
---|
308 | m_dCheckIn = DateTime.Now;
|
---|
309 | }
|
---|
310 | UpdateDialogData(true);
|
---|
311 | m_bInit = false;
|
---|
312 |
|
---|
313 | //Synchronize PCCForm with Clinic
|
---|
314 | if (m_bPCC == true)
|
---|
315 | {
|
---|
316 | cboPCCPlusClinic_SelectedIndexChanged(this, new System.EventArgs());
|
---|
317 | }
|
---|
318 | }
|
---|
319 |
|
---|
320 | /// <summary>
|
---|
321 | /// Not used in VISTA. Needs to be removed
|
---|
322 | /// <remarks>Not used in VISTA.</remarks>
|
---|
323 | /// </summary>
|
---|
324 | private void PCCPlus()
|
---|
325 | {
|
---|
326 | //PCCPlus processing
|
---|
327 | /*Can't do PCCPlus if no stop code
|
---|
328 | * or if PRINT PCC PLUS FORM field in CLINIC SETUP PARAMETERS is false
|
---|
329 | */
|
---|
330 | if ((m_bPCC == false) || (m_sStopCode == ""))
|
---|
331 | {
|
---|
332 | grpPCCPlus.Enabled = false;
|
---|
333 | return;
|
---|
334 | }
|
---|
335 | else
|
---|
336 | {
|
---|
337 | grpPCCPlus.Enabled = true;
|
---|
338 | //Populate combo box with recordset of clinics based on m_sStopCode
|
---|
339 | string sCmd = "SELECT BMXIEN, NAME, DEPARTMENT, DEFAULT_ENCOUNTER_FORM, NEVER_PRINT_OUTGUIDE FROM VEN_EHP_CLINIC WHERE DEPARTMENT = '" + m_sStopCode + "'";
|
---|
340 | m_dtClinic = m_DocManager.ConnectInfo.RPMSDataTable(sCmd, "CLINIC");
|
---|
341 | m_dvClinic = new DataView(m_dtClinic);
|
---|
342 | m_dvClinic.Sort = "NAME ASC";
|
---|
343 |
|
---|
344 | cboPCCPlusClinic.DataSource = m_dvClinic;
|
---|
345 | cboPCCPlusClinic.DisplayMember = "NAME";
|
---|
346 | cboPCCPlusClinic.ValueMember = "BMXIEN";
|
---|
347 |
|
---|
348 |
|
---|
349 | //Populate combo box with recordset of all forms
|
---|
350 | sCmd = "SELECT BMXIEN, TEMPLATE FROM VEN_EHP_EF_TEMPLATES";
|
---|
351 | m_dtForm = m_DocManager.ConnectInfo.RPMSDataTable(sCmd, "FORM");
|
---|
352 | m_dvForm = new DataView(m_dtForm);
|
---|
353 | m_dvForm.Sort = "TEMPLATE ASC";
|
---|
354 |
|
---|
355 | cboPCCPlusForm.DataSource = m_dvForm;
|
---|
356 | cboPCCPlusForm.DisplayMember = "TEMPLATE";
|
---|
357 | cboPCCPlusForm.ValueMember = "BMXIEN";
|
---|
358 |
|
---|
359 | if ((m_dtClinic.Rows.Count == 0) || (m_dtForm.Rows.Count == 0))
|
---|
360 | {
|
---|
361 | //No PCCPlus clinics for current stop code
|
---|
362 | //or no forms available
|
---|
363 | grpPCCPlus.Enabled = false;
|
---|
364 | return;
|
---|
365 | }
|
---|
366 |
|
---|
367 | cboPCCPlusClinic.SelectedIndex = 0;
|
---|
368 | cboPCCPlusClinic_SelectedIndexChanged(this, new System.EventArgs());
|
---|
369 |
|
---|
370 | }
|
---|
371 | }
|
---|
372 |
|
---|
373 | /// <summary>
|
---|
374 | /// If b is true, moves member vars into control data
|
---|
375 | /// otherwise, moves control data into member vars
|
---|
376 | /// </summary>
|
---|
377 | /// <param name="b"></param>
|
---|
378 | private void UpdateDialogData(bool b)
|
---|
379 | {
|
---|
380 | if (b == true) //Move data to dialog controls from member variables
|
---|
381 | {
|
---|
382 | this.lblPatientName.Text = m_sPatientName;
|
---|
383 | this.dtpCheckIn.Value = m_dCheckIn;
|
---|
384 | }
|
---|
385 | else //Move data to member variables from dialog controls
|
---|
386 | {
|
---|
387 |
|
---|
388 | /*
|
---|
389 | * Need to return Provider, ClinicStop, PrintRouteSlip,
|
---|
390 | * PCC Clinic, PCC Form, Print OutGuide
|
---|
391 | */
|
---|
392 |
|
---|
393 | m_dCheckIn = this.dtpCheckIn.Value;
|
---|
394 | m_sProviderIEN = this.cboProvider.SelectedValue.ToString();
|
---|
395 | m_bPrintRouteSlip = chkRoutingSlip.Checked;
|
---|
396 |
|
---|
397 | /*
|
---|
398 | * Don't get value from CLINIC STOP combo since
|
---|
399 | * it may not be enabled, and
|
---|
400 | * it updates the member variable whenever the selection changes
|
---|
401 | */
|
---|
402 |
|
---|
403 | /*
|
---|
404 | * PCCPlus
|
---|
405 | */
|
---|
406 |
|
---|
407 | if (grpPCCPlus.Enabled == false)
|
---|
408 | {
|
---|
409 | m_bPCC = false;
|
---|
410 | m_sPCCClinicIEN = "";
|
---|
411 | m_sPCCFormIEN = "";
|
---|
412 | m_bPCCOutGuide = false;
|
---|
413 | }
|
---|
414 | else
|
---|
415 | {
|
---|
416 | m_bPCC = true;
|
---|
417 | m_sPCCClinicIEN = this.cboPCCPlusClinic.SelectedValue.ToString();
|
---|
418 | m_sPCCFormIEN = this.cboPCCPlusForm.SelectedValue.ToString();
|
---|
419 | if (chkPCCOutGuide.Enabled == false)
|
---|
420 | {
|
---|
421 | m_bPCCOutGuide = false;
|
---|
422 | }
|
---|
423 | else
|
---|
424 | {
|
---|
425 | m_bPCCOutGuide = this.chkPCCOutGuide.Checked;
|
---|
426 | }
|
---|
427 | }
|
---|
428 |
|
---|
429 | }
|
---|
430 | }
|
---|
431 |
|
---|
432 | /// <summary>
|
---|
433 | /// Clean up any resources being used.
|
---|
434 | /// </summary>
|
---|
435 | protected override void Dispose(bool disposing)
|
---|
436 | {
|
---|
437 | if (disposing)
|
---|
438 | {
|
---|
439 | if (components != null)
|
---|
440 | {
|
---|
441 | components.Dispose();
|
---|
442 | }
|
---|
443 | }
|
---|
444 | base.Dispose(disposing);
|
---|
445 | }
|
---|
446 | #endregion Methods
|
---|
447 |
|
---|
448 | #region Windows Form Designer generated code
|
---|
449 | /// <summary>
|
---|
450 | /// Required method for Designer support - do not modify
|
---|
451 | /// the contents of this method with the code editor.
|
---|
452 | /// </summary>
|
---|
453 | private void InitializeComponent()
|
---|
454 | {
|
---|
455 | this.pnlPageBottom = new System.Windows.Forms.Panel();
|
---|
456 | this.cmdCancel = new System.Windows.Forms.Button();
|
---|
457 | this.cmdOK = new System.Windows.Forms.Button();
|
---|
458 | this.pnlDescription = new System.Windows.Forms.Panel();
|
---|
459 | this.grpDescriptionResourceGroup = new System.Windows.Forms.GroupBox();
|
---|
460 | this.lblDescriptionResourceGroup = new System.Windows.Forms.Label();
|
---|
461 | this.label1 = new System.Windows.Forms.Label();
|
---|
462 | this.dtpCheckIn = new System.Windows.Forms.DateTimePicker();
|
---|
463 | this.lblAlready = new System.Windows.Forms.Label();
|
---|
464 | this.label3 = new System.Windows.Forms.Label();
|
---|
465 | this.lblPatientName = new System.Windows.Forms.Label();
|
---|
466 | this.cboProvider = new System.Windows.Forms.ComboBox();
|
---|
467 | this.label2 = new System.Windows.Forms.Label();
|
---|
468 | this.cboStopCode = new System.Windows.Forms.ComboBox();
|
---|
469 | this.lblStopCode = new System.Windows.Forms.Label();
|
---|
470 | this.chkRoutingSlip = new System.Windows.Forms.CheckBox();
|
---|
471 | this.grpPCCPlus = new System.Windows.Forms.GroupBox();
|
---|
472 | this.chkPCCOutGuide = new System.Windows.Forms.CheckBox();
|
---|
473 | this.label4 = new System.Windows.Forms.Label();
|
---|
474 | this.cboPCCPlusClinic = new System.Windows.Forms.ComboBox();
|
---|
475 | this.cboPCCPlusForm = new System.Windows.Forms.ComboBox();
|
---|
476 | this.label5 = new System.Windows.Forms.Label();
|
---|
477 | this.pnlPageBottom.SuspendLayout();
|
---|
478 | this.pnlDescription.SuspendLayout();
|
---|
479 | this.grpDescriptionResourceGroup.SuspendLayout();
|
---|
480 | this.grpPCCPlus.SuspendLayout();
|
---|
481 | this.SuspendLayout();
|
---|
482 | //
|
---|
483 | // pnlPageBottom
|
---|
484 | //
|
---|
485 | this.pnlPageBottom.Controls.Add(this.cmdCancel);
|
---|
486 | this.pnlPageBottom.Controls.Add(this.cmdOK);
|
---|
487 | this.pnlPageBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
|
---|
488 | this.pnlPageBottom.Location = new System.Drawing.Point(0, 360);
|
---|
489 | this.pnlPageBottom.Name = "pnlPageBottom";
|
---|
490 | this.pnlPageBottom.Size = new System.Drawing.Size(520, 40);
|
---|
491 | this.pnlPageBottom.TabIndex = 5;
|
---|
492 | //
|
---|
493 | // cmdCancel
|
---|
494 | //
|
---|
495 | this.cmdCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
---|
496 | this.cmdCancel.Location = new System.Drawing.Point(440, 8);
|
---|
497 | this.cmdCancel.Name = "cmdCancel";
|
---|
498 | this.cmdCancel.Size = new System.Drawing.Size(56, 24);
|
---|
499 | this.cmdCancel.TabIndex = 2;
|
---|
500 | this.cmdCancel.Text = "Cancel";
|
---|
501 | //
|
---|
502 | // cmdOK
|
---|
503 | //
|
---|
504 | this.cmdOK.DialogResult = System.Windows.Forms.DialogResult.OK;
|
---|
505 | this.cmdOK.Location = new System.Drawing.Point(360, 8);
|
---|
506 | this.cmdOK.Name = "cmdOK";
|
---|
507 | this.cmdOK.Size = new System.Drawing.Size(64, 24);
|
---|
508 | this.cmdOK.TabIndex = 1;
|
---|
509 | this.cmdOK.Text = "OK";
|
---|
510 | this.cmdOK.Click += new System.EventHandler(this.cmdOK_Click);
|
---|
511 | //
|
---|
512 | // pnlDescription
|
---|
513 | //
|
---|
514 | this.pnlDescription.Controls.Add(this.grpDescriptionResourceGroup);
|
---|
515 | this.pnlDescription.Dock = System.Windows.Forms.DockStyle.Bottom;
|
---|
516 | this.pnlDescription.Location = new System.Drawing.Point(0, 288);
|
---|
517 | this.pnlDescription.Name = "pnlDescription";
|
---|
518 | this.pnlDescription.Size = new System.Drawing.Size(520, 72);
|
---|
519 | this.pnlDescription.TabIndex = 6;
|
---|
520 | //
|
---|
521 | // grpDescriptionResourceGroup
|
---|
522 | //
|
---|
523 | this.grpDescriptionResourceGroup.Controls.Add(this.lblDescriptionResourceGroup);
|
---|
524 | this.grpDescriptionResourceGroup.Dock = System.Windows.Forms.DockStyle.Fill;
|
---|
525 | this.grpDescriptionResourceGroup.Location = new System.Drawing.Point(0, 0);
|
---|
526 | this.grpDescriptionResourceGroup.Name = "grpDescriptionResourceGroup";
|
---|
527 | this.grpDescriptionResourceGroup.Size = new System.Drawing.Size(520, 72);
|
---|
528 | this.grpDescriptionResourceGroup.TabIndex = 1;
|
---|
529 | this.grpDescriptionResourceGroup.TabStop = false;
|
---|
530 | this.grpDescriptionResourceGroup.Text = "Description";
|
---|
531 | //
|
---|
532 | // lblDescriptionResourceGroup
|
---|
533 | //
|
---|
534 | this.lblDescriptionResourceGroup.Dock = System.Windows.Forms.DockStyle.Fill;
|
---|
535 | this.lblDescriptionResourceGroup.Location = new System.Drawing.Point(3, 16);
|
---|
536 | this.lblDescriptionResourceGroup.Name = "lblDescriptionResourceGroup";
|
---|
537 | this.lblDescriptionResourceGroup.Size = new System.Drawing.Size(514, 53);
|
---|
538 | this.lblDescriptionResourceGroup.TabIndex = 0;
|
---|
539 | this.lblDescriptionResourceGroup.Text = "Use this panel to check in an appointment. A PCC visit will automatically be crea" +
|
---|
540 | "ted for this patient at the check in date and time if the clinic is set up to cr" +
|
---|
541 | "eate a visit at checkin. A patient may only be checked-in once.";
|
---|
542 | //
|
---|
543 | // label1
|
---|
544 | //
|
---|
545 | this.label1.Location = new System.Drawing.Point(16, 16);
|
---|
546 | this.label1.Name = "label1";
|
---|
547 | this.label1.Size = new System.Drawing.Size(80, 16);
|
---|
548 | this.label1.TabIndex = 7;
|
---|
549 | this.label1.Text = "Patient Name:";
|
---|
550 | //
|
---|
551 | // dtpCheckIn
|
---|
552 | //
|
---|
553 | this.dtpCheckIn.AllowDrop = true;
|
---|
554 | this.dtpCheckIn.CustomFormat = "MMMM dd yyyy H:mm";
|
---|
555 | this.dtpCheckIn.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
|
---|
556 | this.dtpCheckIn.Location = new System.Drawing.Point(96, 48);
|
---|
557 | this.dtpCheckIn.Name = "dtpCheckIn";
|
---|
558 | this.dtpCheckIn.ShowUpDown = true;
|
---|
559 | this.dtpCheckIn.Size = new System.Drawing.Size(176, 20);
|
---|
560 | this.dtpCheckIn.TabIndex = 9;
|
---|
561 | //
|
---|
562 | // lblAlready
|
---|
563 | //
|
---|
564 | this.lblAlready.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
|
---|
565 | this.lblAlready.ForeColor = System.Drawing.Color.Green;
|
---|
566 | this.lblAlready.Location = new System.Drawing.Point(288, 40);
|
---|
567 | this.lblAlready.Name = "lblAlready";
|
---|
568 | this.lblAlready.Size = new System.Drawing.Size(192, 32);
|
---|
569 | this.lblAlready.TabIndex = 10;
|
---|
570 | this.lblAlready.Text = "This Patient is already checked in.";
|
---|
571 | this.lblAlready.Visible = false;
|
---|
572 | //
|
---|
573 | // label3
|
---|
574 | //
|
---|
575 | this.label3.Location = new System.Drawing.Point(16, 48);
|
---|
576 | this.label3.Name = "label3";
|
---|
577 | this.label3.Size = new System.Drawing.Size(80, 16);
|
---|
578 | this.label3.TabIndex = 7;
|
---|
579 | this.label3.Text = "CheckIn Time:";
|
---|
580 | //
|
---|
581 | // lblPatientName
|
---|
582 | //
|
---|
583 | this.lblPatientName.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
|
---|
584 | this.lblPatientName.Location = new System.Drawing.Point(96, 16);
|
---|
585 | this.lblPatientName.Name = "lblPatientName";
|
---|
586 | this.lblPatientName.Size = new System.Drawing.Size(256, 16);
|
---|
587 | this.lblPatientName.TabIndex = 11;
|
---|
588 | //
|
---|
589 | // cboProvider
|
---|
590 | //
|
---|
591 | this.cboProvider.Location = new System.Drawing.Point(96, 88);
|
---|
592 | this.cboProvider.Name = "cboProvider";
|
---|
593 | this.cboProvider.Size = new System.Drawing.Size(240, 21);
|
---|
594 | this.cboProvider.TabIndex = 12;
|
---|
595 | //
|
---|
596 | // label2
|
---|
597 | //
|
---|
598 | this.label2.Location = new System.Drawing.Point(16, 88);
|
---|
599 | this.label2.Name = "label2";
|
---|
600 | this.label2.Size = new System.Drawing.Size(80, 16);
|
---|
601 | this.label2.TabIndex = 7;
|
---|
602 | this.label2.Text = "Visit Provider:";
|
---|
603 | //
|
---|
604 | // cboStopCode
|
---|
605 | //
|
---|
606 | this.cboStopCode.Location = new System.Drawing.Point(96, 128);
|
---|
607 | this.cboStopCode.Name = "cboStopCode";
|
---|
608 | this.cboStopCode.Size = new System.Drawing.Size(240, 21);
|
---|
609 | this.cboStopCode.TabIndex = 13;
|
---|
610 | this.cboStopCode.SelectedIndexChanged += new System.EventHandler(this.cboStopCode_SelectedIndexChanged);
|
---|
611 | //
|
---|
612 | // lblStopCode
|
---|
613 | //
|
---|
614 | this.lblStopCode.Location = new System.Drawing.Point(16, 128);
|
---|
615 | this.lblStopCode.Name = "lblStopCode";
|
---|
616 | this.lblStopCode.Size = new System.Drawing.Size(80, 16);
|
---|
617 | this.lblStopCode.TabIndex = 7;
|
---|
618 | this.lblStopCode.Text = "Stop Code:";
|
---|
619 | //
|
---|
620 | // chkRoutingSlip
|
---|
621 | //
|
---|
622 | this.chkRoutingSlip.Location = new System.Drawing.Point(368, 88);
|
---|
623 | this.chkRoutingSlip.Name = "chkRoutingSlip";
|
---|
624 | this.chkRoutingSlip.Size = new System.Drawing.Size(128, 16);
|
---|
625 | this.chkRoutingSlip.TabIndex = 14;
|
---|
626 | this.chkRoutingSlip.Text = "Print Routing Slip";
|
---|
627 | //
|
---|
628 | // grpPCCPlus
|
---|
629 | //
|
---|
630 | this.grpPCCPlus.Controls.Add(this.chkPCCOutGuide);
|
---|
631 | this.grpPCCPlus.Controls.Add(this.label4);
|
---|
632 | this.grpPCCPlus.Controls.Add(this.cboPCCPlusClinic);
|
---|
633 | this.grpPCCPlus.Controls.Add(this.cboPCCPlusForm);
|
---|
634 | this.grpPCCPlus.Controls.Add(this.label5);
|
---|
635 | this.grpPCCPlus.Location = new System.Drawing.Point(8, 168);
|
---|
636 | this.grpPCCPlus.Name = "grpPCCPlus";
|
---|
637 | this.grpPCCPlus.Size = new System.Drawing.Size(488, 104);
|
---|
638 | this.grpPCCPlus.TabIndex = 15;
|
---|
639 | this.grpPCCPlus.TabStop = false;
|
---|
640 | this.grpPCCPlus.Text = "PCC Plus";
|
---|
641 | //
|
---|
642 | // chkPCCOutGuide
|
---|
643 | //
|
---|
644 | this.chkPCCOutGuide.Location = new System.Drawing.Point(360, 24);
|
---|
645 | this.chkPCCOutGuide.Name = "chkPCCOutGuide";
|
---|
646 | this.chkPCCOutGuide.Size = new System.Drawing.Size(96, 16);
|
---|
647 | this.chkPCCOutGuide.TabIndex = 15;
|
---|
648 | this.chkPCCOutGuide.Text = "Print Outguide";
|
---|
649 | //
|
---|
650 | // label4
|
---|
651 | //
|
---|
652 | this.label4.Location = new System.Drawing.Point(8, 24);
|
---|
653 | this.label4.Name = "label4";
|
---|
654 | this.label4.Size = new System.Drawing.Size(72, 16);
|
---|
655 | this.label4.TabIndex = 8;
|
---|
656 | this.label4.Text = "PCC+ Clinic:";
|
---|
657 | //
|
---|
658 | // cboPCCPlusClinic
|
---|
659 | //
|
---|
660 | this.cboPCCPlusClinic.Location = new System.Drawing.Point(88, 24);
|
---|
661 | this.cboPCCPlusClinic.Name = "cboPCCPlusClinic";
|
---|
662 | this.cboPCCPlusClinic.Size = new System.Drawing.Size(240, 21);
|
---|
663 | this.cboPCCPlusClinic.TabIndex = 0;
|
---|
664 | this.cboPCCPlusClinic.SelectedIndexChanged += new System.EventHandler(this.cboPCCPlusClinic_SelectedIndexChanged);
|
---|
665 | //
|
---|
666 | // cboPCCPlusForm
|
---|
667 | //
|
---|
668 | this.cboPCCPlusForm.Location = new System.Drawing.Point(88, 64);
|
---|
669 | this.cboPCCPlusForm.Name = "cboPCCPlusForm";
|
---|
670 | this.cboPCCPlusForm.Size = new System.Drawing.Size(240, 21);
|
---|
671 | this.cboPCCPlusForm.TabIndex = 0;
|
---|
672 | //
|
---|
673 | // label5
|
---|
674 | //
|
---|
675 | this.label5.Location = new System.Drawing.Point(8, 64);
|
---|
676 | this.label5.Name = "label5";
|
---|
677 | this.label5.Size = new System.Drawing.Size(72, 16);
|
---|
678 | this.label5.TabIndex = 8;
|
---|
679 | this.label5.Text = "PCC+ Form:";
|
---|
680 | //
|
---|
681 | // DCheckIn
|
---|
682 | //
|
---|
683 | this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
|
---|
684 | this.ClientSize = new System.Drawing.Size(520, 400);
|
---|
685 | this.Controls.Add(this.grpPCCPlus);
|
---|
686 | this.Controls.Add(this.chkRoutingSlip);
|
---|
687 | this.Controls.Add(this.cboStopCode);
|
---|
688 | this.Controls.Add(this.cboProvider);
|
---|
689 | this.Controls.Add(this.lblPatientName);
|
---|
690 | this.Controls.Add(this.lblAlready);
|
---|
691 | this.Controls.Add(this.dtpCheckIn);
|
---|
692 | this.Controls.Add(this.label1);
|
---|
693 | this.Controls.Add(this.pnlDescription);
|
---|
694 | this.Controls.Add(this.pnlPageBottom);
|
---|
695 | this.Controls.Add(this.label3);
|
---|
696 | this.Controls.Add(this.label2);
|
---|
697 | this.Controls.Add(this.lblStopCode);
|
---|
698 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
|
---|
699 | this.Name = "DCheckIn";
|
---|
700 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
---|
701 | this.Text = "Appointment Check In";
|
---|
702 | this.pnlPageBottom.ResumeLayout(false);
|
---|
703 | this.pnlDescription.ResumeLayout(false);
|
---|
704 | this.grpDescriptionResourceGroup.ResumeLayout(false);
|
---|
705 | this.grpPCCPlus.ResumeLayout(false);
|
---|
706 | this.ResumeLayout(false);
|
---|
707 |
|
---|
708 | }
|
---|
709 | #endregion
|
---|
710 |
|
---|
711 | #region Events
|
---|
712 |
|
---|
713 | private void cmdOK_Click(object sender, System.EventArgs e)
|
---|
714 | {
|
---|
715 | this.UpdateDialogData(false);
|
---|
716 | }
|
---|
717 |
|
---|
718 | private void cboStopCode_SelectedIndexChanged(object sender, System.EventArgs e)
|
---|
719 | {
|
---|
720 | /*
|
---|
721 | * Whenever the stop code changes, the set of PCCPlus Clinic Selections change
|
---|
722 | * except during init.
|
---|
723 | */
|
---|
724 | if (m_bInit == true)
|
---|
725 | return;
|
---|
726 |
|
---|
727 | //Change the value of m_sStopCode
|
---|
728 | DataRowView drv = (DataRowView)this.cboStopCode.SelectedItem;
|
---|
729 | string sStopCode = drv.Row["NAME"].ToString();
|
---|
730 | m_sStopCode = sStopCode;
|
---|
731 | m_sStopCodeIEN = drv.Row["BMXIEN"].ToString();
|
---|
732 | PCCPlus();
|
---|
733 | }
|
---|
734 |
|
---|
735 | private void cboPCCPlusClinic_SelectedIndexChanged(object sender, System.EventArgs e)
|
---|
736 | {
|
---|
737 | /*
|
---|
738 | * Whenever the PCCPlus Clinic changes, the default EF TEMPLATE changes
|
---|
739 | */
|
---|
740 | if (m_bInit == true)
|
---|
741 | return;
|
---|
742 |
|
---|
743 | if (this.cboPCCPlusClinic.SelectedItem == null)
|
---|
744 | return;
|
---|
745 |
|
---|
746 | DataRowView drv = (DataRowView)this.cboPCCPlusClinic.SelectedItem;
|
---|
747 | string sDefaultForm = drv.Row["DEFAULT_ENCOUNTER_FORM"].ToString();
|
---|
748 |
|
---|
749 | int nFind = this.m_dvForm.Find(sDefaultForm);
|
---|
750 | if (nFind > -1)
|
---|
751 | {
|
---|
752 | this.cboPCCPlusForm.SelectedIndex = nFind;
|
---|
753 | }
|
---|
754 | }
|
---|
755 | #endregion Events
|
---|
756 |
|
---|
757 |
|
---|
758 | }
|
---|
759 | }
|
---|