diff options
author | Kirylka <kirylanoshko@gmail.com> | 2015-03-31 17:56:47 +0300 |
---|---|---|
committer | Kirylka <kirylanoshko@gmail.com> | 2015-03-31 17:56:47 +0300 |
commit | f5f99c335707d9b11d40f1eb0f6ddb5a993fd31a (patch) | |
tree | d9c0d3532ec9f0f2fb68e31d2611282ae0642181 /samples/tree/01p_basic_connector.php | |
parent | 458f0aead573842f1df00ce2ae00334c27f66585 (diff) | |
download | connector-php-f5f99c335707d9b11d40f1eb0f6ddb5a993fd31a.zip connector-php-f5f99c335707d9b11d40f1eb0f6ddb5a993fd31a.tar.gz connector-php-f5f99c335707d9b11d40f1eb0f6ddb5a993fd31a.tar.bz2 |
Creating a new connector for yii2.
Diffstat (limited to 'samples/tree/01p_basic_connector.php')
-rw-r--r-- | samples/tree/01p_basic_connector.php | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/samples/tree/01p_basic_connector.php b/samples/tree/01p_basic_connector.php deleted file mode 100644 index 9179ab3..0000000 --- a/samples/tree/01p_basic_connector.php +++ /dev/null @@ -1,20 +0,0 @@ -<?php - require_once("../config.php"); - require_once('../../codebase/db_pdo.php'); - $res= new PDO($mysql_server,$mysql_user,$mysql_pass); - - -function child_setter($data){ - //the check is kind of lame, in real table you most probably may have some more stable way to detect is item have childs or not - if ($data->get_value("taskId")%100>1) - $data->set_kids(false); - else - $data->set_kids(true); -} - - require("../../codebase/tree_connector.php"); - $tree = new TreeConnector($res, "PDO"); -// - $tree->event->attach("beforeRender","child_setter"); - $tree->render_table("tasks","taskId","taskName","","parentId"); -?>
\ No newline at end of file |