mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-23 19:31:53 +02:00
added possebility to remove the crontab-line
This commit is contained in:
parent
625957872d
commit
f4fd01dd10
@ -58,7 +58,7 @@
|
|||||||
'min' => lang('Minute')
|
'min' => lang('Minute')
|
||||||
);
|
);
|
||||||
|
|
||||||
if ($_POST['send'] || $_POST['test'] || $_POST['cancel'] || $_POST['install'] || $_POST['update'] || isset($_POST['asyncservice']))
|
if ($_POST['send'] || $_POST['test'] || $_POST['cancel'] || $_POST['install'] || $_POST['deinstall'] || $_POST['update'] || isset($_POST['asyncservice']))
|
||||||
{
|
{
|
||||||
$times = array();
|
$times = array();
|
||||||
foreach($units as $u => $ulabel)
|
foreach($units as $u => $ulabel)
|
||||||
@ -85,12 +85,13 @@
|
|||||||
echo '<p><b>'.lang("Error canceling timer, maybe there's none set !!!")."</b></p>\n";
|
echo '<p><b>'.lang("Error canceling timer, maybe there's none set !!!")."</b></p>\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($_POST['install'])
|
if ($_POST['install'] || $_POST['deinstall'])
|
||||||
{
|
{
|
||||||
if (!($install = $async->install($times)))
|
if (!($install = $async->install($_POST['install'] ? $times : False)))
|
||||||
{
|
{
|
||||||
echo '<p><b>'.lang('Error: %1 not found or other error !!!',$async->crontab)."</b></p>\n";
|
echo '<p><b>'.lang('Error: %1 not found or other error !!!',$async->crontab)."</b></p>\n";
|
||||||
}
|
}
|
||||||
|
$_POST['asyncservice'] = $_POST['deinstall'] ? 'fallback' : 'crontab';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -129,7 +130,13 @@
|
|||||||
$selected = $key == $GLOBALS['phpgw_info']['server']['asyncservice'] ? ' selected' : '';
|
$selected = $key == $GLOBALS['phpgw_info']['server']['asyncservice'] ? ' selected' : '';
|
||||||
echo "<option value=\"$key\"$selected>$label</option>\n";
|
echo "<option value=\"$key\"$selected>$label</option>\n";
|
||||||
}
|
}
|
||||||
echo "</select></p>\n";
|
echo "</select>\n";
|
||||||
|
|
||||||
|
if (is_array($installed) && isset($installed['cronline']))
|
||||||
|
{
|
||||||
|
echo ' <input type="submit" name="deinstall" value="'.lang('Deinstall crontab')."\">\n";
|
||||||
|
}
|
||||||
|
echo "</p>\n";
|
||||||
|
|
||||||
if ($async->only_fallback)
|
if ($async->only_fallback)
|
||||||
{
|
{
|
||||||
|
@ -86,6 +86,7 @@ day of week<br>(0-6, 0=sun) admin de Wochentag<br>(0-6, 0=Sonntag)
|
|||||||
default admin de Vorgabe
|
default admin de Vorgabe
|
||||||
default file system space per user admin de Vorgabewert für Dateisystemplatz pro Benutzer
|
default file system space per user admin de Vorgabewert für Dateisystemplatz pro Benutzer
|
||||||
default file system space per user/group ? admin de Vorgabewert für Dateisystemplatz pro Benutzer/Gruppe verwenden?
|
default file system space per user/group ? admin de Vorgabewert für Dateisystemplatz pro Benutzer/Gruppe verwenden?
|
||||||
|
deinstall crontab admin de Crontab deinstallieren
|
||||||
delete account admin de Benutzerkonto löschen
|
delete account admin de Benutzerkonto löschen
|
||||||
delete all records admin de Alle Einträge löschen
|
delete all records admin de Alle Einträge löschen
|
||||||
delete application admin de Anwendung löschen
|
delete application admin de Anwendung löschen
|
||||||
@ -115,10 +116,10 @@ description can not exceed 255 characters in length ! admin de Die Beschreibung
|
|||||||
disable "auto completion" of the login form admin de Automatisches Vervollständigen der Logindaten abschalten
|
disable "auto completion" of the login form admin de Automatisches Vervollständigen der Logindaten abschalten
|
||||||
disabled (not recomended) admin de abgeschaltet (nicht empfohlen)
|
disabled (not recomended) admin de abgeschaltet (nicht empfohlen)
|
||||||
display admin de Anzeigen
|
display admin de Anzeigen
|
||||||
do not delete the category and return back to the list admin de
|
do not delete the category and return back to the list admin de Kategorie NICHT löschen und zurück zur Liste gehen
|
||||||
do you also want to delete all global subcategories ? admin de wollen Sie auch alle globalen Unterkategorien löschen ?
|
do you also want to delete all global subcategories ? admin de wollen Sie auch alle globalen Unterkategorien löschen ?
|
||||||
do you want to delete all global subcategories ? admin de Möchten Sie alle Globale Unterkategorien löschen ?
|
do you want to delete all global subcategories ? admin de Möchten Sie alle Globale Unterkategorien löschen ?
|
||||||
do you want to move all global subcategories one level down ? admin de
|
do you want to move all global subcategories one level down ? admin de Wollen sie alle globalen Unterkategorien eine Ebene nach unten verschieben?
|
||||||
edit account admin de Benutzerkonto bearbeiten
|
edit account admin de Benutzerkonto bearbeiten
|
||||||
edit application admin de Anwendung bearbeiten
|
edit application admin de Anwendung bearbeiten
|
||||||
edit global category admin de Globale Kategorie bearbeiten
|
edit global category admin de Globale Kategorie bearbeiten
|
||||||
@ -204,8 +205,8 @@ ldap groups context admin de LDAP Kontext f
|
|||||||
ldap host admin de LDAP Host
|
ldap host admin de LDAP Host
|
||||||
ldap root password admin de LDAP Root Passwort
|
ldap root password admin de LDAP Root Passwort
|
||||||
ldap rootdn admin de LDAP rootdn
|
ldap rootdn admin de LDAP rootdn
|
||||||
leave the category untouched and return back to the list admin de
|
leave the category untouched and return back to the list admin de Kategorie unverändert lassen und zur Liste zurückkehren
|
||||||
leave the group untouched and return back to the list admin de
|
leave the group untouched and return back to the list admin de Gruppe unverändert lassen und zur Liste zurückkehren
|
||||||
list config settings admin de Konfigurationseinstellungen auflisten
|
list config settings admin de Konfigurationseinstellungen auflisten
|
||||||
list current sessions admin de aktive Sitzungen anzeigen
|
list current sessions admin de aktive Sitzungen anzeigen
|
||||||
list of current users admin de Liste der gegenwärtigen Benutzer
|
list of current users admin de Liste der gegenwärtigen Benutzer
|
||||||
@ -259,7 +260,7 @@ read this list of methods. admin de Diese Liste der Methoden lesen
|
|||||||
register application hooks admin de Registrieren der "hooks" der Anwendungen
|
register application hooks admin de Registrieren der "hooks" der Anwendungen
|
||||||
remove all users from this group admin de Entferne alle Benutzer aus dieser Gruppe
|
remove all users from this group admin de Entferne alle Benutzer aus dieser Gruppe
|
||||||
remove all users from this group ? admin de Entferne alle Benutzer aus dieser Gruppe
|
remove all users from this group ? admin de Entferne alle Benutzer aus dieser Gruppe
|
||||||
return to admin mainscreen admin de
|
return to admin mainscreen admin de zum Adminstrationsmenü zurückkehren
|
||||||
return to view account admin de Zurück zum Anzeigen des Benutzerkontos
|
return to view account admin de Zurück zum Anzeigen des Benutzerkontos
|
||||||
run asynchronous services admin de Asynchrone Dienste ausführen
|
run asynchronous services admin de Asynchrone Dienste ausführen
|
||||||
save the category admin de Kategorie speichern
|
save the category admin de Kategorie speichern
|
||||||
@ -272,7 +273,7 @@ section admin de Abschnitt
|
|||||||
security admin de Sicherheit
|
security admin de Sicherheit
|
||||||
select group managers admin de Gruppenmanager auswählen
|
select group managers admin de Gruppenmanager auswählen
|
||||||
select permissions this group will have admin de Wählen Sie die Zugriffsrechte für diese Gruppe.
|
select permissions this group will have admin de Wählen Sie die Zugriffsrechte für diese Gruppe.
|
||||||
select the parent category. if this is a main category select no category admin de
|
select the parent category. if this is a main category select no category admin de Eine übergeordnete Kategorie auswählen. Wenn das eine Hauptkategorie ist, KEINE KATEGORIE auswählen.
|
||||||
select users for inclusion admin de Benutzer für diese Gruppe auswählen
|
select users for inclusion admin de Benutzer für diese Gruppe auswählen
|
||||||
select where you want to store/retrieve filesystem information admin de Wo wollen Sie Datei Informationen ablegen / lesen
|
select where you want to store/retrieve filesystem information admin de Wo wollen Sie Datei Informationen ablegen / lesen
|
||||||
select where you want to store/retrieve user accounts admin de Wo wollen Sie die Benutzerkonten speichern
|
select where you want to store/retrieve user accounts admin de Wo wollen Sie die Benutzerkonten speichern
|
||||||
@ -346,6 +347,7 @@ view this user admin de Diesen Benutzer anzeigen
|
|||||||
view user account admin de Benutzerkonto anzeigen
|
view user account admin de Benutzerkonto anzeigen
|
||||||
who would you like to transfer all records owned by the deleted user to? admin de Wem sollen alle Datensätze, die dem zu löschenden Benutzer gehören, übertragen werden?
|
who would you like to transfer all records owned by the deleted user to? admin de Wem sollen alle Datensätze, die dem zu löschenden Benutzer gehören, übertragen werden?
|
||||||
would you like phpgroupware to cache the phpgw info array ? admin de Soll phpGroupWare das phpgw info Array cachen ?
|
would you like phpgroupware to cache the phpgw info array ? admin de Soll phpGroupWare das phpgw info Array cachen ?
|
||||||
|
would you like phpgroupware to check for a new version<br>when admins login ? admin de Soll phpGroupWare prüfen ob eine neue Version vorhanden ist,<br> wenn sich der Administrator einlogt ?
|
||||||
would you like phpgroupware to check for new application versions when admins login ? admin de Soll phpGroupWare auf neue Programm-Versionen prüfen, wenn sich ein Administrator anmeldet ?
|
would you like phpgroupware to check for new application versions when admins login ? admin de Soll phpGroupWare auf neue Programm-Versionen prüfen, wenn sich ein Administrator anmeldet ?
|
||||||
would you like to automaticaly load new langfiles (at login-time) ? admin de Sollen neue Sprachdateien automatisch gelanden werden (beim Login) ?
|
would you like to automaticaly load new langfiles (at login-time) ? admin de Sollen neue Sprachdateien automatisch gelanden werden (beim Login) ?
|
||||||
would you like to show each application's upgrade status ? admin de Soll der Upgrade-Status aller Anwendungen angezeigt werden ?
|
would you like to show each application's upgrade status ? admin de Soll der Upgrade-Status aller Anwendungen angezeigt werden ?
|
||||||
@ -354,6 +356,7 @@ you have entered an invalid expiration date admin de Sie haben ein ung
|
|||||||
you must add at least 1 permission or group to this account admin de Sie müssen mindestens ein Zugriffsrecht oder eine Gruppe für diesen Benutzer angeben
|
you must add at least 1 permission or group to this account admin de Sie müssen mindestens ein Zugriffsrecht oder eine Gruppe für diesen Benutzer angeben
|
||||||
you must add at least 1 permission to this account admin de Sie müssen diesem Konto mindestens eine Berechtigung zuteilen
|
you must add at least 1 permission to this account admin de Sie müssen diesem Konto mindestens eine Berechtigung zuteilen
|
||||||
you must enter a group name. admin de Sie müssen einen Gruppennamen angeben.
|
you must enter a group name. admin de Sie müssen einen Gruppennamen angeben.
|
||||||
|
you must enter a lastname admin de Sie müssen einen Nachname angeben
|
||||||
you must enter a loginid admin de Sie müssen einen Benutzername angeben
|
you must enter a loginid admin de Sie müssen einen Benutzername angeben
|
||||||
you must enter an application name and title. admin de Sie müssen der Anwendung einen Namen und einen Titel geben.
|
you must enter an application name and title. admin de Sie müssen der Anwendung einen Namen und einen Titel geben.
|
||||||
you must enter an application name. admin de Sie müssen der Anwendung einen Namen geben.
|
you must enter an application name. admin de Sie müssen der Anwendung einen Namen geben.
|
||||||
|
@ -45,8 +45,8 @@ application admin en Application
|
|||||||
application name admin en Application name
|
application name admin en Application name
|
||||||
application title admin en Application title
|
application title admin en Application title
|
||||||
applications admin en Applications
|
applications admin en Applications
|
||||||
apply admin en apply
|
|
||||||
applications list admin en Applications list
|
applications list admin en Applications list
|
||||||
|
apply admin en apply
|
||||||
are you sure you want to delete the application %1 ? admin en Are you sure you want to delete the application %1 ?
|
are you sure you want to delete the application %1 ? admin en Are you sure you want to delete the application %1 ?
|
||||||
are you sure you want to delete this account ? admin en Are you sure you want to delete this account ?
|
are you sure you want to delete this account ? admin en Are you sure you want to delete this account ?
|
||||||
are you sure you want to delete this application ? admin en Are you sure you want to delete this application ?
|
are you sure you want to delete this application ? admin en Are you sure you want to delete this application ?
|
||||||
@ -65,11 +65,11 @@ back to the list admin en back to the list
|
|||||||
bi-dir passthrough admin en bi-dir passthrough
|
bi-dir passthrough admin en bi-dir passthrough
|
||||||
bi-directional admin en bi-directional
|
bi-directional admin en bi-directional
|
||||||
bottom admin en bottom
|
bottom admin en bottom
|
||||||
category %1 has been saved ! admin en Category %1 has been saved !
|
|
||||||
calculate next run admin en Calculate next run
|
calculate next run admin en Calculate next run
|
||||||
can change password admin en Can change password
|
can change password admin en Can change password
|
||||||
cancel testjob! admin en Cancel TestJob!
|
cancel testjob! admin en Cancel TestJob!
|
||||||
categories list admin en Categories list
|
categories list admin en Categories list
|
||||||
|
category %1 has been saved ! admin en Category %1 has been saved !
|
||||||
category list admin en Category list
|
category list admin en Category list
|
||||||
change acl rights admin en change ACL Rights
|
change acl rights admin en change ACL Rights
|
||||||
change config settings admin en Change config settings
|
change config settings admin en Change config settings
|
||||||
@ -85,17 +85,18 @@ day of week<br>(0-6, 0=sun) admin en Day of week<br>(0-6, 0=Sun)
|
|||||||
default admin en Default
|
default admin en Default
|
||||||
default file system space per user admin en Default file system space per user
|
default file system space per user admin en Default file system space per user
|
||||||
default file system space per user/group ? admin en Default file system space per user/group ?
|
default file system space per user/group ? admin en Default file system space per user/group ?
|
||||||
|
deinstall crontab admin en Deinstall crontab
|
||||||
delete account admin en Delete account
|
delete account admin en Delete account
|
||||||
delete all records admin en Delete All Records
|
delete all records admin en Delete All Records
|
||||||
|
delete application admin en Delete application
|
||||||
|
delete category admin en Delete category
|
||||||
|
delete group admin en Delete group
|
||||||
|
delete peer server admin en Delete peer server
|
||||||
delete the category admin en delete the category
|
delete the category admin en delete the category
|
||||||
delete the group admin en delete the group
|
delete the group admin en delete the group
|
||||||
delete this category admin en delete this category
|
delete this category admin en delete this category
|
||||||
delete this group admin en delete this group
|
delete this group admin en delete this group
|
||||||
delete this user admin en delete this user
|
delete this user admin en delete this user
|
||||||
delete application admin en Delete application
|
|
||||||
delete category admin en Delete category
|
|
||||||
delete group admin en Delete group
|
|
||||||
delete peer server admin en Delete peer server
|
|
||||||
deny access to access log admin en Deny access to access log
|
deny access to access log admin en Deny access to access log
|
||||||
deny access to application registery admin en Deny access to application registery
|
deny access to application registery admin en Deny access to application registery
|
||||||
deny access to applications admin en Deny access to applications
|
deny access to applications admin en Deny access to applications
|
||||||
@ -257,9 +258,9 @@ remove all users from this group admin en Remove all users from this group
|
|||||||
remove all users from this group ? admin en Remove all users from this group ?
|
remove all users from this group ? admin en Remove all users from this group ?
|
||||||
return to admin mainscreen admin en return to admin mainscreen
|
return to admin mainscreen admin en return to admin mainscreen
|
||||||
return to view account admin en Return to view account
|
return to view account admin en Return to view account
|
||||||
|
run asynchronous services admin en Run Asynchronous services
|
||||||
save the category admin en save the category
|
save the category admin en save the category
|
||||||
save the category and return back to the list admin en save the category and return back to the list
|
save the category and return back to the list admin en save the category and return back to the list
|
||||||
run asynchronous services admin en Run Asynchronous services
|
|
||||||
search accounts admin en Search accounts
|
search accounts admin en Search accounts
|
||||||
search categories admin en Search categories
|
search categories admin en Search categories
|
||||||
search groups admin en Search groups
|
search groups admin en Search groups
|
||||||
@ -290,6 +291,7 @@ site admin en Site
|
|||||||
site configuration admin en Site configuration
|
site configuration admin en Site configuration
|
||||||
soap admin en SOAP
|
soap admin en SOAP
|
||||||
sorry, that group name has already been taken. admin en Sorry, that group name has already been taken.
|
sorry, that group name has already been taken. admin en Sorry, that group name has already been taken.
|
||||||
|
sorry, the above users are still a member of the group %1 admin en Sorry, the above users are still a member of the group %1
|
||||||
sorry, the follow users are still a member of the group %1 admin en Sorry, the follow users are still a member of the group %1
|
sorry, the follow users are still a member of the group %1 admin en Sorry, the follow users are still a member of the group %1
|
||||||
sort the entries admin en sort the entries
|
sort the entries admin en sort the entries
|
||||||
ssl admin en ssl
|
ssl admin en ssl
|
||||||
@ -340,6 +342,7 @@ view this user admin en view this user
|
|||||||
view user account admin en View user account
|
view user account admin en View user account
|
||||||
who would you like to transfer all records owned by the deleted user to? admin en Who would you like to transfer ALL records owned by the deleted user to?
|
who would you like to transfer all records owned by the deleted user to? admin en Who would you like to transfer ALL records owned by the deleted user to?
|
||||||
would you like phpgroupware to cache the phpgw info array ? admin en Would you like phpGroupWare to cache the phpgw info array ?
|
would you like phpgroupware to cache the phpgw info array ? admin en Would you like phpGroupWare to cache the phpgw info array ?
|
||||||
|
would you like phpgroupware to check for a new version<br>when admins login ? admin en Would you like phpGroupWare to check for a new version<br>when admins login ?
|
||||||
would you like phpgroupware to check for new application versions when admins login ? admin en Would you like phpGroupWare to check for new application versions when admins login ?
|
would you like phpgroupware to check for new application versions when admins login ? admin en Would you like phpGroupWare to check for new application versions when admins login ?
|
||||||
would you like to automaticaly load new langfiles (at login-time) ? admin en Would you like to automaticaly load new langfiles (at login-time) ?
|
would you like to automaticaly load new langfiles (at login-time) ? admin en Would you like to automaticaly load new langfiles (at login-time) ?
|
||||||
would you like to show each application's upgrade status ? admin en Would you like to show each application's upgrade status ?
|
would you like to show each application's upgrade status ? admin en Would you like to show each application's upgrade status ?
|
||||||
@ -347,6 +350,7 @@ xml-rpc admin en XML-RPC
|
|||||||
you have entered an invalid expiration date admin en You have entered an invalid expiration date
|
you have entered an invalid expiration date admin en You have entered an invalid expiration date
|
||||||
you must add at least 1 permission or group to this account admin en You must add at least 1 permission or group to this account
|
you must add at least 1 permission or group to this account admin en You must add at least 1 permission or group to this account
|
||||||
you must enter a group name. admin en You must enter a group name.
|
you must enter a group name. admin en You must enter a group name.
|
||||||
|
you must enter a lastname admin en You must enter a lastname
|
||||||
you must enter a loginid admin en You must enter a loginid
|
you must enter a loginid admin en You must enter a loginid
|
||||||
you must enter an application name and title. admin en You must enter an application name and title.
|
you must enter an application name and title. admin en You must enter an application name and title.
|
||||||
you must enter an application name. admin en You must enter an application name.
|
you must enter an application name. admin en You must enter an application name.
|
||||||
|
@ -644,18 +644,26 @@
|
|||||||
@function insall
|
@function insall
|
||||||
@abstract installs /phpgwapi/cron/asyncservices.php as cron-job
|
@abstract installs /phpgwapi/cron/asyncservices.php as cron-job
|
||||||
@syntax install($times)
|
@syntax install($times)
|
||||||
@param $times array with keys 'min','hour','day','month','dow', not set is equal to '*'
|
@param $times array with keys 'min','hour','day','month','dow', not set is equal to '*'.
|
||||||
@result the times asyncservices are run or False if they are not installed or 0 if crontab not found
|
False means de-install our own crontab line
|
||||||
|
@result the times asyncservices are run, False if they are not installed,
|
||||||
|
0 if crontab not found and ' ' if crontab is deinstalled
|
||||||
@note Not implemented for Windows at the moment, always returns 0
|
@note Not implemented for Windows at the moment, always returns 0
|
||||||
*/
|
*/
|
||||||
function install($times)
|
function install($times)
|
||||||
{
|
{
|
||||||
if ($this->only_fallback) {
|
if ($this->only_fallback && $times !== False) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
$this->installed(); // find other installed cronlines
|
$this->installed(); // find other installed cronlines
|
||||||
|
|
||||||
if (($crontab = popen('/bin/sh -c "'.$this->crontab.' -" 2>&1','w')) !== False)
|
if (($crontab = popen('/bin/sh -c "'.$this->crontab.' -" 2>&1','w')) !== False)
|
||||||
|
{
|
||||||
|
foreach ($this->other_cronlines as $cronline)
|
||||||
|
{
|
||||||
|
fwrite($crontab,$cronline); // preserv the other lines
|
||||||
|
}
|
||||||
|
if ($times !== False)
|
||||||
{
|
{
|
||||||
$cron_units = array('min','hour','day','month','dow');
|
$cron_units = array('min','hour','day','month','dow');
|
||||||
foreach($cron_units as $cu)
|
foreach($cron_units as $cu)
|
||||||
@ -665,13 +673,9 @@
|
|||||||
$cronline .= $this->php.' -q '.$this->cronline."\n";
|
$cronline .= $this->php.' -q '.$this->cronline."\n";
|
||||||
//echo "<p>Installing: '$cronline'</p>\n";
|
//echo "<p>Installing: '$cronline'</p>\n";
|
||||||
fwrite($crontab,$cronline);
|
fwrite($crontab,$cronline);
|
||||||
|
|
||||||
foreach ($this->other_cronlines as $cronline)
|
|
||||||
{
|
|
||||||
fwrite($crontab,$cronline); // preserv the other lines
|
|
||||||
}
|
}
|
||||||
@pclose($crontab);
|
@pclose($crontab);
|
||||||
}
|
}
|
||||||
return $this->installed();
|
return $times !== False ? $this->installed() : ' ';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user