648540858
2023-06-25 66eda32ab97d6e94e9f274d6faa4df586c452dfb
src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java
@@ -177,10 +177,10 @@
                  if (i + limitCount > channels.size()) {
                     toIndex = channels.size();
                  }
                  result = result || deviceChannelMapper.batchAdd(channels.subList(i, toIndex)) < 0;
                  result = result || deviceChannelMapper.batchAddOrUpdate(channels.subList(i, toIndex)) < 0;
               }
            }else {
               result = result || deviceChannelMapper.batchAdd(channels) < 0;
               result = result || deviceChannelMapper.batchAddOrUpdate(channels) < 0;
            }
         }
         if (result) {
@@ -278,10 +278,10 @@
                  if (i + limitCount > addChannels.size()) {
                     toIndex = addChannels.size();
                  }
                  result = result || deviceChannelMapper.batchAdd(addChannels.subList(i, toIndex)) < 0;
                  result = result || deviceChannelMapper.batchAddOrUpdate(addChannels.subList(i, toIndex)) < 0;
               }
            }else {
               result = result || deviceChannelMapper.batchAdd(addChannels) < 0;
               result = result || deviceChannelMapper.batchAddOrUpdate(addChannels) < 0;
            }
         }
         if (updateChannels.size() > 0) {
@@ -434,9 +434,6 @@
    */
   @Override
   public synchronized boolean insertMobilePosition(MobilePosition mobilePosition) {
      if (mobilePosition.getDeviceId().equals(mobilePosition.getChannelId())) {
         mobilePosition.setChannelId(null);
      }
      return deviceMobilePositionMapper.insertNewPosition(mobilePosition) > 0;
   }