]>
Commit | Line | Data |
---|---|---|
897ec54d C |
1 | <div class="row"> |
2 | <div class="content-padding"> | |
dc8bc31b | 3 | |
897ec54d | 4 | <h3>Update {{ video?.name }}</h3> |
1cdb5c0f | 5 | |
897ec54d C |
6 | <div *ngIf="error" class="alert alert-danger">{{ error }}</div> |
7 | ||
8 | <form novalidate [formGroup]="form"> | |
9 | <div class="form-group"> | |
10 | <label for="name">Name</label> | |
11 | <input | |
12 | type="text" class="form-control" id="name" | |
13 | formControlName="name" | |
14 | > | |
15 | <div *ngIf="formErrors.name" class="alert alert-danger"> | |
16 | {{ formErrors.name }} | |
17 | </div> | |
dc8bc31b | 18 | </div> |
dc8bc31b | 19 | |
897ec54d C |
20 | <div class="form-group"> |
21 | <label for="nsfw">NSFW</label> | |
22 | <input | |
23 | type="checkbox" id="nsfw" | |
24 | formControlName="nsfw" | |
25 | > | |
26 | </div> | |
92fb909c | 27 | |
897ec54d C |
28 | <div class="form-group"> |
29 | <label for="category">Category</label> | |
30 | <select class="form-control" id="category" formControlName="category"> | |
31 | <option></option> | |
32 | <option *ngFor="let category of videoCategories" [value]="category.id">{{ category.label }}</option> | |
33 | </select> | |
6e07c3de | 34 | |
897ec54d C |
35 | <div *ngIf="formErrors.category" class="alert alert-danger"> |
36 | {{ formErrors.category }} | |
37 | </div> | |
6e07c3de | 38 | </div> |
6e07c3de | 39 | |
897ec54d C |
40 | <div class="form-group"> |
41 | <label for="licence">Licence</label> | |
42 | <select class="form-control" id="licence" formControlName="licence"> | |
43 | <option></option> | |
44 | <option *ngFor="let licence of videoLicences" [value]="licence.id">{{ licence.label }}</option> | |
45 | </select> | |
d07137b9 | 46 | |
897ec54d C |
47 | <div *ngIf="formErrors.licence" class="alert alert-danger"> |
48 | {{ formErrors.licence }} | |
49 | </div> | |
d07137b9 | 50 | </div> |
d07137b9 | 51 | |
897ec54d C |
52 | <div class="form-group"> |
53 | <label for="language">Language</label> | |
54 | <select class="form-control" id="language" formControlName="language"> | |
55 | <option></option> | |
56 | <option *ngFor="let language of videoLanguages" [value]="language.id">{{ language.label }}</option> | |
57 | </select> | |
db216afd | 58 | |
897ec54d C |
59 | <div *ngIf="formErrors.language" class="alert alert-danger"> |
60 | {{ formErrors.language }} | |
61 | </div> | |
db216afd | 62 | </div> |
db216afd | 63 | |
897ec54d C |
64 | <div class="form-group"> |
65 | <label for="tags" class="label-tags">Tags</label> <span class="little-information">(press enter to add the tag)</span> | |
66 | <tag-input | |
67 | [ngModel]="tags" [validators]="tagValidators" [errorMessages]="tagValidatorsMessages" | |
68 | formControlName="tags" maxItems="3" modelAsStrings="true" | |
69 | ></tag-input> | |
70 | </div> | |
bf57d5ee | 71 | |
897ec54d C |
72 | <div class="form-group"> |
73 | <label for="description">Description</label> | |
74 | <textarea | |
75 | id="description" class="form-control" placeholder="Description..." | |
76 | formControlName="description" | |
77 | > | |
78 | </textarea> | |
79 | <div *ngIf="formErrors.description" class="alert alert-danger"> | |
80 | {{ formErrors.description }} | |
81 | </div> | |
dc8bc31b | 82 | </div> |
dc8bc31b | 83 | |
897ec54d C |
84 | <div class="form-group"> |
85 | <input | |
86 | type="button" value="Update" class="btn btn-default form-control" | |
87 | (click)="update()" | |
88 | > | |
89 | </div> | |
90 | </form> | |
e822fdae | 91 | </div> |
897ec54d | 92 | </div> |