|
|
@@ -5,6 +5,7 @@ import beans.accountbalance.CashbillEntity;
|
|
|
import beans.data.BatchDeleteErr;
|
|
|
import beans.datacontrllog.DataContrlLog;
|
|
|
import beans.parameter.Parameter;
|
|
|
+import beans.report.Report;
|
|
|
import beans.stockbill.Stockbill;
|
|
|
import com.alibaba.fastjson2.JSONArray;
|
|
|
import com.alibaba.fastjson2.JSONObject;
|
|
|
@@ -23,6 +24,7 @@ import restcontroller.webmanage.sale.sendrepair.sendrepair_pj;
|
|
|
|
|
|
import java.math.BigDecimal;
|
|
|
import java.util.ArrayList;
|
|
|
+import java.util.HashMap;
|
|
|
|
|
|
/**
|
|
|
* 出入库单
|
|
|
@@ -267,12 +269,23 @@ public class stockbill extends Controller {
|
|
|
querySQL.addJoinTable(JOINTYPE.left, "st_dbstockbill", "t9", "t1.sourceid=t9.st_dbstockbillid and t1.siteid = t9.siteid and t1.sourceobject='st_dbstockbill'");
|
|
|
querySQL.addQueryFields("dbbillno", "t9.billno");
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
querySQL.setWhere("t1.siteid", siteid);
|
|
|
querySQL.setWhere("t1.type", billtypes);
|
|
|
querySQL.setWhere(where);
|
|
|
querySQL.setCondition("t1.billno", "t1.outplace", "t3.agentnum", " t2.enterprisename", "t6.depname");
|
|
|
querySQL.setPage(pageSize, pageNumber);
|
|
|
Rows rows = querySQL.query();
|
|
|
+
|
|
|
+ ArrayList<Long> ids = rows.toArrayList("st_stockbillid", new ArrayList<>());
|
|
|
+ HashMap<Long, Integer> reportMap =Report.getViewCount(this,"st_stockbill",ids);
|
|
|
+ for(Row row :rows){
|
|
|
+ if(reportMap.containsKey(row.getString("st_stockbillid"))){
|
|
|
+ row.put("printcount",reportMap.get(row.getString("st_stockbillid")));
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
return getSucReturnObject().setData(rows).toString();
|
|
|
}
|
|
|
|