Skip to content

Commit

Permalink
Merge pull request #4560 from hmislk/Issue#4558
Browse files Browse the repository at this point in the history
Issue#4558
  • Loading branch information
binuthi-nil authored Apr 10, 2024
2 parents 47d4904 + d653ee6 commit 78dfa9a
Show file tree
Hide file tree
Showing 25 changed files with 2,009 additions and 85 deletions.
2 changes: 1 addition & 1 deletion nb-configuration.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Any value defined here will override the pom.xml file value but is only applicab
<org-netbeans-modules-maven-jaxws.rest_2e_config_2e_type>ide</org-netbeans-modules-maven-jaxws.rest_2e_config_2e_type>
<org-netbeans-modules-maven-j2ee.netbeans_2e_deploy_2e_on_2e_save>false</org-netbeans-modules-maven-j2ee.netbeans_2e_deploy_2e_on_2e_save>
<org-netbeans-modules-javascript2-requirejs.enabled>true</org-netbeans-modules-javascript2-requirejs.enabled>
<org-netbeans-modules-projectapi.jsf_2e_language>Facelets</org-netbeans-modules-projectapi.jsf_2e_language>
<org-netbeans-modules-projectapi.jsf_2e_language>JSP</org-netbeans-modules-projectapi.jsf_2e_language>
<netbeans.compile.on.save>all</netbeans.compile.on.save>
<org-netbeans-modules-css-prep.less_2e_mappings>/less:/css</org-netbeans-modules-css-prep.less_2e_mappings>
<org-netbeans-modules-css-prep.less_2e_enabled>false</org-netbeans-modules-css-prep.less_2e_enabled>
Expand Down
11 changes: 10 additions & 1 deletion src/main/java/com/divudi/bean/channel/BookingController.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import com.divudi.bean.common.BillBeanController;
import com.divudi.bean.common.BillController;
import com.divudi.bean.common.CommonController;
import com.divudi.bean.common.ConfigOptionController;
import com.divudi.bean.common.ControllerWithPatient;
import com.divudi.bean.common.DoctorSpecialityController;
import com.divudi.bean.common.ItemForItemController;
Expand Down Expand Up @@ -66,6 +67,7 @@
import com.divudi.facade.StaffFacade;
import com.divudi.bean.common.util.JsfUtil;
import com.divudi.data.BillTypeAtomic;
import com.divudi.data.OptionScope;
import com.divudi.data.SmsSentResponse;
import com.divudi.data.dataStructure.ComponentDetail;
import com.divudi.entity.Payment;
Expand Down Expand Up @@ -146,6 +148,8 @@ public class BookingController implements Serializable, ControllerWithPatient {
* Controllers
*/
@Inject
ConfigOptionController configOptionController;
@Inject
PriceMatrixController priceMatrixController;
@Inject
PatientController patientController;
Expand Down Expand Up @@ -803,7 +807,12 @@ private String createChanellBookingNoShowSms(Bill b) {
}

private String createChanellBookingSms(Bill b) {
return createSmsForChannelBooking(b, sessionController.getDepartmentPreference().getSmsTemplateForChannelBooking());
// String template = sessionController.getDepartmentPreference().getSmsTemplateForChannelBooking();
String template = configOptionController.getLongTextValueByKey("Template for SMS sent on Channel Booking", OptionScope.APPLICATION, null, null, null);
if(template==null||template.isBlank()){
template = "Dear {patient_name}, Your appointment with {doctor} is confirmed for {appointment_time} on {appointment_date}. Your serial no. is {serial_no}. Please arrive 10 minutes early. Thank you.";
}
return createSmsForChannelBooking(b, template);
}

public String createSmsForChannelBooking(Bill b, String template) {
Expand Down
10 changes: 5 additions & 5 deletions src/main/java/com/divudi/bean/common/AreaController.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,14 +78,14 @@ public Area findAreaByName(String name) {

public List<Area> completeArea(String qry) {
List<Area> list;
String sql;
HashMap hm = new HashMap();
sql = "select c from Area c "
String jpql;
HashMap params = new HashMap();
jpql = "select c from Area c "
+ " where c.retired=false "
+ " and (c.name) like :q "
+ " order by c.name";
hm.put("q", "%" + qry.toUpperCase() + "%");
list = getFacade().findByJpql(sql, hm);
params.put("q", "%" + qry.toUpperCase() + "%");
list = getFacade().findByJpql(jpql, params);

if (list == null) {
list = new ArrayList<>();
Expand Down
Loading

0 comments on commit 78dfa9a

Please sign in to comment.