Exemplo n.º 1
0
}
while ($row = $results->fetchRow()) {
    $settingArr[$row['name']] = $row['value'];
}
// all fields collected now remove the standard fields except name
unset($fieldArr['id']);
unset($fieldArr['zoek']);
unset($fieldArr['updated']);
unset($query);
if ($debug) {
    Gsm_debug($regelsArr, __LINE__);
    Gsm_debug($settingArr, __LINE__);
    Gsm_debug($_POST, __LINE__);
    Gsm_debug($_GET, __LINE__);
    Gsm_debug($place, __LINE__);
    Gsm_debug($fieldArr, __LINE__);
}
/*
 * some job to do ?
 */
if (isset($_POST['command'])) {
    switch ($_POST['command']) {
        case $MOD_GSMOFF['tbl_icon'][1]:
            // change
            $regelsArr['recid'] = $_POST['recid'];
            $query = "SELECT * FROM `" . $regelsArr['table'] . "`WHERE `id`='" . $regelsArr['recid'] . "'";
            $regelsArr['mode'] = 7;
            break;
        case $MOD_GSMOFF['tbl_icon'][3]:
            //add
            $regelsArr['qty'] = 3;
Exemplo n.º 2
0
 * $icontemp [0-19]
 * $linetemp [0-19]
 */
$MOD_GSMOFF['VERS'] = ' no functionality';
/*
 * debug used data
 */
if ($debug) {
    Gsm_debug($regelsArr, __LINE__);
    Gsm_debug($settingArr, __LINE__);
    Gsm_debug($_POST, __LINE__);
    Gsm_debug($_GET, __LINE__);
    Gsm_debug($place, __LINE__);
}
/*
 * the output to the screen
 */
$regelsArr['hash'] = sha1(MICROTIME() . $_SERVER['HTTP_USER_AGENT']);
$_SESSION['page_h'] = $regelsArr['hash'];
if ($debug) {
    Gsm_debug($regelsArr, __LINE__);
}
switch ($regelsArr['mode']) {
    default:
        $parseViewArray = array('header' => "", 'message' => message($msg, $debug), 'return' => CH_LOGIN, 'module' => $regelsArr['module'], 'page_id' => $page_id, 'section_id' => $section_id, 'hash' => $regelsArr['hash'], 'recid' => "", 'memory' => "", 'kopregels' => "", 'description' => "", 'selection' => "", 'rapportage' => "", 'toegift' => "");
        $prout .= Gsm_prout($TEMPLATE[2], $parseViewArray);
        break;
}
if (strstr($set_mode, "vers")) {
    $prout .= "<small>" . $regelsArr['modulen'] . $regelsArr['versie'] . $MOD_GSMOFF['VERS'] . "</small>";
}
Exemplo n.º 3
0
            }
            $regelsArr['toegift'] = Gsm_trans_report($regelsArr, $calcArr, $MOD_GSMOFF, $func = 1);
            if (isset($regelsArr['owner_email']) && strlen($regelsArr['owner_email']) > 12 && $regelsArr['mode'] == 8) {
                /*
                 *  PDF file condities zijn er
                 */
                // load include with specific layout
                require_once $place_incl . 'vtransitie_pdf.inc';
                $mailArr = array('from' => $regelsArr['email'], 'to' => $regelsArr['owner_email'], 'cc' => $regelsArr['info_mail'], 'volgnummer' => $regelsArr['memored_recid'], 'dossier' => $regelsArr['tvref0'], 'subject' => $regelsArr['tvref0'] . ' / ' . $regelsArr['memored_recid'], 'link' => LEPTON_URL . PAGES_DIRECTORY . '/transitie.php?section_id=' . $section_id . '&command=acc&ref=' . $regelsArr['memored_recid'] . substr(md5($regelsArr['memored_recid']), 0, 5), 'fromname' => "Contracthulp", 'toname' => $regelsArr['owner_email'], 'place' => $regelsArr['file0'] . '/' . $regelsArr['file1'] . '/', 'filename' => $regelsArr['memored_recid'] . '_berekening_' . $regelsArr['tvcalcdate'] . '.pdf', 'url' => LEPTON_URL . "/");
                if ($debug) {
                    Gsm_debug($calcArr, __LINE__);
                }
                $mailArr['file'] = Gsm_out($calcArr, $MOD_GSMOFF, 98, $mailArr['place'], $mailArr['filename'], '');
                //create pdf file
                if ($debug) {
                    Gsm_debug($mailArr, __LINE__);
                }
                $mailArr['body'] = Gsm_prout($MOD_GSMOFF['trans_mail1'], $mailArr);
                // format the message
                $mailArr['body2'] = Gsm_prout($MOD_GSMOFF['trans_mail2'], $mailArr);
                // format the message
                if ($wb->mail($mailArr['from'], $mailArr['to'], $mailArr['subject'], $mailArr['body'], $mailArr['fromname'])) {
                    $regelsArr['toegift'] .= $mailArr['body2'];
                }
                $mailArr['bodyc'] = Gsm_prout($MOD_GSMOFF['trans_mail1c'], $mailArr);
                // format the message
                $help = $wb->mail($mailArr['from'], $mailArr['cc'], $mailArr['subject'], $mailArr['bodyc'], $mailArr['fromname']);
            }
        }
        break;
}
Exemplo n.º 4
0
if (!$results || $results && $results->numRows() == 0) {
    $descr_kop .= $MOD_GSMOFF['TXT_ERROR_DATABASE'];
} else {
    $i = 0;
    while ($row = $results->fetchRow()) {
        if ($debug) {
            Gsm_debug($row, __LINE__);
        }
        /******************
         * Check table
         */
        $query2 = "CHECK TABLE `" . $row[0] . "`";
        $result2 = $database->query($query2);
        $row2 = $result2->fetchRow();
        if ($debug) {
            Gsm_debug($row2, __LINE__);
        }
        $regelsArr['descr'] .= sprintf($LINETEMP[2], $i % 2 == 0 ? '' : $MOD_GSMOFF['line_color']['2'], $row[0], $row2[1] . " " . $row2[2] . " : " . $row2[3]);
        $regelsArr['descr'] .= sprintf($LINETEMP[2], $i % 2 == 0 ? '' : $MOD_GSMOFF['line_color']['2'], "", "Engine : " . $row['Engine'] . ", Rows : " . $row['Rows']);
        $files = scandir(substr($place['backup2'], 0, -1), 1);
        $help = "-- backup files";
        $r = 0;
        foreach ($files as $key) {
            if ($key != "." && $key != "..") {
                if (substr($key, 0, -21) == $row[0]) {
                    if ($r > 2) {
                        unlink($place['backup2'] . $key);
                    } else {
                        if (strstr($key, "_bck")) {
                            $regelsArr['descr'] .= sprintf($LINETEMP[2], $i % 2 == 0 ? '' : $MOD_GSMOFF['line_color']['2'], $help, "existing");
                        } else {
Exemplo n.º 5
0
    $set_menu['tdummy'] = " none";
}
foreach ($set_menu as $key => $value) {
    if (isset($MOD_GSMOFF['menu'][$key])) {
        $set_menu[$key] = $MOD_GSMOFF['menu'][$key];
    }
}
/*
 * debug
 */
if ($debug) {
    echo Gsm_post(1);
    echo Gsm_post(2);
    echo Gsm_post(4);
    Gsm_debug($settingArr, __LINE__, 2);
    Gsm_debug($set_menu, __LINE__, 2);
}
/*
 * Layout template
 */
$TEMPLATE[0] = '
	<div class="container">
	<form name="menu" method="post" action="{return}">
	<table>
		<colgroup><col width="15%"><col width="25%"><col width="20%"><col width="20%"><col width="20%"></colgroup>
		<tr><td>' . $MOD_GSMOFF['module'] . '</td>
		<td><SELECT name="module" >{module}</SELECT></td>
		<td><input type="text" name="selection" value="{parameter}" placeholder="Parameter" /></td>
		<td><input class="modules" type="submit" value="' . $MOD_GSMOFF['go'] . '" /></td>
		<td>{add_needed}</td></tr>
	</table>
Exemplo n.º 6
0
         $msg['bug'] .= __LINE__ . ' access <br/>';
     }
     unset($query);
     $regelsArr['mode'] = 9;
     break;
 case $MOD_GSMOFF['tbl_icon'][4]:
     //opslaan
     if ($debug) {
         $msg['bug'] .= __LINE__ . ' access <br/>';
     }
     $hulpArr = array();
     foreach ($fieldArr as $key => $value) {
         $hulpArr[$key] = $regelsArr['x' . $key];
     }
     if ($debug) {
         Gsm_debug($hulpArr, __LINE__);
     }
     $query = "UPDATE `" . $regelsArr['standen'] . "` SET " . Gsm_parse(2, $hulpArr) . "  WHERE `id` = '" . $regelsArr['recid'] . "'";
     $msg['inf'] .= ' entry updated<br/>';
     if ($debug) {
         $msg['bug'] .= __LINE__ . ' ' . $query . ' <br/>';
     }
     $results = $database->query($query);
     unset($query);
     $regelsArr['mode'] = 9;
     break;
 case $MOD_GSMOFF['tbl_icon'][11]:
     //print
     if ($debug) {
         $msg['bug'] .= __LINE__ . ' access <br/>';
     }
Exemplo n.º 7
0
$projectArray['    '] = '';
$projectArray = func_table_preload($regelsArr['table_proj'], 3, $projectArray);
// preload data
$settingArr = array_merge($settingArr, func_table_preload($regelsArr['file'], 9, $page_id));
// Pick up settings
/*
 * debug
 */
if ($debug) {
    Gsm_debug($settingArr, __LINE__);
    Gsm_debug($regelsArr, __LINE__);
    Gsm_debug($_POST, __LINE__);
    Gsm_debug($_GET, __LINE__);
    Gsm_debug($place, __LINE__);
    Gsm_debug($rekeningArray, __LINE__);
    Gsm_debug($projectArray, __LINE__);
}
//$debug
/*
 * some job to do ?
 */
if (isset($_POST['command'])) {
    switch ($_POST['command']) {
        case $MOD_GSMOFF['tbl_icon'][2]:
            // terug
            $regelsArr['mode'] = 9;
            break;
        case $MOD_GSMOFF['tbl_icon'][4]:
            $regelsArr['save_update'] = true;
        case $MOD_GSMOFF['tbl_icon'][5]:
            /*
Exemplo n.º 8
0
} else {
    $regelsArr['detail'] = true;
    $regelsArr['setting'] = true;
}
/*
 * debug
 */
if ($debug) {
    Gsm_debug($settingArr, __LINE__);
    Gsm_debug($regelsArr, __LINE__);
    Gsm_debug($_POST, __LINE__);
    Gsm_debug($_GET, __LINE__);
    Gsm_debug($place, __LINE__);
    Gsm_debug($rekeningArray, __LINE__);
    Gsm_debug($projectArray, __LINE__);
    Gsm_debug($bookingArray, __LINE__);
}
//$debug
/*
 * bookingtype menu
 */
$menu = "Boeking type:<br/>";
foreach ($bookingArray as $key => $value) {
    $menu .= '&nbsp;<input class="settings" name="setting" type="submit" value="' . $key . '" />' . CH_CR;
}
$parseViewArray = array('return' => CH_RETURN, 'module' => $regelsArr['module'], 'menu' => $menu);
$print .= $TEMPLATE[3];
foreach ($parseViewArray as $key => $value) {
    $print = str_replace("{" . $key . "}", $value, $print);
}
unset($query);
Exemplo n.º 9
0
$regelsArr['period_begin'] = isset($_POST['select_van']) ? $regelsArr['period_begin'] = $_POST['select_van'] : date("Y", strtotime($regelsArr['period_start'])) . "-01-01";
$regelsArr['period_end'] = isset($_POST['select_tot']) ? $regelsArr['period_end'] = $_POST['select_tot'] : date("Y", strtotime($regelsArr['period_begin'])) . "-12-31";
unset($query);
/*
 * debug
 */
if ($debug) {
    Gsm_debug($settingArr, __LINE__);
    Gsm_debug($regelsArr, __LINE__);
    Gsm_debug($_POST, __LINE__);
    Gsm_debug($_GET, __LINE__);
    Gsm_debug($place, __LINE__);
    Gsm_debug($budgetArray, __LINE__);
    Gsm_debug($offsetArray, __LINE__);
    Gsm_debug($rekeningArray, __LINE__);
    Gsm_debug($rekeningtypeArray, __LINE__);
}
//$debug
/*
 * some job to do
 */
if (isset($_POST['command'])) {
    switch ($_POST['command']) {
        case $MOD_GSMOFF['SUR_VENW']:
            $regelsArr['Document'] = $MOD_GSMOFF['SUR_VENW'];
            $regelsArr['Vanaf'] = $_POST['select_van'];
            $regelsArr['Totenmet'] = $_POST['select_tot'];
            $regelsArr['show1_type'] = '4';
            $regelsArr['show2_type'] = '5';
            if (isset($_POST['details']) && $_POST['details'] == 'yes') {
                $regelsArr['details'] = true;