EIOS/rabprog/cron.php

44 lines
1.3 KiB
PHP
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
session_start();
include_once 'config.php';
$step = ''; if (isset($_GET['step'])) $step = $_GET['step'];
if (isset($argv[1])) $step = $argv[1];
if (isset($argv[2])) $des = $argv[2];
if (isset($argv[3])) $id = $argv[3];
if($step=='UchebPlans_Works'){//Обход файлов xls и обработка данных в них
$cClass = new class_ShahtPlans();
$cClass->plans_get();
}
if($step=='RPD_calculate'){//Подсчет данных в РПД
$data['tip'] = 'prorektor';
$data['cron'] = 1;
$class = new class_StatPUR($data);
$class->get_facultets();
}
if($step=='RPD_signs'){//Подпись РПД больших
$smartyC = new class_smarty();
$smarty = $smartyC->config(__DIR__.'\tpl');
$_POST['ajdes'] = 'RPDSign';
$_POST['id_disc'] = 23867;
$_POST['sign'] = 1;
$_POST['descr'] = '';
$_POST['kafvyp'] = 0;
$_SESSION['user']['statuses'][79]=1;
$class = new class_RPDSign();
$rez = $class->RPD_sign_DES($_POST);
print_r(json_decode($rez,1));
}
//Обработка подписей РПД от УР
/*
$_SESSION['user']['id'] = 565;
include_once 'inc/class_smarty.php';
$smartyC = new class_smarty();
$smarty = $smartyC->config(__DIR__.'\tpl');
$smarty->assign('TPL','/rabprog');
include_once 'inc/class_RPDSign.php';
$classRPD = new class_RPDSign();
$classRPD->rpdsign_auto(3);*/