OpenSlides/openslides/mediafiles/static/templates/mediafiles/mediafile-form.html
2017-02-17 12:43:50 +01:00

25 lines
901 B
HTML

<h1 ng-if="model.id" translate>Edit file</h1>
<h1 ng-if="!model.id" translate>New file</h1>
<div uib-alert ng-show="alert.show" ng-class="'alert-' + (alert.type || 'warning')" close="alert={}">
{{ alert.msg }}
</div>
<form name="mediafileForm" ng-submit="save(model)" novalidate>
<formly-form model="model" fields="formFields">
<i ng-if="model.file.$error.maxSize">File too large
{{ picFile.size / 1000000|number:1}}MB: max {{ mediafile.mediafile.$errorParam}}</i>
<uib-progressbar ng-if="activeUpload" value="progress" animate="false">
<span class="nobr">{{ progress }}%</span>
</uib-progressbar>
<button type="submit" ng-disabled="mediafileForm.$invalid || activeUpload" class="btn btn-primary" translate>
Save
</button>
<button type="button" ng-click="close()" class="btn btn-default" translate>
Cancel
</button>
</formly-form>
</form>