|
|
@@ -2026,21 +2026,21 @@ public class TimerServiceImpl implements TimerService {
|
|
|
long lastTime = calendar.getTimeInMillis();
|
|
|
|
|
|
String sql = "SELECT\n" +
|
|
|
- "\tsum( predict_income )*10000/12 predict_income,\n" +
|
|
|
- "\tSUM( `open` )*10000/12 `open`,\n" +
|
|
|
- "\tSUM( income )*10000/12 income,\n" +
|
|
|
- "\tSUM( person )*10000/12 person,\n" +
|
|
|
- "\tSUM( folding_repair )*10000/12 folding_repair,\n" +
|
|
|
- "\tSUM( person_cost )*10000/12 person_cost,\n" +
|
|
|
- "\tSUM( material )*10000/12 material,\n" +
|
|
|
- "\tSUM( other_cost )*10000/12 other_cost,\n" +
|
|
|
- "\tSUM( cost_sum )*10000/12 cost_sum,\n" +
|
|
|
- "\tSUM( taxes )*10000/12 taxes,\n" +
|
|
|
- "\tSUM( gross_profit )*10000/12 gross_profit,\n" +
|
|
|
+ "\tAVG( predict_income )*10000 predict_income,\n" +
|
|
|
+ "\tAVG( `open` )*10000 `open`,\n" +
|
|
|
+ "\tAVG( income )*10000 income,\n" +
|
|
|
+ "\tAVG( person )*10000 person,\n" +
|
|
|
+ "\tAVG( folding_repair )*10000 folding_repair,\n" +
|
|
|
+ "\tAVG( person_cost )*10000 person_cost,\n" +
|
|
|
+ "\tAVG( material )*10000 material,\n" +
|
|
|
+ "\tAVG( other_cost )*10000 other_cost,\n" +
|
|
|
+ "\tAVG( cost_sum )*10000 cost_sum,\n" +
|
|
|
+ "\tAVG( taxes )*10000 taxes,\n" +
|
|
|
+ "\tAVG( gross_profit )*10000 gross_profit,\n" +
|
|
|
"\tCONCAT( ROUND( SUM( gross_profit )/ SUM( income )* 100, 2 ), '%' ) gross_margin,\n" +
|
|
|
- "\tSUM( overhead )*10000/12 overhead,\n" +
|
|
|
- "\tSUM( corporate_income_tax )*10000/12 corporate_income_tax,\n" +
|
|
|
- "\tSUM( net_profit )*10000/12 net_profit,\n" +
|
|
|
+ "\tAVG( overhead )*10000 overhead,\n" +
|
|
|
+ "\tAVG( corporate_income_tax )*10000 corporate_income_tax,\n" +
|
|
|
+ "\tAVG( net_profit )*10000 net_profit,\n" +
|
|
|
"\tCONCAT( ROUND( SUM( net_profit )/ SUM( income )* 100, 2 ), '%' ) net_margin \n" +
|
|
|
"FROM\n" +
|
|
|
"\tlanyun_project_analysis\n" +
|