示例#1
0
文件: config.php 项目: solire/trieur
 public static function run()
 {
     $configPath = 'config/client.yml';
     $array = Yaml::parse($configPath);
     $conf = Loader::load($array);
     $trieur = new Trieur($conf);
     self::$jsConfig = $trieur->getDriver()->getJsConfig();
     self::$jsColumnFilterConfig = $trieur->getDriver()->getColumnFilterConfig();
 }
示例#2
0
文件: data.php 项目: solire/trieur
 public static function run()
 {
     $configPath = 'config/client.yml';
     $array = Yaml::parse($configPath);
     $conf = Loader::load($array);
     $trieur = new Trieur($conf, 'data/clients.csv');
     $trieur->setRequest($_POST);
     $response = $trieur->getResponse();
     return $response;
 }
示例#3
0
文件: data.php 项目: solire/trieur
 public static function run()
 {
     $configPath = 'config/client.yml';
     $array = Yaml::parse($configPath);
     $conf = Loader::load($array);
     $configDbPath = 'config/connection.ini';
     $configDb = parse_ini_file($configDbPath);
     $configDb['driverOptions'] = [PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8'];
     $doctrineConnection = DriverManager::getConnection($configDb);
     $trieur = new Trieur($conf, $doctrineConnection);
     $response = $trieur->getResponse();
     return $response;
 }