Skip to content

Commit

Permalink
Merge pull request #3 from LeonardoRM/per-domain-rcpath
Browse files Browse the repository at this point in the history
Per domain rcpath
  • Loading branch information
LeonardoRM authored Mar 29, 2019
2 parents 90d5729 + 38fd135 commit 69f24b0
Show file tree
Hide file tree
Showing 26 changed files with 701 additions and 825 deletions.
2 changes: 1 addition & 1 deletion roundcube/appinfo/app.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* ownCloud - roundcube mail plugin
* ownCloud - RoundCube mail plugin
*
* @author Martin Reinhardt and David Jaedke
* @author 2019 Leonardo R. Morelli github.com/LeonardoRM
Expand Down
11 changes: 3 additions & 8 deletions roundcube/appinfo/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,12 @@
<name>RoundCube Mail</name>
<licence>AGPL</licence>
<author>Martin Reinhardt; Leonardo R. Morelli</author>
<version>10.0.0</version>
<version>10.0.1</version>
<dependencies>
<owncloud min-version="10" max-version="11.0" />
</dependencies>
<description>
Integrates existing roundcube into OwnCloud, check the instructions below.
Integrates existing roundcube into OwnCloud.
</description>

<documentation>
<admin>https://github.com/hypery2k/owncloud/wiki/Installation#roundcube</admin>
</documentation>

<website>https://github.com/hypery2k/owncloud</website>
<website>https://github.com/LeonardoRM/owncloud-roundcube/</website>
</info>
21 changes: 21 additions & 0 deletions roundcube/appinfo/routes.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,25 @@
<?php
/**
* ownCloud - RoundCube mail plugin
*
* @author Martin Reinhardt and David Jaedke
* @author 2019 Leonardo R. Morelli github.com/LeonardoRM
* @copyright 2012 Martin Reinhardt [email protected]
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
* License as published by the Free Software Foundation; either
* version 3 of the License, or any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library. If not, see <http://www.gnu.org/licenses/>.
*
*/
return ['routes' => [
['name' => 'page#index', 'url' => '/', 'verb' => 'GET'],
//settings
Expand Down
6 changes: 6 additions & 0 deletions roundcube/css/adminSettings.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.rcSetting {
margin-bottom: 24px;
}
#rcAddDomainPath {
display: inline-block;
}
16 changes: 14 additions & 2 deletions roundcube/js/adminSettings.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,32 @@ Roundcube.adminSettingsUI = function() {
if ($('#roundcube').length <= 0) {
return;
}
$('#rcAddDomainPath').click(function() {
document.getElementById('rcTableDomainPath').tBodies[0].appendChild(
document.importNode(
document.getElementById('rcDomainPath').content,
true
)
);
});
$('#rcTableDomainPath').on('click', '.action.delete', function() {
$(this).closest('tr').remove();
});
$('#rcAdminSubmit').click(function(event) {
event.preventDefault();

// Prevent CSRF with OC request token
$('#requesttoken').val(oc_requesttoken);
var data = $('#rcMailAdminPrefs').serialize();
var data = $('#rcAdminSettings').serialize();
$('#rc_save_success, #rc_save_error').hide();
$('#rc_save_status').show();
// Ajax
$.post(OC.filePath('roundcube', 'ajax', 'adminSettings.php'), data, function(res) {
$('#rc_save_status').hide();
if (res.status == 'success') {
$('#maildir').val(res.config.maildir);
$('#defaultRCPath').val(res.config.defaultRCPath);
$('#rc_save_success').text(res.message).show().delay(2000).fadeOut(2000);
} else if (res.status == 'error') {
$('#rc_save_error').text(res.message).show();
}
}, 'json');
Expand Down
10 changes: 6 additions & 4 deletions roundcube/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ var Roundcube = Roundcube || {};
* This is only for larry/melanie2_larry_mobile skins.
* For other skins we don't do anything.
*/
Roundcube.modIframe = function() {
Roundcube.hideTopLine = function() {
var rcf = $("#roundcubeFrame");
if (!rcf[0].contentWindow.rcmail.env.skin.includes("larry")) {
return;
Expand Down Expand Up @@ -64,9 +64,11 @@ Roundcube.resizeIframe = function() {
}

$('#roundcubeFrame').ready(function() {
$('#roundcubeFrame').load(function() {
Roundcube.modIframe();
});
if (!$('#roundcubeFrame').hasClass('showTopLine')) {
$('#roundcubeFrame').load(function() {
Roundcube.hideTopLine();
});
}
Roundcube.resizeIframe();
});

Expand Down
204 changes: 0 additions & 204 deletions roundcube/js/mail.js

This file was deleted.

39 changes: 18 additions & 21 deletions roundcube/l10n/es.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,27 @@ OC.L10N.register(
{
"Webmail" : "Webmail",
"Not submitted for us." : "No enviado para nosotros.",
"Maildir can't be an empty string." : "Maildir no puede estar vacía.",
"Host is not valid." : "El host no es válido.",
"Port must be a valid port number or left empty." : "El número de puerto debe ser válido o dejado vacío.",
"Internal address '%s' is not an URL" : "La dirección interna '%s' no es una URL.",
"Default RC installation path can't be an empty string." : "La ruta por defecto de la instalación del RC no puede ser vacía.",
"Default path must be a url relative to this server." : "La ruta por defecto debe ser una url relativa a este servidor.",
"A domain is not valid." : "Uno de los dominios no es válido.",
"A path is not valid." : "Una de las rutas no es válida.",
"Paths must be urls relative to this server." : "Las rutas deben ser urls relativas a este servidor.",
"Unpaired domains and paths." : "El número de dominios y rutas no es parejo.",
"Some inputs are not valid." : "Algunas entradas no son válidas.",
"Application settings successfully stored." : "Configuración de la aplicación guardada con éxito.",
"Usuario 'admin' no hace Auto-Login." : "Usuario 'admin' no hace Auto-Login.",
"Unable to login into roundcube. There are login errors." : "No se puede hacer login en RoundCube. Hay errores de login.",
"Basic settings" : "Configuración básica",
"If you have \"http://example.com/roundcube\" enter \"/roundcube/\" here. Note that subdomains or URLs do not work, just absolute paths to the same domain ownCloud is running." : "Si se tiene \"http://example.com/roundcube\", ingresar \"/roundcube/\" aquí. Notar que subdominios o URLs no funcionan, sólo rutas absolutas al mismo dominio en el que está ejecutándose ownCloud.",
"Absolute path to RC installation" : "Ruta absoluta a la instalación del RC.",
"Username '%s' is not an email address." : "El usuario '%s' no es un email válido.",
"Default RC installation path" : "Ruta por defecto al RC",
"Default path relative to ownCloud server (%s)." : "Ruta por defecto relativa al servidor ownCloud (%s).",
"Per email domain RC installations" : "Rutas a RC por dominio de email",
"Enter your users' email domains and their corresponding paths if you have different RoundCube installations. For example: 'domain1.com':'roundcube1/', 'domain2.com':'roundcube2/'. Path relative to ownCloud server." : "Ingresar los dominios de los emails de sus usuarios y las correspondientes rutas si tiene diferentes instalaciones de RoundCube. Por ejemplo: 'domain1.com':'roundcube1/', 'domain2.com':'roundcube2/'. Rutas relativas al servidor ownCloud.",
"Remove" : "Quitar",
"Add" : "Agregar",
"Advanced settings" : "Configuración avanzada",
"Show RoundCube control navigation menu items with currently logged in user information" : "Mostrar menú de control de navegación del RC con información del usuario logueado.",
"Show information bar on top of page" : "Mostrar barra de información arriba de la página.",
"Enable SSL verification, e.g. disable for self-signed certificates" : "Habilitar verificación SSL (deshabilitar para certificados auto-firmados).",
"Enable debug messages. RC tends to bloat the log-files." : "Habilitar mensajes de depuración. RC tiende a llenar los archivos de log.",
"Enable debug logging" : "Habilitar depuración.",
"Overwrite roundcube server hostname if not the same as owncloud, e.g. for (sub)domains which resides on the same server, e.g rc.domain.tld. But keep in mind that due to iFrame security constraints it will be only working on the same server, see HTML/JS same-origin policies." : "Sobreescribir el hostname del servidor de RC si no es el mismo que ownCloud, ej.: para (sub)dominios que residan en el mismo servidor (rc.dominio.tld). Tener en cuenta que sólo funcionará en el mismo servidor por las restricciones de seguridad del iFrame. Ver políticas de HTML/JS same-origin.",
"Overwrite RC server hostname" : "Sobreescribir el hostname del servidor de RC.",
"Overwrite roundcube server port (If not specified, ports 80/443 are used for HTTP/S)." : "Sobreescribir el puerto del servidor de RC. (Si no se especifica, se usan los puertos 80/443 para HTTP/S.",
"Overwrite RC server port" : "Sobreescribir el puerto del servidor de RC.",
"Internal RoundCube address (as seen by the OwnCloud server). Use this if the internal address, to which OwnCloud should connect when talking to RoundCube, does not match the host and port set above." : "Dirección interna del RC (como la ve el servidor ownCloud). Usar esto si la dirección interna, a la que el ownCloud se debería conectar cuando habla con RC, no concuerda con el host y puerto de arriba.",
"Internal RC address" : "Dirección interna del RC.",
"Saving..." : "Guardando...",
"Save" : "Guardar"
"Show RoundCube top information bar (shows logout button)." : "Mostrar barra de información de RoundCube arriba (muestra botón de logout).",
"Disable when debugging with self-signed certificates." : "Deshabilitar para depurar con certificados auto-firmados.",
"Enable SSL verification." : "Habilitar verificación SSL.",
"Save" : "Guardar",
"Saving..." : "Guardando..."
},
"");
Loading

0 comments on commit 69f24b0

Please sign in to comment.