AfterTreeFixture.php 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <?php
  2. /**
  3. * Short description for after_tree_fixture.php
  4. *
  5. * Long description for after_tree_fixture.php
  6. *
  7. * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
  8. *
  9. * Licensed under The MIT License
  10. * For full copyright and license information, please see the LICENSE.txt
  11. * Redistributions of files must retain the above copyright notice.
  12. *
  13. * @copyright Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
  14. * @link http://www.cakephp.org
  15. * @since 1.2
  16. * @license http://www.opensource.org/licenses/mit-license.php MIT License
  17. */
  18. namespace Cake\Test\Fixture;
  19. use Cake\TestSuite\Fixture\TestFixture;
  20. /**
  21. * AdFixture class
  22. *
  23. */
  24. class AfterTreeFixture extends TestFixture {
  25. /**
  26. * fields property
  27. *
  28. * @var array
  29. */
  30. public $fields = array(
  31. 'id' => ['type' => 'integer'],
  32. 'parent_id' => ['type' => 'integer'],
  33. 'lft' => ['type' => 'integer'],
  34. 'rght' => ['type' => 'integer'],
  35. 'name' => ['type' => 'string', 'length' => 255, 'null' => false],
  36. '_constraints' => ['primary' => ['type' => 'primary', 'columns' => ['id']]]
  37. );
  38. /**
  39. * records property
  40. *
  41. * @var array
  42. */
  43. public $records = array(
  44. array('parent_id' => null, 'lft' => 1, 'rght' => 2, 'name' => 'One'),
  45. array('parent_id' => null, 'lft' => 3, 'rght' => 4, 'name' => 'Two'),
  46. array('parent_id' => null, 'lft' => 5, 'rght' => 6, 'name' => 'Three'),
  47. array('parent_id' => null, 'lft' => 7, 'rght' => 12, 'name' => 'Four'),
  48. array('parent_id' => null, 'lft' => 8, 'rght' => 9, 'name' => 'Five'),
  49. array('parent_id' => null, 'lft' => 10, 'rght' => 11, 'name' => 'Six'),
  50. array('parent_id' => null, 'lft' => 13, 'rght' => 14, 'name' => 'Seven')
  51. );
  52. }