dev
parent
d7b7127f55
commit
809f6b3659
|
|
@ -116,12 +116,13 @@ public class OrderStatController extends BaseController {
|
|||
*/
|
||||
@Before(DayValidator.class)
|
||||
public void daystatCustomer() {
|
||||
String tm = get("tm");
|
||||
int export = getInt("export", 0);
|
||||
String tm = get("tm");
|
||||
Integer invoice_type = getInt("invoice_type");
|
||||
int export = getInt("export", 0);
|
||||
if (export == 0) {
|
||||
renderJson(Result.object(OrderStatService.me.salestatCustomer(tm)));
|
||||
renderJson(Result.object(OrderStatService.me.salestatCustomer(tm, invoice_type)));
|
||||
} else {
|
||||
Workbook wb = OrderStatService.me.daysalestatCustomerExport(tm);
|
||||
Workbook wb = OrderStatService.me.daysalestatCustomerExport(tm, invoice_type);
|
||||
render(new ExcelRender(tm + "_销售日统计_" + System.currentTimeMillis() + ".xlsx", wb));
|
||||
}
|
||||
}
|
||||
|
|
@ -131,13 +132,14 @@ public class OrderStatController extends BaseController {
|
|||
*/
|
||||
@Before(MonthValidator.class)
|
||||
public void monthstatCustomer() {
|
||||
String tm = get("tm");
|
||||
int export = getInt("export", 0);
|
||||
String tm = get("tm");
|
||||
Integer invoice_type = getInt("invoice_type");
|
||||
int export = getInt("export", 0);
|
||||
|
||||
if (export == 0) {
|
||||
renderJson(Result.object(OrderStatService.me.salestatCustomer(tm)));
|
||||
renderJson(Result.object(OrderStatService.me.salestatCustomer(tm, invoice_type)));
|
||||
} else {
|
||||
Workbook wb = OrderStatService.me.monthsalestatCustomerExport(tm);
|
||||
Workbook wb = OrderStatService.me.monthsalestatCustomerExport(tm, invoice_type);
|
||||
render(new ExcelRender(tm + "_销售月统计_" + System.currentTimeMillis() + ".xlsx", wb));
|
||||
}
|
||||
}
|
||||
|
|
@ -305,8 +307,8 @@ public class OrderStatController extends BaseController {
|
|||
|
||||
@Before(StartAndEndIntervalValidator.class)
|
||||
public void statRangeAllCustomer() {
|
||||
String stm = get("stm");
|
||||
String etm = get("etm");
|
||||
String stm = get("stm");
|
||||
String etm = get("etm");
|
||||
int export = getInt("export", 0); // 是否导出为exce 0 不导出,1 导出
|
||||
if (export == 0) {
|
||||
renderJson(Result.object(OrderStatService.me.yearStatByCustomer(stm, etm)));
|
||||
|
|
@ -318,8 +320,8 @@ public class OrderStatController extends BaseController {
|
|||
|
||||
@Before(StartAndEndIntervalValidator.class)
|
||||
public void statRangeAllSup() {
|
||||
String stm = get("stm");
|
||||
String etm = get("etm");
|
||||
String stm = get("stm");
|
||||
String etm = get("etm");
|
||||
int export = getInt("export", 0); // 是否导出为exce 0 不导出,1 导出
|
||||
if (export == 0) {
|
||||
renderJson(Result.object(OrderStatService.me.yearStatBySup(stm, etm)));
|
||||
|
|
|
|||
Loading…
Reference in New Issue