summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxinhuili <lxinhui@vmware.com>2017-03-30 20:12:05 -0700
committerxinhuili <lxinhui@vmware.com>2017-03-30 20:12:05 -0700
commit86abddb5cb581e2e14bc47bed7c404a1fbf66fcd (patch)
treeb68e583c7c15720e8b82da4f229d6a04e64f4156
parent3c29a80e90dbe9e9763a2eda0db108ec21ef38c7 (diff)
Add imagename support
This patch is to support imagename. Change-Id: I7dd0645699650cf639aa824efbaad3e56155ed59 Issue-ids: MULTIVIM-36 Signed-off-by: xinhuili <lxinhui@vmware.com>
-rw-r--r--vio/vio/swagger/views/volume/views.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/vio/vio/swagger/views/volume/views.py b/vio/vio/swagger/views/volume/views.py
index 0c38d5a..fa3131c 100644
--- a/vio/vio/swagger/views/volume/views.py
+++ b/vio/vio/swagger/views/volume/views.py
@@ -129,7 +129,7 @@ class CreateListVolumeView(APIView):
if body.get('imageId'):
image_op = OperateImage.OperateImage(vim_info)
- imageName = body.get('imageId')
+ imageName = body.get('imageId') or body.get('imageName')
image = image_op.find_vim_image(imageName)
body['imageId'] = image.id