|
|
@@ -82,6 +82,7 @@ public class Tsaler extends Controller {
|
|
|
ftype = content.getString("ftype");
|
|
|
}
|
|
|
Rows amountRows = null;
|
|
|
+ Rows invoiceamountRows = null;
|
|
|
if ("打款".equals(ftype)) {
|
|
|
SQLFactory amountfactory = new SQLFactory(this, "收入凭证金额汇总查询");
|
|
|
amountfactory.addParameter_SQL("hrid", hridinwhere);
|
|
|
@@ -96,12 +97,20 @@ public class Tsaler extends Controller {
|
|
|
amountfactory.addParameter_SQL("fyear", content.getString("fyear"));
|
|
|
amountRows = connect.runSqlQuery(amountfactory.getSQL());
|
|
|
}
|
|
|
+ {
|
|
|
+ SQLFactory amountfactory = new SQLFactory(this, "开票金额汇总查询");
|
|
|
+ amountfactory.addParameter_SQL("hrid", hridinwhere);
|
|
|
+ amountfactory.addParameter("siteid", siteid);
|
|
|
+ amountfactory.addParameter_SQL("fyear", content.getString("fyear"));
|
|
|
+ invoiceamountRows = connect.runSqlQuery(amountfactory.getSQL());
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
|
* 年度订单金额及完成率预设
|
|
|
*/
|
|
|
yearrow.put("forderamount", 0);
|
|
|
yearrow.put("fcompletionrate", 0);
|
|
|
+ yearrow.put("finvoiceamount", 0);
|
|
|
|
|
|
/**
|
|
|
* 开始遍历年度订单金额及完成率计算
|
|
|
@@ -115,6 +124,16 @@ public class Tsaler extends Controller {
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
+ /**
|
|
|
+ * 开始遍历年度开票金额
|
|
|
+ */
|
|
|
+ for (Row invoiceamountRow : invoiceamountRows) {
|
|
|
+ if ("年".equals(invoiceamountRow.getString("ftype"))) {
|
|
|
+ double finvoiceamount = invoiceamountRow.getDouble("finvoiceamount");
|
|
|
+ yearrow.put("finvoiceamount", finvoiceamount);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
|
* SQL季度任务查询参数设置并查询
|
|
|
@@ -137,6 +156,7 @@ public class Tsaler extends Controller {
|
|
|
*/
|
|
|
quarterrow.put("forderamount", 0);
|
|
|
quarterrow.put("fcompletionrate", 0);
|
|
|
+ quarterrow.put("finvoiceamount", 0);
|
|
|
/**
|
|
|
* 开始遍历季度订单金额及完成率计算
|
|
|
*/
|
|
|
@@ -149,6 +169,16 @@ public class Tsaler extends Controller {
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
+ /**
|
|
|
+ * 开始遍历季度开票金额
|
|
|
+ */
|
|
|
+ for (Row invoiceamountRow : invoiceamountRows) {
|
|
|
+ if ("季".equals(invoiceamountRow.getString("ftype")) && quarter.equals(invoiceamountRow.getString("number"))) {
|
|
|
+ double finvoiceamount = invoiceamountRow.getDouble("finvoiceamount");
|
|
|
+ quarterrow.put("finvoiceamount", finvoiceamount);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
/**
|
|
|
* SQL月度任务查询参数设置并查询
|
|
|
@@ -184,6 +214,16 @@ public class Tsaler extends Controller {
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
+ /**
|
|
|
+ * 开始遍历月度开票金额
|
|
|
+ */
|
|
|
+ for (Row invoiceamountRow : invoiceamountRows) {
|
|
|
+ if ("月".equals(invoiceamountRow.getString("ftype")) && month.equals(invoiceamountRow.getString("number"))) {
|
|
|
+ double finvoiceamount = invoiceamountRow.getDouble("finvoiceamount");
|
|
|
+ monthrow.put("finvoiceamount", finvoiceamount);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
//季度任务
|