mirror of
https://github.com/dyiop/astute.git
synced 2025-04-06 21:30:20 -04:00
Add files via upload
This commit is contained in:
parent
a7a8188926
commit
688896ea4e
|
@ -41,13 +41,13 @@ public class SqlDAO extends DAO {
|
||||||
List<PO> pos = new ArrayList<>();
|
List<PO> pos = new ArrayList<>();
|
||||||
Statement stmt = conn.createStatement();
|
Statement stmt = conn.createStatement();
|
||||||
String sql = "SELECT PO_num, contract_num, PO_date, customer_id, contract_amt FROM PO ";
|
String sql = "SELECT PO_num, contract_num, PO_date, customer_id, contract_amt FROM PO ";
|
||||||
if (PONum != null) {
|
if (PONum != null && !PONum.isEmpty()) {
|
||||||
sql += "WHERE UPPER(PO_num) = '" + PONum.toUpperCase() + "'";
|
sql += "WHERE UPPER(PO_num) = '" + PONum.toUpperCase() + "'";
|
||||||
} else if (contractNum != null) {
|
} else if (contractNum != null && !contractNum.isEmpty()) {
|
||||||
sql += "WHERE UPPER(contract_num) = '" + contractNum.toUpperCase()+ "'";
|
sql += "WHERE UPPER(contract_num) = '" + contractNum.toUpperCase()+ "'";
|
||||||
} else if (PODate != null) {
|
} else if (PODate != null) {
|
||||||
sql += "WHERE PO_date = STR_TO_DATE(" + PODate + ", '%Y-%m-%d')";
|
sql += "WHERE PO_date = STR_TO_DATE(" + PODate + ", '%Y-%m-%d')";
|
||||||
} else if (astuteProjectNumber!= null) {
|
} else if (astuteProjectNumber!= null && !astuteProjectNumber.isEmpty() ) {
|
||||||
sql += "WHERE UPPER(astute_project_num) = '" + astuteProjectNumber.toUpperCase()+ "'";
|
sql += "WHERE UPPER(astute_project_num) = '" + astuteProjectNumber.toUpperCase()+ "'";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -282,7 +282,7 @@ public class SqlDAO extends DAO {
|
||||||
String whereClause = " WHERE ";
|
String whereClause = " WHERE ";
|
||||||
boolean whereClauseIndicator = false;
|
boolean whereClauseIndicator = false;
|
||||||
String sql = "SELECT inv_no, inv_date, PO_num, change_order_num, pmt_status, bill_amt, special_notes, certification FROM INVOICE ";
|
String sql = "SELECT inv_no, inv_date, PO_num, change_order_num, pmt_status, bill_amt, special_notes, certification FROM INVOICE ";
|
||||||
if (invoiceNumber != null) {
|
if (invoiceNumber != null && !invoiceNumber.isEmpty()) {
|
||||||
whereClause = whereClause + " UPPER(inv_no) = '"+ invoiceNumber.toUpperCase() +"'";
|
whereClause = whereClause + " UPPER(inv_no) = '"+ invoiceNumber.toUpperCase() +"'";
|
||||||
whereClauseIndicator = true;
|
whereClauseIndicator = true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user