BrightSide Workbench Full Report + Source Code
org.turro.erp.purchase.HoursEdit Class Reference
Inheritance diagram for org.turro.erp.purchase.HoursEdit:
Collaboration diagram for org.turro.erp.purchase.HoursEdit:

Public Member Functions

void onClick $doccreate ()
 
void onChange $docdate ()
 
void onChange $docnumber ()
 
void onChange $humanres ()
 
void onChange $hoursGrid ()
 
void onChanging $hoursGrid ()
 
void onChanging $hoursHistGrid ()
 
void doAfterCompose (Component comp) throws Exception
 

Detailed Description

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

Definition at line 39 of file HoursEdit.java.

Member Function Documentation

◆ $doccreate()

void onClick org.turro.erp.purchase.HoursEdit.$doccreate ( )

Definition at line 48 of file HoursEdit.java.

48  {
49  for(HoursItem hi : hoursGrid.getValues()) {
50  if(hi.isValid()) {
51  if(hoursGrid.isReceipt()) {
52  createReceipt(humanres.getObjectValue(), docnumber.getValue(), docdate.getValue(), hi);
53  } else {
54  createOrder(humanres.getObjectValue(), docnumber.getValue(), docdate.getValue(), hi);
55  }
56  }
57  }
58  hoursGrid.clearValidRows();
59  if(hoursHistGrid != null) {
60  hoursHistGrid.refreshUsing(humanres.getObjectValue(), docnumber.getValue(), docdate.getValue());
61  }
62  }
void refreshUsing(HumanResource humanResource, String documentNumber, Date documentDate)
Definition: HoursGrid.java:222
Here is the call graph for this function:

◆ $docdate()

void onChange org.turro.erp.purchase.HoursEdit.$docdate ( )

Definition at line 64 of file HoursEdit.java.

64  {
65  hoursGrid.setDocumentDate(docdate.getValue());
66  if(hoursHistGrid != null) {
67  hoursHistGrid.refreshUsing(humanres.getObjectValue(), docnumber.getValue(), docdate.getValue());
68  }
69  updateButton();
70  }
void setDocumentDate(Date documentDate)
Definition: HoursGrid.java:77
Here is the call graph for this function:

◆ $docnumber()

void onChange org.turro.erp.purchase.HoursEdit.$docnumber ( )

Definition at line 72 of file HoursEdit.java.

72  {
73  if(hoursHistGrid != null) {
74  hoursHistGrid.refreshUsing(humanres.getObjectValue(), docnumber.getValue(), docdate.getValue());
75  }
76  updateButton();
77  }
Here is the call graph for this function:

◆ $hoursGrid() [1/2]

void onChange org.turro.erp.purchase.HoursEdit.$hoursGrid ( )

Definition at line 86 of file HoursEdit.java.

86  {
87  updateButton();
88  }

◆ $hoursGrid() [2/2]

void onChanging org.turro.erp.purchase.HoursEdit.$hoursGrid ( )

Definition at line 90 of file HoursEdit.java.

90  {
91  EditableCell ec = hoursGrid.getCurrentCell();
92  if(ec != null) {
93  HoursItem pi = (HoursItem) ec.getRow().getValue();
94  if(pi != null) {
95  lWorkOrder.setValue(pi.getWorkOrder() == null ? null :
96  "#" + pi.getWorkOrder().getWorkOrderId() + "\n" + pi.getWorkOrder().getSomeDescription());
97  lOrderReference.setValue(pi.getOrderReference() == null ? null :
98  "#" + pi.getOrderReference().getOrderRef() + "\n" + pi.getOrderReference().getSomeDescription());
99  }
100  }
101  }
Here is the call graph for this function:

◆ $hoursHistGrid()

void onChanging org.turro.erp.purchase.HoursEdit.$hoursHistGrid ( )

Definition at line 103 of file HoursEdit.java.

103  {
104  EditableCell ec = hoursGrid.getCurrentCell();
105  if(ec != null) {
106  HoursItem hi = (HoursItem) ec.getRow().getValue();
107  if(hi != null) {
108  lWorkOrder.setValue(hi.getWorkOrder() == null ? null : hi.getWorkOrder().getSomeDescription());
109  lOrderReference.setValue(hi.getOrderReference() == null ? null : hi.getOrderReference().getSomeDescription());
110  }
111  }
112  }
Here is the call graph for this function:

◆ $humanres()

void onChange org.turro.erp.purchase.HoursEdit.$humanres ( )

Definition at line 79 of file HoursEdit.java.

79  {
80  if(hoursHistGrid != null) {
81  hoursHistGrid.refreshUsing(humanres.getObjectValue(), docnumber.getValue(), docdate.getValue());
82  }
83  updateButton();
84  }
Here is the call graph for this function:

◆ doAfterCompose()

void org.turro.erp.purchase.HoursEdit.doAfterCompose ( Component  comp) throws Exception

Definition at line 124 of file HoursEdit.java.

124  {
125  super.doAfterCompose(comp);
126  docdate.setValue(new Date());
127  doccreate.setDisabled(true);
128  hoursGrid.setDocumentDate(docdate.getValue());
129  }
Here is the call graph for this function:

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