|
@@ -603,11 +603,13 @@ public class MaterialInfoServiceImpl extends ServiceImpl<MaterialInfoMapper, Mat
|
|
|
}
|
|
|
}
|
|
|
JSONArray tagList = json.getJSONArray("tagList");
|
|
|
- for(int m=0;m<tagList.size();m++){
|
|
|
- Long tagId = tagList.getLong(m);
|
|
|
- TagInfo tagInfo = tagInfoService.getById(tagId);
|
|
|
- MaterialTagInfo setTag= new MaterialTagInfo(code,tagInfo,userId);
|
|
|
- materialTagInfoService.save(setTag);
|
|
|
+ if(null!=tagList&&!tagList.isEmpty()){
|
|
|
+ for(int m=0;m<tagList.size();m++){
|
|
|
+ Long tagId = tagList.getLong(m);
|
|
|
+ TagInfo tagInfo = tagInfoService.getById(tagId);
|
|
|
+ MaterialTagInfo setTag= new MaterialTagInfo(code,tagInfo,userId);
|
|
|
+ materialTagInfoService.save(setTag);
|
|
|
+ }
|
|
|
}
|
|
|
getFile(info, project.getMediaId());
|
|
|
ResultMapUtils.setResultMap(resultMap, StatusCode.COMMON_SUCCESS.getCode());
|