CounterpartSeeder.php 1.64 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?php

use Phinx\Seed\AbstractSeed;

class CounterpartSeeder extends AbstractSeed
{
    /**
     * Run Method.
     *
     * Write your database seeder using this method.
     *
     * More information on writing seeders is available here:
     * http://docs.phinx.org/en/latest/seeding.html
     */
    public function run()
    {
        $data = array(
            array(
                'id' => 1,
                'datec' => '2016-06-22 12:34',
                'user_id' => 1,
                'quoi' => 'pishirt', // [piplome|pibag|pishirt|hoodie]
                'taille' => 8,
                'status' => 1,
                'adresse_id' => 1,
            ),
            array(
                'id' => 2,
                'datec' => '2016-06-22 12:34',
                'user_id' => 2,
                'quoi' => 'piplome', // [piplome|pibag|pishirt|hoodie]
32
                'taille' => 2,
33
                'status' => 2,
34
35
                'adresse_id' => null,
            ),
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
            array(
                'id' => 3,
                'datec' => '2016-06-22 12:34',
                'user_id' => 2,
                'quoi' => 'pibag', // [piplome|pibag|pishirt|hoodie]
                'taille' => 2,
                'status' => 2,
                'adresse_id' => null,
            ),
            array(
                'id' => 4,
                'datec' => '2016-06-22 12:34',
                'user_id' => 2,
                'quoi' => 'hoopie', // [piplome|pibag|pishirt|hoodie]
                'taille' => 2,
                'status' => 2,
                'adresse_id' => null,
            ),
54
55
56
57
58
        );

        $this->table('contreparties')->insert($data)->save();
    }
}