yaozhixue 1 year ago
parent
commit
935b87725f

+ 51 - 37
src/main/java/com/zfire/jiasm/syncdata/service/impl/OrderBaseInstallCjOrWgServiceImpl.java

@@ -2027,6 +2027,17 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         setJysWdno(orderBase, mxup);
         mxup.setCjren(orderBase.getCreateBy());
         mxup.setCjrmc(orderBase.getCreateName());
+
+        if (StringUtils.isNotEmpty(mxup.getSjcjjd()) && mxup.getSjcjjd().length()>12){
+            mxup.setSjcjjd(mxup.getSjcjjd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjwd()) && mxup.getSjcjwd().length()>12){
+            mxup.setSjcjwd(mxup.getSjcjwd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjjwdu()) && mxup.getSjcjjwdu().length()>50){
+            mxup.setSjcjjwdu(mxup.getSjcjjwdu().substring(0,50));
+        }
+
         // 售后网点处理
         websitSH = publicService.ptshwdToshshwd(mxup.getCzwd(), orderBase.getMainId());
         mxup.setCzwd(websitSH.getWdId());
@@ -2055,13 +2066,6 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         mxup.setGmsj(orderBase.getBuyTime());
         mxup.setCjwdno(mxup.getAzwdno());
         mxup.setZjczwd(mxup.getAzwdno());
-        if (StringUtils.isNotEmpty(orderBase.getLat()) && orderBase.getLat().length()>12){
-            mxup.setSjcjjd(orderBase.getLat().substring(0,12));
-        }
-        if (StringUtils.isNotEmpty(orderBase.getLng()) && orderBase.getLng().length()>12){
-            mxup.setSjcjwd(orderBase.getLng().substring(0,12));
-        }
-        mxup.setSjcjjwdu(mxup.getSjcjjd()+","+ mxup.getSjcjwd());
 
     }
 
@@ -2089,7 +2093,15 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
 
         mxup.setCjren(orderBase.getCreateBy());
         mxup.setCjrmc(orderBase.getCreateName());
-
+        if (StringUtils.isNotEmpty(mxup.getSjcjjd()) && mxup.getSjcjjd().length()>12){
+            mxup.setSjcjjd(mxup.getSjcjjd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjwd()) && mxup.getSjcjwd().length()>12){
+            mxup.setSjcjwd(mxup.getSjcjwd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjjwdu()) && mxup.getSjcjjwdu().length()>50){
+            mxup.setSjcjjwdu(mxup.getSjcjjwdu().substring(0,50));
+        }
 
         // 售后网点处理
         websitSH = publicService.ptshwdToshshwd(mxup.getCzwd(), orderBase.getMainId());
@@ -2122,14 +2134,6 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
             }
         }
         mxup.setGmsj(orderBase.getBuyTime());
-
-        if (StringUtils.isNotEmpty(orderBase.getLat()) && orderBase.getLat().length()>12){
-            mxup.setSjcjjd(orderBase.getLat().substring(0,12));
-        }
-        if (StringUtils.isNotEmpty(orderBase.getLng()) && orderBase.getLng().length()>12){
-            mxup.setSjcjwd(orderBase.getLng().substring(0,12));
-        }
-        mxup.setSjcjjwdu(mxup.getSjcjjd()+","+ mxup.getSjcjwd());
     }
 
     public void setOtherParm(OrderBase orderBase, ItfTblAzAssignLcLsUpload lcls, Integer cjstat,
@@ -2144,6 +2148,16 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         websitSH = publicService.ptshwdToshshwd(mxup.getCzwd(), orderBase.getMainId());
         mxup.setCzwd(websitSH.getWdId());
 
+        if (StringUtils.isNotEmpty(mxup.getSjcjjd()) && mxup.getSjcjjd().length()>12){
+            mxup.setSjcjjd(mxup.getSjcjjd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjwd()) && mxup.getSjcjwd().length()>12){
+            mxup.setSjcjwd(mxup.getSjcjwd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjjwdu()) && mxup.getSjcjjwdu().length()>50){
+            mxup.setSjcjjwdu(mxup.getSjcjjwdu().substring(0,50));
+        }
+
         // 提取安装师傅的账号信息
         mxup.setAzrenid(publicService.getBrandWorkerId(orderBase.getWorkerId(),websitSH.getWdId(),brand.getBrandId(),orderBase.getWebsitId()));
 
@@ -2168,13 +2182,7 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         mxup.setGmsj(orderBase.getBuyTime());
         mxup.setCjwdno(mxup.getAzwdno());
         mxup.setZjczwd(mxup.getAzwdno());
-        if (StringUtils.isNotEmpty(orderBase.getLat()) && orderBase.getLat().length()>12){
-            mxup.setSjcjjd(orderBase.getLat().substring(0,12));
-        }
-        if (StringUtils.isNotEmpty(orderBase.getLng()) && orderBase.getLng().length()>12){
-            mxup.setSjcjwd(orderBase.getLng().substring(0,12));
-        }
-        mxup.setSjcjjwdu(mxup.getSjcjjd()+","+ mxup.getSjcjwd());
+
     }
 
     public void setSyParm(OrderBase orderBase, ItfTblAzAssignLcLsUpload lcls, Integer cjstat,
@@ -2186,6 +2194,16 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         mxup.setCjren(orderBase.getCreateBy());
         mxup.setCjrmc(orderBase.getCreateName());
 
+        if (StringUtils.isNotEmpty(mxup.getSjcjjd()) && mxup.getSjcjjd().length()>12){
+            mxup.setSjcjjd(mxup.getSjcjjd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjwd()) && mxup.getSjcjwd().length()>12){
+            mxup.setSjcjwd(mxup.getSjcjwd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjjwdu()) && mxup.getSjcjjwdu().length()>50){
+            mxup.setSjcjjwdu(mxup.getSjcjjwdu().substring(0,50));
+        }
+
         // 售后网点处理
         websitSH = publicService.ptshwdToshshwd(mxup.getCzwd(), orderBase.getMainId());
         mxup.setCzwd(websitSH.getWdId());
@@ -2214,13 +2232,6 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         mxup.setGmsj(orderBase.getBuyTime());
         mxup.setCjwdno(mxup.getAzwdno());
         mxup.setZjczwd(mxup.getAzwdno());
-        if (StringUtils.isNotEmpty(orderBase.getLat()) && orderBase.getLat().length()>12){
-            mxup.setSjcjjd(orderBase.getLat().substring(0,12));
-        }
-        if (StringUtils.isNotEmpty(orderBase.getLng()) && orderBase.getLng().length()>12){
-            mxup.setSjcjwd(orderBase.getLng().substring(0,12));
-        }
-        mxup.setSjcjjwdu(mxup.getSjcjjd()+","+ mxup.getSjcjwd());
 
         // 网点维修工ID单独处理
         // 先找出网点编号对应的品牌商网点编号
@@ -2250,6 +2261,16 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         mxup.setCjren(orderBase.getCreateBy());
         mxup.setCjrmc(orderBase.getCreateName());
 
+        if (StringUtils.isNotEmpty(mxup.getSjcjjd()) && mxup.getSjcjjd().length()>12){
+            mxup.setSjcjjd(mxup.getSjcjjd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjwd()) && mxup.getSjcjwd().length()>12){
+            mxup.setSjcjwd(mxup.getSjcjwd().substring(0,12));
+        }
+        if (StringUtils.isNotEmpty(mxup.getSjcjjwdu()) && mxup.getSjcjjwdu().length()>50){
+            mxup.setSjcjjwdu(mxup.getSjcjjwdu().substring(0,50));
+        }
+
         // 售后网点处理
         websitSH = publicService.ptshwdToshshwd(mxup.getCzwd(), orderBase.getMainId());
         mxup.setCzwd(websitSH.getWdId());
@@ -2278,13 +2299,6 @@ log.info("测试信息a   id={} ",ojtutl.getSynReqId());
         mxup.setGmsj(orderBase.getBuyTime());
         mxup.setCjwdno(mxup.getAzwdno());
         mxup.setZjczwd(mxup.getAzwdno());
-        if (StringUtils.isNotEmpty(orderBase.getLat()) && orderBase.getLat().length()>12){
-            mxup.setSjcjjd(orderBase.getLat().substring(0,12));
-        }
-        if (StringUtils.isNotEmpty(orderBase.getLng()) && orderBase.getLng().length()>12){
-            mxup.setSjcjwd(orderBase.getLng().substring(0,12));
-        }
-        mxup.setSjcjjwdu(mxup.getSjcjjd()+","+ mxup.getSjcjwd());
 
         // 网点维修工ID单独处理
         // 先找出网点编号对应的品牌商网点编号

+ 12 - 6
src/main/resources/mapper/DetailOrderInstallMapper.xml

@@ -27,7 +27,8 @@
                if(length(a.gps_address)>140,left(a.gps_address,140),a.gps_address) as sjcjgps,
                if(a.first_time=0,a.update_time,a.first_time) as sjcjsj,'' as kjmm2,
                g.bracket as zjia,g.pipe as jcguan,g.swith_flag as kqkg,g.high_altitude as gkzy,g.hole as yccxqk,
-               a.websit_id as zjczwdxtbh,a.first_time as wcsj
+               a.websit_id as zjczwdxtbh,a.first_time as wcsj,
+               a.lat as sjcjjd,a.lng as sjcjwd,CONCAT(a.lat,',',a.lng) as sjcjjwdu
         from order_install_detail a
                  left join order_product b on b.order_base_id = a.order_base_id and a.order_product_id=b.id
                  left join sys_dict_ref c on c.dict_code=a.main_id and c.brand_id = #{request.brandId} and c.dict_type='MAIN_TYPE'
@@ -62,7 +63,8 @@
                if(length(a.gps_address)>140,left(a.gps_address,140),a.gps_address) as sjcjgps,
                if(a.first_time=0,a.update_time,a.first_time) as sjcjsj,
                g.bracket as zjia,g.pipe as jcguan,g.swith_flag as kqkg,g.high_altitude as gkzy,g.hole as yccxqk,
-               a.websit_id as zjczwdxtbh,a.first_time as wcsj
+               a.websit_id as zjczwdxtbh,a.first_time as wcsj,
+               a.lat as sjcjjd,a.lng as sjcjwd,CONCAT(a.lat,',',a.lng) as sjcjjwdu
         from order_install_detail a
                  left join order_product b on b.order_base_id = a.order_base_id and a.order_product_id=b.id
                  left join sys_dict_ref c on c.dict_code=a.main_id and c.brand_id = #{request.brandId} and c.dict_type='MAIN_TYPE'
@@ -98,7 +100,8 @@
                if(length(a.gps_address)>140,left(a.gps_address,140),a.gps_address) as sjcjgps,
                if(a.first_time=0,a.update_time,a.first_time) as sjcjsj,'' as kjmm2,
                g.bracket as zjia,g.pipe as jcguan,g.swith_flag as kqkg,g.high_altitude as gkzy,g.hole as yccxqk,
-               a.websit_id as zjczwdxtbh,a.first_time as wcsj
+               a.websit_id as zjczwdxtbh,a.first_time as wcsj,
+               a.lat as sjcjjd,a.lng as sjcjwd,CONCAT(a.lat,',',a.lng) as sjcjjwdu
         from order_install_detail a
                  left join order_product b on b.order_base_id = a.order_base_id and a.order_product_id=b.id
                  left join sys_dict_ref c on c.dict_code=a.main_id and c.brand_id = #{request.brandId} and c.dict_type='MAIN_TYPE'
@@ -133,7 +136,8 @@
                if(length(a.gps_address)>140,left(a.gps_address,140),a.gps_address) as sjcjgps,
                if(a.first_time=0,a.update_time,a.first_time) as sjcjsj,'' as kjmm2,
                g.bracket as zjia,g.pipe as jcguan,g.swith_flag as kqkg,g.high_altitude as gkzy,g.hole as yccxqk,
-               a.websit_id as zjczwdxtbh,a.first_time as wcsj
+               a.websit_id as zjczwdxtbh,a.first_time as wcsj,
+               a.lat as sjcjjd,a.lng as sjcjwd,CONCAT(a.lat,',',a.lng) as sjcjjwdu
         from order_install_detail a
                  left join order_product b on b.order_base_id = a.order_base_id and a.order_product_id=b.id
                  left join sys_dict_ref c on c.dict_code=a.main_id and c.brand_id = #{request.brandId} and c.dict_type='MAIN_TYPE'
@@ -168,7 +172,8 @@
                if(length(a.gps_address)>140,left(a.gps_address,140),a.gps_address) as sjcjgps,
                if(a.first_time=0,a.update_time,a.first_time) as sjcjsj,
                g.bracket as zjia,g.pipe as jcguan,g.swith_flag as kqkg,g.high_altitude as gkzy,g.hole as yccxqk,
-               a.websit_id as zjczwdxtbh,a.first_time as wcsj
+               a.websit_id as zjczwdxtbh,a.first_time as wcsj,
+               a.lat as sjcjjd,a.lng as sjcjwd,CONCAT(a.lat,',',a.lng) as sjcjjwdu
         from order_install_detail a
                  left join order_product b on b.order_base_id = a.order_base_id and a.order_product_id=b.id
                  left join sys_dict_ref c on c.dict_code=a.main_id and c.brand_id = #{request.brandId} and c.dict_type='MAIN_TYPE'
@@ -203,7 +208,8 @@
                if(length(a.gps_address)>140,left(a.gps_address,140),a.gps_address) as sjcjgps,
                if(a.first_time=0,a.update_time,a.first_time) as sjcjsj,'' as kjmm2,
                g.bracket as zjia,g.pipe as jcguan,g.swith_flag as kqkg,g.high_altitude as gkzy,g.hole as yccxqk,
-               a.websit_id as zjczwdxtbh,a.first_time as wcsj
+               a.websit_id as zjczwdxtbh,a.first_time as wcsj,
+               a.lat as sjcjjd,a.lng as sjcjwd,CONCAT(a.lat,',',a.lng) as sjcjjwdu
         from order_install_detail a
                  left join order_product b on b.order_base_id = a.order_base_id and a.order_product_id=b.id
                  left join sys_dict_ref c on c.dict_code=a.main_id and c.brand_id = #{request.brandId} and c.dict_type='MAIN_TYPE'