phpc#
Here are some of the conversions to C #, how do I go?
Class application_model_checknote{
Private $db;
Private $incheck = ' in_check ';
Private $outcheck = ' out_check ';
Private $table =array (' check_office ' = ' patient_check_office ', ' out_check ' = ' Patient_out_check ',
' In_check ' = ' patient_in_check ', ' check_note ' = ' patient_check_note ', ' Check_note_lab ' and ' Patient_check_ ' Note_lab ',
' Check_note_item ' = ' patient_check_item_note ', ' check_note_lab ' = ' patient_check_note_lab ');
Private $type =array (' in_check ' = ' hospitalization ', ' out_check ' + ' outpatient ');
Private $case =array (' In_check ' =>1, ' Out_check ' =>0);
Private $kind =array (' ECG ' =>0, ' b Super ' =>0, ' color Super ' =>0, ' test ' =>1, ' Radiology ' =>2, ' CT ' =>2, ' MRI ' =>2, ' CR ' =>2, ' DR ' =>2, ' DX ' =>2, ' MR ' =>2);
Public Function __construct () {
}public function Getchecklist ($icno) {return Array_merge ($this->getoutcheck ($icno), $this->getincheck ($ICNO)) ;} Private Function Getoutcheck ($ICNO) {return $this->getcheck ($this->outcheck, $icno);} Private Function Getincheck ($ICNO) {return $this->getcheck ($this->incheck, $icno);} Private Function Getcheck ($type, $icno) {$data =array (); $outsql = "Select B.s_kind,a.n_serial,a.s_check_sn,a.s_check_name,convert (varchar), a.d_check_time,23) as D_ Check_time from ". $this->table[$type]." As a, ". $this->table[' Check_office ']." As B WHERE (A.s_office_check = B.s_code) and (A.s_ic_no = ' ". $icno." ') and (A.s_charge_mark = ' 1 ') "; $res = $this->db->query ($outsql); if (count ($res) >0) {foreach ($res as $r) {$data []=array (' i ' = $this->case[$type], ' type ' = = $this- >type[$type], ' checksn ' = $r [' s_check_sn '], ' kind ' + $r [' s_kind '], ' k ' = $this->kind[$r [' S_kind '], ' Serial ' + $r [' n_serial '], ' checkname ' + $r [' s_check_name '], ' checktime ' = $r [' d_check_time ']); }} return $data;}