Bonjour,
de mon coté, j'obtiens la même erreur, et bien sur, la regeneration des modeles et de tout le sql ne change rien.
(build all)
j'ai donc :
Code schema.yml : Sélectionner tout - Visualiser dans une fenêtre à part
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48 Image: connection: doctrine tableName: image columns: id: type: integer(8) primary: true autoincrement: true name: type: string(45) notnull: true url: type: string(255) notnull: true width: type: integer(8) notnull: true height: type: integer(8) notnull: true Vignettes_accueil: connection: doctrine tableName: vignettes_accueil actAs: I18n: fields: [name,value,id_image] columns: id: type: integer(8) primary: true autoincrement: true num: type: integer(1) name: type: varchar(50) unique: true value: type: text notnull: true id_image: type: integer(8) notnull: true relations: Image: local: id_image foreign: id type: one
dans mon model :
Code BaseVignettes_accueil.class.php : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 * @method integer getId() Returns the current record's "id" value * @method integer getNum() Returns the current record's "num" value * @method varchar getName() Returns the current record's "name" value * @method text getValue() Returns the current record's "value" value * @method integer getIdImage() Returns the current record's "id_image" value * @method Image getImage() Returns the current record's "Image" value * @method Vignettes_accueil setId() Sets the current record's "id" value * @method Vignettes_accueil setNum() Sets the current record's "num" value * @method Vignettes_accueil setName() Sets the current record's "name" value * @method Vignettes_accueil setValue() Sets the current record's "value" value * @method Vignettes_accueil setIdImage() Sets the current record's "id_image" value * @method Vignettes_accueil setImage() Sets the current record's "Image" value * * @package LEXIBOOK * @subpackage model * @author Your name here * @version SVN: $Id: Builder.php 7490 2010-03-29 19:53:27Z jwage $ */ abstract class BaseVignettes_accueil extends sfDoctrineRecord
Mais dans mon action, lorsque j'essaye de faire ceci :
Code action.class.php : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5 $this->vignettes = Doctrine_Core::getTable('Vignettes_accueil') ->createQuery('v') ->leftJoin('v.Image i') ->execute();
me retourne ca :
Mon but étant dans mon template de faire :500 | Internal Server Error | Doctrine_Table_Exception
Unknown relation alias Image
Est ce que vous avez une idée du problème ?
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6 <?php for($i=0;$i<count($vignettes)&&$i<5;$i++):?> <?php echo $vignettes[i]->getImage();?> <a id="t0" class="<?php echo $class;?>"></a> <?php $class="";?> <?php endfor;?>
Ca me bloque depuis hier, et j'avoue que ca m'enerve un brin...
Merci,
Pierre
Partager