Subversion Repository Public Repository

Satyam

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.bestray.labinformationsystem.controller;

import com.bestray.healthcarecommonutil.exception.ProcessingException;
import com.bestray.healthcarecommonutil.service.OrderSpecimenCollectionService;
import com.bestray.healthcarecommonutil.vo.TEncounterProcedure;
import com.bestray.healthcarecommonutil.vo.TPatEncOrderSpecimen;
import com.bestray.healthcarecommonutil.vo.TPatient;
import com.bestray.healthcarecommonutil.vo.TPatientEncounter;
import com.bestray.healthcarecommonutil.vo.TProcedureMaster;
import com.bestray.labinformationsystem.service.LabInformationService;
import java.util.List;
import java.util.Vector;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.orm.hibernate3.HibernateOptimisticLockingFailureException;
import org.springframework.stereotype.Controller;

/**
 *
 * @author User1
 */
@Controller
public class LabInformationController {
    
    @Autowired
    private LabInformationService labInformationService;
    
    @Autowired
    private OrderSpecimenCollectionService orderSpecimenCollectionService;

    /*public LabInformationController(LabInformationService labInformationService, OrderSpecimenCollectionService orderSpecimenCollectionService) {
        this.labInformationService = labInformationService;
        this.orderSpecimenCollectionService = orderSpecimenCollectionService;
    }*/

    public Vector<Vector<String>> getPrescribeOrderList(TPatient patient) throws ProcessingException{
        try{
        return labInformationService.getPrescribeOrderList(patient);
        }catch(ProcessingException e){
            throw e;
        }
    } 
    
     public Vector<Vector<String>> getComponentListByProcedure(TEncounterProcedure orderDetails,TPatientEncounter encounter) throws ProcessingException{
        try{
        return labInformationService.getComponentListByProcedure(orderDetails,encounter);
        }catch(ProcessingException e){
            throw e;
        }
    } 
     
     public void saveSpecimenDetails(TPatEncOrderSpecimen patEncOrderSpecimen)throws ProcessingException{
        try{
            orderSpecimenCollectionService.saveSpecimenDetails(patEncOrderSpecimen);
        }catch(ProcessingException e){
            throw e;
        }
    }
     
     public Long saveProcedureEncounter(TEncounterProcedure encounterProcedure)throws ProcessingException{
        try{
            return labInformationService.saveProcedureEncounter(encounterProcedure);
        }catch(ProcessingException e){
            throw e;
        }
    }
     
     public void deleteProcedureEncounter(TProcedureMaster procrdure, TPatientEncounter encounter)throws ProcessingException,IllegalArgumentException {
        try{
            labInformationService.deleteProcedureEncounter(procrdure,encounter);
        }catch(IllegalArgumentException e){
            throw e;
        }catch(ProcessingException e){
            throw e;
        }
    }
     
     public TEncounterProcedure getProcedureEncounterByID(Long ID)throws ProcessingException {
        try{
            return labInformationService.getProcedureEncounterByID(ID);
        }catch(ProcessingException e){
            throw e;
        }
    }
     
     public void updateProcedureEncounter(TEncounterProcedure encounterProcedure)throws ProcessingException,HibernateOptimisticLockingFailureException {
        try{
            labInformationService.upDateProcedureEncounter(encounterProcedure);
        }catch(HibernateOptimisticLockingFailureException e){
            throw e;
        }catch(ProcessingException e){
            throw e;
        }
    }
    
    public void deleteProcedureEncounterDetailsByID(Long ID, TPatientEncounter encounter)throws ProcessingException,IllegalArgumentException {
        try{
            labInformationService.deleteProcedureEncounterDetailsByID(ID,encounter);
        }catch(IllegalArgumentException e){
            throw e;
        }catch(ProcessingException e){
            throw e;
        }
    }
    
    
    
    public List<TEncounterProcedure> getTodayPrescribeOrder(TPatient patient)throws ProcessingException{
         try{
          return labInformationService.getTodayPrescribeOrder(patient);
        }catch(ProcessingException e){
            throw e;
        }
     
     }
    
    public Vector<TProcedureMaster> getAllPrescribeOrderForPatient(TPatient patient)throws ProcessingException{
         try{
            Vector procedures = new Vector();
            List<TProcedureMaster> procedureList = labInformationService.getAllPrescribeOrderForPatient(patient);
            for(TProcedureMaster procedure:procedureList){
                TProcedureMaster tempprocedure = new TProcedureMaster();
                tempprocedure.setId(procedure.getId());
                tempprocedure.setProcedureName(procedure.getProcedureName());
                procedures.addElement(tempprocedure);
            }
            return procedures;
        }catch(ProcessingException e){
            throw e;
        }
     }
    
    public Vector<Vector<String>> getPrescribeOrderToday(TPatient patient) throws ProcessingException{
        try{
        return labInformationService.getPrescribeOrderToday(patient);
        }catch(ProcessingException e){
            throw e;
        }
    }
    public List<TEncounterProcedure> getEncounterProcedureForPatient(TPatient patient,TProcedureMaster orderSelected)throws ProcessingException{
        try{
        return labInformationService.getEncounterProcedureForPatient(patient,orderSelected);
        }catch(ProcessingException e){
            throw e;
        }
    }

    public List<TPatientEncounter> getEncounterDates(TPatient patient)throws ProcessingException {
        try{
            return labInformationService.getEncounterDates(patient);
        }catch(ProcessingException e){
            throw e;
        }
    }

     public List<TEncounterProcedure> findAllOrderListForCheckBoxTable(TPatient patient)throws ProcessingException{
         try{
          return labInformationService.findAllOrderListForCheckBoxTable(patient);
        }catch(ProcessingException e){
            throw e;
        }
     
     }

    public TPatientEncounter saveNewEncForSelectedPatient(TPatientEncounter enc)throws ProcessingException,HibernateOptimisticLockingFailureException {
        try{
            return labInformationService.saveNewEncForSelectedPatient(enc);
        }catch(HibernateOptimisticLockingFailureException e){
            throw e;
        }catch(ProcessingException e){
            throw e;
        }
    }

    public TPatientEncounter getencforlab(TPatient patient,String enctype)throws ProcessingException {
        try{
            return labInformationService.getencforlab(patient,enctype);
        }catch(ProcessingException e){
            throw e;
        }
    }

    public List<TEncounterProcedure> getPreviousLabTest(TPatient patient) throws ProcessingException{
        try{
            return labInformationService.getPreviousLabTest(patient);
        }catch(ProcessingException e){
            throw e;
        }
    }
     
}

Commits for Satyam/AuroCareLabInformationSystem/src/main/java/com/bestray/labinformationsystem/controller/LabInformationController.java

Diff revisions: vs.
Revision Author Commited Message
1 girijabapi picture girijabapi Fri 20 Jul, 2018 05:59:17 +0000