1. Import
This commit is contained in:
57
html/tools/cron_export.php
Normal file
57
html/tools/cron_export.php
Normal file
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
/*=======================================================================
|
||||
*
|
||||
* cron_export.php
|
||||
*
|
||||
=======================================================================*/
|
||||
|
||||
|
||||
include_once ("../include/mcglobal.inc.php");
|
||||
|
||||
if ($argv[1] == "acapella7890") :
|
||||
|
||||
$path = getAbsoluteSystemPath();
|
||||
$passwd = "acapella7890";
|
||||
$emptyArgument = "\"\"";
|
||||
$fileNamePrefix = substr(getDateTime("6"), 0, 12); // eq. "YmdHi"
|
||||
$dayYesterday = getDateTime("day_yesterday");
|
||||
$monthYesterday = getDateTime("month_yesterday");
|
||||
$yearYesterday = getDateTime("year_yesterday");
|
||||
|
||||
// Arguments
|
||||
// $hq_id $usr_id $dummy_01 $f_act $f_exp_category $f_delimiter $f_parname $f_parname_export $f_fileName $day_to $month_to $year_to $f_cs_eid_filter $f_jbp_filter $specialJbPayment $jbpc_id
|
||||
|
||||
$exportPars = array();
|
||||
$exportPars["HTM_HTHH_ABR"] = array("1020","18086","_","export","5","|","RETRANS Abrechnungen","RETRANS Abrechnungen",$fileNamePrefix . ".101.abr",$dayYesterday,$monthYesterday,$yearYesterday,$emptyArgument,$emptyArgument,"4",$emptyArgument);
|
||||
|
||||
/*
|
||||
$exportParsKeys = array_keys($exportPars);
|
||||
$exportParsKeysLen = count($exportParsKeys);
|
||||
for ($i = 0; $i < $maskDisplayedArrayLen; $i++) :
|
||||
|
||||
list($hq_id,$usr_id,$dummy_01,$f_act,$f_exp_category,$f_delimiter,$f_parname,$f_parname_export,$f_fileName,
|
||||
$day_to,$month_to,$year_to,$f_cs_eid_filter,$f_jbp_filter,$specialJbPayment,$jbpc_id) = $exportPars[$exportParsKeys[$i]];
|
||||
|
||||
$cmd = "php " . $path . "/export/export.php " . $passwd . " " . $hq_id . " " . $usr_id . " " . $dummy_01 . " " . $f_act . " " . $aaaa . " " . $aaaa . " " . $aaaa . " " . $aaaa . " &";
|
||||
$cmdOutput = null;
|
||||
exec($cmd, $cmdOutput);
|
||||
|
||||
// list($errNo, $errDesc) = $cmdOutput;
|
||||
endfor;
|
||||
*/
|
||||
|
||||
|
||||
// TEST
|
||||
|
||||
list($hq_id,$usr_id,$dummy_01,$f_act,$f_exp_category,$f_delimiter,$f_parname,$f_parname_export,$f_fileName,
|
||||
$day_to,$month_to,$year_to,$f_cs_eid_filter,$f_jbp_filter,$specialJbPayment,$jbpc_id) = $exportPars["HTM_HTHH_ABR"];
|
||||
|
||||
$cmd = "php " . $path . "/export/export.php " . $passwd . " " . $hq_id . " " . $usr_id . " " . $dummy_01 . " " . $f_act . " " . $f_exp_category . " " . "\"" . $f_delimiter. "\"" . " "
|
||||
. "\"" . $f_parname . "\"" . " " . "\"" . $f_parname_export . "\"" . " " . "\"" . $f_fileName . "\"" . " " . $day_to . " " . $month_to . " " . $year_to . " "
|
||||
. $f_cs_eid_filter . " " . $f_jbp_filter . " " . $specialJbPayment . " " . $jbpc_id . " &";
|
||||
echo $cmd . "\n";
|
||||
$cmdOutput = null;
|
||||
exec($cmd, $cmdOutput);
|
||||
|
||||
endif;
|
||||
?>
|
||||
Reference in New Issue
Block a user