Skip to content

Commit

Permalink
Merge pull request #9767 from hmislk/Issue#9700_staff_welfare_return_…
Browse files Browse the repository at this point in the history
…not_working

Issue#9700 staff welfare return not working  Closes #9700
  • Loading branch information
Irani96 authored Dec 20, 2024
2 parents 5b39673 + 3e3b32a commit 2d93a7d
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 6 deletions.
27 changes: 27 additions & 0 deletions src/main/java/com/divudi/bean/common/BillReturnController.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@

import com.divudi.bean.cashTransaction.DrawerController;
import com.divudi.bean.cashTransaction.PaymentController;
import com.divudi.bean.collectingCentre.CollectingCentreBillController;
import com.divudi.bean.common.util.JsfUtil;
import com.divudi.data.BillTypeAtomic;
import com.divudi.data.FeeType;
import com.divudi.data.HistoryType;
import com.divudi.data.PaymentMethod;
import static com.divudi.data.PaymentMethod.Card;
Expand All @@ -19,11 +21,19 @@

import com.divudi.ejb.BillNumberGenerator;
import com.divudi.entity.Bill;
import com.divudi.entity.BillEntry;
import com.divudi.entity.BillFee;
import com.divudi.entity.BillItem;
import com.divudi.entity.Category;
import com.divudi.entity.Department;
import com.divudi.entity.Institution;
import com.divudi.entity.Item;
import com.divudi.entity.PatientDeposit;
import com.divudi.entity.Payment;
import com.divudi.entity.PaymentScheme;
import com.divudi.entity.PriceMatrix;
import com.divudi.entity.RefundBill;
import com.divudi.entity.Staff;

import com.divudi.entity.cashTransaction.Drawer;

Expand All @@ -36,6 +46,7 @@
import javax.inject.Named;
import javax.enterprise.context.SessionScoped;
import java.io.Serializable;
import java.text.DecimalFormat;
import java.util.ArrayList;
import java.util.List;
import javax.ejb.EJB;
Expand Down Expand Up @@ -83,6 +94,12 @@ public class BillReturnController implements Serializable, ControllerWithMultipl
AgentAndCcApplicationController agentAndCcApplicationController;
@Inject
PatientDepositController patientDepositController;
@Inject
PriceMatrixController priceMatrixController;
@Inject
private BillBeanController billBean;
@Inject
CollectingCentreBillController collectingCentreBillController;
// </editor-fold>

// <editor-fold defaultstate="collapsed" desc="Class Variable">
Expand Down Expand Up @@ -237,6 +254,8 @@ public boolean checkDraverBalance(Drawer drawer, PaymentMethod paymentMethod) {
}
return canReturn;
}

private Staff toStaff;

public String settleOpdReturnBill() {
if (returningStarted) {
Expand Down Expand Up @@ -688,4 +707,12 @@ public void recieveRemainAmountAutomatically() {
public void setPaymentMethodData(PaymentMethodData paymentMethodData) {
throw new UnsupportedOperationException("Multiple Payments Not supported in Returns and Refunds");
}

public Staff getToStaff() {
return toStaff;
}

public void setToStaff(Staff toStaff) {
this.toStaff = toStaff;
}
}
10 changes: 4 additions & 6 deletions src/main/webapp/opd/bill_return.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,9 @@
<f:convertNumber pattern="#,##0.00" ></f:convertNumber>
</h:outputText>
</p:column>
<p:ajax process="@this"
<!-- <p:ajax process="@this"
update=":#{p:resolveFirstComponentWithId('pBillDetails',view).clientId} :#{p:resolveFirstComponentWithId('tblRequests',view).clientId} :#{p:resolveFirstComponentWithId('tblBillItem',view).clientId}"
event="itemSelect"
listener="#{billReturnController.calTotals()}" />
event="itemSelect" />-->
</p:autoComplete>
</div>
</div>
Expand Down Expand Up @@ -185,10 +184,9 @@
<f:convertNumber pattern="#,##0.00" ></f:convertNumber>
</h:outputText>
</p:column>
<p:ajax process="@this"
<!-- <p:ajax process="@this"
update=":#{p:resolveFirstComponentWithId('pBillDetails',view).clientId} :#{p:resolveFirstComponentWithId('tblRequests',view).clientId} :#{p:resolveFirstComponentWithId('tblBillItem',view).clientId}"
event="itemSelect"
listener="#{billReturnController.calTotals()}" />
event="itemSelect" />-->
</p:autoComplete>
</div>
</div>
Expand Down

0 comments on commit 2d93a7d

Please sign in to comment.