Lines 7-150
Link Here
|
7 |
<h2 v-else>{{ $__("New agreement") }}</h2> |
7 |
<h2 v-else>{{ $__("New agreement") }}</h2> |
8 |
<div> |
8 |
<div> |
9 |
<form @submit="onSubmit($event)"> |
9 |
<form @submit="onSubmit($event)"> |
10 |
<div class="page-section"> |
10 |
<fieldset class="rows"> |
11 |
<fieldset class="rows"> |
11 |
<ol> |
12 |
<ol> |
12 |
<li> |
13 |
<li> |
13 |
<label for="agreement_name" class="required" |
14 |
<label for="agreement_name" class="required" |
14 |
>{{ $__("Agreement name") }}:</label |
15 |
>{{ $__("Agreement name") }}:</label |
15 |
> |
16 |
> |
16 |
<input |
17 |
<input |
17 |
id="agreement_name" |
18 |
id="agreement_name" |
18 |
v-model="agreement.name" |
19 |
v-model="agreement.name" |
19 |
:placeholder="$__('Agreement name')" |
20 |
:placeholder="$__('Agreement name')" |
20 |
required |
21 |
required |
21 |
/> |
22 |
/> |
22 |
<span class="required">{{ |
23 |
<span class="required">{{ |
23 |
$__("Required") |
24 |
$__("Required") |
24 |
}}</span> |
25 |
}}</span> |
25 |
</li> |
26 |
</li> |
26 |
<li> |
27 |
<li> |
27 |
<label for="agreement_vendor_id" |
28 |
<label for="agreement_vendor_id" |
28 |
>{{ $__("Vendor") }}:</label |
29 |
>{{ $__("Vendor") }}:</label |
29 |
> |
30 |
> |
30 |
<v-select |
31 |
<v-select |
31 |
id="agreement_vendor_id" |
32 |
id="agreement_vendor_id" |
32 |
v-model="agreement.vendor_id" |
33 |
v-model="agreement.vendor_id" |
33 |
label="display_name" |
34 |
label="display_name" |
34 |
:reduce="vendor => vendor.id" |
35 |
:reduce="vendor => vendor.id" |
35 |
:options="vendors" |
36 |
:options="vendors" |
36 |
/> |
37 |
/> |
37 |
</li> |
38 |
</li> |
38 |
<li> |
39 |
<li> |
39 |
<label for="agreement_description" |
40 |
<label for="agreement_description" |
40 |
>{{ $__("Description") }}: |
41 |
>{{ $__("Description") }}: |
41 |
</label> |
42 |
</label> |
42 |
<textarea |
43 |
<textarea |
43 |
id="agreement_description" |
44 |
id="agreement_description" |
44 |
v-model="agreement.description" |
45 |
v-model="agreement.description" |
45 |
:placeholder="$__('Description')" |
46 |
:placeholder="$__('Description')" |
46 |
rows="10" |
47 |
rows="10" |
47 |
cols="50" |
48 |
cols="50" |
48 |
/> |
49 |
/> |
49 |
</li> |
50 |
</li> |
50 |
<li> |
51 |
<li> |
51 |
<label for="agreement_status" class="required" |
52 |
<label for="agreement_status" class="required" |
52 |
>{{ $__("Status") }}:</label |
53 |
>{{ $__("Status") }}:</label |
53 |
> |
54 |
> |
54 |
<v-select |
55 |
<v-select |
55 |
id="agreement_status" |
56 |
id="agreement_status" |
56 |
v-model="agreement.status" |
57 |
v-model="agreement.status" |
57 |
label="description" |
58 |
label="description" |
58 |
:reduce="av => av.value" |
59 |
:reduce="av => av.value" |
59 |
:options="av_agreement_statuses" |
60 |
:options="av_agreement_statuses" |
60 |
@option:selected="onStatusChanged" |
61 |
@option:selected="onStatusChanged" |
61 |
:required="!agreement.status" |
62 |
:required="!agreement.status" |
62 |
> |
63 |
> |
63 |
<template #search="{ attributes, events }"> |
64 |
<template #search="{ attributes, events }"> |
|
|
65 |
<input |
66 |
:required="!agreement.status" |
67 |
class="vs__search" |
68 |
v-bind="attributes" |
69 |
v-on="events" |
70 |
/> |
71 |
</template> |
72 |
</v-select> |
73 |
<span class="required">{{ |
74 |
$__("Required") |
75 |
}}</span> |
76 |
</li> |
77 |
<li> |
78 |
<label for="agreement_closure_reason" |
79 |
>{{ $__("Closure reason") }}:</label |
80 |
> |
81 |
<v-select |
82 |
id="agreement_closure_reason" |
83 |
v-model="agreement.closure_reason" |
84 |
label="description" |
85 |
:reduce="av => av.value" |
86 |
:options="av_agreement_closure_reasons" |
87 |
:disabled=" |
88 |
agreement.status == 'closed' |
89 |
? false |
90 |
: true |
91 |
" |
92 |
/> |
93 |
</li> |
94 |
<li> |
95 |
<label for="agreement_is_perpetual" |
96 |
>{{ $__("Is perpetual") }}:</label |
97 |
> |
98 |
<label |
99 |
class="radio" |
100 |
for="agreement_is_perpetual_yes" |
101 |
>Yes |
102 |
<input |
64 |
<input |
103 |
type="radio" |
65 |
:required="!agreement.status" |
104 |
name="is_perpetual" |
66 |
class="vs__search" |
105 |
id="agreement_is_perpetual_yes" |
67 |
v-bind="attributes" |
106 |
:value="true" |
68 |
v-on="events" |
107 |
v-model="agreement.is_perpetual" |
|
|
108 |
/> |
69 |
/> |
109 |
</label> |
70 |
</template> |
110 |
<label |
71 |
</v-select> |
111 |
class="radio" |
72 |
<span class="required">{{ |
112 |
for="agreement_is_perpetual_no" |
73 |
$__("Required") |
113 |
>No |
74 |
}}</span> |
114 |
<input |
75 |
</li> |
115 |
type="radio" |
76 |
<li> |
116 |
name="is_perpetual" |
77 |
<label for="agreement_closure_reason" |
117 |
id="agreement_is_perpetual_no" |
78 |
>{{ $__("Closure reason") }}:</label |
118 |
:value="false" |
79 |
> |
119 |
v-model="agreement.is_perpetual" |
80 |
<v-select |
120 |
/> |
81 |
id="agreement_closure_reason" |
121 |
</label> |
82 |
v-model="agreement.closure_reason" |
122 |
</li> |
83 |
label="description" |
123 |
<li> |
84 |
:reduce="av => av.value" |
124 |
<label for="agreement_renewal_priority" |
85 |
:options="av_agreement_closure_reasons" |
125 |
>{{ $__("Renewal priority") }}:</label |
86 |
:disabled=" |
126 |
> |
87 |
agreement.status == 'closed' |
127 |
<v-select |
88 |
? false |
128 |
id="agreement_renewal_priority" |
89 |
: true |
129 |
v-model="agreement.renewal_priority" |
90 |
" |
130 |
label="description" |
91 |
/> |
131 |
:reduce="av => av.value" |
92 |
</li> |
132 |
:options="av_agreement_renewal_priorities" |
93 |
<li> |
|
|
94 |
<label for="agreement_is_perpetual" |
95 |
>{{ $__("Is perpetual") }}:</label |
96 |
> |
97 |
<label |
98 |
class="radio" |
99 |
for="agreement_is_perpetual_yes" |
100 |
>Yes |
101 |
<input |
102 |
type="radio" |
103 |
name="is_perpetual" |
104 |
id="agreement_is_perpetual_yes" |
105 |
:value="true" |
106 |
v-model="agreement.is_perpetual" |
133 |
/> |
107 |
/> |
134 |
</li> |
108 |
</label> |
135 |
<li> |
109 |
<label |
136 |
<label for="agreement_license_info" |
110 |
class="radio" |
137 |
>{{ $__("License info") }}: |
111 |
for="agreement_is_perpetual_no" |
138 |
</label> |
112 |
>No |
139 |
<textarea |
113 |
<input |
140 |
id="agreement_license_info" |
114 |
type="radio" |
141 |
v-model="agreement.license_info" |
115 |
name="is_perpetual" |
142 |
placeholder="License info" |
116 |
id="agreement_is_perpetual_no" |
|
|
117 |
:value="false" |
118 |
v-model="agreement.is_perpetual" |
143 |
/> |
119 |
/> |
144 |
</li> |
120 |
</label> |
145 |
</ol> |
121 |
</li> |
146 |
</fieldset> |
122 |
<li> |
147 |
</div> |
123 |
<label for="agreement_renewal_priority" |
|
|
124 |
>{{ $__("Renewal priority") }}:</label |
125 |
> |
126 |
<v-select |
127 |
id="agreement_renewal_priority" |
128 |
v-model="agreement.renewal_priority" |
129 |
label="description" |
130 |
:reduce="av => av.value" |
131 |
:options="av_agreement_renewal_priorities" |
132 |
/> |
133 |
</li> |
134 |
<li> |
135 |
<label for="agreement_license_info" |
136 |
>{{ $__("License info") }}: |
137 |
</label> |
138 |
<textarea |
139 |
id="agreement_license_info" |
140 |
v-model="agreement.license_info" |
141 |
placeholder="License info" |
142 |
/> |
143 |
</li> |
144 |
</ol> |
145 |
</fieldset> |
148 |
<AgreementPeriods :periods="agreement.periods" /> |
146 |
<AgreementPeriods :periods="agreement.periods" /> |
149 |
<UserRoles |
147 |
<UserRoles |
150 |
:user_type="$__('Agreement user')" |
148 |
:user_type="$__('Agreement user')" |