BrightSide Workbench Full Report + Source Code
org.turro.erp.aptitude.logic.AptitudeWrapper Class Reference
Inheritance diagram for org.turro.erp.aptitude.logic.AptitudeWrapper:
Collaboration diagram for org.turro.erp.aptitude.logic.AptitudeWrapper:

Public Member Functions

 AptitudeWrapper (Aptitude entity)
 
void delete (final boolean close)
 
boolean canDelete ()
 
- Public Member Functions inherited from org.turro.hr.aptitude.AptitudeWrapper
Aptitude save ()
 
IDossier getDossier ()
 
- Public Member Functions inherited from org.turro.jpa.entity.DaoEntity< T extends IDaoEntity, ID extends Serializable >
 DaoEntity ()
 
 DaoEntity (Class< T > persistentClass)
 
 DaoEntity (T entity)
 
Dao getDao ()
 
getEntity ()
 
IElephantEntity getIee ()
 
find (ID id)
 
boolean delete ()
 
ID getId ()
 
List< String > getMessages ()
 
boolean canSave ()
 
boolean equals (Object obj)
 
int hashCode ()
 

Protected Member Functions

void logEntity (LogType logType, String path, String action, String data)
 
- Protected Member Functions inherited from org.turro.hr.aptitude.AptitudeWrapper
Dao createDao ()
 
boolean shouldLog ()
 
- Protected Member Functions inherited from org.turro.jpa.entity.DaoEntity< T extends IDaoEntity, ID extends Serializable >
void logEntity (SystemLogType logType, Object entity, String action, String data)
 
String dataEntity (Object entity)
 
void initOperation ()
 
void addMessage (String message)
 

Additional Inherited Members

- Static Public Member Functions inherited from org.turro.jpa.entity.DaoEntity< T extends IDaoEntity, ID extends Serializable >
static Object getEntityId (Object entity)
 
static boolean isNewId (Object id)
 
- Protected Attributes inherited from org.turro.jpa.entity.DaoEntity< T extends IDaoEntity, ID extends Serializable >
entity
 
ID id
 
List< String > messages = new ArrayList<>()
 

Detailed Description

Constructor & Destructor Documentation

◆ AptitudeWrapper()

org.turro.erp.aptitude.logic.AptitudeWrapper.AptitudeWrapper ( Aptitude  entity)

Member Function Documentation

◆ canDelete()

boolean org.turro.erp.aptitude.logic.AptitudeWrapper.canDelete ( )

Reimplemented from org.turro.jpa.entity.DaoEntity< T extends IDaoEntity, ID extends Serializable >.

Definition at line 53 of file bserp-www/src/main/java/org/turro/erp/aptitude/logic/AptitudeWrapper.java.

53  {
54  if(entity.getId() == 0) return false;
55 // Dao dao = getDao();
56 // Long count = (Long) dao.getSingleResult(
57 // "select count(*) from Document " +
58 // "where contract = ?",
59 // new Object[] { contract });
60 // if(count == 0) {
61 // count = (Long) dao.getSingleResult(
62 // "select count(*) from DocumentLine " +
63 // "where store = ?",
64 // new Object[] { contract });
65 // }
66 // return count == 0;
67  return true;
68  }
Here is the caller graph for this function:

◆ delete()

void org.turro.erp.aptitude.logic.AptitudeWrapper.delete ( final boolean  close)

Definition at line 38 of file bserp-www/src/main/java/org/turro/erp/aptitude/logic/AptitudeWrapper.java.

38  {
39  // Check if possible and notify
40  if(canDelete()) {
41  ZkossUtils.confirmDeletion(null, new Command() {
42  @Override
43  public Object execute(Context context) {
44  if(AptitudeWrapper.super.delete()) {
45  if(close) Framework.getCurrent().closeSelected();
46  }
47  return null;
48  }
49  });
50  }
51  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ logEntity()

void org.turro.erp.aptitude.logic.AptitudeWrapper.logEntity ( LogType  logType,
String  path,
String  action,
String  data 
)
protected

Definition at line 71 of file bserp-www/src/main/java/org/turro/erp/aptitude/logic/AptitudeWrapper.java.

71  {
72  Authentication.log(logType, path, action, data);
73  }

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