BrightSide Workbench Full Report + Source Code
org.turro.dossier.dw.DWDossierModel Class Reference
Collaboration diagram for org.turro.dossier.dw.DWDossierModel:

Public Member Functions

Long getCount ()
 
Long getProjectCount ()
 
Long getOpenedCount ()
 
List getByStatus ()
 
List getByPhase ()
 
Long getParticipantsCount ()
 
IContact getIParticipant ()
 
void setIParticipant (IContact contact)
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 37 of file DWDossierModel.java.

Member Function Documentation

◆ getByPhase()

List org.turro.dossier.dw.DWDossierModel.getByPhase ( )

Definition at line 85 of file DWDossierModel.java.

85  {
86  WhereClause wc = new WhereClause();
87  wc.addClause("select phase, count(distinct dossierId)");
88  wc.addClause("from DWDossier");
89  wc.addClause("where phase is not null");
90  addCriteria(wc);
91  wc.addClause("group by phase");
92  return getDao().getResultList(wc);
93  }
Here is the call graph for this function:

◆ getByStatus()

List org.turro.dossier.dw.DWDossierModel.getByStatus ( )

Definition at line 75 of file DWDossierModel.java.

75  {
76  WhereClause wc = new WhereClause();
77  wc.addClause("select status, count(distinct dossierId)");
78  wc.addClause("from DWDossier");
79  wc.addClause("where 1=1");
80  addCriteria(wc);
81  wc.addClause("group by status");
82  return getDao().getResultList(wc);
83  }
Here is the call graph for this function:

◆ getCount()

Long org.turro.dossier.dw.DWDossierModel.getCount ( )

Definition at line 46 of file DWDossierModel.java.

46  {
47  WhereClause wc = new WhereClause();
48  wc.addClause("select count(distinct dossierId)");
49  wc.addClause("from DWDossier");
50  wc.addClause("where 1=1");
51  addCriteria(wc);
52  return (Long) getDao().getSingleResultOrNull(wc);
53  }
Object getSingleResultOrNull(SqlClause sc)
Definition: Dao.java:419
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getIParticipant()

IContact org.turro.dossier.dw.DWDossierModel.getIParticipant ( )

Definition at line 142 of file DWDossierModel.java.

142  {
143  if(_contact == null) {
144  _contact = Contacts.getContactById(participantId);
145  }
146  return _contact;
147  }
Here is the call graph for this function:

◆ getOpenedCount()

Long org.turro.dossier.dw.DWDossierModel.getOpenedCount ( )

Definition at line 65 of file DWDossierModel.java.

65  {
66  WhereClause wc = new WhereClause();
67  wc.addClause("select count(distinct dossierId)");
68  wc.addClause("from DWDossier");
69  wc.addClause("where status <> :status");
70  wc.addNamedValue("status", DossierStatus.DOSSIER_CLOSED);
71  addCriteria(wc);
72  return (Long) getDao().getSingleResultOrNull(wc);
73  }
Here is the call graph for this function:

◆ getParticipantsCount()

Long org.turro.dossier.dw.DWDossierModel.getParticipantsCount ( )

Definition at line 95 of file DWDossierModel.java.

95  {
96  WhereClause wc = new WhereClause();
97  wc.addClause("select count(participantId)");
98  wc.addClause("from DWDossier");
99  wc.addClause("where 1=1");
100  addCriteria(wc);
101  return (Long) getDao().getSingleResultOrNull(wc);
102  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getProjectCount()

Long org.turro.dossier.dw.DWDossierModel.getProjectCount ( )

Definition at line 55 of file DWDossierModel.java.

55  {
56  WhereClause wc = new WhereClause();
57  wc.addClause("select count(distinct dossierId)");
58  wc.addClause("from DWDossier");
59  wc.addClause("where type=:type");
60  wc.addNamedValue("type", DossierType.TYPE_PROJECT);
61  addCriteria(wc);
62  return (Long) getDao().getSingleResultOrNull(wc);
63  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setIParticipant()

void org.turro.dossier.dw.DWDossierModel.setIParticipant ( IContact  contact)

Definition at line 149 of file DWDossierModel.java.

149  {
150  _contact = contact;
151  participantId = _contact != null ? _contact.getId() : null;
152  }
Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following file: