1
0
Fork 0
mirror of https://github.com/Oreolek/ifhub.club.git synced 2024-06-26 03:30:48 +03:00

Fix media

This commit is contained in:
Denis Shakhov 2015-11-18 23:41:37 +07:00
parent dc9b236ce4
commit b5c20d2dbd
2 changed files with 10 additions and 1 deletions

View file

@ -153,6 +153,13 @@
this._list.lsUploaderFileList( 'option', 'multiselect_ctrl', false );
this.elements.uploader.lsUploader( 'filterFilesByType', [ '1' ] );
}
if ( type === 'url' ) {
var url = this.elements.url.url.val();
this.elements.url.submit_insert.prop( 'disabled', ! url );
this.elements.url.submit_upload.prop( 'disabled', ! url );
}
},
/**
@ -305,6 +312,9 @@
var _this = this,
url = this.elements.url.url.val();
this.elements.url.submit_insert.prop( 'disabled', ! url );
this.elements.url.submit_upload.prop( 'disabled', ! url );
$('<img />', {
src: url,
style: 'max-width: 50%',

View file

@ -19,7 +19,6 @@
{* Ссылка *}
{component 'field' template='text'
name = 'url'
value = 'http://'
inputClasses = 'js-media-url-form-url'
label = {lang 'media.url.fields.url.label'}}
</form>