Bonjour
je souhaite créer un service et utiliser doctrine dans ce service
j'ai mis dans mon fichier services.yml ceci:
NetBeans me signal une erreur du type:parameters: dsi_main.log.class: DSI\MainBundle\Service\GestionLog services: dsi_main.log: class: %dsi_main.log.class% arguments: [@doctrine]
donc sûrement lié à l'@ de doctrine...ScannerException while scanning for the next token we had this found character @(64) that cannot start any token
voici ma class service:
quand je lance mon test voici ce que j’obtiens:
Code : Sélectionner tout - Visualiser dans une fenêtre à part 
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
49
50
51
52
j'ai déjà eu ce pb avec l'@ mais je ne sais pas si l'erreur vient de la ou pas...Catchable Fatal Error: Argument 1 passed to DSI\MainBundle\Service\GestionLog::__construct() must be an instance of Doctrine\Bundle\DoctrineBundle\Registry, instance of Symfony\Bundle\DoctrineBundle\Registry given, called in /Synfony-Cache/dsiweb/cache/dev/appDevDebugProjectContainer.php on line 327 and defined in /MOUNT/STOCKAGE/WORKPLACE/Dsi-Symfony/src/DSI/MainBundle/Service/GestionLog.php line 28

 

 
		
		 
         
 

 
			
			


 
  
  
 
 
			 
   
 


 création service argument doctrine
 création service argument doctrine
				 Répondre avec citation
  Répondre avec citation


 Envoyé par Viduc
 Envoyé par Viduc
					
Partager