|
@@ -539,6 +539,8 @@ static uploadFileManager * cur_uploadFileShareInstance = nil;
|
|
|
{
|
|
|
//逻辑待优化
|
|
|
BOOL isSuc = false;
|
|
|
+
|
|
|
+ BOOL isDelUploadingModel = false;
|
|
|
for (uploadFileDataModel *uploadFileDataMod in delArr) {
|
|
|
|
|
|
NSMutableString* where = [[NSMutableString alloc] initWithString:@"where "];
|
|
@@ -563,19 +565,46 @@ static uploadFileManager * cur_uploadFileShareInstance = nil;
|
|
|
if(isSuc && !isDelCache){//上传报云机已经存在文件了 查询本地是否有任务记录
|
|
|
[self handleRetryUploadAndDelRecordFun:uploadFileDataMod];
|
|
|
}
|
|
|
+
|
|
|
+ //是否在删除上传中的任务
|
|
|
+ if(_fileModelDataArr && _fileModelDataArr.count >0)
|
|
|
+ {
|
|
|
+ for (uploadFileDataModel *curUploadFileDataMod in _fileModelDataArr)
|
|
|
+ {
|
|
|
+ if(curUploadFileDataMod.bg_id.integerValue == uploadFileDataMod.bg_id.integerValue){
|
|
|
+ [_fileModelDataArr removeObject:curUploadFileDataMod];
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ if(!isDelUploadingModel){
|
|
|
+ if(_curUploadFileDataModel.bg_id.integerValue == uploadFileDataMod.bg_id.integerValue){
|
|
|
+ isDelUploadingModel = YES;
|
|
|
+
|
|
|
+ [[NSNotificationCenter defaultCenter] postNotificationName:uploadFileSuspendNotification object:nil];
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
- complete(isSuc);
|
|
|
-
|
|
|
- //继续下一个
|
|
|
- if(_fileModelDataArr){
|
|
|
- [_fileModelDataArr removeObject:_curUploadFileDataModel];
|
|
|
+ if(isDelUploadingModel){
|
|
|
_isUploadIngType = NO;
|
|
|
if(_fileModelDataArr.count >=1){
|
|
|
[self beginUploadFileFun];
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //继续下一个
|
|
|
+// if(_fileModelDataArr){
|
|
|
+// [_fileModelDataArr removeObject:_curUploadFileDataModel];
|
|
|
+// _isUploadIngType = NO;
|
|
|
+// if(_fileModelDataArr.count >=1){
|
|
|
+// [self beginUploadFileFun];
|
|
|
+// }
|
|
|
+// }
|
|
|
+
|
|
|
+ complete(isSuc);
|
|
|
+
|
|
|
}
|
|
|
|
|
|
#pragma mark 处理重复上传文件的问题
|