cron last_visit for mods, system.js proto, text tag definitions
This commit is contained in:
parent
f179eef5e9
commit
973038d2bc
@ -49,6 +49,20 @@ class cron {
|
|||||||
$cron[\SYSTEM\SQL\system_cron::FIELD_MONTH]);
|
$cron[\SYSTEM\SQL\system_cron::FIELD_MONTH]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static function last($class){
|
||||||
|
$cron = \SYSTEM\SQL\SYS_CRON_GET::Q1(array($class));
|
||||||
|
//check module
|
||||||
|
if(!self::check($cron[\SYSTEM\SQL\system_cron::FIELD_CLASS])){
|
||||||
|
throw new \SYSTEM\LOG\ERROR("Given class is not a cronjob");}
|
||||||
|
//time
|
||||||
|
return \SYSTEM\CRON\crontime::last( strtotime($cron[\SYSTEM\SQL\system_cron::FIELD_LAST_RUN]),
|
||||||
|
$cron[\SYSTEM\SQL\system_cron::FIELD_MIN],
|
||||||
|
$cron[\SYSTEM\SQL\system_cron::FIELD_HOUR],
|
||||||
|
$cron[\SYSTEM\SQL\system_cron::FIELD_DAY],
|
||||||
|
$cron[\SYSTEM\SQL\system_cron::FIELD_DAY_WEEK],
|
||||||
|
$cron[\SYSTEM\SQL\system_cron::FIELD_MONTH]);
|
||||||
|
}
|
||||||
|
|
||||||
private static function status($class, $status){
|
private static function status($class, $status){
|
||||||
//new \SYSTEM\LOG\CRON('Cron Status for Class '.$class.' updated to: '. \SYSTEM\CRON\cronstatus::text($status));
|
//new \SYSTEM\LOG\CRON('Cron Status for Class '.$class.' updated to: '. \SYSTEM\CRON\cronstatus::text($status));
|
||||||
return \SYSTEM\SQL\SYS_CRON_UPD::QI(array($status,time(),$class));}
|
return \SYSTEM\SQL\SYS_CRON_UPD::QI(array($status,time(),$class));}
|
||||||
|
|||||||
@ -1,3 +1,29 @@
|
|||||||
|
/*var SYSTEM = ( function( window, undefined ) {
|
||||||
|
var instance = null;
|
||||||
|
// revealing module pattern that handles initialization of our new module
|
||||||
|
function init() {
|
||||||
|
|
||||||
|
function back(){
|
||||||
|
window.history.back();};
|
||||||
|
function forward(){
|
||||||
|
window.history.forward();};
|
||||||
|
function reload(){
|
||||||
|
SYSTEM.go_state(SYSTEM.cur_state(),true);
|
||||||
|
};
|
||||||
|
|
||||||
|
return {
|
||||||
|
back : back,
|
||||||
|
forward : forward
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
if( ! instance ) {
|
||||||
|
instance = new init();
|
||||||
|
}
|
||||||
|
return instance;
|
||||||
|
|
||||||
|
} )( window );*/
|
||||||
|
|
||||||
var system = null;
|
var system = null;
|
||||||
|
|
||||||
//mother object
|
//mother object
|
||||||
|
|||||||
@ -13,7 +13,7 @@ class saimod_sys_cron extends \SYSTEM\SAI\SaiModule {
|
|||||||
$r['selected_'.$r['status']] = 'selected';
|
$r['selected_'.$r['status']] = 'selected';
|
||||||
$r['i'] = $i++;
|
$r['i'] = $i++;
|
||||||
$vars['content'] .= \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_cron/tpl/list_entry.tpl'), $r);}
|
$vars['content'] .= \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_cron/tpl/list_entry.tpl'), $r);}
|
||||||
$vars = array_merge($vars, \SYSTEM\PAGE\text::tag(\SYSTEM\SQL\system_text::TAG_SAI_CRON));
|
$vars = array_merge($vars, \SYSTEM\PAGE\text::tag(\SYSTEM\SQL\system_text::TAG_SAI_CRON));
|
||||||
return \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_cron/tpl/tabs.tpl'), $vars);
|
return \SYSTEM\PAGE\replace::replaceFile(\SYSTEM\SERVERPATH(new \SYSTEM\PSAI(),'modules/saimod_sys_cron/tpl/tabs.tpl'), $vars);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -3,13 +3,16 @@
|
|||||||
namespace SYSTEM\SQL;
|
namespace SYSTEM\SQL;
|
||||||
|
|
||||||
class system_text {
|
class system_text {
|
||||||
const NAME_PG = 'system.text';
|
const NAME_PG = 'system.text';
|
||||||
const NAME_MYS = 'system_text';
|
const NAME_MYS = 'system_text';
|
||||||
|
|
||||||
const FIELD_ID = 'id';
|
const FIELD_ID = 'id';
|
||||||
const FIELD_TEXT = 'text';
|
const FIELD_TEXT = 'text';
|
||||||
|
|
||||||
const TAG_BASIC = 'basic';
|
const TAG_BASIC = 'basic';
|
||||||
|
const TAG_TIME = 'time';
|
||||||
|
const TAG_TABLE = 'table';
|
||||||
|
|
||||||
const TAG_SAI = 'sai';
|
const TAG_SAI = 'sai';
|
||||||
const TAG_SAI_DEFAULT = 'sai_default';
|
const TAG_SAI_DEFAULT = 'sai_default';
|
||||||
const TAG_SAI_START = 'sai_start';
|
const TAG_SAI_START = 'sai_start';
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user