Commit c76771e0f75df5799c6eaa6bcae42838a43a56a2
1 parent
fb692fd3
首页修改数量,局部作用域去除
Showing
2 changed files
with
5 additions
and
5 deletions
ant-design-vue-jeecg/src/components/NumberInfo/NumberInfo.vue
huaheng-wms-core/src/main/java/org/jeecg/modules/wms/home/service/impl/HomePageViewServiceImpl.java
@@ -159,10 +159,10 @@ public class HomePageViewServiceImpl implements HomePageViewService { | @@ -159,10 +159,10 @@ public class HomePageViewServiceImpl implements HomePageViewService { | ||
159 | //先存储总数 | 159 | //先存储总数 |
160 | int inStock=locations.size(); | 160 | int inStock=locations.size(); |
161 | 161 | ||
162 | - //删除为空的数量 | 162 | + //总库位删除为空的数量长度 == 有货数量 |
163 | locations.removeIf(location -> StringUtils.isEmpty(location.getContainerCode())); | 163 | locations.removeIf(location -> StringUtils.isEmpty(location.getContainerCode())); |
164 | 164 | ||
165 | - //有货数量 总数-无货数量 | 165 | + //总数-有货数量 == 无货数量 |
166 | inStock=inStock-locations.size(); | 166 | inStock=inStock-locations.size(); |
167 | 167 | ||
168 | Option option = new Option(); | 168 | Option option = new Option(); |
@@ -193,10 +193,10 @@ public class HomePageViewServiceImpl implements HomePageViewService { | @@ -193,10 +193,10 @@ public class HomePageViewServiceImpl implements HomePageViewService { | ||
193 | pie.itemStyle().emphasis().setShadowColor("rgba(0, 0, 0, 0.4)"); | 193 | pie.itemStyle().emphasis().setShadowColor("rgba(0, 0, 0, 0.4)"); |
194 | 194 | ||
195 | option.legend().data().add("有货"); | 195 | option.legend().data().add("有货"); |
196 | - pie.data().add(new ChartData("有货", Convert.toDouble(inStock))); | 196 | + pie.data().add(new ChartData("有货", Convert.toDouble(locations.size()))); |
197 | 197 | ||
198 | option.legend().data().add("无货"); | 198 | option.legend().data().add("无货"); |
199 | - pie.data().add(new ChartData("无货", Convert.toDouble(locations.size()))); | 199 | + pie.data().add(new ChartData("无货", Convert.toDouble(inStock))); |
200 | 200 | ||
201 | option.series(pie); | 201 | option.series(pie); |
202 | String format = GsonUtil.format(option); | 202 | String format = GsonUtil.format(option); |