Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 6481 | Rev 6523 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 6481 Rev 6521
Línea 1... Línea 1...
1
<?php
1
<?php
-
 
2
use LeadersLinked\Model\ContentReaction;
-
 
3
 
2
$acl            = $this->viewModel()->getRoot()->getVariable('acl');
4
$acl            = $this->viewModel()->getRoot()->getVariable('acl');
3
$currentUser    = $this->currentUserHelper();
5
$currentUser    = $this->currentUserHelper();
4
$roleName       = $currentUser->getUserTypeId();
6
$roleName       = $currentUser->getUserTypeId();
Línea 5... Línea 7...
5
 
7
 
Línea 25... Línea 27...
25
 
27
 
26
$this->inlineScript()->appendFile($this->basePath('vendors/jquery-validation/jquery.validate.js'));
28
$this->inlineScript()->appendFile($this->basePath('vendors/jquery-validation/jquery.validate.js'));
27
$this->inlineScript()->appendFile($this->basePath('vendors/jquery-validation/additional-methods.js'));
29
$this->inlineScript()->appendFile($this->basePath('vendors/jquery-validation/additional-methods.js'));
Línea -... Línea 30...
-
 
30
$this->inlineScript()->appendFile($this->basePath('vendors/jquery-validation/localization/messages_es.js'));
Línea 28... Línea 31...
28
$this->inlineScript()->appendFile($this->basePath('vendors/jquery-validation/localization/messages_es.js'));
31
 
29
 
32
$this->headLink()->appendStylesheet($this->basePath('css/my-coach.css'));
Línea 30... Línea 33...
30
 
33
 
-
 
34
 
-
 
35
$this->inlineScript()->captureStart();
-
 
36
echo <<<JS
-
 
37
 
-
 
38
jQuery( document ).ready(function( $ ) {
-
 
39
 
-
 
40
 
-
 
41
    $.fn.reloadAnswers = function() {
-
 
42
 
-
 
43
        var action = $('#row-view').data('link-answers');
-
 
44
 
-
 
45
        NProgress.start();
-
 
46
        $.ajax({
-
 
47
            'dataType'  : 'json',
-
 
48
            'accept'    : 'application/json',
-
 
49
            'method'    : 'get',
-
 
50
            'url'       : action,
-
 
51
        }).done(function(response) {
-
 
52
            if(response['success']) {
-
 
53
                $('#my-coach-question-answers-list').empty();
-
 
54
 
-
 
55
 
-
 
56
                if(response['data']['items'].length > 0) {
-
 
57
 
-
 
58
 
-
 
59
 
-
 
60
                    $( "#my-coach-question-answers-list" ).html(
-
 
61
                		$( "#answerTemplate" ).render( response['data']['items'] )
-
 
62
                	);
-
 
63
                } else {
-
 
64
                    var html = '<div class="company-title"><div class="widget widget-jobs"><div class="sd-title">ERROR_NO_RECORD_MATCHED_YOUR_QUERY</div></div></div>';
-
 
65
                    $( "#my-coach-question-answers-list" ).html(html);
-
 
66
                }     
-
 
67
 
-
 
68
 
-
 
69
                $('button.btn-my-coach-delete-answer').confirmation({
-
 
70
                    rootSelector: 'button.btn-my-coach-delete-answer',
-
 
71
                    title : 'LABEL_ARE_YOU_SURE',
-
 
72
                    singleton : true,
-
 
73
                    btnOkLabel: 'LABEL_YES',
-
 
74
                    btnCancelLabel: 'LABEL_NO',
-
 
75
                    onConfirm: function(value) {
-
 
76
                        var action = $(this).data('link');
-
 
77
                        NProgress.start();
-
 
78
                        $.ajax({
-
 
79
                            'dataType'  : 'json',
-
 
80
                            'accept'    : 'application/json',
-
 
81
                            'method'    : 'post',
-
 
82
                            'url'       :  action,
-
 
83
                        }).done(function(response) {
-
 
84
                            if(response['success']) {
-
 
85
                                $.fn.showSuccess(response['data']);
-
 
86
 
-
 
87
                                $.fn.reload();
-
 
88
                            } else {
-
 
89
                                $.fn.showError(response['data']);
-
 
90
                            }
-
 
91
                        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
92
                            $.fn.showError(textStatus);
-
 
93
                        }).always(function() {
-
 
94
                            NProgress.done();
-
 
95
                        });
-
 
96
                       
-
 
97
                        return false;
-
 
98
                    },
-
 
99
                });
-
 
100
 
-
 
101
            } else {
-
 
102
                $.fn.showError(response['data']);
-
 
103
            } 
-
 
104
        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
105
            $.fn.showError(textStatus);
-
 
106
        }).always(function() {
31
 
107
            NProgress.done();
Línea 32... Línea 108...
32
$this->inlineScript()->captureStart();
108
        });
33
echo <<<JS
109
 
34
 
110
    }
35
jQuery( document ).ready(function( $ ) {
111
 
Línea 62... Línea 138...
62
                    var html = '<div class="company-title"><div class="widget widget-jobs"><div class="sd-title">ERROR_NO_RECORD_MATCHED_YOUR_QUERY</div></div></div>';
138
                    var html = '<div class="company-title"><div class="widget widget-jobs"><div class="sd-title">ERROR_NO_RECORD_MATCHED_YOUR_QUERY</div></div></div>';
63
                    $( "#my-coach-record-list" ).html(html);
139
                    $( "#my-coach-record-list" ).html(html);
64
                }     
140
                }     
Línea 65... Línea 141...
65
 
141
 
66
 
142
 
67
                $('button.btn-my-coach-delete').confirmation({
143
                $('button.btn-my-coach-delete-question').confirmation({
68
                    rootSelector: 'button.btn-my-coach-delete',
144
                    rootSelector: 'button.btn-my-coach-delete-question',
69
                    title : 'LABEL_ARE_YOU_SURE',
145
                    title : 'LABEL_ARE_YOU_SURE',
70
                    singleton : true,
146
                    singleton : true,
71
                    btnOkLabel: 'LABEL_YES',
147
                    btnOkLabel: 'LABEL_YES',
Línea 212... Línea 288...
212
        invalidHandler: function(form, validator) {
288
        invalidHandler: function(form, validator) {
Línea 213... Línea 289...
213
            
289
            
214
        }
290
        }
Línea -... Línea 291...
-
 
291
    });
-
 
292
 
-
 
293
    var validatorAnswer = $('#form-answer').validate({
-
 
294
        debug: true,
-
 
295
        onclick: false,
-
 
296
        onkeyup: false,
-
 
297
        ignore: [],
-
 
298
        rules: {
-
 
299
            'description': {
-
 
300
                updateCkeditor:function() {
-
 
301
                        CKEDITOR.instances.description_answer.updateElement();
-
 
302
                },
-
 
303
                
-
 
304
                required: true
-
 
305
            },
-
 
306
          
-
 
307
        },
-
 
308
        submitHandler: function(form)
-
 
309
        {
-
 
310
 
-
 
311
 
-
 
312
			NProgress.start();
-
 
313
            $.ajax({
-
 
314
                'dataType'  : 'json',
-
 
315
                'accept'    : 'application/json',
-
 
316
                'method'    : 'post',
-
 
317
                'url'       :  $('#form-answer').attr('action'),
-
 
318
                'data'      :  $('#form-answer').serialize(),
-
 
319
 
-
 
320
            }).done(function(response) {
-
 
321
				if(response['success']) {
-
 
322
                    $('#modal-answer').modal('hide');
-
 
323
    
-
 
324
                    var uuid = $('#row-view').data('question-uuid');
-
 
325
                    $('#answers-' + uuid).html(response['data']['answers']);
-
 
326
                    $('#my-coach-question-answer-count-answers').html(response['data']['answers']);
-
 
327
                    $('#my-coach-question-answers-list').prepend(
-
 
328
                        $('#answerTemplate').render(response['data']['item'])
-
 
329
                    );
-
 
330
                } else {
-
 
331
                    validatorAnswer.resetForm();
-
 
332
                    if(jQuery.type(response['data']) == 'string') {
-
 
333
                        $.fn.showError(response['data']);
-
 
334
                    } else  {
-
 
335
                        $.each(response['data'], function( fieldname, errors ) {
-
 
336
                            $.fn.showFormErrorValidator('#form-answer #' + fieldname, errors);
-
 
337
                        });
-
 
338
                    }
-
 
339
                }
-
 
340
            }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
341
                $.fn.showError(textStatus);
-
 
342
            }).always(function() {
-
 
343
                NProgress.done();
-
 
344
            });
-
 
345
            return false;
-
 
346
        },
-
 
347
        invalidHandler: function(form, validator) {
-
 
348
            
-
 
349
        }
Línea 215... Línea 350...
215
    });
350
    });
216
 
351
 
Línea 286... Línea 421...
286
    $('button.btn-cancel').click(function(e) {
421
    $('button.btn-cancel').click(function(e) {
287
        e.preventDefault();
422
        e.preventDefault();
Línea 288... Línea 423...
288
 
423
 
-
 
424
 
-
 
425
        $('#modal-question').modal('hide');
-
 
426
        $('#modal-answer').modal('hide');
-
 
427
    });
-
 
428
 
-
 
429
 
-
 
430
 
-
 
431
 
-
 
432
    $('#my-coach-question-answer-btn-delete').confirmation({
-
 
433
        rootSelector: 'button.my-coach-question-answer-btn-delete',
-
 
434
        title : 'LABEL_ARE_YOU_SURE',
-
 
435
        singleton : true,
-
 
436
        btnOkLabel: 'LABEL_YES',
-
 
437
        btnCancelLabel: 'LABEL_NO',
-
 
438
        onConfirm: function(value) {
-
 
439
            var action = $(this).data('link');
-
 
440
            var uuid = $(this).data('question-uuid');
-
 
441
               
-
 
442
            NProgress.start();
-
 
443
            $.ajax({
-
 
444
                'dataType'  : 'json',
-
 
445
                'accept'    : 'application/json',
-
 
446
                'method'    : 'post',
-
 
447
                'url'       :  action,
-
 
448
            }).done(function(response) {
-
 
449
                if(response['success']) {
-
 
450
                    $.fn.showSuccess(response['data']);
-
 
451
 
-
 
452
                    var uuid = $('#row-view').data('question-uuid');
-
 
453
                    var key = 'my-coach-record-card-question-' + uuid;
-
 
454
                    $('#' + key).remove();
-
 
455
 
-
 
456
                    $('#row-view').hide();
-
 
457
 
-
 
458
                    $('#my-coach-add-question').show();
-
 
459
                    $('#row-list').show();
-
 
460
 
-
 
461
                
-
 
462
               
-
 
463
                } else {
-
 
464
                    $.fn.showError(response['data']);
-
 
465
                }
-
 
466
            }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
467
                $.fn.showError(textStatus);
-
 
468
            }).always(function() {
-
 
469
                NProgress.done();
-
 
470
            });
-
 
471
                       
-
 
472
            return false;
-
 
473
        },
-
 
474
    });
-
 
475
    
-
 
476
 
-
 
477
    $('body').on('click', 'button.btn-my-coach-edit-view', function(e) {
-
 
478
        e.preventDefault();
-
 
479
        var action = $(this).data('link');
-
 
480
 
-
 
481
        NProgress.start();
-
 
482
        $.ajax({
-
 
483
            'dataType'  : 'json',
-
 
484
            'accept'    : 'application/json',
-
 
485
            'method'    : 'get',
-
 
486
            'url'       :  action,
-
 
487
        }).done(function(response) {
-
 
488
            if(response['success']) {
-
 
489
                $('#row-view').data('link-answers', response['data']['link_answers']);
-
 
490
                $('#row-view').data('question-uuid', response['data']['uuid']);
-
 
491
 
-
 
492
                $('#my-coach-question-answer-btn-answer').data('link', response['data']['link_answers_add']); 
-
 
493
                $('#my-coach-question-answer-btn-delete').data('link', response['data']['link_delete']); 
-
 
494
 
-
 
495
 
-
 
496
 
-
 
497
                $('#my-coach-question-user-image').attr('src', response['data']['user_image']);
-
 
498
                $('#my-coach-question-user-name').html(response['data']['user_name']);
-
 
499
                $('#my-coach-question-title').html(response['data']['title']);
-
 
500
                $('#my-coach-question-description').html(response['data']['description']);
-
 
501
 
-
 
502
                $('#my-coach-answer-categories').empty();
-
 
503
                $.each(response['data']['categories'], function(key, value) {
-
 
504
 
-
 
505
                    var li = $('<li>');
-
 
506
                    li.text(value.category).appendTo('#my-coach-answer-categories')
-
 
507
                });
-
 
508
 
-
 
509
                $('#my-coach-question-answer-question-date').html(response['data']['added_on']);
-
 
510
                $('#my-coach-question-answer-last-date').html(response['data']['last_answer_on']);
-
 
511
                $('#my-coach-question-answer-count-answers').html(response['data']['answers']);
-
 
512
                $('#my-coach-question-answer-count-reactions').html(response['data']['reactions']);
-
 
513
                $('#my-coach-question-answer-count-views').html(response['data']['views']);
-
 
514
                $('#my-coach-question-answer-count-comments').html(response['data']['comments']);
-
 
515
 
-
 
516
                $('#views-' + response['data']['uuid']).html( response['data']['views'] );
-
 
517
 
-
 
518
 
-
 
519
                $('#my-coach-add-question').hide();
-
 
520
                $('#row-list').hide();
-
 
521
                $('#row-view').show();
-
 
522
 
-
 
523
                $.fn.reloadAnswers();
-
 
524
 
-
 
525
            } else {
-
 
526
                $.fn.showError(response['data']);
-
 
527
            }
-
 
528
        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
529
            $.fn.showError(textStatus);
-
 
530
        }).always(function() {
-
 
531
            NProgress.done();
-
 
532
        });
-
 
533
    });
-
 
534
 
-
 
535
    $('#my-coach-question-answer-btn-back').click(function(e) {
-
 
536
        e.preventDefault();
-
 
537
     
-
 
538
        $('#my-coach-add-question').show();
-
 
539
        $('#row-view').hide();
-
 
540
        $('#row-list').show();
-
 
541
                
-
 
542
    });
-
 
543
 
-
 
544
 
-
 
545
    $('#my-coach-question-answer-btn-answer').click(function(e) {
-
 
546
        e.preventDefault();
-
 
547
 
-
 
548
        $('#form-answer').attr('action', $(this).data('link') );
-
 
549
        CKEDITOR.instances.description_answer.setData('');
-
 
550
        validatorAnswer
-
 
551
     
-
 
552
        $('#modal-answer').modal('show');
-
 
553
    });
-
 
554
 
-
 
555
    $('body').on('click', 'a.btn-comment-trash', function(e) {
-
 
556
        e.preventDefault();
-
 
557
        var action = $(this).data('link');
-
 
558
        var unique = $(this).data('comment-unique');
-
 
559
        var answer_uuid = $(this).data('answer-uuid');
-
 
560
        var question_uuid = $('#row-view').data('question-uuid');
-
 
561
 
-
 
562
 
-
 
563
 
-
 
564
        NProgress.start();
-
 
565
        $.ajax({
-
 
566
            'dataType'  : 'json',
-
 
567
            'accept'    : 'application/json',
-
 
568
            'method'    : 'post',
-
 
569
            'url'       :  action,
-
 
570
        }).done(function(response) {
-
 
571
            if(response['success']) {
-
 
572
                $('div.comment-' + unique).remove();
-
 
573
 
-
 
574
                //Listado de la respuesta
-
 
575
                $('#answer-total-comment-' + answer_uuid).html( response['data']['total_comments_answer'] );
-
 
576
 
-
 
577
                //Encabezado pregunta del view
-
 
578
                $('#my-coach-question-answer-count-comments').html( response['data']['total_comments_question'] );
-
 
579
                
-
 
580
                //Listado de preguntas
-
 
581
                $('#comments-' + question_uuid).html( response['data']['total_comments_question'] );
-
 
582
 
-
 
583
 
-
 
584
            } else {
-
 
585
                $.fn.showError(response['data']);
-
 
586
            }
-
 
587
        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
588
            $.fn.showError(textStatus);
-
 
589
        }).always(function() {
-
 
590
            NProgress.done();
-
 
591
        });
-
 
592
 
-
 
593
    });
-
 
594
 
-
 
595
    $('body').on('submit', 'form.feedCommentContainer', function(e) {
-
 
596
        e.preventDefault();
-
 
597
 
-
 
598
        var action          = $(this).attr('action');
-
 
599
        var answer_uuid     = $(this).data('answer');
-
 
600
        var question_uuid   = $('#row-view').data('question-uuid');
-
 
601
        var form_id         = $(this).attr('id');
-
 
602
 
-
 
603
        var comment = $('#' + form_id + ' #comment').val().trim();
-
 
604
        if(comment.length == 0) {
-
 
605
            return;
-
 
606
        }
-
 
607
 
-
 
608
        NProgress.start();
-
 
609
        $.ajax({
-
 
610
            'dataType'  : 'json',
-
 
611
            'accept'    : 'application/json',
-
 
612
            'method'    : 'post',
-
 
613
            'url'       : action,
-
 
614
            'data'      : $(this).serialize()
-
 
615
 
-
 
616
        }).done(function(response) {
-
 
617
		  if(response['success']) {
-
 
618
            $('#' + form_id + ' #comment').val('');
-
 
619
            $('#comment-list-' + answer_uuid).prepend(
-
 
620
                $( "#commentTemplate" ).render( response['data']['item'] )
-
 
621
            );
-
 
622
 
-
 
623
            //Listado de la respuesta
-
 
624
            $('#answer-total-comment-' + answer_uuid).html( response['data']['total_comments_answer'] );
-
 
625
 
-
 
626
            //Encabezado pregunta del view
-
 
627
            $('#my-coach-question-answer-count-comments').html( response['data']['total_comments_question'] );
-
 
628
                
-
 
629
            //Listado de preguntas
-
 
630
            $('#comments-' + question_uuid).html( response['data']['total_comments_question'] );
-
 
631
 
-
 
632
          } else {
-
 
633
            $.fn.showError(textStatus);
-
 
634
          }
-
 
635
 
-
 
636
        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
637
            $.fn.showError(textStatus);
-
 
638
        }).always(function() {
-
 
639
            NProgress.done();
-
 
640
        });
-
 
641
        return false;
-
 
642
 
-
 
643
    });
-
 
644
 
-
 
645
  $('body').on('click', 'button.btn-save-reaction', function(e) {
-
 
646
        e.preventDefault();
-
 
647
        var reaction = $(this).data('reaction');
-
 
648
        var action = $(this).data('link');
-
 
649
        var answer_uuid = $(this).data('answer');
-
 
650
        var question_uuid   = $('#row-view').data('question-uuid');
-
 
651
 
-
 
652
        NProgress.start();
-
 
653
        $.ajax({
-
 
654
            'dataType'  : 'json',
-
 
655
            'accept'    : 'application/json',
-
 
656
            'method'    : 'post',
-
 
657
            'url'       :  action,
-
 
658
            'data'      : {
-
 
659
                'reaction' : reaction
-
 
660
            }
-
 
661
        }).done(function(response) {
-
 
662
            if(response['success']) {
-
 
663
 
-
 
664
                $('#reactions-' + question_uuid).html(response['data']['total_reactions_question']) ; 
-
 
665
                $('#my-coach-question-answer-count-reactions').html(response['data']['total_reactions_question']) ; 
-
 
666
                $('#answer-total-reactions-' + answer_uuid).html(response['data']['total_reactions_answer']) ; 
-
 
667
 
-
 
668
                $('#' + 'current-reaction-' + answer_uuid).data('reaction', response['data']['reaction']);
-
 
669
                $('#' + 'current-reaction-' + answer_uuid).html(
-
 
670
                    $('#reactionTemplate').render({reaction: reaction})
-
 
671
                );
-
 
672
            } else {
-
 
673
                $.fn.showError(response['data']);
-
 
674
            }
-
 
675
        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
676
            $.fn.showError(textStatus);
-
 
677
        }).always(function() {
-
 
678
            NProgress.done();
289
 
679
        });
Línea -... Línea 680...
-
 
680
 
-
 
681
    });
-
 
682
 
-
 
683
    $('body').on('click', 'button.reaction-btn', function(e) {
-
 
684
        e.preventDefault();
-
 
685
        var reaction = $(this).data('reaction');
-
 
686
 
-
 
687
        if(!reaction) return 
-
 
688
        var action = $(this).data('link');
-
 
689
 
-
 
690
        var answer_uuid = $(this).data('answer');
-
 
691
        var question_uuid   = $('#row-view').data('question-uuid');
-
 
692
 
-
 
693
        NProgress.start();
-
 
694
        $.ajax({
-
 
695
            'dataType'  : 'json',
-
 
696
            'accept'    : 'application/json',
-
 
697
            'method'    : 'post',
-
 
698
            'url'       :  action,
-
 
699
        }).done(function(response) {
-
 
700
            if(response['success']) {
-
 
701
                $('#' + 'current-reaction-' + answer_uuid).data('reaction', response['data']['reaction']);
-
 
702
                $('#' + 'current-reaction-' + answer_uuid).html(
-
 
703
                    $('#reactionTemplate').render({reaction: ''})
-
 
704
                );
-
 
705
 
-
 
706
                $('#reactions-' + question_uuid).html(response['data']['total_reactions_question']) ; 
-
 
707
                $('#my-coach-question-answer-count-reactions').html(response['data']['total_reactions_question']) ; 
-
 
708
                $('#answer-total-reactions-' + answer_uuid).html(response['data']['total_reactions_answer']) ; 
-
 
709
    
-
 
710
            } else {
-
 
711
                $.fn.showError(response['data']);
-
 
712
            }
-
 
713
        }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
714
            $.fn.showError(textStatus);
-
 
715
        }).always(function() {
-
 
716
            NProgress.done();
-
 
717
        });
-
 
718
    });
-
 
719
 
-
 
720
    let isMouseHover;
-
 
721
 
-
 
722
    $('body').on('mouseover', '#reaction-container', function(e) {
-
 
723
        isMouseHover = true;
-
 
724
        setTimeout(() => {
-
 
725
            $('.reactions').addClass('active');
-
 
726
        }, 500);
-
 
727
    });
-
 
728
 
-
 
729
    $('body').on('mouseout', '#reaction-container', function(e) {
-
 
730
        isMouseHover = false;
-
 
731
        setTimeout(() => {
-
 
732
            if(!isMouseHover) {
-
 
733
                $('.reactions').removeClass('active');
-
 
734
            }
-
 
735
        }, 500);
-
 
736
    });
-
 
737
 
-
 
738
    $('#paginator-process-comm').click(function(e) {
-
 
739
        e.preventDefault();
-
 
740
 
-
 
741
        var next_page = $(this).data('next-page');
-
 
742
        $.fn.reload(false, next_page);
-
 
743
        
290
        $('#modal-question').modal('hide');
744
    });
Línea 291... Línea 745...
291
    });
745
 
292
 
746
 
Línea 305... Línea 759...
305
                    { name: 'tools', items: ['Maximize'] }
759
                    { name: 'tools', items: ['Maximize'] }
306
                ],
760
                ],
307
                removePlugins: 'elementspath,Anchor',
761
                removePlugins: 'elementspath,Anchor',
308
                heigth: 100
762
                heigth: 100
309
    });
763
    });
-
 
764
 
-
 
765
 
-
 
766
    CKEDITOR.replace('description_answer',{
-
 
767
        toolbar: [
-
 
768
                    { name: 'editing', items: ['Scayt'] },
-
 
769
                    { name: 'links', items: ['Link', 'Unlink'] },
-
 
770
                    { name: 'paragraph', items: ['NumberedList', 'BulletedList', '-', 'Outdent', 'Indent', 'Blockquote'] },
-
 
771
                    { name: 'basicstyles', items: ['Bold', 'Italic', 'Strike', 'RemoveFormat'] },
-
 
772
                    '/',
-
 
773
                    { name: 'insert', items: ['Image', 'Table', 'HorizontalRule', 'SpecialChar'] },
-
 
774
                    { name: 'styles', items: ['Styles', 'Format'] },
-
 
775
                    { name: 'tools', items: ['Maximize'] }
-
 
776
                ],
-
 
777
                removePlugins: 'elementspath,Anchor',
-
 
778
                heigth: 100
-
 
779
    }); 
310
});
780
});
311
JS;
781
JS;
Línea 312... Línea 782...
312
 
782
 
313
$this->inlineScript()->captureEnd();
783
$this->inlineScript()->captureEnd();
314
$this->headLink()->appendStylesheet('/look-and-field/my-coach.css');
784
$this->headLink()->appendStylesheet('/look-and-field/my-coach.css');
Línea 315... Línea 785...
315
?>
785
?>
316
 
786
 
317
<section class="companies-info container px-0">
787
<section class="container px-0">
318
    <div class="company-title">
788
    <div class="company-title">
319
        <h1 class="title mx-auto">LABEL_MY_COACH</h1>
789
        <h1 class="title mx-auto">LABEL_MY_COACH</h1>
320
        <?php if($allowQuestionAdd) : ?>
790
        <?php if($allowQuestionAdd) : ?>
Línea 324... Línea 794...
324
       <?php endif; ?>     
794
       <?php endif; ?>     
Línea 325... Línea 795...
325
 
795
 
Línea 326... Línea 796...
326
    </div>
796
    </div>
327
 
797
 
328
    <div class="row gap-3" id="row-list">
798
    <div class="row gap-3" id="row-list">
329
        <div class="my-coach-category-list col-12 col-md-3">
799
		<div class="my-coach-category-list col-12 col-md-3">
330
            <ul>
800
            <ul>
331
                <li class="my-coach-category-li my-coach-category-li-selected">
801
                <li class="my-coach-category-li my-coach-category-li-selected">
332
                    <a class="my-coach-category-a" href="" data-uuid="">LABEL_MY_COACH_CATEGORY_ALL</a>
802
                    <a class="my-coach-category-a" href="" data-uuid="">LABEL_MY_COACH_CATEGORY_ALL</a>
333
                </li>
803
                </li>
334
                <?php
804
                <?php
335
                foreach ($categories as $categorie) :
805
                foreach ($categories as $uuid => $name) :
336
                ?>
806
                ?>
337
                    <li class="my-coach-category-li">
807
                    <li class="my-coach-category-li">
Línea 338... Línea 808...
338
                        <a class="my-coach-category-a" href="" data-uuid="<?php echo $categorie['uuid'] ?>"><?php echo $categorie['name'] ?></a>
808
                        <a class="my-coach-category-a" href="" data-uuid="<?php echo $uuid ?>"><?php echo $name ?></a>
339
                    </li>
809
                    </li>
340
 
810
 
Línea 356... Línea 826...
356
            <div id="my-coach-pagination">
826
            <div id="my-coach-pagination">
357
            </div>
827
            </div>
Línea 358... Línea 828...
358
 
828
 
359
        </div>
829
        </div>
-
 
830
    </div>
-
 
831
    
-
 
832
    
-
 
833
    <div id="row-view" style="display: none">
-
 
834
    
-
 
835
    	<div class="row">
-
 
836
        	<div class="col-12 col-md-8 mx-auto">
-
 
837
    
-
 
838
            	<div class="my-coach-record-card" >
-
 
839
                	<div class="my-coach-record-card-container" >
-
 
840
                    	<div class="my-coach-record-card-resume" >
-
 
841
        					<div class="my_coach_question_detail_user_rectangle"> 
-
 
842
                        		<img id="my-coach-question-user-image" class="my_coach_question_detail_user_image" src="" />
-
 
843
                        		<p id="my-coach-question-user-name" class="my_coach_question_detail_user_name"></p>
-
 
844
                        	</div>
-
 
845
                    	</div>
-
 
846
                    	<div class="my-coach-record-card-content" >
-
 
847
                        	<h2 id="my-coach-question-title"></h2>
-
 
848
                        	<p id="my-coach-question-description"></p> 
-
 
849
                        
-
 
850
                        
-
 
851
                        	<div class="d-flex align-items-center justify-content-between">
-
 
852
                            	<ul id="my-coach-answer-categories" class="d-flex align-items-center  my-coach-record-card-categories">
-
 
853
                            	</ul> 
-
 
854
                        	</div>    
-
 
855
                            
-
 
856
                         	<div class="d-flex align-items-center justify-content-between">    
-
 
857
                            
-
 
858
                            	<div>LABEL_MY_COACH_QUESTION <br/>  <span  id="my-coach-question-answer-question-date"> </span></div>
-
 
859
                            	<div>LABEL_MY_COACH_LAST_ANSWER <br/> <span id="my-coach-question-answer-last-date"> </span></div>
-
 
860
                            
-
 
861
                            
-
 
862
                        	</div>
-
 
863
                         	<div class="d-flex align-items-center justify-content-between">
-
 
864
                         
-
 
865
                            	<div><span id="my-coach-question-answer-count-answers"> </span> LABEL_MY_COACH_ANSWERS</div>
-
 
866
                            	<div><span id="my-coach-question-answer-count-reactions"></span> LABEL_MY_COACH_REACTIONS</div>
-
 
867
                            	<div><span id="my-coach-question-answer-count-views"> </span> LABEL_MY_COACH_VIEWS</div>
-
 
868
                            	<div><span id="my-coach-question-answer-count-comments"> </span> LABEL_COMMENTS</div>
-
 
869
                        	</div>
-
 
870
                
-
 
871
                          	<div class="d-flex align-items-center justify-content-between">
-
 
872
                          		<button id="my-coach-question-answer-btn-back"> <i class="fa fa-chevron-left" aria-hidden="true"></i> LABEL_BACK </button>
-
 
873
                            	<button id="my-coach-question-answer-btn-answer"> <i class="fa fa-pencil" aria-hidden="true"></i> LABEL_REPLY </button>
-
 
874
                            	<button id="my-coach-question-answer-btn-delete"> <i class="fa fa-trash" aria-hidden="true"></i> LABEL_DELETE </button>
-
 
875
                        	</div>
-
 
876
                    	</div>
-
 
877
                	</div>
-
 
878
				</div>
-
 
879
			</div>		
-
 
880
		</div>
-
 
881
		
-
 
882
    		    
-
 
883
        <div id="my-coach-question-answers-list">
-
 
884
        </div>
-
 
885
	</div>        
-
 
886
 
-
 
887
 
-
 
888
 
-
 
889
    
Línea 360... Línea 890...
360
    </div>
890
</section>    
361
 
891
 
362
 
892
 
Línea 424... Línea 954...
424
 
954
 
425
        </div>
955
        </div>
426
    </div>
956
    </div>
Línea -... Línea 957...
-
 
957
</div>
-
 
958
   
-
 
959
<div class="modal" id="modal-answer">
-
 
960
    <div class="modal-dialog  modal-xl">
-
 
961
        <div class="modal-content">
-
 
962
 
-
 
963
            <!-- Modal Header -->
-
 
964
            <div class="modal-header">
-
 
965
                <h4 class="modal-title">LABEL_MY_COACH_ANSWER_ADD</h4>
-
 
966
                <button type="button" class="close" data-dismiss="modal">&times;</button>
-
 
967
            </div>
-
 
968
 
-
 
969
            <!-- Modal body -->
-
 
970
            <div class="modal-body">
-
 
971
                <?php
-
 
972
                $form = $this->formAnswer;
-
 
973
                $form->setAttributes([
-
 
974
                    'method'    => 'post',
-
 
975
                    'name'      => 'form-answer',
-
 
976
                    'id'        => 'form-answer',
-
 
977
                ]);
-
 
978
 
-
 
979
                $form->prepare();
-
 
980
                echo $this->form()->openTag($form);
-
 
981
                ?>
-
 
982
              	<div class="form-group">
-
 
983
                    <?php
-
 
984
                    $element = $form->get('description');
-
 
985
                    $element->setOptions(['label' => 'LABEL_TEXT']);
-
 
986
                    $element->setAttributes(['class' => 'form-control', 'id' => 'description_answer']);
-
 
987
                    
-
 
988
                    echo $this->formLabel($element);
-
 
989
                    echo $this->formTextArea($element);
-
 
990
                    ?>
-
 
991
                </div>
-
 
992
                <div class="text-right">
-
 
993
                    <button type="submit" class="btn btn-primary">LABEL_SAVE</button>
-
 
994
                    <button type="button" class="btn btn-light btn-cancel">LABEL_CANCEL</button>
-
 
995
                </div>
Línea -... Línea 996...
-
 
996
                <?php echo $this->form()->closeTag($form); ?>
-
 
997
            </div>
-
 
998
 
-
 
999
 
-
 
1000
        </div>
-
 
1001
    </div>
-
 
1002
</div>
-
 
1003
 
-
 
1004
<script id="answerTemplate" type="text/x-jsrender">
-
 
1005
<div class="row">
-
 
1006
    <div class="col-12 col-md-8 mx-auto">
-
 
1007
        <div class="my-coach-record-card-container" >
-
 
1008
            <div class="my-coach-record-card-resume" >
-
 
1009
                <div class="my_coach_question_detail_user_rectangle"> 
-
 
1010
                    <img class="my_coach_question_detail_user_image" src="{{:user_image}}" />
-
 
1011
                    <p class="my_coach_question_detail_user_name">{{:user_name}}</p>
-
 
1012
                </div>
-
 
1013
 
-
 
1014
            </div>
-
 
1015
            <div class="my-coach-record-card-content" >
-
 
1016
                <p>{{>description}}</p> 
-
 
1017
                <div class="d-flex align-items-center justify-content-between">
-
 
1018
                   <div>LABEL_DATE  <span>{{:time_elapsed}} </span></div> 
-
 
1019
                   <div>LABEL_COMMENTS <span id="answer-total-comment-{{:uuid}}">{{:total_comments}}<span></div>
-
 
1020
                   <div>LABEL_REACTIONS <span id="answer-total-reactions-{{:uuid}}">{{:total_reactions}}<span></div>  
-
 
1021
                </div>
-
 
1022
            </div>
-
 
1023
 
-
 
1024
 
-
 
1025
            <div class="my-coach-record-card-actions">
-
 
1026
                <div class="position-relative" id="reaction-container">
-
 
1027
                    <button class="btn reaction-btn" data-answer="{{:uuid}}" data-link="{{:link_reaction_delete}}" data-reaction="{{:reaction}}" id="current-reaction-{{:uuid}}">
-
 
1028
 
-
 
1029
 
-
 
1030
                        {{if reaction === '<?php echo ContentReaction::REACTION_FUN ?>'}}
-
 
1031
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="EmojiEmotionsIcon" style="color: rgb(255, 127, 80);">
-
 
1032
                            <path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM8.5 8c.83 0 1.5.67 1.5 1.5S9.33 11 8.5 11 7 10.33 7 9.5 7.67 8 8.5 8zM12 18c-2.28 0-4.22-1.66-5-4h10c-.78 2.34-2.72 4-5 4zm3.5-7c-.83 0-1.5-.67-1.5-1.5S14.67 8 15.5 8s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"></path>
-
 
1033
                        </svg>
-
 
1034
                        LABEL_REACTION_FUN
-
 
1035
                        {{/if}}
-
 
1036
    
-
 
1037
                        {{if reaction === '<?php echo ContentReaction::REACTION_INTEREST ?>'}}
-
 
1038
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="TungstenIcon" style="color: rgb(245, 187, 92);transform: rotate(180deg);">
-
 
1039
                            <path d="M11 19h2v3h-2zm-9-8h3v2H2zm17 0h3v2h-3zm-3.106 6.8014 1.4072-1.4071 2.1213 2.1213-1.4071 1.4071zm-11.3099.7071 2.1214-2.1213 1.4071 1.4072-2.1213 2.1213zM15 8.02V3H9v5.02c-1.21.92-2 2.35-2 3.98 0 2.76 2.24 5 5 5s5-2.24 5-5c0-1.63-.79-3.06-2-3.98zM11 5h2v2.1c-.32-.06-.66-.1-1-.1s-.68.04-1 .1V5z"></path>
-
 
1040
                        </svg>
-
 
1041
                        LABEL_REACTION_INTEREST
-
 
1042
                        {{/if}}
-
 
1043
 
-
 
1044
 
-
 
1045
                        {{if reaction === '<?php echo ContentReaction::REACTION_LOVE ?>'}}
-
 
1046
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="FavoriteTwoToneIcon" style="color: rgb(223, 112, 77);">
-
 
1047
                            <path d="M16.5 5c-1.54 0-3.04.99-3.56 2.36h-1.87C10.54 5.99 9.04 5 7.5 5 5.5 5 4 6.5 4 8.5c0 2.89 3.14 5.74 7.9 10.05l.1.1.1-.1C16.86 14.24 20 11.39 20 8.5c0-2-1.5-3.5-3.5-3.5z" opacity=".3"></path>
-
 
1048
                            <path d="M16.5 3c-1.74 0-3.41.81-4.5 2.09C10.91 3.81 9.24 3 7.5 3 4.42 3 2 5.42 2 8.5c0 3.78 3.4 6.86 8.55 11.54L12 21.35l1.45-1.32C18.6 15.36 22 12.28 22 8.5 22 5.42 19.58 3 16.5 3zm-4.4 15.55-.1.1-.1-.1C7.14 14.24 4 11.39 4 8.5 4 6.5 5.5 5 7.5 5c1.54 0 3.04.99 3.57 2.36h1.87C13.46 5.99 14.96 5 16.5 5c2 0 3.5 1.5 3.5 3.5 0 2.89-3.14 5.74-7.9 10.05z"></path>
-
 
1049
                        </svg>
-
 
1050
                        LABEL_REACTION_LOVE
-
 
1051
                        {{/if}}
-
 
1052
 
-
 
1053
 
-
 
1054
                        {{if reaction === '<?php echo ContentReaction::REACTION_RECOMMENDED ?>'}}
-
 
1055
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="RecommendIcon" style="color: rgb(116, 5, 249);">
-
 
1056
                            <path d="M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm6 9.8a.9.9 0 0 1-.1.5l-2.1 4.9a1.34 1.34 0 0 1-1.3.8H9a2 2 0 0 1-2-2v-5a1.28 1.28 0 0 1 .4-1L12 5l.69.69a1.08 1.08 0 0 1 .3.7v.2L12.41 10H17a1 1 0 0 1 1 1z"></path>
-
 
1057
                        </svg>
-
 
1058
                        LABEL_REACTION_RECOMMENDED
-
 
1059
                        {{/if}}
-
 
1060
 
-
 
1061
                        {{if reaction === '<?php echo ContentReaction::REACTION_SUPPORT ?>'}}
-
 
1062
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="VolunteerActivismIcon" style="color: rgb(100, 149, 237);">
-
 
1063
                            <path d="M1 11h4v11H1zm15-7.75C16.65 2.49 17.66 2 18.7 2 20.55 2 22 3.45 22 5.3c0 2.27-2.91 4.9-6 7.7-3.09-2.81-6-5.44-6-7.7C10 3.45 11.45 2 13.3 2c1.04 0 2.05.49 2.7 1.25zM20 17h-7l-2.09-.73.33-.94L13 16h2.82c.65 0 1.18-.53 1.18-1.18 0-.49-.31-.93-.77-1.11L8.97 11H7v9.02L14 22l8.01-3c-.01-1.1-.9-2-2.01-2z"></path>
-
 
1064
                        </svg>
-
 
1065
                        LABEL_REACTION_SUPPORT
-
 
1066
                        {{/if}}
-
 
1067
 
-
 
1068
                        {{if reaction === ''}}
-
 
1069
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="RecommendIcon" style="color: gray;">
-
 
1070
                            <path d="M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm6 9.8a.9.9 0 0 1-.1.5l-2.1 4.9a1.34 1.34 0 0 1-1.3.8H9a2 2 0 0 1-2-2v-5a1.28 1.28 0 0 1 .4-1L12 5l.69.69a1.08 1.08 0 0 1 .3.7v.2L12.41 10H17a1 1 0 0 1 1 1z"></path>
-
 
1071
                        </svg>
-
 
1072
                        LABEL_REACTION_UNSET
-
 
1073
                        {{/if}}
-
 
1074
 
-
 
1075
 
-
 
1076
                    </button>
-
 
1077
                    <div class="reactions">
-
 
1078
                        <button class="btn-save-reaction" data-link="{{:link_save_reaction}}" data-reaction="<?php echo ContentReaction::REACTION_RECOMMENDED ?>" title="LABEL_REACTION_RECOMMENDED" data-answer="{{:uuid}}">
-
 
1079
                            <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="RecommendIcon" style="color: rgb(116, 5, 249);">
-
 
1080
                                <path d="M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm6 9.8a.9.9 0 0 1-.1.5l-2.1 4.9a1.34 1.34 0 0 1-1.3.8H9a2 2 0 0 1-2-2v-5a1.28 1.28 0 0 1 .4-1L12 5l.69.69a1.08 1.08 0 0 1 .3.7v.2L12.41 10H17a1 1 0 0 1 1 1z"></path>
-
 
1081
                            </svg>
-
 
1082
                        </button>
-
 
1083
                        <button class="btn-save-reaction" data-link="{{:link_save_reaction}}" data-reaction="<?php echo ContentReaction::REACTION_SUPPORT ?>" title="LABEL_REACTION_SUPPORT" data-answer="{{:uuid}}">
-
 
1084
                            <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="VolunteerActivismIcon" style="color: rgb(100, 149, 237);">
-
 
1085
                                <path d="M1 11h4v11H1zm15-7.75C16.65 2.49 17.66 2 18.7 2 20.55 2 22 3.45 22 5.3c0 2.27-2.91 4.9-6 7.7-3.09-2.81-6-5.44-6-7.7C10 3.45 11.45 2 13.3 2c1.04 0 2.05.49 2.7 1.25zM20 17h-7l-2.09-.73.33-.94L13 16h2.82c.65 0 1.18-.53 1.18-1.18 0-.49-.31-.93-.77-1.11L8.97 11H7v9.02L14 22l8.01-3c-.01-1.1-.9-2-2.01-2z"></path>
-
 
1086
                            </svg>
-
 
1087
                        </button>
-
 
1088
                        <button class="btn-save-reaction" data-link="{{:link_save_reaction}}" data-reaction="<?php echo ContentReaction::REACTION_LOVE ?>" title="LABEL_REACTION_LOVE" data-answer="{{:uuid}}">
-
 
1089
                            <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="FavoriteTwoToneIcon" style="color: rgb(223, 112, 77);">
-
 
1090
                                <path d="M16.5 5c-1.54 0-3.04.99-3.56 2.36h-1.87C10.54 5.99 9.04 5 7.5 5 5.5 5 4 6.5 4 8.5c0 2.89 3.14 5.74 7.9 10.05l.1.1.1-.1C16.86 14.24 20 11.39 20 8.5c0-2-1.5-3.5-3.5-3.5z" opacity=".3"></path>
-
 
1091
                                <path d="M16.5 3c-1.74 0-3.41.81-4.5 2.09C10.91 3.81 9.24 3 7.5 3 4.42 3 2 5.42 2 8.5c0 3.78 3.4 6.86 8.55 11.54L12 21.35l1.45-1.32C18.6 15.36 22 12.28 22 8.5 22 5.42 19.58 3 16.5 3zm-4.4 15.55-.1.1-.1-.1C7.14 14.24 4 11.39 4 8.5 4 6.5 5.5 5 7.5 5c1.54 0 3.04.99 3.57 2.36h1.87C13.46 5.99 14.96 5 16.5 5c2 0 3.5 1.5 3.5 3.5 0 2.89-3.14 5.74-7.9 10.05z"></path>
-
 
1092
                            </svg>
-
 
1093
                        </button>
-
 
1094
                        <button class="btn-save-reaction" data-link="{{:link_save_reaction}}" data-reaction="<?php echo ContentReaction::REACTION_INTEREST ?>" title="LABEL_REACTION_INTEREST" data-answer="{{:uuid}}">
-
 
1095
                            <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="TungstenIcon" style="color: rgb(245, 187, 92);transform: rotate(180deg);">
-
 
1096
                                <path d="M11 19h2v3h-2zm-9-8h3v2H2zm17 0h3v2h-3zm-3.106 6.8014 1.4072-1.4071 2.1213 2.1213-1.4071 1.4071zm-11.3099.7071 2.1214-2.1213 1.4071 1.4072-2.1213 2.1213zM15 8.02V3H9v5.02c-1.21.92-2 2.35-2 3.98 0 2.76 2.24 5 5 5s5-2.24 5-5c0-1.63-.79-3.06-2-3.98zM11 5h2v2.1c-.32-.06-.66-.1-1-.1s-.68.04-1 .1V5z"></path>
-
 
1097
                            </svg>
-
 
1098
                        </button>
-
 
1099
                        <button class="btn-save-reaction" data-link="{{:link_save_reaction}}" data-reaction="<?php echo ContentReaction::REACTION_FUN ?>" title="LABEL_REACTION_FUN" data-answer="{{:uuid}}">
-
 
1100
                            <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="EmojiEmotionsIcon" style="color: rgb(255, 127, 80);">
-
 
1101
                                <path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM8.5 8c.83 0 1.5.67 1.5 1.5S9.33 11 8.5 11 7 10.33 7 9.5 7.67 8 8.5 8zM12 18c-2.28 0-4.22-1.66-5-4h10c-.78 2.34-2.72 4-5 4zm3.5-7c-.83 0-1.5-.67-1.5-1.5S14.67 8 15.5 8s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"></path>
-
 
1102
                             </svg>
-
 
1103
                        </button>
-
 
1104
                    </div>
-
 
1105
                </div>
-
 
1106
            </div>
-
 
1107
 
-
 
1108
            <div class="comments-container show px-3">
-
 
1109
                <form class="feedCommentContainer"  id="form-comment-{{:uuid}}" class="form-comment-{{:uuid}}" action="{{:link_add_comment}}" data-answer="{{:uuid}}">
-
 
1110
                    <input class="commentInput" type="text" name="comment" id="comment" maxlength="256" placeholder="LABEL_WRITE_A_COMMENT">
-
 
1111
                    <button class="btn btn-primary" type="submit">LABEL_SEND</button>
-
 
1112
                </form>
-
 
1113
                <ul id="comment-list-{{:uuid}}" class="comment-list">
-
 
1114
                    {{for comments}}
-
 
1115
 
-
 
1116
                    <li>
-
 
1117
                        <div class="comment-container">
-
 
1118
	                       <div class="comment-content comment-{{:unique}}" >
-
 
1119
	                           <div class="info">
-
 
1120
                                    <a href="{{>user_url}}">
-
 
1121
                                        <h3>{{>user_name}}</h3>
-
 
1122
                                    </a>
-
 
1123
                                    <span>
-
 
1124
                                        {{>time_elapsed}}
-
 
1125
                                        {{if link_delete}}
-
 
1126
                                        <a href="#" class="btn-comment-trash" data-link="{{:link_delete}}" data-comment-unique="{{>unique}}" data-answer-uuid="{{>answer_uuid}}">
-
 
1127
                                        <i class="fa fa-trash"></i>
-
 
1128
                                        </a> 
-
 
1129
                                        {{/if}}
-
 
1130
                                    </span>
-
 
1131
                                </div>            
-
 
1132
		                        <p>{{>comment}}</p>
-
 
1133
		                  </div>
-
 
1134
	                   </div>
-
 
1135
                    </li>
-
 
1136
 
-
 
1137
 
-
 
1138
                    {{/for}}
-
 
1139
                </ul>
-
 
1140
 
-
 
1141
            </div>
-
 
1142
        </div>
-
 
1143
    </div>
-
 
1144
</div>    
-
 
1145
</script>
-
 
1146
 
-
 
1147
<script id="reactionTemplate" type="text/x-jsrender">
-
 
1148
                        {{if reaction === '<?php echo ContentReaction::REACTION_FUN ?>'}}
-
 
1149
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="EmojiEmotionsIcon" style="color: rgb(255, 127, 80);">
-
 
1150
                            <path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM8.5 8c.83 0 1.5.67 1.5 1.5S9.33 11 8.5 11 7 10.33 7 9.5 7.67 8 8.5 8zM12 18c-2.28 0-4.22-1.66-5-4h10c-.78 2.34-2.72 4-5 4zm3.5-7c-.83 0-1.5-.67-1.5-1.5S14.67 8 15.5 8s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"></path>
-
 
1151
                        </svg>
-
 
1152
                        LABEL_REACTION_FUN
427
</div>
1153
                        {{/if}}
-
 
1154
    
-
 
1155
                        {{if reaction === '<?php echo ContentReaction::REACTION_INTEREST ?>'}}
-
 
1156
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="TungstenIcon" style="color: rgb(245, 187, 92);transform: rotate(180deg);">
-
 
1157
                            <path d="M11 19h2v3h-2zm-9-8h3v2H2zm17 0h3v2h-3zm-3.106 6.8014 1.4072-1.4071 2.1213 2.1213-1.4071 1.4071zm-11.3099.7071 2.1214-2.1213 1.4071 1.4072-2.1213 2.1213zM15 8.02V3H9v5.02c-1.21.92-2 2.35-2 3.98 0 2.76 2.24 5 5 5s5-2.24 5-5c0-1.63-.79-3.06-2-3.98zM11 5h2v2.1c-.32-.06-.66-.1-1-.1s-.68.04-1 .1V5z"></path>
-
 
1158
                        </svg>
-
 
1159
                        LABEL_REACTION_INTEREST
-
 
1160
                        {{/if}}
-
 
1161
 
-
 
1162
 
-
 
1163
                        {{if reaction === '<?php echo ContentReaction::REACTION_LOVE ?>'}}
-
 
1164
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="FavoriteTwoToneIcon" style="color: rgb(223, 112, 77);">
-
 
1165
                            <path d="M16.5 5c-1.54 0-3.04.99-3.56 2.36h-1.87C10.54 5.99 9.04 5 7.5 5 5.5 5 4 6.5 4 8.5c0 2.89 3.14 5.74 7.9 10.05l.1.1.1-.1C16.86 14.24 20 11.39 20 8.5c0-2-1.5-3.5-3.5-3.5z" opacity=".3"></path>
-
 
1166
                            <path d="M16.5 3c-1.74 0-3.41.81-4.5 2.09C10.91 3.81 9.24 3 7.5 3 4.42 3 2 5.42 2 8.5c0 3.78 3.4 6.86 8.55 11.54L12 21.35l1.45-1.32C18.6 15.36 22 12.28 22 8.5 22 5.42 19.58 3 16.5 3zm-4.4 15.55-.1.1-.1-.1C7.14 14.24 4 11.39 4 8.5 4 6.5 5.5 5 7.5 5c1.54 0 3.04.99 3.57 2.36h1.87C13.46 5.99 14.96 5 16.5 5c2 0 3.5 1.5 3.5 3.5 0 2.89-3.14 5.74-7.9 10.05z"></path>
-
 
1167
                        </svg>
-
 
1168
                        LABEL_REACTION_LOVE
-
 
1169
                        {{/if}}
-
 
1170
 
-
 
1171
 
-
 
1172
                        {{if reaction === '<?php echo ContentReaction::REACTION_RECOMMENDED ?>'}}
-
 
1173
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="RecommendIcon" style="color: rgb(116, 5, 249);">
-
 
1174
                            <path d="M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm6 9.8a.9.9 0 0 1-.1.5l-2.1 4.9a1.34 1.34 0 0 1-1.3.8H9a2 2 0 0 1-2-2v-5a1.28 1.28 0 0 1 .4-1L12 5l.69.69a1.08 1.08 0 0 1 .3.7v.2L12.41 10H17a1 1 0 0 1 1 1z"></path>
-
 
1175
                        </svg>
-
 
1176
                        LABEL_REACTION_RECOMMENDED
-
 
1177
                        {{/if}}
-
 
1178
 
-
 
1179
                        {{if reaction === '<?php echo ContentReaction::REACTION_SUPPORT ?>'}}
-
 
1180
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="VolunteerActivismIcon" style="color: rgb(100, 149, 237);">
-
 
1181
                            <path d="M1 11h4v11H1zm15-7.75C16.65 2.49 17.66 2 18.7 2 20.55 2 22 3.45 22 5.3c0 2.27-2.91 4.9-6 7.7-3.09-2.81-6-5.44-6-7.7C10 3.45 11.45 2 13.3 2c1.04 0 2.05.49 2.7 1.25zM20 17h-7l-2.09-.73.33-.94L13 16h2.82c.65 0 1.18-.53 1.18-1.18 0-.49-.31-.93-.77-1.11L8.97 11H7v9.02L14 22l8.01-3c-.01-1.1-.9-2-2.01-2z"></path>
-
 
1182
                        </svg>
-
 
1183
                        LABEL_REACTION_SUPPORT
-
 
1184
                        {{/if}}
-
 
1185
 
-
 
1186
                        {{if reaction === ''}}
-
 
1187
                        <svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewBox="0 0 24 24" data-testid="RecommendIcon" style="color: gray;">
-
 
1188
                            <path d="M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm6 9.8a.9.9 0 0 1-.1.5l-2.1 4.9a1.34 1.34 0 0 1-1.3.8H9a2 2 0 0 1-2-2v-5a1.28 1.28 0 0 1 .4-1L12 5l.69.69a1.08 1.08 0 0 1 .3.7v.2L12.41 10H17a1 1 0 0 1 1 1z"></path>
-
 
1189
                        </svg>
-
 
1190
                        LABEL_REACTION_UNSET
-
 
1191
                        {{/if}}
-
 
1192
</script>
-
 
1193
 
-
 
1194
 
-
 
1195
 
-
 
1196
<script id="commentTemplate" type="text/x-jsrender">
-
 
1197
    <li>
-
 
1198
        <div class="comment-container">
-
 
1199
	        <div class="comment-content comment-{{:unique}}" >
-
 
1200
	            <div class="info">
-
 
1201
                    <a href="{{>user_url}}">
-
 
1202
                        <h3>{{>user_name}}</h3>
-
 
1203
                    </a>
-
 
1204
                    <span>
-
 
1205
                        {{>time_elapsed}}
-
 
1206
                        {{if link_delete}}
-
 
1207
                        <a href="#" class="btn-comment-trash" data-link="{{:link_delete}}" data-comment-unique="{{>unique}}"  data-answer-uuid="{{>answer_uuid}}">
-
 
1208
                            <i class="fa fa-trash"></i>
-
 
1209
                        </a> 
-
 
1210
                        {{/if}}
-
 
1211
                    </span>
-
 
1212
                </div>            
-
 
1213
		      <p>{{>comment}}</p>
Línea 428... Línea 1214...
428
   
1214
		  </div>
429
 
1215
	   </div>
430
 
1216
    </li>
431
</section>
1217
</script>
-
 
1218
 
-
 
1219
 
-
 
1220
<script id="recordTemplate" type="text/x-jsrender">
-
 
1221
    <div class="my-coach-record-card" id="my-coach-record-card-question-{{:uuid}}">
432
 
1222
        <div class="my-coach-record-card-container" >
433
 
1223
            <div class="my-coach-record-card-resume" >
434
<script id="recordTemplate" type="text/x-jsrender">
1224
                <div class="my_coach_question_detail_user_rectangle"> 
435
    <div class="my-coach-record-card" >
1225
                    <img class="my_coach_question_detail_user_image" src="{{:user_image}}" />
-
 
1226
                    <p class="my_coach_question_detail_user_name">{{:user_name}}</p>
436
        <div class="my-coach-record-card-container" >
1227
                </div>
437
            <div class="my-coach-record-card-resume" >
1228
                <ul>
438
                <ul>
1229
                    <li><span id="answers-{{:uuid}}"> {{:answers}} </span> LABEL_MY_COACH_ANSWERS</li>
439
                    <li><span id="answers-{{:uuid}}"> {{:answers}} </span> LABEL_MY_COACH_ANSWERS</li>
1230
                    <li><span id="reactions-{{:uuid}}"> {{:reactions}} </span> LABEL_MY_COACH_REACTIONS</li>
440
                    <li><span id="reactions-{{:uuid}}"> {{:reactions}} </span> LABEL_MY_COACH_REACTIONS</li>
1231
                    <li><span id="views-{{:uuid}}"> {{:views}} </span> LABEL_MY_COACH_VIEWS</li>
441
                    <li><span id="views-{{:uuid}}"> {{:views}} </span> LABEL_MY_COACH_VIEWS</li>
1232
                    <li><span id="comments-{{:uuid}}"> {{:comments}} </span> LABEL_COMMENTS</li>     
442
                </ul>
1233
                </ul>
443
            </div>
1234
            </div>
444
            <div class="my-coach-record-card-content" >
1235
            <div class="my-coach-record-card-content" >
Línea 454... Línea 1245...
454
                </div>
1245
                </div>
455
            </div>
1246
            </div>
456
        </div>
1247
        </div>
Línea 457... Línea 1248...
457
 
1248
 
-
 
1249
        <div class="d-flex align-items-center justify-content-between">
-
 
1250
            <button data-link="{{:link_view}}" class="btn-my-coach-edit-view"> <i class="fa fa-external-link" aria-hidden="true"></i> LABEL_VIEW </button>
458
        <div class="d-flex align-items-center justify-content-between">
1251
 
459
            {{if link_edit }}
1252
            {{if link_edit }}
460
            <button data-link="{{>link_edit}}" class="btn-my-coach-edit"> <i class="fa fa-pencil" aria-hidden="true"></i> </button>
1253
            <button data-link="{{>link_edit}}" class="btn-my-coach-edit-question"> <i class="fa fa-pencil" aria-hidden="true"></i> LABEL_EDIT </button>
461
            {{/if}}
1254
            {{/if}}
462
            {{if link_delete }}
1255
            {{if link_delete }}
463
            <button data-link="{{>link_delete}}" class="btn-my-coach-delete"> <i class="fa fa-trash" aria-hidden="true"></i> </button>
1256
            <button data-link="{{>link_delete}}" class="btn-my-coach-delete-question"> <i class="fa fa-trash" aria-hidden="true"></i> LABEL_DELETE </button>
464
            {{/if}}
1257
            {{/if}}
465
        </div>
1258
        </div>
466
    </div>
1259
    </div>