Changeset 6985 for sandbox/2.4.2-expresso1/expressoMail1_2/js/main.js
- Timestamp:
- 08/10/12 12:25:20 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/2.4.2-expresso1/expressoMail1_2/js/main.js
r6965 r6985 1 1 // Tempo do auto refresh (em milisegundos) 2 //var time_refresh = 300000; 3 var time_refresh = 30000; 2 var time_refresh = 300000; 4 3 5 4 // tempo do auto save (em milisegundos) … … 589 588 var handler_refresh = function(data){ 590 589 handlerMessageFilter = function (data) { 591 if(checkAlarmsFilter){ 592 alarmFollowupflagged('filtersAlarms', data); 593 } 590 alarmFollowupflagged('filtersAlarms', data); 594 591 notificationFilter(data, notifyPermission); 595 596 checkAlarmsFilter = true;597 598 592 } 599 593 /* Busca nas pastas indexadas para ver se há novas mensagens com a flag $FilteredMessage */ … … 3962 3956 type == 'event' ? 3963 3957 {calendar: User.preferences.defaultCalendar ? User.preferences.defaultCalendar : Calendar.calendars[0], calendars: Calendar.calendars} 3964 : {group: Calendar.groups[0].id, groups: Calendar.groups }3958 : {group: Calendar.groups[0].id, groups: Calendar.groups, percentage: 0} 3965 3959 ); 3966 3960 … … 4088 4082 4089 4083 if(typeof(typeImport) == "object"){ 4090 var calendar Permission = typeImport.calendar;4084 var calendarIds = !!typeImport.calendar ? typeImport.calendar : Calendar[typeImport.type]; 4091 4085 typeImport = typeImport.action; 4092 4086 } … … 4100 4094 var options = ''; 4101 4095 4102 if(typeImport == 10){ 4103 for(var i = 0; i < calendarPermission.length; i++) 4104 options += '<option value="'+calendarPermission[i]+'">'+Calendar.signatureOf[calendarPermission[i]].calendar.name+'</option>' 4105 }else{ 4106 for(var id in Calendar.signatures) 4107 options += parseInt(Calendar.signatures[id].isOwner) ? '<option value="'+Calendar.signatures[id].calendar.id+'">'+Calendar.signatures[id].calendar.name+'</option>' : ''; 4096 if(calendarIds){ 4097 for(var i = 0; i < calendarIds.length; i++) 4098 options += '<option value="'+calendarIds[i]+'">'+Calendar.signatureOf[calendarIds[i]].calendar.name+'</option>' 4108 4099 } 4109 4100 … … 4120 4111 url: "controller.php?action="+import_url+'&from_ajax=true&selected='+$("#select-agenda option:selected").val()+'&status='+$("#select-status option:selected").val()+'&uidAccount='+decodeOwner(), 4121 4112 success: function(msg){ 4122 var alt = ( (msg = connector.unserialize(msg)) == "ok") ? "Importado com sucesso para " : "Ocorreu um erro ao importar o evento para a agenda ";4113 var alt = ( (msg = connector.unserialize(msg)) == "ok") ? "Importado com sucesso para " : "Ocorreu um erro ao importar o evento/tarefa para a agenda "; 4123 4114 alert( alt + $("#select-agenda option:selected").text() ); 4124 4115 } … … 4138 4129 url: "controller.php?action="+import_url+'&from_ajax=true&selected=true', 4139 4130 success: function(msg){ 4140 alert( ( ( connector.unserialize(msg)) == "ok") ? "Seu evento foi removido " : "Ocorreu um erro ao remover o evento" );4131 alert( ( ( connector.unserialize(msg)) == "ok") ? "Seu evento/tarefa foi removido " : "Ocorreu um erro ao remover o evento/tarefa" ); 4141 4132 } 4142 4133 }); … … 4147 4138 url: "controller.php?action="+import_url+'&from_ajax=true&selected=true', 4148 4139 success: function(msg){ 4149 alert( ( ( connector.unserialize(msg)) == "ok") ? "Seu evento foi Atualizado com sucesso" : "Ocorreu um erro ao atualizar evento" );4140 alert( ( ( connector.unserialize(msg)) == "ok") ? "Seu evento/tarefa foi Atualizado com sucesso" : "Ocorreu um erro ao atualizar evento/tarefa" ); 4150 4141 } 4151 4142 }); … … 4153 4144 break; 4154 4145 case 6: 4155 var acceptedSuggestion = confirm("Deseja atualizar o evento de acordo com a sugestão ?");4146 var acceptedSuggestion = confirm("Deseja atualizar o evento/tarefa de acordo com a sugestão ?"); 4156 4147 $.ajax({ 4157 4148 url: "controller.php?action="+import_url+'&from_ajax=true&id_user='+User.me.id+'&selected=true&cirus_delimiter='+cyrus_delimiter+'&acceptedSuggestion='+acceptedSuggestion+"&from="+document.getElementById('from_values_'+currentTab).value+'&uidAccount='+decodeOwner(), 4158 4149 success: function(msg){ 4159 4150 if(acceptedSuggestion) 4160 alert( ( ( connector.unserialize(msg)) == "ok") ? "Evento atualizado com sucesso " : "Ocorreu um erro ao atualizar o evento" );4151 alert( ( ( connector.unserialize(msg)) == "ok") ? "Evento/tarefa atualizado com sucesso " : "Ocorreu um erro ao atualizar o evento" ); 4161 4152 } 4162 4153 }); … … 4164 4155 break; 4165 4156 case 9: 4166 alert('Seu evento não possui alterações!');4157 alert('Seu evento/tarefa não possui alterações!'); 4167 4158 return; 4168 4159 break; 4169 4160 case 11: 4170 alert('Este evento já fora importando por algum dos particpantes e já se encontra disponível em sua agenda compartilhada!');4161 alert('Este evento/tarefa já fora importando por algum dos particpantes e já se encontra disponível em sua agenda compartilhada!'); 4171 4162 return; 4172 4163 break; … … 4177 4168 $("#import-dialog" ).dialog({ 4178 4169 height: 160, 4179 title: 'Atualizar Evento ',4170 title: 'Atualizar Evento/Tarefa', 4180 4171 buttons: { 4181 4172 Cancel: function() {
Note: See TracChangeset
for help on using the changeset viewer.