2019-10-24 22:53:53 +00:00
|
|
|
<mg-ajax path="dms/upload" options="vnPost"></mg-ajax>
|
2019-06-06 11:59:11 +00:00
|
|
|
<vn-watcher
|
|
|
|
vn-id="watcher"
|
|
|
|
data="$ctrl.dms">
|
|
|
|
</vn-watcher>
|
2020-09-17 18:12:52 +00:00
|
|
|
<vn-crud-model
|
|
|
|
auto-load="true"
|
|
|
|
url="Companies"
|
|
|
|
data="companies"
|
|
|
|
order="code">
|
|
|
|
</vn-crud-model>
|
|
|
|
<vn-crud-model
|
|
|
|
auto-load="true"
|
|
|
|
url="Warehouses"
|
|
|
|
data="warehouses"
|
|
|
|
order="name">
|
|
|
|
</vn-crud-model>
|
|
|
|
<vn-crud-model
|
|
|
|
auto-load="true"
|
|
|
|
url="DmsTypes"
|
|
|
|
data="dmsTypes"
|
|
|
|
order="name">
|
|
|
|
</vn-crud-model>
|
2019-10-04 22:16:57 +00:00
|
|
|
<form
|
|
|
|
name="form"
|
|
|
|
ng-submit="$ctrl.onSubmit()"
|
|
|
|
class="vn-ma-md"
|
|
|
|
enctype="multipart/form-data">
|
2019-11-10 10:08:44 +00:00
|
|
|
<div class="vn-w-md">
|
2019-10-04 22:16:57 +00:00
|
|
|
<vn-card class="vn-pa-lg">
|
2019-06-06 11:59:11 +00:00
|
|
|
<vn-horizontal>
|
2019-10-09 22:47:29 +00:00
|
|
|
<vn-textfield
|
|
|
|
vn-one
|
|
|
|
vn-focus
|
2019-06-06 11:59:11 +00:00
|
|
|
label="Reference"
|
2019-10-09 22:47:29 +00:00
|
|
|
ng-model="$ctrl.dms.reference"
|
|
|
|
rule>
|
2019-06-06 11:59:11 +00:00
|
|
|
</vn-textfield>
|
|
|
|
<vn-autocomplete vn-one
|
|
|
|
label="Company"
|
2019-10-09 22:47:29 +00:00
|
|
|
ng-model="$ctrl.dms.companyId"
|
2020-09-17 18:12:52 +00:00
|
|
|
data="companies"
|
2019-06-06 11:59:11 +00:00
|
|
|
show-field="code"
|
|
|
|
value-field="id">
|
|
|
|
</vn-autocomplete>
|
|
|
|
</vn-horizontal>
|
|
|
|
<vn-horizontal>
|
|
|
|
<vn-autocomplete vn-one
|
|
|
|
label="Warehouse"
|
2019-10-09 22:47:29 +00:00
|
|
|
ng-model="$ctrl.dms.warehouseId"
|
2020-09-17 18:12:52 +00:00
|
|
|
data="warehouses"
|
2019-06-06 11:59:11 +00:00
|
|
|
show-field="name"
|
|
|
|
value-field="id">
|
|
|
|
</vn-autocomplete>
|
|
|
|
<vn-autocomplete vn-one
|
|
|
|
label="Type"
|
2019-10-09 22:47:29 +00:00
|
|
|
ng-model="$ctrl.dms.dmsTypeId"
|
2020-09-17 18:12:52 +00:00
|
|
|
data="dmsTypes"
|
2019-06-06 11:59:11 +00:00
|
|
|
show-field="name"
|
|
|
|
value-field="id">
|
|
|
|
</vn-autocomplete>
|
|
|
|
</vn-horizontal>
|
|
|
|
<vn-horizontal>
|
2019-10-09 22:47:29 +00:00
|
|
|
<vn-textarea
|
|
|
|
vn-one
|
2019-06-06 11:59:11 +00:00
|
|
|
label="Description"
|
2019-10-09 22:47:29 +00:00
|
|
|
ng-model="$ctrl.dms.description"
|
|
|
|
rule>
|
2019-06-06 11:59:11 +00:00
|
|
|
</vn-textarea>
|
|
|
|
</vn-horizontal>
|
|
|
|
<vn-horizontal>
|
2019-10-28 20:40:24 +00:00
|
|
|
<vn-input-file
|
|
|
|
vn-one
|
2019-06-06 11:59:11 +00:00
|
|
|
label="File"
|
2019-10-28 20:40:24 +00:00
|
|
|
ng-model="$ctrl.dms.files"
|
|
|
|
on-change="$ctrl.onFileChange($files)"
|
2019-08-08 06:37:03 +00:00
|
|
|
accept="{{$ctrl.allowedContentTypes}}"
|
|
|
|
required="true"
|
|
|
|
multiple="true">
|
2019-10-09 22:47:29 +00:00
|
|
|
<append>
|
2019-08-08 06:37:03 +00:00
|
|
|
<vn-icon vn-none
|
2019-11-10 10:08:44 +00:00
|
|
|
color-marginal
|
2019-08-08 06:37:03 +00:00
|
|
|
title="{{$ctrl.contentTypesInfo}}"
|
|
|
|
icon="info">
|
|
|
|
</vn-icon>
|
2019-10-09 22:47:29 +00:00
|
|
|
</append>
|
2019-06-06 11:59:11 +00:00
|
|
|
</vn-input-file>
|
|
|
|
</vn-horizontal>
|
|
|
|
<vn-vertical>
|
|
|
|
<vn-check
|
2019-07-16 11:37:25 +00:00
|
|
|
label="Generate identifier for original file"
|
2019-10-09 22:47:29 +00:00
|
|
|
ng-model="$ctrl.dms.hasFile">
|
2019-06-06 11:59:11 +00:00
|
|
|
</vn-check>
|
|
|
|
</vn-vertical>
|
|
|
|
</vn-card>
|
|
|
|
<vn-button-bar>
|
|
|
|
<vn-submit label="Upload"></vn-submit>
|
|
|
|
<vn-button ui-sref="client.card.dms.index" label="Cancel"></vn-button>
|
|
|
|
</vn-button-bar>
|
|
|
|
</div>
|
|
|
|
</form>
|