Set the placeholder attribute in forms.py
Closes-Bug: #1640059 Change-Id: I4428d4c6ef7c198b480595bda8e12d8794b25e8d
This commit is contained in:
parent
0323f1fd17
commit
016724d4ed
@ -230,15 +230,6 @@ horizon.forms.add_password_fields_reveal_buttons = function (el) {
|
||||
});
|
||||
};
|
||||
|
||||
horizon.forms.init_examples = function (el) {
|
||||
var $el = $(el);
|
||||
|
||||
// FIXME(gabriel): These should be moved into the forms themselves as help text, etc.
|
||||
|
||||
// Update/create image form.
|
||||
$el.find("#create_image_form input#id_copy_from").attr("placeholder", "http://example.com/image.iso");
|
||||
};
|
||||
|
||||
horizon.forms.init_themable_select = function ($elem) {
|
||||
"use strict";
|
||||
|
||||
@ -348,9 +339,6 @@ horizon.addInitFunction(horizon.forms.init = function () {
|
||||
horizon.forms.init_themable_select();
|
||||
horizon.modals.addModalInitFunction(horizon.forms.init_themable_select);
|
||||
|
||||
horizon.forms.init_examples($body);
|
||||
horizon.modals.addModalInitFunction(horizon.forms.init_examples);
|
||||
|
||||
horizon.forms.handle_snapshot_source();
|
||||
horizon.forms.handle_volume_source();
|
||||
horizon.forms.handle_image_source();
|
||||
|
@ -125,7 +125,8 @@ class CreateImageForm(CreateParent):
|
||||
'data-switch-on': 'source',
|
||||
'data-source-url': _('Image Location'),
|
||||
'ng-model': 'ctrl.copyFrom',
|
||||
'ng-change': 'ctrl.selectImageFormat(ctrl.copyFrom)'
|
||||
'ng-change': 'ctrl.selectImageFormat(ctrl.copyFrom)',
|
||||
'placeholder': 'http://example.com/image.img'
|
||||
}
|
||||
image_url = ImageURLField(label=_("Image Location"),
|
||||
help_text=_("An external (HTTP/HTTPS) URL to "
|
||||
|
Loading…
x
Reference in New Issue
Block a user