writeproject.php 758 B

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. session_start();
  3. if (!$_SESSION['pass'] && !$_SESSION['login'])
  4. return;
  5. use Doctrine\Common\Collections\ArrayCollection;
  6. use Doctrine\Common\Collections\Collection;
  7. use Doctrine\Common\Collections\Criteria;
  8. require_once "doctrine/bootstrap.php";
  9. require_once "functions.php";
  10. //require_once "server.php";
  11. require_once "auth.php";
  12. require_once 'CheckPoint.php';
  13. require_once 'CheckPointType.php';
  14. use \CheckPoints\CheckPoint;
  15. require_once 'api/vendor/autoload.php';
  16. require_once 'api/vendor/yiisoft/yii2/Yii.php';
  17. $config = require_once 'api/config/web.php';
  18. (new yii\web\Application($config));
  19. /**
  20. * @var $proj Project
  21. *
  22. */
  23. $id = $_REQUEST['id'];
  24. $proj = Project::Find($id);
  25. $proj->checkPointsWrite();