From 26acdd7f6c4ff458af9d54e4edafcc10789d1fd9 Mon Sep 17 00:00:00 2001 From: Jessica Wang Date: Thu, 22 Jan 2015 13:23:00 -0800 Subject: [PATCH] volume-upload: volumes > (1) Shorten action label to make all items in header to fit into one line, otherwise search box will be pushed out of place. (2) Add dialog: move URL field to the top. --- ui/scripts/storage.js | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/ui/scripts/storage.js b/ui/scripts/storage.js index c754e3c930b..bf832c20f66 100644 --- a/ui/scripts/storage.js +++ b/ui/scripts/storage.js @@ -68,7 +68,7 @@ actions: { // Add volume add: { - label: 'label.add.volume', + label: 'Add', preFilter: function(args) { return !args.context.instances; @@ -255,18 +255,25 @@ uploadVolume: { isHeader: true, - label: 'label.upload.volume', + label: 'Upload', preFilter: function(args) { return !args.context.instances; }, messages: { notification: function() { - return 'label.upload.volume'; + return 'Upload Volume from URL'; } }, createForm: { - title: 'label.upload.volume', + title: 'Upload Volume from URL', fields: { + url: { + label: 'label.url', + docID: 'helpUploadVolumeURL', + validation: { + required: true + } + }, name: { label: 'label.name', validation: { @@ -321,14 +328,7 @@ data: items }); } - }, - url: { - label: 'label.url', - docID: 'helpUploadVolumeURL', - validation: { - required: true - } - }, + }, checksum: { docID: 'helpUploadVolumeChecksum', label: 'label.md5.checksum' @@ -380,7 +380,7 @@ uploadVolumefromLocal: { isHeader: true, - label: 'Upload Volume from Local', + label: 'Upload from Local', preFilter: function(args) { return !args.context.instances; }, @@ -445,7 +445,10 @@ fields: { volumeFileUpload: { label: 'local file', - isFileUpload: true + isFileUpload: true, + validation: { + required: true + } }, name: { label: 'label.name',