| 16849 |
stevensc |
1 |
<?php
|
| 16822 |
efrain |
2 |
$currentUser = $this->currentUserHelper();
|
|
|
3 |
$currentUser = $currentUser->getUser();
|
| 16761 |
efrain |
4 |
|
| 1 |
www |
5 |
$routeTimeline = $this->url('feeds/timeline');
|
| 16761 |
efrain |
6 |
|
| 16841 |
efrain |
7 |
$this->headLink()->appendStylesheet($this->basePath('assets/vendors/nprogress/nprogress.css'));
|
|
|
8 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/nprogress/nprogress.js'));
|
| 16822 |
efrain |
9 |
|
| 16841 |
efrain |
10 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/ckeditor/ckeditor.js'));
|
| 16822 |
efrain |
11 |
|
| 16841 |
efrain |
12 |
$this->headLink()->appendStylesheet($this->basePath('assets/vendors/bootstrap-fileinput/css/fileinput.min.css'));
|
|
|
13 |
$this->headLink()->appendStylesheet($this->basePath('assets/vendors/bootstrap-fileinput/themes/explorer-fa/theme.css'));
|
| 16822 |
efrain |
14 |
|
| 16843 |
efrain |
15 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-fileinput/js/plugins/piexif.js'));
|
|
|
16 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-fileinput/js/plugins/sortable.js'));
|
| 16841 |
efrain |
17 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-fileinput/js/fileinput.js'));
|
|
|
18 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-fileinput/js/locales/es.js'));
|
|
|
19 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-fileinput/themes/fa/theme.js'));
|
|
|
20 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-fileinput/themes/explorer-fa/theme.js'));
|
| 16822 |
efrain |
21 |
|
| 17019 |
efrain |
22 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/moment/moment-with-locales.min.js'));
|
| 17003 |
efrain |
23 |
$this->headLink()->appendStylesheet($this->basePath('assets/vendors/bootstrap-datetimepicker/css/bootstrap-datetimepicker.css'));
|
|
|
24 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js'));
|
| 16822 |
efrain |
25 |
|
| 17019 |
efrain |
26 |
$this->headLink()->appendStylesheet($this->basePath('assets/vendors/bootstrap4-toggle/css/bootstrap4-toggle.min.css'));
|
|
|
27 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootstrap4-toggle/js/bootstrap4-toggle.min.js'));
|
|
|
28 |
|
| 16841 |
efrain |
29 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/jsrender/jsrender.min.js'));
|
| 16822 |
efrain |
30 |
|
| 16841 |
efrain |
31 |
$this->inlineScript()->appendFile($this->basePath('assets/vendors/bootbox/bootbox.all.min.js'));
|
| 16822 |
efrain |
32 |
|
|
|
33 |
$this->inlineScript()->captureStart();
|
|
|
34 |
echo <<<JS
|
|
|
35 |
jQuery( document ).ready(function( $ ) {
|
|
|
36 |
var feed_unique_shared = '';
|
|
|
37 |
|
|
|
38 |
$.validator.addMethod('requiredContent', function (value, element, param) {
|
|
|
39 |
value = $.trim($.fn.stripHtml(value));
|
|
|
40 |
return value.length > 0;
|
|
|
41 |
}, 'ERROR_REQUIRED');
|
|
|
42 |
|
|
|
43 |
$.fn.reload = function(page) {
|
|
|
44 |
NProgress.start();
|
|
|
45 |
$.ajax({
|
|
|
46 |
'dataType' : 'json',
|
|
|
47 |
'accept' : 'application/json',
|
|
|
48 |
'method' : 'get',
|
|
|
49 |
'data' : {
|
|
|
50 |
'page' : page
|
|
|
51 |
},
|
|
|
52 |
'url' : '$routeTimeline'
|
|
|
53 |
}).done(function(response) {
|
|
|
54 |
if(response['success']) {
|
|
|
55 |
$('.posts-section').empty();
|
|
|
56 |
|
|
|
57 |
$( ".posts-section" ).append(
|
|
|
58 |
$( "#feedTemplate" ).render( response['data']['current']['items'] )
|
|
|
59 |
);
|
|
|
60 |
|
| 17019 |
efrain |
61 |
|
| 16822 |
efrain |
62 |
if(response['data']['total']['pages'] > 1 ) {
|
| 17019 |
efrain |
63 |
|
| 16822 |
efrain |
64 |
$('#paginator-process-comm').show();
|
|
|
65 |
if(response['data']['current']['page'] > 1) {
|
|
|
66 |
$('#btn-page-previous').data('page', response['data']['current']['page'] - 1);
|
|
|
67 |
$('#btn-page-previous').show();
|
|
|
68 |
} else {
|
|
|
69 |
$('#btn-page-previous').hide();
|
| 17019 |
efrain |
70 |
}
|
| 16822 |
efrain |
71 |
if(response['data']['current']['page'] < response['data']['total']['pages']) {
|
|
|
72 |
$('#btn-page-next').data('page', response['data']['current']['page'] + 1);
|
|
|
73 |
$('#btn-page-next').show();
|
|
|
74 |
} else {
|
|
|
75 |
$('#btn-page-next').hide();
|
| 17019 |
efrain |
76 |
}
|
| 16822 |
efrain |
77 |
|
|
|
78 |
$('#paginator-process-comm').show();
|
| 17019 |
efrain |
79 |
|
| 16822 |
efrain |
80 |
} else {
|
|
|
81 |
$('#paginator-process-comm').hide();
|
|
|
82 |
}
|
| 17019 |
efrain |
83 |
|
|
|
84 |
|
| 16822 |
efrain |
85 |
} else {
|
|
|
86 |
$.fn.showError(response['data']);
|
| 17019 |
efrain |
87 |
}
|
| 16822 |
efrain |
88 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
89 |
$.fn.showError(textStatus);
|
|
|
90 |
}).always(function() {
|
|
|
91 |
NProgress.done();
|
|
|
92 |
});
|
|
|
93 |
|
|
|
94 |
}
|
|
|
95 |
|
|
|
96 |
$('#btn-page-previous').click(function(e) {
|
|
|
97 |
e.preventDefault();
|
|
|
98 |
|
|
|
99 |
var page = $(this).data('page');
|
|
|
100 |
$.fn.reload(page);
|
| 17019 |
efrain |
101 |
|
| 16822 |
efrain |
102 |
});
|
|
|
103 |
|
|
|
104 |
$('#btn-page-next').click(function(e) {
|
|
|
105 |
e.preventDefault();
|
|
|
106 |
|
|
|
107 |
var page = $(this).data('page');
|
|
|
108 |
$.fn.reload(page);
|
| 17019 |
efrain |
109 |
|
| 16822 |
efrain |
110 |
});
|
|
|
111 |
|
|
|
112 |
|
|
|
113 |
|
| 17019 |
efrain |
114 |
|
| 16822 |
efrain |
115 |
var validatorFeed = $('#form-feed').validate({
|
|
|
116 |
debug: true,
|
|
|
117 |
onclick: false,
|
|
|
118 |
onkeyup: false,
|
|
|
119 |
onfocusout: false,
|
|
|
120 |
ignore: [],
|
|
|
121 |
rules: {
|
|
|
122 |
'shared_with' : {
|
|
|
123 |
required: true,
|
|
|
124 |
},
|
|
|
125 |
'description': {
|
|
|
126 |
updateCkeditor:function() {
|
|
|
127 |
CKEDITOR.instances.description_feed.updateElement();
|
|
|
128 |
},
|
|
|
129 |
required: true
|
|
|
130 |
},
|
|
|
131 |
},
|
|
|
132 |
|
|
|
133 |
submitHandler: function(form)
|
|
|
134 |
{
|
|
|
135 |
$('input[type="submit"]').prop('disabled', true);
|
|
|
136 |
NProgress.start();
|
|
|
137 |
$.ajax({
|
|
|
138 |
'dataType' : 'json',
|
|
|
139 |
'accept' : 'application/json',
|
|
|
140 |
'method' : 'post',
|
|
|
141 |
'url' : $('#form-feed').attr('action'),
|
|
|
142 |
'data' : $('#form-feed').serialize(),
|
|
|
143 |
}).done(function(response) {
|
|
|
144 |
if(response['success']) {
|
|
|
145 |
var s = $( "#feedTemplate" ).render( response['data'] );
|
| 17019 |
efrain |
146 |
$(s).prependTo(".posts-section");
|
| 16822 |
efrain |
147 |
|
|
|
148 |
$('#form-feed')[0].reset()
|
| 17019 |
efrain |
149 |
$("#modal-feed-box").modal('hide');
|
| 16822 |
efrain |
150 |
} else {
|
|
|
151 |
validatorFeed.resetForm();
|
|
|
152 |
if(jQuery.type(response['data']) == 'string') {
|
|
|
153 |
$.fn.showError(response['data']);
|
|
|
154 |
} else {
|
|
|
155 |
$.each(response['data'], function( fieldname, errors ) {
|
|
|
156 |
$.fn.showFormErrorValidator('#form-feed #' + fieldname, errors);
|
|
|
157 |
});
|
|
|
158 |
}
|
|
|
159 |
}
|
|
|
160 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
161 |
$.fn.showError(textStatus);
|
|
|
162 |
}).always(function() {
|
|
|
163 |
$('input[type="submit"]').prop('disabled', false);
|
|
|
164 |
NProgress.done();
|
|
|
165 |
});
|
|
|
166 |
return false;
|
|
|
167 |
},
|
|
|
168 |
invalidHandler: function(form, validator) {
|
| 17019 |
efrain |
169 |
|
| 16822 |
efrain |
170 |
}
|
|
|
171 |
});
|
|
|
172 |
|
|
|
173 |
$('.btn-modal-feed-close').click(function(e) {
|
|
|
174 |
e.preventDefault();
|
|
|
175 |
$('#form-feed')[0].reset()
|
|
|
176 |
$('#modal-feed-box').modal('hide');
|
|
|
177 |
return false;
|
|
|
178 |
});
|
|
|
179 |
|
|
|
180 |
$('#description-main, #btn-description-main').click(function(e) {
|
|
|
181 |
e.preventDefault();
|
|
|
182 |
|
| 17019 |
efrain |
183 |
$('.nav-tabs a[href="#tab-share-basic"]').tab('show');
|
|
|
184 |
|
|
|
185 |
$('#form-feed #notification_active').prop('checked', false);
|
|
|
186 |
$('#form-feed #notification_custom_active').prop('checked', false);
|
|
|
187 |
$('#form-feed #notification_custom_active').attr('disabled', 'disabled');
|
|
|
188 |
|
|
|
189 |
|
|
|
190 |
$('#form-feed #notification_custom_title').val('');
|
|
|
191 |
$('#form-feed #notification_custom_title').attr('readonly', 'readonly');
|
|
|
192 |
_
|
|
|
193 |
|
|
|
194 |
CKEDITOR.instances.notification_custom_description_share.setData('');
|
|
|
195 |
CKEDITOR.instances.notification_custom_description_sahre.setReadOnly(true);
|
|
|
196 |
|
|
|
197 |
|
| 16822 |
efrain |
198 |
$('#form-feed')[0].reset()
|
|
|
199 |
validatorFeed.resetForm();
|
| 17019 |
efrain |
200 |
$("#modal-feed-box").modal('show');
|
| 16822 |
efrain |
201 |
})
|
|
|
202 |
|
|
|
203 |
var validatorFeedImage = $('#form-feed-image').validate({
|
|
|
204 |
debug: true,
|
|
|
205 |
onclick: false,
|
|
|
206 |
onkeyup: false,
|
|
|
207 |
onfocusout: false,
|
|
|
208 |
ignore: [],
|
|
|
209 |
rules: {
|
|
|
210 |
'shared_with' : {
|
|
|
211 |
required: true,
|
|
|
212 |
},
|
|
|
213 |
'description': {
|
|
|
214 |
updateCkeditor:function() {
|
|
|
215 |
CKEDITOR.instances.description_image.updateElement();
|
|
|
216 |
},
|
|
|
217 |
required: true
|
|
|
218 |
},
|
|
|
219 |
'file': {
|
|
|
220 |
required: true,
|
|
|
221 |
extension: 'jpg|jpeg|png',
|
|
|
222 |
accept: 'image/jpg,image/jpeg,image/png'
|
|
|
223 |
},
|
|
|
224 |
},
|
|
|
225 |
|
|
|
226 |
submitHandler: function(form)
|
|
|
227 |
{
|
|
|
228 |
var formdata = false;
|
|
|
229 |
if (window.FormData){
|
|
|
230 |
formdata = new FormData(form); //form[0]);
|
|
|
231 |
}
|
|
|
232 |
|
|
|
233 |
$('input[type="submit"]').prop('disabled', true);
|
|
|
234 |
NProgress.start();
|
|
|
235 |
$.ajax({
|
|
|
236 |
'dataType' : 'json',
|
|
|
237 |
'accept' : 'application/json',
|
|
|
238 |
'method' : 'post',
|
|
|
239 |
'url' : $('#form-feed-image').attr('action'),
|
|
|
240 |
'data' : formdata ? formdata : $('#form-feed-image').serialize(),
|
|
|
241 |
'processData': false,
|
|
|
242 |
'contentType': false,
|
|
|
243 |
}).done(function(response) {
|
|
|
244 |
if(response['success']) {
|
|
|
245 |
|
| 17019 |
efrain |
246 |
|
| 16822 |
efrain |
247 |
var s = $( "#feedTemplate" ).render( response['data'] );
|
| 17019 |
efrain |
248 |
$(s).prependTo(".posts-section");
|
| 16822 |
efrain |
249 |
|
|
|
250 |
$("#modal-feed-image-box").modal('hide');
|
|
|
251 |
} else {
|
|
|
252 |
validatorFeedImage.resetForm();
|
|
|
253 |
if(jQuery.type(response['data']) == 'string') {
|
|
|
254 |
$.fn.showError(response['data']);
|
|
|
255 |
} else {
|
|
|
256 |
$.each(response['data'], function( fieldname, errors ) {
|
| 17019 |
efrain |
257 |
|
| 16929 |
efrain |
258 |
$.fn.showFormErrorValidator('#form-feed-image #' + fieldname, errors);
|
| 17019 |
efrain |
259 |
|
| 16822 |
efrain |
260 |
});
|
|
|
261 |
}
|
|
|
262 |
}
|
|
|
263 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
264 |
$.fn.showError(textStatus);
|
|
|
265 |
}).always(function() {
|
|
|
266 |
$('input[type="submit"]').prop('disabled', false);
|
|
|
267 |
NProgress.done();
|
|
|
268 |
});
|
|
|
269 |
return false;
|
|
|
270 |
},
|
|
|
271 |
invalidHandler: function(form, validator) {
|
| 17019 |
efrain |
272 |
|
| 16822 |
efrain |
273 |
}
|
|
|
274 |
});
|
|
|
275 |
|
|
|
276 |
var validatorFeedVideo = $('#form-feed-video').validate({
|
|
|
277 |
debug: true,
|
|
|
278 |
onclick: false,
|
|
|
279 |
onkeyup: false,
|
|
|
280 |
onfocusout: false,
|
|
|
281 |
ignore: [],
|
|
|
282 |
rules: {
|
|
|
283 |
'shared_with' : {
|
|
|
284 |
required: true,
|
|
|
285 |
},
|
|
|
286 |
'description': {
|
|
|
287 |
updateCkeditor:function() {
|
|
|
288 |
CKEDITOR.instances.description_video.updateElement();
|
|
|
289 |
},
|
|
|
290 |
required: true
|
|
|
291 |
},
|
|
|
292 |
'file': {
|
|
|
293 |
required: true,
|
|
|
294 |
extension: 'webm,mp4,webm',
|
|
|
295 |
accept: 'video/webm,video/mpeg,video/mp4'
|
|
|
296 |
},
|
|
|
297 |
},
|
|
|
298 |
|
|
|
299 |
submitHandler: function(form)
|
|
|
300 |
{
|
|
|
301 |
var formdata = false;
|
|
|
302 |
if (window.FormData){
|
|
|
303 |
formdata = new FormData(form); //form[0]);
|
|
|
304 |
}
|
|
|
305 |
|
|
|
306 |
$('input[type="submit"]').prop('disabled', true);
|
|
|
307 |
NProgress.start();
|
|
|
308 |
$.ajax({
|
|
|
309 |
'dataType' : 'json',
|
|
|
310 |
'accept' : 'application/json',
|
|
|
311 |
'method' : 'post',
|
|
|
312 |
'url' : $('#form-feed-video').attr('action'),
|
|
|
313 |
'data' : formdata ? formdata : $('#form-feed-video').serialize(),
|
|
|
314 |
'processData': false,
|
|
|
315 |
'contentType': false,
|
|
|
316 |
}).done(function(response) {
|
|
|
317 |
if(response['success']) {
|
|
|
318 |
var s = $( "#feedTemplate" ).render( response['data'] );
|
| 17019 |
efrain |
319 |
$(s).prependTo(".posts-section");
|
| 16822 |
efrain |
320 |
|
|
|
321 |
$("#modal-feed-video-box").modal('hide');
|
|
|
322 |
} else {
|
|
|
323 |
validatorFeedVideo.resetForm();
|
|
|
324 |
if(jQuery.type(response['data']) == 'string') {
|
|
|
325 |
$.fn.showError(response['data']);
|
|
|
326 |
} else {
|
|
|
327 |
$.each(response['data'], function( fieldname, errors ) {
|
|
|
328 |
$.fn.showFormErrorValidator('#form-feed-video #' + fieldname, errors);
|
|
|
329 |
});
|
|
|
330 |
}
|
|
|
331 |
}
|
|
|
332 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
333 |
$.fn.showError(textStatus);
|
|
|
334 |
}).always(function() {
|
|
|
335 |
$('input[type="submit"]').prop('disabled', false);
|
|
|
336 |
NProgress.done();
|
|
|
337 |
});
|
|
|
338 |
return false;
|
|
|
339 |
},
|
|
|
340 |
invalidHandler: function(form, validator) {
|
| 17019 |
efrain |
341 |
|
| 16822 |
efrain |
342 |
}
|
|
|
343 |
});
|
|
|
344 |
|
|
|
345 |
var validatorFeedDocument = $('#form-feed-document').validate({
|
|
|
346 |
debug: true,
|
|
|
347 |
onclick: false,
|
|
|
348 |
onkeyup: false,
|
|
|
349 |
onfocusout: false,
|
|
|
350 |
ignore: [],
|
|
|
351 |
rules: {
|
|
|
352 |
'shared_with' : {
|
|
|
353 |
required: true,
|
|
|
354 |
},
|
|
|
355 |
'description': {
|
|
|
356 |
updateCkeditor:function() {
|
|
|
357 |
CKEDITOR.instances.description_document.updateElement();
|
|
|
358 |
},
|
|
|
359 |
required: true
|
|
|
360 |
},
|
|
|
361 |
'file': {
|
|
|
362 |
required: true,
|
|
|
363 |
extension: 'pdf',
|
|
|
364 |
accept: 'application/pdf'
|
|
|
365 |
},
|
|
|
366 |
},
|
|
|
367 |
|
|
|
368 |
submitHandler: function(form)
|
|
|
369 |
{
|
|
|
370 |
var formdata = false;
|
|
|
371 |
if (window.FormData){
|
|
|
372 |
formdata = new FormData(form); //form[0]);
|
|
|
373 |
}
|
|
|
374 |
|
|
|
375 |
$('input[type="submit"]').prop('disabled', true);
|
|
|
376 |
NProgress.start();
|
|
|
377 |
$.ajax({
|
|
|
378 |
'dataType' : 'json',
|
|
|
379 |
'accept' : 'application/json',
|
|
|
380 |
'method' : 'post',
|
|
|
381 |
'url' : $('#form-feed-document').attr('action'),
|
|
|
382 |
'data' : formdata ? formdata : $('#form-feed-document').serialize(),
|
|
|
383 |
'processData': false,
|
|
|
384 |
'contentType': false,
|
|
|
385 |
}).done(function(response) {
|
|
|
386 |
if(response['success']) {
|
|
|
387 |
var s = $( "#feedTemplate" ).render( response['data'] );
|
| 17019 |
efrain |
388 |
$(s).prependTo(".posts-section");
|
| 16822 |
efrain |
389 |
|
|
|
390 |
$("#modal-feed-document-box").modal('hide');
|
|
|
391 |
} else {
|
|
|
392 |
validatorFeedDocument.resetForm();
|
|
|
393 |
if(jQuery.type(response['data']) == 'string') {
|
|
|
394 |
$.fn.showError(response['data']);
|
|
|
395 |
} else {
|
|
|
396 |
$.each(response['data'], function( fieldname, errors ) {
|
|
|
397 |
$.fn.showFormErrorValidator('#form-feed-document #' + fieldname, errors);
|
|
|
398 |
});
|
|
|
399 |
}
|
|
|
400 |
}
|
|
|
401 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
402 |
$.fn.showError(textStatus);
|
|
|
403 |
}).always(function() {
|
|
|
404 |
$('input[type="submit"]').prop('disabled', false);
|
|
|
405 |
NProgress.done();
|
|
|
406 |
});
|
|
|
407 |
return false;
|
|
|
408 |
},
|
|
|
409 |
invalidHandler: function(form, validator) {
|
| 17019 |
efrain |
410 |
|
| 16822 |
efrain |
411 |
}
|
|
|
412 |
});
|
|
|
413 |
|
|
|
414 |
|
|
|
415 |
|
|
|
416 |
|
| 17019 |
efrain |
417 |
|
| 16845 |
efrain |
418 |
$('i.fa-file').on('click', function(e){
|
| 16822 |
efrain |
419 |
e.preventDefault();
|
|
|
420 |
|
| 17019 |
efrain |
421 |
$('.nav-tabs a[href="#tab-document-basic"]').tab('show');
|
|
|
422 |
|
| 16822 |
efrain |
423 |
$('#form-feed-document #shared_with').val('');
|
|
|
424 |
$('#form-feed-document #file').val('');
|
|
|
425 |
CKEDITOR.instances.description_document.setData('');
|
|
|
426 |
|
| 17019 |
efrain |
427 |
$('#form-feed-document #notification_active').prop('checked', false);
|
|
|
428 |
$('#form-feed-document #notification_custom_active').prop('checked', false);
|
|
|
429 |
$('#form-feed-document #notification_custom_active').attr('disabled', 'disabled');
|
|
|
430 |
|
|
|
431 |
|
|
|
432 |
$('#form-feed-document #notification_custom_title').val('');
|
|
|
433 |
$('#form-feed-document #notification_custom_title').attr('readonly', 'readonly');
|
|
|
434 |
|
|
|
435 |
|
|
|
436 |
CKEDITOR.instances.notification_custom_description_document.setData('');
|
|
|
437 |
CKEDITOR.instances.notification_custom_description_document.setReadOnly(true);
|
|
|
438 |
|
| 16822 |
efrain |
439 |
$('#form-feed-document')[0].reset()
|
|
|
440 |
validatorFeedDocument.resetForm();
|
|
|
441 |
$('#modal-feed-document-box').modal('show');
|
|
|
442 |
});
|
|
|
443 |
|
|
|
444 |
$('#form-feed-document #file').fileinput({
|
|
|
445 |
theme: 'fa',
|
|
|
446 |
language: 'es',
|
|
|
447 |
showUpload: false,
|
|
|
448 |
dropZoneEnabled: false,
|
|
|
449 |
maxFileCount: 1,
|
|
|
450 |
allowedFileExtensions: ['pdf'],
|
|
|
451 |
});
|
|
|
452 |
|
| 17019 |
efrain |
453 |
|
| 16822 |
efrain |
454 |
$('.btn-modal-feed-document-close').on('click', function(e){
|
|
|
455 |
e.preventDefault();
|
| 17019 |
efrain |
456 |
|
| 16822 |
efrain |
457 |
$('#modal-feed-document-box').modal('hide');
|
|
|
458 |
return false;
|
|
|
459 |
});
|
|
|
460 |
|
|
|
461 |
|
| 16845 |
efrain |
462 |
$('i.fa-camera').on('click', function(e){
|
| 16822 |
efrain |
463 |
e.preventDefault();
|
|
|
464 |
|
| 17019 |
efrain |
465 |
$('.nav-tabs a[href="#tab-image-basic"]').tab('show');
|
|
|
466 |
|
| 16822 |
efrain |
467 |
$('#form-feed-image #shared_with').val('');
|
|
|
468 |
$('#form-feed-image #file').val('');
|
|
|
469 |
CKEDITOR.instances.description_image.setData('');
|
|
|
470 |
|
| 17019 |
efrain |
471 |
$('#form-feed-image #notification_active').prop('checked', false);
|
|
|
472 |
$('#form-feed-image #notification_custom_active').prop('checked', false);
|
|
|
473 |
$('#form-feed-image #notification_custom_active').attr('disabled', 'disabled');
|
|
|
474 |
|
|
|
475 |
|
|
|
476 |
$('#form-feed-image #notification_custom_title').val('');
|
|
|
477 |
$('#form-feed-image #notification_custom_title').attr('readonly', 'readonly');
|
|
|
478 |
|
|
|
479 |
|
|
|
480 |
CKEDITOR.instances.notification_custom_description_video.setData('');
|
|
|
481 |
CKEDITOR.instances.notification_custom_description_video.setReadOnly(true);
|
|
|
482 |
|
|
|
483 |
|
| 16822 |
efrain |
484 |
$('#form-feed-image')[0].reset()
|
|
|
485 |
validatorFeedImage.resetForm();
|
|
|
486 |
$('#modal-feed-image-box').modal('show');
|
|
|
487 |
});
|
|
|
488 |
|
|
|
489 |
$('#form-feed-image #file').fileinput({
|
|
|
490 |
theme: 'fa',
|
|
|
491 |
language: 'es',
|
|
|
492 |
showUpload: false,
|
|
|
493 |
dropZoneEnabled: false,
|
|
|
494 |
maxFileCount: 1,
|
|
|
495 |
allowedFileExtensions: ['jpg', 'jpeg', 'png', 'gif'],
|
|
|
496 |
});
|
|
|
497 |
|
| 17019 |
efrain |
498 |
|
| 16822 |
efrain |
499 |
$('.btn-modal-feed-image-close').on('click', function(e){
|
|
|
500 |
e.preventDefault();
|
| 17019 |
efrain |
501 |
|
| 16822 |
efrain |
502 |
$('#modal-feed-image-box').modal('hide');
|
|
|
503 |
return false;
|
|
|
504 |
});
|
|
|
505 |
|
|
|
506 |
|
| 16845 |
efrain |
507 |
$('i.fa-video').on('click', function(e){
|
| 16822 |
efrain |
508 |
e.preventDefault();
|
|
|
509 |
|
| 17019 |
efrain |
510 |
$('.nav-tabs a[href="#tab-video-basic"]').tab('show');
|
|
|
511 |
|
| 16822 |
efrain |
512 |
$('#form-feed-video #shared_with').val('');
|
|
|
513 |
$('#form-feed-video #file').val('');
|
|
|
514 |
CKEDITOR.instances.description_video.setData('');
|
|
|
515 |
|
|
|
516 |
|
| 17019 |
efrain |
517 |
$('#form-feed-video #scheduled_active').prop('checked', false);
|
|
|
518 |
$('#form-feed-video #scheduled_timestamp').val('');
|
|
|
519 |
$('#form-feed-video #scheduled_timestamp').attr('readonly', 'readonly');
|
|
|
520 |
|
|
|
521 |
|
|
|
522 |
$('#form-feed-video #notification_active').prop('checked', false);
|
|
|
523 |
$('#form-feed-video #notification_custom_active').prop('checked', false);
|
|
|
524 |
$('#form-feed-video #notification_custom_active').attr('disabled', 'disabled');
|
|
|
525 |
|
|
|
526 |
|
|
|
527 |
$('#form-feed-video #notification_custom_title').val('');
|
|
|
528 |
$('#form-feed-video #notification_custom_title').attr('readonly', 'readonly');
|
|
|
529 |
|
|
|
530 |
|
|
|
531 |
CKEDITOR.instances.notification_custom_description_video.setData('');
|
|
|
532 |
CKEDITOR.instances.notification_custom_description_video.setReadOnly(true);
|
|
|
533 |
|
|
|
534 |
|
| 16822 |
efrain |
535 |
$('#form-feed-video')[0].reset()
|
|
|
536 |
validatorFeedVideo.resetForm();
|
|
|
537 |
$('#modal-feed-video-box').modal('show');
|
|
|
538 |
});
|
|
|
539 |
|
|
|
540 |
$('#form-feed-video #file').fileinput({
|
|
|
541 |
theme: 'fa',
|
|
|
542 |
language: 'es',
|
|
|
543 |
showUpload: false,
|
|
|
544 |
dropZoneEnabled: false,
|
|
|
545 |
maxFileCount: 1,
|
|
|
546 |
allowedFileExtensions: ['mp4', 'mpeg','webm'],
|
|
|
547 |
});
|
|
|
548 |
|
| 17019 |
efrain |
549 |
|
| 16822 |
efrain |
550 |
$('.btn-modal-feed-video-close').on('click', function(e){
|
|
|
551 |
e.preventDefault();
|
| 17019 |
efrain |
552 |
|
| 16822 |
efrain |
553 |
$('#modal-feed-video-box').modal('hide');
|
|
|
554 |
return false;
|
|
|
555 |
});
|
|
|
556 |
|
|
|
557 |
$('body').on('click', 'a.btn-indicator', function(e) {
|
| 17019 |
efrain |
558 |
|
| 16822 |
efrain |
559 |
e.preventDefault();
|
|
|
560 |
});
|
|
|
561 |
|
|
|
562 |
|
|
|
563 |
|
|
|
564 |
|
|
|
565 |
|
| 17019 |
efrain |
566 |
|
| 16822 |
efrain |
567 |
$('body').on('submit', 'form.form-comment-feed', function(e) {
|
|
|
568 |
e.preventDefault();
|
|
|
569 |
|
|
|
570 |
var form = $(this);
|
|
|
571 |
var url = form.attr('action');
|
|
|
572 |
var unique = $(this).data('feed-unique');
|
|
|
573 |
|
|
|
574 |
NProgress.start();
|
|
|
575 |
$.ajax({
|
|
|
576 |
'dataType' : 'json',
|
|
|
577 |
'accept' : 'application/json',
|
|
|
578 |
'method' : 'post',
|
|
|
579 |
'url' : url,
|
|
|
580 |
'data' : form.serialize(),
|
|
|
581 |
}).done(function(response) {
|
|
|
582 |
if(response['success']) {
|
|
|
583 |
$('#comment-' + unique).val('');
|
|
|
584 |
|
|
|
585 |
var s = $( "#commentTemplate" ).render( response['data'] );
|
| 17019 |
efrain |
586 |
$(s).appendTo('ul.comment-sec-' + unique);
|
| 16822 |
efrain |
587 |
|
| 17019 |
efrain |
588 |
|
| 16845 |
efrain |
589 |
$('#btn-comments-' + unique).html('<i class="<i class="fa fa-comments"></i>"></i> ' + response['total_comments']);
|
| 16822 |
efrain |
590 |
|
|
|
591 |
$('form.form-comment-feed > input[name="comment"]').val('');
|
| 17019 |
efrain |
592 |
|
| 16822 |
efrain |
593 |
} else {
|
|
|
594 |
$.fn.showError(response['data']);
|
|
|
595 |
}
|
|
|
596 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
597 |
$.fn.showError(textStatus);
|
|
|
598 |
}).always(function() {
|
|
|
599 |
NProgress.done();
|
|
|
600 |
});
|
|
|
601 |
return false;
|
|
|
602 |
|
|
|
603 |
});
|
|
|
604 |
|
|
|
605 |
|
|
|
606 |
$.fn.deleteFeed = function(url, feed_unique) {
|
|
|
607 |
|
|
|
608 |
|
|
|
609 |
NProgress.start();
|
|
|
610 |
$.ajax({
|
|
|
611 |
'dataType' : 'json',
|
|
|
612 |
'accept' : 'application/json',
|
|
|
613 |
'method' : 'post',
|
|
|
614 |
'url' : url,
|
|
|
615 |
}).done(function(response) {
|
|
|
616 |
if(response['success']) {
|
|
|
617 |
$('.post-bar-' + feed_unique).remove();
|
|
|
618 |
|
|
|
619 |
$.fn.showSuccess(response['data']);
|
|
|
620 |
} else {
|
|
|
621 |
$.fn.showError(response['data']);
|
| 17019 |
efrain |
622 |
}
|
| 16822 |
efrain |
623 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
624 |
$.fn.showError(textStatus);
|
|
|
625 |
}).always(function() {
|
|
|
626 |
NProgress.done();
|
|
|
627 |
});
|
|
|
628 |
|
|
|
629 |
}
|
|
|
630 |
|
|
|
631 |
$('body').on('click', 'a.btn-feed-trash', function(e) {
|
|
|
632 |
e.preventDefault();
|
|
|
633 |
var url = $(this).data('link');
|
|
|
634 |
var feed_unique = $(this).data('feed-unique');
|
|
|
635 |
|
|
|
636 |
swal.fire({
|
|
|
637 |
title: 'LABEL_ARE_YOU_SURE',
|
|
|
638 |
message: 'LABEL_QUESTION_DELETE_POST',
|
|
|
639 |
icon: 'question',
|
|
|
640 |
cancelButtonText: 'LABEL_NO',
|
|
|
641 |
showCancelButton: true,
|
|
|
642 |
confirmButtonText: 'LABEL_YES'
|
|
|
643 |
}).then((result) => {
|
|
|
644 |
if (result.isConfirmed) {
|
|
|
645 |
$.fn.deleteFeed(url, feed_unique);
|
|
|
646 |
}
|
|
|
647 |
});
|
|
|
648 |
});
|
|
|
649 |
|
|
|
650 |
|
|
|
651 |
$.fn.deleteComment = function(url, unique) {
|
|
|
652 |
|
|
|
653 |
var feed_unique = $('.comment-' + unique).closest('div.comment-sec').data('feed-unique');
|
|
|
654 |
|
|
|
655 |
NProgress.start();
|
|
|
656 |
$.ajax({
|
|
|
657 |
'dataType' : 'json',
|
|
|
658 |
'accept' : 'application/json',
|
|
|
659 |
'method' : 'post',
|
|
|
660 |
'url' : url,
|
|
|
661 |
}).done(function(response) {
|
|
|
662 |
if(response['success']) {
|
|
|
663 |
|
|
|
664 |
$('.comment-' + unique).closest('li').remove();
|
|
|
665 |
$('#btn-comments-' + feed_unique).html('<i class="fa fa-comments"></i> ' + response['data']['total_comments']);
|
| 17019 |
efrain |
666 |
|
| 16822 |
efrain |
667 |
$.fn.showSuccess(response['data']['message']);
|
|
|
668 |
} else {
|
|
|
669 |
$.fn.showError(response['data']);
|
| 17019 |
efrain |
670 |
}
|
| 16822 |
efrain |
671 |
}).fail(function( jqXHR, textStatus, errorThrown) {
|
|
|
672 |
$.fn.showError(textStatus);
|
|
|
673 |
}).always(function() {
|
|
|
674 |
NProgress.done();
|
|
|
675 |
});
|
|
|
676 |
|
|
|
677 |
|
|
|
678 |
}
|
|
|
679 |
|
|
|
680 |
|
|
|
681 |
$('body').on('click', 'a.btn-comment-trash', function(e) {
|
|
|
682 |
e.preventDefault();
|
|
|
683 |
var url = $(this).data('link');
|
|
|
684 |
var unique = $(this).data('comment-unique');
|
| 17019 |
efrain |
685 |
|
| 16822 |
efrain |
686 |
swal.fire({
|
|
|
687 |
title: 'LABEL_ARE_YOU_SURE',
|
|
|
688 |
message: 'LABEL_QUESTION_DELETE_COMMENT',
|
|
|
689 |
icon: 'question',
|
|
|
690 |
cancelButtonText: 'LABEL_NO',
|
|
|
691 |
showCancelButton: true,
|
|
|
692 |
confirmButtonText: 'LABEL_YES'
|
|
|
693 |
}).then((result) => {
|
|
|
694 |
if (result.isConfirmed) {
|
|
|
695 |
$.fn.deleteComment(url, unique);
|
|
|
696 |
}
|
|
|
697 |
});
|
|
|
698 |
});
|
|
|
699 |
|
| 17019 |
efrain |
700 |
$('#form-feed #scheduled_timestamp').datetimepicker({
|
|
|
701 |
//viewMode: 'years',
|
|
|
702 |
locale: 'es',
|
|
|
703 |
format: 'YYYY-MM-DD HH:mm:ss'
|
|
|
704 |
});
|
| 16822 |
efrain |
705 |
|
| 17019 |
efrain |
706 |
$('#form-feed-document #scheduled_timestamp').datetimepicker({
|
|
|
707 |
//viewMode: 'years',
|
|
|
708 |
locale: 'es',
|
|
|
709 |
format: 'YYYY-MM-DD HH:mm:ss'
|
|
|
710 |
});
|
|
|
711 |
|
|
|
712 |
|
|
|
713 |
$ ('#form-feed-image #scheduled_timestamp').datetimepicker({
|
|
|
714 |
//viewMode: 'years',
|
|
|
715 |
locale: 'es',
|
|
|
716 |
format: 'YYYY-MM-DD HH:mm:ss'
|
|
|
717 |
});
|
|
|
718 |
|
|
|
719 |
$('#form-feed-video #scheduled_timestamp').datetimepicker({
|
|
|
720 |
//viewMode: 'years',
|
|
|
721 |
locale: 'es',
|
|
|
722 |
format: 'YYYY-MM-DD HH:mm:ss'
|
|
|
723 |
});
|
|
|
724 |
|
|
|
725 |
|
|
|
726 |
|
| 16822 |
efrain |
727 |
$('div.modal').on("hide.bs.modal", function() {
|
|
|
728 |
$(".wrapper").removeClass("overlay");
|
|
|
729 |
})
|
|
|
730 |
|
|
|
731 |
|
| 17019 |
efrain |
732 |
|
| 16822 |
efrain |
733 |
CKEDITOR.replace('description_feed');
|
|
|
734 |
CKEDITOR.replace('description_video');
|
|
|
735 |
CKEDITOR.replace('description_image');
|
|
|
736 |
CKEDITOR.replace('description_document');
|
|
|
737 |
|
| 17019 |
efrain |
738 |
CKEDITOR.replace('notification_custom_description_image');
|
|
|
739 |
CKEDITOR.replace('notification_custom_description_video');
|
|
|
740 |
CKEDITOR.replace('notification_custom_description_document');
|
|
|
741 |
CKEDITOR.replace('notification_custom_description_share');
|
| 16822 |
efrain |
742 |
|
| 17019 |
efrain |
743 |
|
|
|
744 |
$.fn.reload(1);
|
|
|
745 |
|
|
|
746 |
|
|
|
747 |
|
| 16822 |
efrain |
748 |
});
|
|
|
749 |
|
|
|
750 |
|
| 7154 |
stevensc |
751 |
JS;
|
| 16822 |
efrain |
752 |
$this->inlineScript()->captureEnd();
|
| 7154 |
stevensc |
753 |
|
| 1 |
www |
754 |
?>
|
|
|
755 |
|
| 16822 |
efrain |
756 |
<div class="container">
|
| 17019 |
efrain |
757 |
<h6 class="mb-2">LABEL_FEEDS</h6>
|
| 16849 |
stevensc |
758 |
|
| 17019 |
efrain |
759 |
<main class="feed-section">
|
|
|
760 |
<form class="theme-container p-2" id="form-main" name="form-main">
|
|
|
761 |
<input id="description-main" name="description-main"
|
|
|
762 |
placeholder="LABEL_WHAT_DO_YOU_HAVE_IN_MIND"
|
|
|
763 |
class="cursor-pointer mb-2" readonly="readonly" rows="2"></input>
|
| 16849 |
stevensc |
764 |
|
| 17019 |
efrain |
765 |
<div class="d-flex align-items-center justify-content-end gap-2">
|
|
|
766 |
<a class="btn btn-trans btn-icon add-tooltip" href="#"><i
|
|
|
767 |
class="fa fa-video"></i></a> <a
|
|
|
768 |
class="btn btn-trans btn-icon add-tooltip" href="#"><i
|
|
|
769 |
class="fa fa-camera"></i></a> <a
|
|
|
770 |
class="btn btn-trans btn-icon add-tooltip" href="#"><i
|
|
|
771 |
class="fa fa-file "></i></a>
|
|
|
772 |
<button class="btn btn-sm btn-primary" type="button"
|
|
|
773 |
id="btn-description-main">
|
|
|
774 |
<i class="fa fa-edit"></i> LABEL_SHARE
|
|
|
775 |
</button>
|
|
|
776 |
</div>
|
|
|
777 |
</form>
|
| 16885 |
stevensc |
778 |
|
| 17019 |
efrain |
779 |
<!--posts-section star-->
|
|
|
780 |
<div class="posts-section w-100"></div>
|
| 16853 |
stevensc |
781 |
|
| 17019 |
efrain |
782 |
<div class="process-comm" id="paginator-process-comm"
|
|
|
783 |
style="display: none">
|
|
|
784 |
<button class="btn btn-sm btn-primary" data-page="0"
|
|
|
785 |
id="btn-page-previous">
|
|
|
786 |
<i class="fa fa-chevron-left" aria-hidden="true"></i> LABEL_PREVIOUS
|
|
|
787 |
</button>
|
|
|
788 |
<button class="btn btn-sm btn-primary" data-page="0"
|
|
|
789 |
id="btn-page-next">
|
|
|
790 |
LABEL_NEXT <i class="fa fa-chevron-right" aria-hidden="true"></i>
|
|
|
791 |
</button>
|
|
|
792 |
</div>
|
|
|
793 |
<!--posts-section end-->
|
|
|
794 |
</main>
|
| 16849 |
stevensc |
795 |
|
| 17019 |
efrain |
796 |
<!--main-ws-sec end-->
|
| 16822 |
efrain |
797 |
</div>
|
|
|
798 |
|
|
|
799 |
|
| 16849 |
stevensc |
800 |
|
| 16822 |
efrain |
801 |
<div class="modal" tabindex="-1" role="dialog" id="modal-feed-image-box">
|
| 17019 |
efrain |
802 |
<div class="modal-dialog modal-xl" role="document">
|
| 16849 |
stevensc |
803 |
<?php
|
|
|
804 |
$form = $this->formFeed;
|
| 16822 |
efrain |
805 |
$form->setAttributes([
|
|
|
806 |
'method' => 'post',
|
|
|
807 |
'action' => $this->url('feeds/add'),
|
|
|
808 |
'name' => 'form-feed-image',
|
|
|
809 |
'id' => 'form-feed-image',
|
| 16849 |
stevensc |
810 |
'enctype' => 'multipart/form-data'
|
| 16822 |
efrain |
811 |
]);
|
|
|
812 |
$form->prepare();
|
|
|
813 |
echo $this->form()->openTag($form);
|
| 16849 |
stevensc |
814 |
|
|
|
815 |
?>
|
|
|
816 |
<div class="modal-content">
|
| 17019 |
efrain |
817 |
<div class="modal-header">
|
|
|
818 |
<h6 class="modal-title">LABEL_SHARE_IMAGE</h6>
|
|
|
819 |
</div>
|
|
|
820 |
<div class="modal-body">
|
| 16849 |
stevensc |
821 |
|
| 17019 |
efrain |
822 |
<ul class="nav nav-tabs" id="tabImage" role="tablist">
|
|
|
823 |
<li class="nav-item"><a class="nav-link active" id="tab-image-basic-tab"
|
|
|
824 |
data-bs-toggle="tab" href="#tab-image-basic" role="tab"
|
|
|
825 |
aria-controls="basic" aria-selected="true">LABEL_BASIC</a></li>
|
|
|
826 |
<li class="nav-item"><a class="nav-link" id="tab-image-scheduled-tab"
|
|
|
827 |
data-bs-toggle="tab" href="#tab-image-scheduled" role="tab"
|
|
|
828 |
aria-controls="scheduled" aria-selected="false">LABEL_SCHEDULED</a>
|
|
|
829 |
</li>
|
|
|
830 |
<li class="nav-item"><a class="nav-link" id="tab-image-notification-tab"
|
|
|
831 |
data-bs-toggle="tab" href="#tab-image-notification" role="tab"
|
|
|
832 |
aria-controls="notification" aria-selected="false">LABEL_NOTIFICATION</a>
|
|
|
833 |
</li>
|
|
|
834 |
</ul>
|
|
|
835 |
<div class="tab-content border border-top-0 p-3"
|
|
|
836 |
id="tabImageContent">
|
|
|
837 |
<div class="tab-pane fade show active" id="tab-image-basic" role="tabpanel"
|
|
|
838 |
aria-labelledby="tab-image-basic-tab">
|
|
|
839 |
|
|
|
840 |
<div class="row">
|
|
|
841 |
<div class="col-12 mt-3">
|
|
|
842 |
<?php
|
|
|
843 |
$element = $form->get('description');
|
|
|
844 |
$element->setAttributes([
|
|
|
845 |
'id' => 'description_image',
|
|
|
846 |
'rows' => '2',
|
|
|
847 |
'placeholder' => 'LABEL_WHAT_DO_YOU_HAVE_IN_MIND',
|
|
|
848 |
'class' => 'form-control'
|
|
|
849 |
]);
|
|
|
850 |
echo $this->formTextArea($element);
|
|
|
851 |
?>
|
|
|
852 |
</div>
|
|
|
853 |
</div>
|
|
|
854 |
<div class="row">
|
|
|
855 |
<div class="col-12 mt-3">
|
|
|
856 |
<?php
|
|
|
857 |
$element = $form->get('file');
|
|
|
858 |
$element->setAttributes([
|
|
|
859 |
'accept' => 'image/jpg,image/jpeg,image/png'
|
|
|
860 |
]);
|
|
|
861 |
echo $this->formFile($element);
|
|
|
862 |
?>
|
|
|
863 |
</div>
|
|
|
864 |
</div>
|
|
|
865 |
|
|
|
866 |
</div>
|
|
|
867 |
<div class="tab-pane fade" id="tab-image-scheduled" role="tabpanel"
|
|
|
868 |
aria-labelledby="tab-image-scheduled-tab">
|
|
|
869 |
<div class="row">
|
|
|
870 |
<div class="col-12 mt-3">
|
|
|
871 |
<div class="form-check mb-3">
|
|
|
872 |
<?php
|
|
|
873 |
$element = $form->get('scheduled_active');
|
|
|
874 |
$element->setAttributes([
|
|
|
875 |
'class' => 'form-check-input'
|
|
|
876 |
]);
|
|
|
877 |
$element->setOptions([
|
|
|
878 |
'label' => 'LABEL_SCHEDULED_ACTIVE',
|
|
|
879 |
'class' => 'form-check-label'
|
|
|
880 |
]);
|
|
|
881 |
echo $this->formCheckbox($element);
|
|
|
882 |
echo $this->formLabel($element);
|
|
|
883 |
?>
|
|
|
884 |
</div>
|
|
|
885 |
</div>
|
|
|
886 |
</div>
|
|
|
887 |
<div class="row">
|
|
|
888 |
<div class="col-12 mt-3">
|
|
|
889 |
<?php
|
|
|
890 |
$element = $form->get('scheduled_timestamp');
|
|
|
891 |
$element->setOptions([
|
|
|
892 |
'label' => 'LABEL_SCHEDULED_DATETIME',
|
|
|
893 |
'class' => 'form-label'
|
|
|
894 |
]);
|
|
|
895 |
$element->setAttributes([
|
|
|
896 |
'class' => 'form-control'
|
|
|
897 |
]);
|
|
|
898 |
echo $this->formLabel($element);
|
|
|
899 |
echo $this->formText($element);
|
|
|
900 |
?>
|
|
|
901 |
</div>
|
|
|
902 |
</div>
|
|
|
903 |
|
|
|
904 |
</div>
|
|
|
905 |
<div class="tab-pane fade" id="tab-image-notification" role="tabpanel"
|
|
|
906 |
aria-labelledby="tab-image-notification-tab">
|
|
|
907 |
<div class="row">
|
|
|
908 |
<div class="col-12 mt-3">
|
|
|
909 |
<div class="form-check mb-3">
|
|
|
910 |
<?php
|
|
|
911 |
$element = $form->get('notification_active');
|
|
|
912 |
$element->setAttributes([
|
|
|
913 |
'class' => 'form-check-input'
|
|
|
914 |
]);
|
|
|
915 |
$element->setOptions([
|
|
|
916 |
'label' => 'LABEL_NOTIFICATION_ACTIVE',
|
|
|
917 |
'class' => 'form-check-label'
|
|
|
918 |
]);
|
|
|
919 |
echo $this->formCheckbox($element);
|
|
|
920 |
echo $this->formLabel($element);
|
|
|
921 |
?>
|
|
|
922 |
</div>
|
|
|
923 |
</div>
|
|
|
924 |
</div>
|
|
|
925 |
<div class="row">
|
|
|
926 |
<div class="col-12 mt-3">
|
|
|
927 |
<div class="form-check mb-3">
|
|
|
928 |
<?php
|
|
|
929 |
$element = $form->get('notification_custom_active');
|
|
|
930 |
$element->setAttributes([
|
|
|
931 |
'class' => 'form-check-input'
|
|
|
932 |
]);
|
|
|
933 |
$element->setOptions([
|
|
|
934 |
'label' => 'LABEL_USE_CUSTOM_NOTIFICATION',
|
|
|
935 |
'class' => 'form-check-label'
|
|
|
936 |
]);
|
|
|
937 |
echo $this->formCheckbox($element);
|
|
|
938 |
echo $this->formLabel($element);
|
|
|
939 |
?>
|
|
|
940 |
</div>
|
|
|
941 |
|
|
|
942 |
</div>
|
|
|
943 |
</div>
|
|
|
944 |
|
|
|
945 |
<div class="row">
|
|
|
946 |
<div class="col-12 mt-3">
|
|
|
947 |
<?php
|
|
|
948 |
$element = $form->get('notification_custom_title');
|
|
|
949 |
$element->setOptions([
|
|
|
950 |
'label' => 'LABEL_TITLE',
|
|
|
951 |
'class' => 'form-label'
|
|
|
952 |
]);
|
|
|
953 |
$element->setAttributes([
|
|
|
954 |
'class' => 'form-control'
|
|
|
955 |
]);
|
|
|
956 |
echo $this->formLabel($element);
|
|
|
957 |
echo $this->formText($element);
|
|
|
958 |
?>
|
|
|
959 |
</div>
|
|
|
960 |
</div>
|
|
|
961 |
<div class="row">
|
|
|
962 |
<div class="col-12 mt-3">
|
|
|
963 |
<?php
|
|
|
964 |
$element = $form->get('notification_custom_description');
|
|
|
965 |
$element->setOptions([
|
|
|
966 |
'label' => 'LABEL_DESCRIPTION',
|
|
|
967 |
'class' => 'form-label'
|
|
|
968 |
]);
|
|
|
969 |
$element->setAttributes([
|
|
|
970 |
'id' => 'notification_custom_description_image',
|
|
|
971 |
'rows' => '2',
|
|
|
972 |
'class' => 'form-control'
|
|
|
973 |
]);
|
|
|
974 |
echo $this->formLabel($element);
|
|
|
975 |
echo $this->formTextArea($element);
|
|
|
976 |
?>
|
|
|
977 |
</div>
|
|
|
978 |
</div>
|
|
|
979 |
</div>
|
|
|
980 |
</div>
|
|
|
981 |
|
|
|
982 |
|
|
|
983 |
|
|
|
984 |
</div>
|
|
|
985 |
<div class="modal-footer text-right">
|
|
|
986 |
<button type="submit" class="btn btn-sm btn-primary save">LABEL_UPLOAD</button>
|
|
|
987 |
<button type="button"
|
|
|
988 |
class="btn btn-light cancel btn-modal-feed-image-close">LABEL_CANCEL</button>
|
|
|
989 |
</div>
|
|
|
990 |
|
|
|
991 |
</div>
|
|
|
992 |
<a href="#" title="" class="close-box btn-feed-image-close"><i
|
|
|
993 |
class="la la-close"></i></a>
|
| 16849 |
stevensc |
994 |
<?php echo $this->form()->closeTag($form); ?>
|
|
|
995 |
</div>
|
| 16822 |
efrain |
996 |
</div>
|
|
|
997 |
|
|
|
998 |
|
|
|
999 |
<div class="modal" tabindex="-1" role="dialog" id="modal-feed-video-box">
|
| 17019 |
efrain |
1000 |
<div class="modal-dialog modal-xl" role="document">
|
| 16849 |
stevensc |
1001 |
<?php
|
|
|
1002 |
$form = $this->formFeed;
|
| 16822 |
efrain |
1003 |
$form->setAttributes([
|
|
|
1004 |
'method' => 'post',
|
|
|
1005 |
'action' => $this->url('feeds/add'),
|
|
|
1006 |
'name' => 'form-feed-video',
|
|
|
1007 |
'id' => 'form-feed-video',
|
| 16849 |
stevensc |
1008 |
'enctype' => 'multipart/form-data'
|
| 16822 |
efrain |
1009 |
]);
|
|
|
1010 |
$form->prepare();
|
|
|
1011 |
echo $this->form()->openTag($form);
|
|
|
1012 |
|
| 16849 |
stevensc |
1013 |
?>
|
|
|
1014 |
<div class="modal-content">
|
| 17019 |
efrain |
1015 |
<div class="modal-header">
|
|
|
1016 |
<h6 class="modal-title">LABEL_SHARE_VIDEO</h6>
|
|
|
1017 |
</div>
|
|
|
1018 |
<div class="modal-body">
|
|
|
1019 |
<ul class="nav nav-tabs" id="tabVideo" role="tablist">
|
|
|
1020 |
<li class="nav-item"><a class="nav-link active" id="tab-video-basic-tab"
|
|
|
1021 |
data-bs-toggle="tab" href="#tab-video-basic" role="tab"
|
|
|
1022 |
aria-controls="basic" aria-selected="true">LABEL_BASIC</a></li>
|
|
|
1023 |
<li class="nav-item"><a class="nav-link" id="tab-video-scheduled-tab"
|
|
|
1024 |
data-bs-toggle="tab" href="#tab-video-scheduled" role="tab"
|
|
|
1025 |
aria-controls="scheduled" aria-selected="false">LABEL_SCHEDULED</a>
|
|
|
1026 |
</li>
|
|
|
1027 |
<li class="nav-item"><a class="nav-link" id="tab-video-notification-tab"
|
|
|
1028 |
data-bs-toggle="tab" href="#tab-video-notification" role="tab"
|
|
|
1029 |
aria-controls="notification" aria-selected="false">LABEL_NOTIFICATION</a>
|
|
|
1030 |
</li>
|
|
|
1031 |
</ul>
|
|
|
1032 |
<div class="tab-content border border-top-0 p-3"
|
|
|
1033 |
id="tabVideoContent">
|
|
|
1034 |
<div class="tab-pane fade show active" id="tab-video-basic" role="tabpanel"
|
|
|
1035 |
aria-labelledby="tab-video-basic-tab">
|
|
|
1036 |
|
|
|
1037 |
<div class="row">
|
|
|
1038 |
<div class="col-12 mt-3">
|
|
|
1039 |
<?php
|
|
|
1040 |
$element = $form->get('description');
|
|
|
1041 |
$element->setAttributes([
|
|
|
1042 |
'id' => 'description_video',
|
|
|
1043 |
'rows' => '2',
|
|
|
1044 |
'placeholder' => 'LABEL_WHAT_DO_YOU_HAVE_IN_MIND',
|
|
|
1045 |
'class' => 'form-control'
|
|
|
1046 |
]);
|
|
|
1047 |
echo $this->formTextArea($element);
|
|
|
1048 |
?>
|
|
|
1049 |
</div>
|
|
|
1050 |
</div>
|
|
|
1051 |
<div class="row">
|
|
|
1052 |
<div class="col-12 mt-3">
|
|
|
1053 |
<?php
|
|
|
1054 |
$element = $form->get('file');
|
|
|
1055 |
$element->setAttributes([
|
|
|
1056 |
'accept' => 'video/webm,video/mpeg,video/mp4'
|
|
|
1057 |
]);
|
|
|
1058 |
echo $this->formFile($element);
|
|
|
1059 |
?>
|
|
|
1060 |
</div>
|
|
|
1061 |
</div>
|
|
|
1062 |
|
|
|
1063 |
</div>
|
|
|
1064 |
<div class="tab-pane fade" id="tab-video-scheduled" role="tabpanel"
|
|
|
1065 |
aria-labelledby="tab-video-scheduled-tab">
|
|
|
1066 |
<div class="row">
|
|
|
1067 |
<div class="col-12 mt-3">
|
|
|
1068 |
<div class="form-check mb-3">
|
|
|
1069 |
<?php
|
|
|
1070 |
$element = $form->get('scheduled_active');
|
|
|
1071 |
$element->setAttributes([
|
|
|
1072 |
'class' => 'form-check-input'
|
|
|
1073 |
]);
|
|
|
1074 |
$element->setOptions([
|
|
|
1075 |
'label' => 'LABEL_SCHEDULED_ACTIVE',
|
|
|
1076 |
'class' => 'form-check-label'
|
|
|
1077 |
]);
|
|
|
1078 |
echo $this->formCheckbox($element);
|
|
|
1079 |
echo $this->formLabel($element);
|
| 16822 |
efrain |
1080 |
?>
|
| 17019 |
efrain |
1081 |
</div>
|
|
|
1082 |
</div>
|
|
|
1083 |
</div>
|
|
|
1084 |
<div class="row">
|
|
|
1085 |
<div class="col-12 mt-3">
|
|
|
1086 |
<?php
|
|
|
1087 |
$element = $form->get('scheduled_timestamp');
|
|
|
1088 |
$element->setOptions([
|
|
|
1089 |
'label' => 'LABEL_SCHEDULED_DATETIME',
|
|
|
1090 |
'class' => 'form-label'
|
|
|
1091 |
]);
|
|
|
1092 |
$element->setAttributes([
|
|
|
1093 |
'class' => 'form-control'
|
|
|
1094 |
]);
|
|
|
1095 |
echo $this->formLabel($element);
|
|
|
1096 |
echo $this->formText($element);
|
|
|
1097 |
?>
|
|
|
1098 |
</div>
|
|
|
1099 |
</div>
|
| 16849 |
stevensc |
1100 |
|
| 17019 |
efrain |
1101 |
</div>
|
|
|
1102 |
<div class="tab-pane fade" id="tab-video-notification" role="tabpanel"
|
|
|
1103 |
aria-labelledby="tab-video-notification-tab">
|
|
|
1104 |
<div class="row">
|
|
|
1105 |
<div class="col-12 mt-3">
|
|
|
1106 |
<div class="form-check mb-3">
|
|
|
1107 |
<?php
|
|
|
1108 |
$element = $form->get('notification_active');
|
|
|
1109 |
$element->setAttributes([
|
|
|
1110 |
'class' => 'form-check-input'
|
|
|
1111 |
]);
|
|
|
1112 |
$element->setOptions([
|
|
|
1113 |
'label' => 'LABEL_NOTIFICATION_ACTIVE',
|
|
|
1114 |
'class' => 'form-check-label'
|
|
|
1115 |
]);
|
|
|
1116 |
echo $this->formCheckbox($element);
|
|
|
1117 |
echo $this->formLabel($element);
|
|
|
1118 |
?>
|
|
|
1119 |
</div>
|
|
|
1120 |
</div>
|
|
|
1121 |
</div>
|
|
|
1122 |
<div class="row">
|
|
|
1123 |
<div class="col-12 mt-3">
|
|
|
1124 |
<div class="form-check mb-3">
|
|
|
1125 |
<?php
|
|
|
1126 |
$element = $form->get('notification_custom_active');
|
|
|
1127 |
$element->setAttributes([
|
|
|
1128 |
'class' => 'form-check-input'
|
|
|
1129 |
]);
|
|
|
1130 |
$element->setOptions([
|
|
|
1131 |
'label' => 'LABEL_USE_CUSTOM_NOTIFICATION',
|
|
|
1132 |
'class' => 'form-check-label'
|
|
|
1133 |
]);
|
|
|
1134 |
echo $this->formCheckbox($element);
|
|
|
1135 |
echo $this->formLabel($element);
|
|
|
1136 |
?>
|
|
|
1137 |
</div>
|
|
|
1138 |
|
|
|
1139 |
</div>
|
|
|
1140 |
</div>
|
|
|
1141 |
|
|
|
1142 |
<div class="row">
|
|
|
1143 |
<div class="col-12 mt-3">
|
|
|
1144 |
<?php
|
|
|
1145 |
$element = $form->get('notification_custom_title');
|
|
|
1146 |
$element->setOptions([
|
|
|
1147 |
'label' => 'LABEL_TITLE',
|
|
|
1148 |
'class' => 'form-label'
|
|
|
1149 |
]);
|
|
|
1150 |
$element->setAttributes([
|
|
|
1151 |
'class' => 'form-control'
|
|
|
1152 |
]);
|
|
|
1153 |
echo $this->formLabel($element);
|
|
|
1154 |
echo $this->formText($element);
|
|
|
1155 |
?>
|
|
|
1156 |
</div>
|
|
|
1157 |
</div>
|
|
|
1158 |
<div class="row">
|
|
|
1159 |
<div class="col-12 mt-3">
|
|
|
1160 |
<?php
|
|
|
1161 |
$element = $form->get('notification_custom_description');
|
|
|
1162 |
$element->setOptions([
|
|
|
1163 |
'label' => 'LABEL_DESCRIPTION',
|
|
|
1164 |
'class' => 'form-label'
|
|
|
1165 |
]);
|
|
|
1166 |
$element->setAttributes([
|
|
|
1167 |
'id' => 'notification_custom_description_video',
|
|
|
1168 |
'rows' => '2',
|
|
|
1169 |
'class' => 'form-control'
|
|
|
1170 |
]);
|
|
|
1171 |
echo $this->formLabel($element);
|
|
|
1172 |
echo $this->formTextArea($element);
|
|
|
1173 |
?>
|
|
|
1174 |
</div>
|
|
|
1175 |
</div>
|
|
|
1176 |
</div>
|
|
|
1177 |
</div>
|
|
|
1178 |
|
|
|
1179 |
|
|
|
1180 |
|
|
|
1181 |
</div>
|
|
|
1182 |
<div class="modal-footer">
|
|
|
1183 |
<button type="submit" class="btn btn-sm btn-primary save">LABEL_UPLOAD</button>
|
|
|
1184 |
<button type="button"
|
|
|
1185 |
class="btn btn-light cancel btn-modal-feed-video-close">LABEL_CANCEL</button>
|
|
|
1186 |
</div>
|
|
|
1187 |
|
|
|
1188 |
</div>
|
|
|
1189 |
<a href="#" title="" class="close-box btn-feed-video-close"><i
|
|
|
1190 |
class="la la-close"></i></a>
|
| 16849 |
stevensc |
1191 |
<?php echo $this->form()->closeTag($form); ?>
|
|
|
1192 |
</div>
|
| 16822 |
efrain |
1193 |
</div>
|
|
|
1194 |
|
| 17019 |
efrain |
1195 |
<div class="modal" tabindex="-1" role="dialog"
|
|
|
1196 |
id="modal-feed-document-box">
|
|
|
1197 |
<div class="modal-dialog modal-xl" role="document">
|
| 16849 |
stevensc |
1198 |
<?php
|
|
|
1199 |
$form = $this->formFeed;
|
| 16822 |
efrain |
1200 |
$form->setAttributes([
|
|
|
1201 |
'method' => 'post',
|
|
|
1202 |
'action' => $this->url('feeds/add'),
|
|
|
1203 |
'name' => 'form-feed-document',
|
|
|
1204 |
'id' => 'form-feed-document',
|
| 16849 |
stevensc |
1205 |
'enctype' => 'multipart/form-data'
|
| 16822 |
efrain |
1206 |
]);
|
|
|
1207 |
$form->prepare();
|
|
|
1208 |
echo $this->form()->openTag($form);
|
|
|
1209 |
|
| 17019 |
efrain |
1210 |
?>
|
|
|
1211 |
<div class="modal-content">
|
|
|
1212 |
<div class="modal-header">
|
|
|
1213 |
<h6 class="modal-title">LABEL_SHARE_DOCUMENT</h6>
|
|
|
1214 |
</div>
|
|
|
1215 |
<div class="modal-body">
|
| 16849 |
stevensc |
1216 |
|
| 17019 |
efrain |
1217 |
<ul class="nav nav-tabs" id="tabDocument" role="tablist">
|
|
|
1218 |
<li class="nav-item"><a class="nav-link active" id="tab-document-basic-tab"
|
|
|
1219 |
data-bs-toggle="tab" href="#tab-document-basic" role="tab"
|
|
|
1220 |
aria-controls="basic" aria-selected="true">LABEL_BASIC</a></li>
|
|
|
1221 |
<li class="nav-item"><a class="nav-link" id="tab-document-scheduled-tab"
|
|
|
1222 |
data-bs-toggle="tab" href="#tab-document-scheduled" role="tab"
|
|
|
1223 |
aria-controls="scheduled" aria-selected="false">LABEL_SCHEDULED</a>
|
|
|
1224 |
</li>
|
|
|
1225 |
<li class="nav-item"><a class="nav-link" id="tab-document-notification-tab"
|
|
|
1226 |
data-bs-toggle="tab" href="#tab-document-notification" role="tab"
|
|
|
1227 |
aria-controls="notification" aria-selected="false">LABEL_NOTIFICATION</a>
|
|
|
1228 |
</li>
|
|
|
1229 |
</ul>
|
|
|
1230 |
<div class="tab-content border border-top-0 p-3"
|
|
|
1231 |
id="tabDocumentContent">
|
|
|
1232 |
<div class="tab-pane fade show active" id="tab-document-basic" role="tabpanel"
|
|
|
1233 |
aria-labelledby="tab-document-basic-tab">
|
| 16849 |
stevensc |
1234 |
|
| 17019 |
efrain |
1235 |
<div class="row">
|
|
|
1236 |
<div class="col-12 mt-3">
|
|
|
1237 |
<?php
|
|
|
1238 |
$element = $form->get('description');
|
|
|
1239 |
$element->setAttributes([
|
|
|
1240 |
'id' => 'description_document',
|
|
|
1241 |
'rows' => '2',
|
|
|
1242 |
'placeholder' => 'LABEL_WHAT_DO_YOU_HAVE_IN_MIND',
|
|
|
1243 |
'class' => 'form-control'
|
|
|
1244 |
]);
|
|
|
1245 |
echo $this->formTextArea($element);
|
|
|
1246 |
?>
|
|
|
1247 |
</div>
|
|
|
1248 |
</div>
|
|
|
1249 |
<div class="row">
|
|
|
1250 |
<div class="col-12 mt-3">
|
|
|
1251 |
<?php
|
|
|
1252 |
$element = $form->get('file');
|
|
|
1253 |
$element->setAttributes([
|
|
|
1254 |
'accept' => 'application/pdf'
|
|
|
1255 |
]);
|
|
|
1256 |
echo $this->formFile($element);
|
|
|
1257 |
?>
|
|
|
1258 |
</div>
|
|
|
1259 |
</div>
|
|
|
1260 |
|
|
|
1261 |
</div>
|
|
|
1262 |
<div class="tab-pane fade" id="tab-document-scheduled" role="tabpanel"
|
|
|
1263 |
aria-labelledby="tab-document-scheduled-tab">
|
|
|
1264 |
<div class="row">
|
|
|
1265 |
<div class="col-12 mt-3">
|
|
|
1266 |
<div class="form-check mb-3">
|
|
|
1267 |
<?php
|
|
|
1268 |
$element = $form->get('scheduled_active');
|
|
|
1269 |
$element->setAttributes([
|
|
|
1270 |
'class' => 'form-check-input'
|
|
|
1271 |
]);
|
|
|
1272 |
$element->setOptions([
|
|
|
1273 |
'label' => 'LABEL_SCHEDULED_ACTIVE',
|
|
|
1274 |
'class' => 'form-check-label'
|
|
|
1275 |
]);
|
|
|
1276 |
echo $this->formCheckbox($element);
|
|
|
1277 |
echo $this->formLabel($element);
|
| 16822 |
efrain |
1278 |
?>
|
| 17019 |
efrain |
1279 |
</div>
|
|
|
1280 |
</div>
|
|
|
1281 |
</div>
|
|
|
1282 |
<div class="row">
|
|
|
1283 |
<div class="col-12 mt-3">
|
|
|
1284 |
<?php
|
|
|
1285 |
$element = $form->get('scheduled_timestamp');
|
|
|
1286 |
$element->setOptions([
|
|
|
1287 |
'label' => 'LABEL_SCHEDULED_DATETIME',
|
|
|
1288 |
'class' => 'form-label'
|
|
|
1289 |
]);
|
|
|
1290 |
$element->setAttributes([
|
|
|
1291 |
'class' => 'form-control'
|
|
|
1292 |
]);
|
|
|
1293 |
echo $this->formLabel($element);
|
|
|
1294 |
echo $this->formText($element);
|
|
|
1295 |
?>
|
|
|
1296 |
</div>
|
|
|
1297 |
</div>
|
|
|
1298 |
|
|
|
1299 |
</div>
|
|
|
1300 |
<div class="tab-pane fade" id="tab-document-notification" role="tabpanel"
|
|
|
1301 |
aria-labelledby="tab-document-notification-tab">
|
|
|
1302 |
<div class="row">
|
|
|
1303 |
<div class="col-12 mt-3">
|
|
|
1304 |
<div class="form-check mb-3">
|
|
|
1305 |
<?php
|
|
|
1306 |
$element = $form->get('notification_active');
|
|
|
1307 |
$element->setAttributes([
|
|
|
1308 |
'class' => 'form-check-input'
|
|
|
1309 |
]);
|
|
|
1310 |
$element->setOptions([
|
|
|
1311 |
'label' => 'LABEL_NOTIFICATION_ACTIVE',
|
|
|
1312 |
'class' => 'form-check-label'
|
|
|
1313 |
]);
|
|
|
1314 |
echo $this->formCheckbox($element);
|
|
|
1315 |
echo $this->formLabel($element);
|
|
|
1316 |
?>
|
|
|
1317 |
</div>
|
|
|
1318 |
</div>
|
|
|
1319 |
</div>
|
|
|
1320 |
<div class="row">
|
|
|
1321 |
<div class="col-12 mt-3">
|
|
|
1322 |
<div class="form-check mb-3">
|
|
|
1323 |
<?php
|
|
|
1324 |
$element = $form->get('notification_custom_active');
|
|
|
1325 |
$element->setAttributes([
|
|
|
1326 |
'class' => 'form-check-input'
|
|
|
1327 |
]);
|
|
|
1328 |
$element->setOptions([
|
|
|
1329 |
'label' => 'LABEL_USE_CUSTOM_NOTIFICATION',
|
|
|
1330 |
'class' => 'form-check-label'
|
|
|
1331 |
]);
|
|
|
1332 |
echo $this->formCheckbox($element);
|
|
|
1333 |
echo $this->formLabel($element);
|
|
|
1334 |
?>
|
|
|
1335 |
</div>
|
|
|
1336 |
|
|
|
1337 |
</div>
|
|
|
1338 |
</div>
|
|
|
1339 |
|
|
|
1340 |
<div class="row">
|
|
|
1341 |
<div class="col-12 mt-3">
|
|
|
1342 |
<?php
|
|
|
1343 |
$element = $form->get('notification_custom_title');
|
|
|
1344 |
$element->setOptions([
|
|
|
1345 |
'label' => 'LABEL_TITLE',
|
|
|
1346 |
'class' => 'form-label'
|
|
|
1347 |
]);
|
|
|
1348 |
$element->setAttributes([
|
|
|
1349 |
'class' => 'form-control'
|
|
|
1350 |
]);
|
|
|
1351 |
echo $this->formLabel($element);
|
|
|
1352 |
echo $this->formText($element);
|
|
|
1353 |
?>
|
|
|
1354 |
</div>
|
|
|
1355 |
</div>
|
|
|
1356 |
<div class="row">
|
|
|
1357 |
<div class="col-12 mt-3">
|
|
|
1358 |
<?php
|
|
|
1359 |
$element = $form->get('notification_custom_description');
|
|
|
1360 |
$element->setOptions([
|
|
|
1361 |
'label' => 'LABEL_DESCRIPTION',
|
|
|
1362 |
'class' => 'form-label'
|
|
|
1363 |
]);
|
|
|
1364 |
$element->setAttributes([
|
|
|
1365 |
'id' => 'notification_custom_description_document',
|
|
|
1366 |
'rows' => '2',
|
|
|
1367 |
'class' => 'form-control'
|
|
|
1368 |
]);
|
|
|
1369 |
echo $this->formLabel($element);
|
|
|
1370 |
echo $this->formTextArea($element);
|
|
|
1371 |
?>
|
|
|
1372 |
</div>
|
|
|
1373 |
</div>
|
|
|
1374 |
</div>
|
|
|
1375 |
</div>
|
|
|
1376 |
|
|
|
1377 |
|
|
|
1378 |
|
|
|
1379 |
</div>
|
|
|
1380 |
<div class="modal-footer text-right">
|
|
|
1381 |
<button type="submit" class="btn btn-sm btn-primary save">LABEL_UPLOAD</button>
|
|
|
1382 |
<button type="button"
|
|
|
1383 |
class="btn btn-light cancel btn-modal-feed-document-close">LABEL_CANCEL</button>
|
|
|
1384 |
</div>
|
|
|
1385 |
</div>
|
|
|
1386 |
<a href="#" title="" class="close-box btn-feed-document-close"><i
|
|
|
1387 |
class="la la-close"></i></a>
|
| 16849 |
stevensc |
1388 |
<?php echo $this->form()->closeTag($form); ?>
|
|
|
1389 |
</div>
|
| 16822 |
efrain |
1390 |
</div>
|
|
|
1391 |
|
|
|
1392 |
<div class="modal" tabindex="-1" role="dialog" id="modal-feed-box">
|
| 17019 |
efrain |
1393 |
<div class="modal-dialog modal-xl" role="document">
|
| 16849 |
stevensc |
1394 |
<?php
|
|
|
1395 |
$form = $this->formFeed;
|
| 16822 |
efrain |
1396 |
$form->setAttributes([
|
|
|
1397 |
'method' => 'post',
|
|
|
1398 |
'action' => $this->url('feeds/add'),
|
|
|
1399 |
'name' => 'form-feed',
|
| 17019 |
efrain |
1400 |
'id' => 'form-feed'
|
| 16822 |
efrain |
1401 |
]);
|
|
|
1402 |
$form->prepare();
|
|
|
1403 |
echo $this->form()->openTag($form);
|
|
|
1404 |
|
| 17019 |
efrain |
1405 |
?>
|
|
|
1406 |
<div class="modal-content">
|
|
|
1407 |
<div class="modal-header">
|
|
|
1408 |
<h6 class="modal-title">LABEL_SHARE</h6>
|
|
|
1409 |
</div>
|
|
|
1410 |
<div class="modal-body">
|
| 16849 |
stevensc |
1411 |
|
|
|
1412 |
|
| 17019 |
efrain |
1413 |
<ul class="nav nav-tabs" id="tabShare" role="tablist">
|
|
|
1414 |
<li class="nav-item"><a class="nav-link active" id="tab-share-basic-tab"
|
|
|
1415 |
data-bs-toggle="tab" href="#tab-share-basic" role="tab"
|
|
|
1416 |
aria-controls="basic" aria-selected="true">LABEL_BASIC</a></li>
|
|
|
1417 |
<li class="nav-item"><a class="nav-link" id="tab-share-scheduled-tab"
|
|
|
1418 |
data-bs-toggle="tab" href="#tab-share-scheduled" role="tab"
|
|
|
1419 |
aria-controls="scheduled" aria-selected="false">LABEL_SCHEDULED</a>
|
|
|
1420 |
</li>
|
|
|
1421 |
<li class="nav-item"><a class="nav-link" id="tab-share-notification-tab"
|
|
|
1422 |
data-bs-toggle="tab" href="#tab-share-notification" role="tab"
|
|
|
1423 |
aria-controls="notification" aria-selected="false">LABEL_NOTIFICATION</a>
|
|
|
1424 |
</li>
|
|
|
1425 |
</ul>
|
|
|
1426 |
<div class="tab-content border border-top-0 p-3" id="tabTextContent">
|
|
|
1427 |
<div class="tab-pane fade show active" id="tab-share-basic" role="tabpanel"
|
|
|
1428 |
aria-labelledby="basic-tab">
|
|
|
1429 |
<div class="row">
|
|
|
1430 |
<div class="col-12 mt-3">
|
|
|
1431 |
<?php
|
|
|
1432 |
$element = $form->get('description');
|
|
|
1433 |
$element->setAttributes([
|
|
|
1434 |
'id' => 'description_feed',
|
|
|
1435 |
'rows' => '2',
|
|
|
1436 |
'placeholder' => 'LABEL_WHAT_DO_YOU_HAVE_IN_MIND',
|
|
|
1437 |
'class' => 'form-control'
|
|
|
1438 |
]);
|
|
|
1439 |
echo $this->formTextArea($element);
|
|
|
1440 |
?>
|
|
|
1441 |
</div>
|
|
|
1442 |
</div>
|
|
|
1443 |
</div>
|
|
|
1444 |
<div class="tab-pane fade" id="tab-share-scheduled" role="tabpanel"
|
|
|
1445 |
aria-labelledby="scheduled-tab">
|
|
|
1446 |
<div class="row">
|
|
|
1447 |
<div class="col-12 mt-3">
|
|
|
1448 |
<div class="form-check mb-3">
|
|
|
1449 |
<?php
|
|
|
1450 |
$element = $form->get('scheduled_active');
|
|
|
1451 |
$element->setAttributes([
|
|
|
1452 |
'class' => 'form-check-input'
|
|
|
1453 |
]);
|
|
|
1454 |
$element->setOptions([
|
|
|
1455 |
'label' => 'LABEL_SCHEDULED_ACTIVE',
|
|
|
1456 |
'class' => 'form-check-label'
|
|
|
1457 |
]);
|
|
|
1458 |
echo $this->formCheckbox($element);
|
|
|
1459 |
echo $this->formLabel($element);
|
|
|
1460 |
?>
|
|
|
1461 |
</div>
|
|
|
1462 |
</div>
|
|
|
1463 |
</div>
|
|
|
1464 |
<div class="row">
|
|
|
1465 |
<div class="col-12 mt-3">
|
|
|
1466 |
<?php
|
|
|
1467 |
$element = $form->get('scheduled_timestamp');
|
|
|
1468 |
$element->setOptions([
|
|
|
1469 |
'label' => 'LABEL_SCHEDULED_DATETIME',
|
|
|
1470 |
'class' => 'form-label'
|
|
|
1471 |
]);
|
|
|
1472 |
$element->setAttributes([
|
|
|
1473 |
'class' => 'form-control'
|
|
|
1474 |
]);
|
|
|
1475 |
echo $this->formLabel($element);
|
|
|
1476 |
echo $this->formText($element);
|
|
|
1477 |
?>
|
|
|
1478 |
</div>
|
|
|
1479 |
</div>
|
|
|
1480 |
|
|
|
1481 |
</div>
|
|
|
1482 |
<div class="tab-pane fade" id="tab-share-notification" role="tabpanel"
|
|
|
1483 |
aria-labelledby="notification-tab">
|
|
|
1484 |
<div class="row">
|
|
|
1485 |
<div class="col-12 mt-3">
|
|
|
1486 |
<div class="form-check mb-3">
|
|
|
1487 |
<?php
|
|
|
1488 |
$element = $form->get('notification_active');
|
|
|
1489 |
$element->setAttributes([
|
|
|
1490 |
'class' => 'form-check-input'
|
|
|
1491 |
]);
|
|
|
1492 |
$element->setOptions([
|
|
|
1493 |
'label' => 'LABEL_NOTIFICATION_ACTIVE',
|
|
|
1494 |
'class' => 'form-check-label'
|
|
|
1495 |
]);
|
|
|
1496 |
echo $this->formCheckbox($element);
|
|
|
1497 |
echo $this->formLabel($element);
|
|
|
1498 |
?>
|
|
|
1499 |
</div>
|
|
|
1500 |
</div>
|
|
|
1501 |
</div>
|
|
|
1502 |
<div class="row">
|
|
|
1503 |
<div class="col-12 mt-3">
|
|
|
1504 |
<div class="form-check mb-3">
|
|
|
1505 |
<?php
|
|
|
1506 |
$element = $form->get('notification_custom_active');
|
|
|
1507 |
$element->setAttributes([
|
|
|
1508 |
'class' => 'form-check-input'
|
|
|
1509 |
]);
|
|
|
1510 |
$element->setOptions([
|
|
|
1511 |
'label' => 'LABEL_USE_CUSTOM_NOTIFICATION',
|
|
|
1512 |
'class' => 'form-check-label'
|
|
|
1513 |
]);
|
|
|
1514 |
echo $this->formCheckbox($element);
|
|
|
1515 |
echo $this->formLabel($element);
|
|
|
1516 |
?>
|
|
|
1517 |
</div>
|
|
|
1518 |
|
|
|
1519 |
</div>
|
|
|
1520 |
</div>
|
|
|
1521 |
|
|
|
1522 |
<div class="row">
|
|
|
1523 |
<div class="col-12 mt-3">
|
|
|
1524 |
<?php
|
|
|
1525 |
$element = $form->get('notification_custom_title');
|
|
|
1526 |
$element->setOptions([
|
|
|
1527 |
'label' => 'LABEL_TITLE',
|
|
|
1528 |
'class' => 'form-label'
|
|
|
1529 |
]);
|
|
|
1530 |
$element->setAttributes([
|
|
|
1531 |
'class' => 'form-control'
|
|
|
1532 |
]);
|
|
|
1533 |
echo $this->formLabel($element);
|
|
|
1534 |
echo $this->formText($element);
|
|
|
1535 |
?>
|
|
|
1536 |
</div>
|
|
|
1537 |
</div>
|
|
|
1538 |
<div class="row">
|
|
|
1539 |
<div class="col-12 mt-3">
|
|
|
1540 |
<?php
|
|
|
1541 |
$element = $form->get('notification_custom_description');
|
|
|
1542 |
$element->setOptions([
|
|
|
1543 |
'label' => 'LABEL_DESCRIPTION',
|
|
|
1544 |
'class' => 'form-label'
|
|
|
1545 |
]);
|
|
|
1546 |
$element->setAttributes([
|
|
|
1547 |
'id' => 'notification_custom_description_share',
|
|
|
1548 |
'rows' => '2',
|
|
|
1549 |
'class' => 'form-control'
|
|
|
1550 |
]);
|
|
|
1551 |
echo $this->formLabel($element);
|
|
|
1552 |
echo $this->formTextArea($element);
|
|
|
1553 |
?>
|
|
|
1554 |
</div>
|
|
|
1555 |
</div>
|
|
|
1556 |
</div>
|
|
|
1557 |
</div>
|
|
|
1558 |
|
|
|
1559 |
</div>
|
|
|
1560 |
<div class="modal-footer text-right">
|
|
|
1561 |
<button type="submit" class="btn btn-sm btn-primary save">LABEL_SAVE</button>
|
|
|
1562 |
<button type="button"
|
|
|
1563 |
class="btn btn-light cancel btn-modal-feed-close">LABEL_CANCEL</button>
|
|
|
1564 |
</div>
|
|
|
1565 |
</div>
|
|
|
1566 |
<a href="#" title="" class="close-box btn-modal-feed-close"><i
|
|
|
1567 |
class="la la-close"></i></a>
|
| 16849 |
stevensc |
1568 |
<?php echo $this->form()->closeTag($form); ?>
|
|
|
1569 |
</div>
|
| 16822 |
efrain |
1570 |
</div>
|
|
|
1571 |
|
|
|
1572 |
|
|
|
1573 |
|
|
|
1574 |
|
|
|
1575 |
<script id="commentTemplate" type="text/x-jsrender">
|
| 16849 |
stevensc |
1576 |
<li>
|
| 16851 |
stevensc |
1577 |
<div class="comment-list">
|
|
|
1578 |
<div class="comment comment-{{:unique}}" >
|
| 16935 |
efrain |
1579 |
<a href="{{>user_url}}"><h6>{{>user_name}}</h6>
|
| 17019 |
efrain |
1580 |
<span><img src="<?php echo $this->basePath('assets/images/clock.png') ?>" alt="">{{>time_elapsed}}
|
| 16851 |
stevensc |
1581 |
{{if link_delete}}
|
| 17019 |
efrain |
1582 |
<a href="#" class="btn-comment-trash" data-link="{{:link_delete}}" data-comment-unique="{{>unique}}"><i class="fa fa-trash"></i></a>
|
| 16851 |
stevensc |
1583 |
{{/if}}
|
|
|
1584 |
</span>
|
| 17019 |
efrain |
1585 |
|
| 16851 |
stevensc |
1586 |
<p>{{>comment}}</p>
|
|
|
1587 |
</div>
|
|
|
1588 |
</div>
|
|
|
1589 |
</li>
|
| 16822 |
efrain |
1590 |
</script>
|
|
|
1591 |
|
|
|
1592 |
<script id="feedTemplate" type="text/x-jsrender">
|
| 16867 |
stevensc |
1593 |
<div class="theme-container feed-{{>feed_unique}} mb-2">
|
| 16849 |
stevensc |
1594 |
<div class="feed-header">
|
| 16851 |
stevensc |
1595 |
<a href="{{>owner_url}}">
|
| 16858 |
stevensc |
1596 |
<img src="{{>owner_image}}" alt="">
|
| 16851 |
stevensc |
1597 |
</a>
|
| 17019 |
efrain |
1598 |
|
| 16851 |
stevensc |
1599 |
<div class="feed-info">
|
| 16822 |
efrain |
1600 |
<a href="{{>owner_url}}">
|
| 16852 |
stevensc |
1601 |
<h2>{{>owner_name}}</h2>
|
| 16822 |
efrain |
1602 |
</a>
|
| 16853 |
stevensc |
1603 |
|
| 16851 |
stevensc |
1604 |
<span>
|
| 16929 |
efrain |
1605 |
<img src="<?php echo $this->basePath('assets/images/clock.png') ?>" alt="">
|
| 17019 |
efrain |
1606 |
{{>owner_time_elapse}}
|
|
|
1607 |
{{if feed_delete_url}}
|
| 16851 |
stevensc |
1608 |
<a href="#" class="btn-feed-trash" data-link="{{:feed_delete_url}}" data-feed-unique="{{>feed_unique}}"><i class="fa fa-trash"></i></a>
|
|
|
1609 |
{{/if}}
|
| 17019 |
efrain |
1610 |
</span>
|
| 16822 |
efrain |
1611 |
</div>
|
|
|
1612 |
</div>
|
| 16849 |
stevensc |
1613 |
|
| 16853 |
stevensc |
1614 |
<div class="feed-body px-0">
|
|
|
1615 |
<p class="show-read-more">
|
|
|
1616 |
{{:owner_description}}
|
| 16822 |
efrain |
1617 |
</p>
|
|
|
1618 |
{{if owner_file_image}}
|
|
|
1619 |
<img src="{{>owner_file_image}}" class="Entradas">
|
|
|
1620 |
{{/if}}
|
|
|
1621 |
{{if owner_file_video}}
|
|
|
1622 |
<video src="{{>owner_file_video}}" controls poster="{{>owner_file_image_preview}}">
|
|
|
1623 |
{{/if}}
|
|
|
1624 |
{{if owner_file_document}}
|
|
|
1625 |
<a href="{{>owner_file_document}}" target="_blank">Descargar</a>
|
|
|
1626 |
{{/if}}
|
|
|
1627 |
|
| 16860 |
stevensc |
1628 |
{{if shared_name}}
|
| 16867 |
stevensc |
1629 |
<div class="theme-container">
|
| 16860 |
stevensc |
1630 |
<div class="feed-header">
|
|
|
1631 |
<img src="{{>shared_image}}" alt="" style="width:50px; height: auto">
|
| 16853 |
stevensc |
1632 |
|
| 16860 |
stevensc |
1633 |
<div class="feed-info">
|
| 16935 |
efrain |
1634 |
<h6>{{>shared_name}}</h6>
|
| 16860 |
stevensc |
1635 |
<span>
|
| 16929 |
efrain |
1636 |
<img style="width: 12px; height: auto" src="<?php echo $this->basePath('assets/images/clock.png') ?>" alt="">
|
| 16860 |
stevensc |
1637 |
{{>shared_time_elapse}}
|
| 17019 |
efrain |
1638 |
</span>
|
| 16860 |
stevensc |
1639 |
</div>
|
|
|
1640 |
</div>
|
| 16853 |
stevensc |
1641 |
|
| 16860 |
stevensc |
1642 |
<div class="feed-body">
|
|
|
1643 |
<p class="show-read-more">{{:shared_description}}</p>
|
| 16853 |
stevensc |
1644 |
|
| 16860 |
stevensc |
1645 |
{{if shared_file_image}}
|
|
|
1646 |
<img src="{{>shared_file_image}}" class="Entradas">
|
|
|
1647 |
{{/if}}
|
|
|
1648 |
{{if shared_file_video}}
|
|
|
1649 |
<video src="{{>shared_file_video}}" controls poster="{{>shared_file_image_preview}}">
|
|
|
1650 |
{{/if}}
|
|
|
1651 |
{{if shared_file_document}}
|
|
|
1652 |
<a href="{{>shared_file_document}}" target="_blank">Descargar</a>
|
|
|
1653 |
{{/if}}
|
|
|
1654 |
</div>
|
|
|
1655 |
</div>
|
|
|
1656 |
{{/if}}
|
| 16822 |
efrain |
1657 |
</div>
|
|
|
1658 |
|
| 16849 |
stevensc |
1659 |
<div class="feed-actions">
|
| 16850 |
stevensc |
1660 |
<span id="btn-comments-{{>feed_unique}}" class="btn-indicator"><i class="fa fa-comments"></i> {{>owner_comments}}</span>
|
|
|
1661 |
<span id="btn-share-{{>feed_unique}}" class="btn-indicator"><i class="fa fa-share"></i> {{>owner_shared}}</span>
|
| 16822 |
efrain |
1662 |
</div>
|
| 16849 |
stevensc |
1663 |
|
| 17019 |
efrain |
1664 |
{{if comments}}
|
| 16860 |
stevensc |
1665 |
<ul class="comment-list comment-sec-{{>feed_unique}}" data-feed-unique="{{>feed_unique}}">
|
|
|
1666 |
{{for comments}}
|
|
|
1667 |
<li>
|
|
|
1668 |
<div class="comment-container comment-{{:unique}}">
|
|
|
1669 |
<a href="{{>user_url}}">
|
| 16862 |
stevensc |
1670 |
<h2>{{>user_name}}</h2>
|
| 16860 |
stevensc |
1671 |
</a>
|
|
|
1672 |
|
|
|
1673 |
<span>
|
| 16929 |
efrain |
1674 |
<img src="<?php echo $this->basePath('assets/images/clock.png') ?>" alt="">
|
| 17019 |
efrain |
1675 |
{{>time_elapsed}}
|
| 16862 |
stevensc |
1676 |
{{if link_delete}}
|
|
|
1677 |
<a href="#" class="btn-comment-trash" data-link="{{:link_delete}}" data-comment-unique="{{>unique}}">
|
|
|
1678 |
<i class="fa fa-trash"></i>
|
| 17019 |
efrain |
1679 |
</a>
|
| 16862 |
stevensc |
1680 |
{{/if}}
|
| 16860 |
stevensc |
1681 |
</span>
|
|
|
1682 |
|
|
|
1683 |
<p>{{>comment}}</p>
|
|
|
1684 |
</div>
|
|
|
1685 |
</li>
|
|
|
1686 |
{{/for}}
|
|
|
1687 |
</ul>
|
| 16822 |
efrain |
1688 |
{{/if}}
|
| 17019 |
efrain |
1689 |
|
| 16951 |
efrain |
1690 |
<form class="form-comment-feed comment-form px-2 mb-2" data-feed-unique="{{>feed_unique}}" action="{{>comment_add_url}}">
|
| 16860 |
stevensc |
1691 |
<input type="text" name="comment" id="comment-{{>feed_unique}}" maxlength="256" placeholder="LABEL_WRITE_A_COMMENT">
|
| 16885 |
stevensc |
1692 |
<button class="btn btn-primary" type="submit">LABEL_SEND</button>
|
| 16860 |
stevensc |
1693 |
</form>
|
| 16822 |
efrain |
1694 |
</div>
|
|
|
1695 |
</script>
|