From 6356c6e148c854bb60ba1cd51fafdabfa932efff Mon Sep 17 00:00:00 2001 From: wu <731351411@qq.com> Date: 星期一, 18 三月 2024 08:29:05 +0800 Subject: [PATCH] 逻辑更新 --- springboot-vue3/src/main/java/com/example/springboot/service/HomeService.java | 68 +++++++++++++++++----------------- 1 files changed, 34 insertions(+), 34 deletions(-) diff --git a/springboot-vue3/src/main/java/com/example/springboot/service/HomeService.java b/springboot-vue3/src/main/java/com/example/springboot/service/HomeService.java index 452b8eb..2467976 100644 --- a/springboot-vue3/src/main/java/com/example/springboot/service/HomeService.java +++ b/springboot-vue3/src/main/java/com/example/springboot/service/HomeService.java @@ -8,43 +8,43 @@ import com.example.springboot.entity.GlassInfo; import com.example.springboot.entity.MeasureSetting; -import com.example.springboot.mapper.GlassInfoMapper; -import com.example.springboot.mapper.MeasureSettingMapper; -import com.example.springboot.mapper.QueueMapper; +// import com.example.springboot.mapper.GlassInfoMapper; +// import com.example.springboot.mapper.MeasureSettingMapper; +// import com.example.springboot.mapper.QueueMapper; @Service public class HomeService { - @Autowired - MeasureSettingMapper MeasureSettingMapper; - @Autowired - GlassInfoMapper GlassInfoMapper; - @Autowired - QueueMapper QueueMapper; + // @Autowired + // MeasureSettingMapper MeasureSettingMapper; + // @Autowired + // GlassInfoMapper GlassInfoMapper; + // @Autowired + // QueueMapper QueueMapper; - // 鍖归厤鐜荤拑 瀹斤紝楂橈紝绾胯矾 - public List<GlassInfo> NormalGlassInfo(double width, double height, String line) { - // - List<GlassInfo> Results=new ArrayList<GlassInfo>(); - // 鑾峰彇鍖归厤璁剧疆 - MeasureSetting MeasureSetting = MeasureSettingMapper.SelectMeasureSetting(line); - if (height > 0 && width > 0 && MeasureSetting != null) { - // 鏈夋晥鍙傛暟 璇锋眰=1 闀�/瀹�>0 - double maxheight = height + MeasureSetting.getErrorHeight(); - double minheight = height - MeasureSetting.getErrorHeight(); - double maxwidth = width + MeasureSetting.getErrorWidth(); - double minwidth = width - MeasureSetting.getErrorWidth(); - // 鏌ヨ褰撳墠娴嬮噺鏁版嵁 - List<GlassInfo> GlassInfos = GlassInfoMapper.selectGlassInfos(maxwidth, minwidth, maxheight, minheight); - List types = new ArrayList<>(); - for (int i = 0; i < GlassInfos.size(); i++) { - Integer glasstype = GlassInfos.get(i).getGlasstype(); - if (!types.contains(glasstype)) { - types.add(glasstype); - Results.add(GlassInfos.get(i)); - } - } - } - return Results; - } + // // 鍖归厤鐜荤拑 瀹斤紝楂橈紝绾胯矾 + // public List<GlassInfo> NormalGlassInfo(double width, double height, String line) { + // // + // List<GlassInfo> Results=new ArrayList<GlassInfo>(); + // // 鑾峰彇鍖归厤璁剧疆 + // MeasureSetting MeasureSetting = MeasureSettingMapper.SelectMeasureSetting(line); + // if (height > 0 && width > 0 && MeasureSetting != null) { + // // 鏈夋晥鍙傛暟 璇锋眰=1 闀�/瀹�>0 + // double maxheight = height + MeasureSetting.getErrorHeight(); + // double minheight = height - MeasureSetting.getErrorHeight(); + // double maxwidth = width + MeasureSetting.getErrorWidth(); + // double minwidth = width - MeasureSetting.getErrorWidth(); + // // 鏌ヨ褰撳墠娴嬮噺鏁版嵁 + // List<GlassInfo> GlassInfos = GlassInfoMapper.selectGlassInfos(maxwidth, minwidth, maxheight, minheight); + // List types = new ArrayList<>(); + // for (int i = 0; i < GlassInfos.size(); i++) { + // Integer glasstype = GlassInfos.get(i).getGlasstype(); + // if (!types.contains(glasstype)) { + // types.add(glasstype); + // Results.add(GlassInfos.get(i)); + // } + // } + // } + // return Results; + // } } -- Gitblit v1.8.0