|
@@ -47,6 +47,10 @@ func UpdateImage(c *gin.Context, apictx *ApiSession) (interface{}, error) {
|
|
|
if !found {
|
|
|
return nil, NewError("未找到数据")
|
|
|
}
|
|
|
+ // 未更改图片
|
|
|
+ if matImage.RawImage == nil {
|
|
|
+ return repo.RepoUpdateSetDoc(apictx.CreateRepoCtx(), repo.CollectionMatImages, matImage.Id.Hex(), &matImage)
|
|
|
+ }
|
|
|
// 更新了面料原图 对应更新fassi 特征数据
|
|
|
if searchMat.RawImage.Url != matImage.RawImage.Url {
|
|
|
// 先删除
|