Changeset 7978 for branches


Ignore:
Timestamp:
03/07/13 09:51:27 (6 years ago)
Author:
douglas
Message:

Ticket #3371 - Corrigido query de busca de evento para melhor atender a agendas compartilhadas

Location:
branches/2.5/prototype/modules/calendar
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/2.5/prototype/modules/calendar/interceptors/DBMapping.php

    r7976 r7978  
    943943                .'calendar_object.tzid as "timezone", calendar_to_calendar_object.calendar_id as "calendar" ' 
    944944                .'FROM calendar_object, calendar_to_calendar_object ' 
    945                 .'WHERE ( calendar_object.id = '. $criteria['schedulable'] .' AND calendar_to_calendar_object.calendar_object_id = calendar_object.id)'; 
     945                .'WHERE ( calendar_object.id = '. $criteria['schedulable'] .' AND calendar_to_calendar_object.calendar_object_id = calendar_object.id'  
     946                .' AND calendar_to_calendar_object.calendar_id IN (select calendar_id from calendar_signature where calendar_signature.user_uidnumber = '. Config::me('uidNumber') .' )         )';  
    946947 
    947948            $params = Controller::service('PostgreSQL')->execResultSql($sql); 
  • branches/2.5/prototype/modules/calendar/templates/event_add.ejs

    r7036 r7978  
    7272                <p class="input-group"> 
    7373                        <label for="calendar_addevent_details_slt_cal">Agenda</label> 
    74                         <select name="calendar" > 
     74                        <select name="calendar" <%=( data.event.isShared ) ? 'disabled="disabled"' : '' %> > 
    7575                        <%  
    7676                          for (var i=0; i< data.event.calendars.length; i++) { 
  • branches/2.5/prototype/modules/calendar/templates/event_repeat.ejs

    r7602 r7978  
    55        <p class="input-group"> 
    66                <label for="frequency">Repetição:</label> 
    7                 <select name="frequency" class="frequency" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled'%>> 
     7                <select name="frequency" class="frequency" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    88                        <option value="none">Sem repetição</option> 
    99                        <option value="daily">Diária</option> 
     
    1919        <p class="input-group event-repeat-monthly hidden frequency-option">  
    2020                <label>Mensalmente por </label> 
    21                 <input type="radio" name="repeatmonthyType" value="0"> 
     21                <input type="radio" name="repeatmonthyType" value="0" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    2222                <label for="repeatmonthyType">dia do mês</label> 
    2323 
    24                 <input type="radio" name="repeatmonthyType" value="1"> 
     24                <input type="radio" name="repeatmonthyType" value="1" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    2525                <label for="repeatmonthyType">dia da semana</label> 
    2626        </p> 
     
    2929        <p class="input-group event-repeat-weekly hidden frequency-option">    
    3030                <label>Toda </label> 
    31                 <input type="checkbox" name="repeatweekly[]" value="SU"> 
     31                <input type="checkbox" name="repeatweekly[]" value="SU" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    3232                <label for="repeatweekly[]">Domingo</label> 
    3333 
    34                 <input type="checkbox" name="repeatweekly[]" value="MO"> 
     34                <input type="checkbox" name="repeatweekly[]" value="MO"  <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    3535                <label for="repeatweekly[]">Segunda</label> 
    3636 
    37                 <input type="checkbox" name="repeatweekly[]" value="TU"> 
     37                <input type="checkbox" name="repeatweekly[]" value="TU"  <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    3838                <label for="repeatweekly[]">Terça</label> 
    3939 
    40                 <input type="checkbox" name="repeatweekly[]" value="WE"> 
     40                <input type="checkbox" name="repeatweekly[]" value="WE" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    4141                <label for="repeatweekly[]">Quarta</label> 
    4242 
    43                 <input type="checkbox" name="repeatweekly[]" value="TH"> 
     43                <input type="checkbox" name="repeatweekly[]" value="TH" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    4444                <label for="repeatweekly[]">Quinta</label> 
    4545 
    46                 <input type="checkbox" name="repeatweekly[]" value="FR"> 
     46                <input type="checkbox" name="repeatweekly[]" value="FR" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    4747                <label for="repeatweekly[]">Sexta</label> 
    4848 
    49                 <input type="checkbox" name="repeatweekly[]" value="SA"> 
     49                <input type="checkbox" name="repeatweekly[]" value="SA" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    5050                <label for="repeatweekly[]">Sabado</label> 
    5151        </p> 
     
    6565                        <label class="label_finish_event">A repetição</label> 
    6666                        <!--<input type="radio" name="repeat_finish" value="date_fixed">--> 
    67                         <select name="endOptions" class="endRepeat"> 
     67                        <select name="endOptions" class="endRepeat" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    6868                            <option value="never">Nunca termina</option> 
    6969                            <option value="customDate">Termina na Data Selecionada</option> 
    7070                            <option value="occurrences">Termina Após n Ocorrencias</option> 
    7171                        </select> 
    72                         <input type="text" name="end" class="date customDateEnd hidden"> 
    73                         <input type="text" name="occurrences" class="tiny number occurrencesEnd hidden"> 
     72                        <input type="text" name="end" class="date customDateEnd hidden" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
     73                        <input type="text" name="occurrences" class="tiny number occurrencesEnd hidden" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    7474                        <label name="occurrences" class="hidden">Ocorrências</label> 
    7575                </span> 
     
    7878                <span class="input-group"> 
    7979                        <label>Tendo intervalo de</label> 
    80                         <input type="text" name="" class="tiny number eventInterval" value="1"> 
     80                        <input type="text" name="" class="tiny number eventInterval" value="1" <%= ((data.event.acl.write || data.event.acl.organization) && data.event.isAttendee) ? '' : 'disabled="disabled"'%>> 
    8181                        <label class="interval"></label> 
    8282                </span> 
Note: See TracChangeset for help on using the changeset viewer.