Re: [symfony-users] Re: Need Help to Install Symfony
Seems like something is usling port 8080. Swap port tö something else. On May 25, 2011 7:55 AM, Chinthaka Rukshan Weerakkody chinthakaruks...@gmail.com wrote: Hi, I followed that tutorial and configured the httpd.conf file as follows. My installation directories are as follows. symfony projects directory: /var/www/symphonyprojects (project directory is inside the localhost www directory) I created /lib/vendor directory inside the symphonyprojects directory and installed it. Then I added the below lines of codes and configured the /etc/apache2/httpd.conf file. # Be sure to only have this line once in your configuration NameVirtualHost 127.0.0.1:8080 # This is the configuration for your project Listen 127.0.0.1:8080 VirtualHost 127.0.0.1:8080 DocumentRoot /var/www/SymphonyProjects/web DirectoryIndex index.php Directory /var/www/SymphonyProjects/web AllowOverride All Allow from All /Directory Alias /sf /home/sfproject/lib/vendor/symfony/data/web/sf Directory /home/sfproject/lib/vendor/symfony/data/web/sf AllowOverride All Allow from All /Directory /VirtualHost Then I tried to restart apache server and when restarting using terminal it gave me the below error. * Starting web server apache2 (98)Address already in use: make_sock: could not bind to address 127.0.0.1:8080 no listening sockets available, shutting down Unable to open logs Action 'start' failed. The Apache error log may have more information. what is the error and what can I do to overcome this problem. Can anyone help me please. Thank You. -- Chinthaka Rukshan Department of Computer Science and Engineering, University of Moratuwa, Sri Lanka. -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Doctrine hydration for relations not working with object records
(symfony 1.4.10 doctrine 1.2) Hello, Given the following method, I use a foreach loop in the template to show students and their group (Regroupements here). I would like to avoid an extra query inside the loop for the group. EtudiantTable.class.php : === public function getEtudiantsForEnseignement($enseignementId) { $q = $this-createQuery('e') -select('e.nom_naissance, e.nom_usuel, e.prenom, r.id, r.code, r.type_id, t.id, t.nom') -innerJoin('e.Regroupements r') -innerJoin('r.Type t') -innerJoin('r.EnseignantEnseignementRegroupements eer') -where('eer.enseignement_id=? and e.semestre_id=?', array($enseignementId, $semestre-getId())) -andWhere('t.code=?', array('groupe')) -orderBy('e.nom_naissance'); return $q-execute(array(), Doctrine_Core::HYDRATE_ARRAY); } With hydration done with Doctrine_Core::HYDRATE_ARRAY, I can use the result of this query : ?php foreach ($etudiants as $etudiant): ? ?php echo $etudiant['nom_naissance'] ? ?php echo $etudiant['prenom'] ? ?php echo $etudiant['Regroupements'][0]['code'] ? ?php endforeach ? But with Doctrine_Core::HYDRATE_RECORD, I write this code, which generates an extra query for each student : ?php foreach ($etudiants as $etudiant): ? ?php echo $etudiant-getNom() ? ?php echo $etudiant-getPrenom() ? ?php echo $etudiant-getGroupe()-getNom() ? ?php endforeach ? The code used by these methods are a mix of Doctrines and mine : Etudiant.class.php : === public function getGroupe() { return Doctrine::getTable('Regroupement')-createQuery('r') -select('r.id, r.code') -innerJoin('r.Type t') -innerJoin('r.Etudiants e') -where('e.id=? and t.code=?', array($this-getId(), 'groupe')) -fetchOne(); } Regroupement.class.php : public function getNom() { return trim($this-getType()-getNom().' '.$this-getCode()); } Would anybody have an idea of how to achieve that with Doctrine_Core::HYDRATE_RECORD ? Regards, Mikael -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Symfony 1.4 - reflexive relation with doctrine generates DELETE query
Hello, I have a strange behavior when I save a Doctrine form based on this model : Enseignement: columns: code: { type: varchar } nom: { type: varchar } valide: { type: boolean, default: false, notnull: true } parent_id: { type: integer } relations: Parent: {class: Enseignement, local: parent_id, foreign: id, type: one} I just want to change the value of the valide field form the object with id 15 and then, I get these queries : UPDATE enseignement SET updated_at = '2011-05-17 11:41:41' WHERE id = '13' UPDATE enseignement SET valide = '1', updated_at = '2011-05-17 11:41:41' WHERE id = '15' DELETE FROM enseignement WHERE id = '13' I'm currently trying to find out the problem, but maybe it's a flawed model or known problem. Any idea on that ? Regards, Mikael Kermorgant -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: Symfony 1.4 - reflexive relation with doctrine generates DELETE query
Hello, Found out it by myself (well, I got it working) I did not use the relation Parent by its name, but by the class name (-getEnseignement). I added a Child relation to be able to navigate on each side, adapted the getters in the code and voila... Mikael On 17 mai, 13:55, Mikael mikael.kermorg...@gmail.com wrote: Hello, I have a strange behavior when I save a Doctrine form based on this model : Enseignement: columns: code: { type: varchar } nom: { type: varchar } valide: { type: boolean, default: false, notnull: true } parent_id: { type: integer } relations: Parent: {class: Enseignement, local: parent_id, foreign: id, type: one} I just want to change the value of the valide field form the object with id 15 and then, I get these queries : UPDATE enseignement SET updated_at = '2011-05-17 11:41:41' WHERE id = '13' UPDATE enseignement SET valide = '1', updated_at = '2011-05-17 11:41:41' WHERE id = '15' DELETE FROM enseignement WHERE id = '13' I'm currently trying to find out the problem, but maybe it's a flawed model or known problem. Any idea on that ? Regards, Mikael Kermorgant -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] schema imported without relations
Hello, We're working on a small website aimed at showings stats extracted from limesurvey (php tool to manage surveys). We've decided to import the schema in order to generate the model classes and work with Doctrine to build our queries, but infortunately, the relations haven't been imported. And this query fails : $q = Doctrine_Query::create() -select('lls.surveyls_title') -from('LimeSurveysLanguagesettings lls') -innerJoin('LimeSurveys ls ON lls.surveyls_survey_id = ls.sid' ); with the following error : 500 | Internal Server Error | Doctrine_Table_Exception Unknown relation alias So a question : is it at all possible to use DQL with joins when the schema does not specify relations ? Regards, Mikael -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: iocombiner plugin : activation procedure ?
Ok, thanks. So, I'm not so sure of where this plugin benefits in my use. I've loaded my test page in opera to trigger the minifying process, and then loaded it again in firefox with firebug. It showed that the loading of the combine.js file took nearly 2s. Isn't there a way to reuse symfony's cache ? app.yml io_combiner_plugin: enabled:true # enable or disable the combiner response_class: ioCombinerResponse combiner_class: ioCombiner expires_days: 30 web_debug_panel:false stylesheets:[common.css, frontend.css, jquery.alerts.css] javascripts:[jquery.js, jquery.alerts.js, jquery.iufm.js] view.yml: stylesheets: [common.css, frontend.css,jquery.alerts.css] javascripts:[jquery.js,jquery.alerts.js, jquery.iufm.js] Regards, Mikael On 14 avr, 16:05, weaverryan weaverr...@gmail.com wrote: Hey Mikael- Yes, this is a mistake in the documentation - I apologize. You're absolutely right to include the combiner_include_stylesheets() and combiner_include_javascripts() in your layout, in place of the normal functions. Thanks! On Apr 14, 2:13 am, Mikael mikael.kermorg...@gmail.com wrote: Hello, I'd like to use iocombiner for our symfony 1.4 project. I've followed the doc but the only way to see combine.css and combine.js requested in firebug is to replace include_stylesheets() by combiner_include_stylesheets() in my layout.php Is this the right way to procede ? Regards, Mikael Kermorgant -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject.
[symfony-users] iocombiner plugin : activation procedure ?
Hello, I'd like to use iocombiner for our symfony 1.4 project. I've followed the doc but the only way to see combine.css and combine.js requested in firebug is to replace include_stylesheets() by combiner_include_stylesheets() in my layout.php Is this the right way to procede ? Regards, Mikael Kermorgant -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject.
[symfony-users] doctrine autoloading pb while deploying on debian lenny
Hello, I try to deploy a symfony project (developped on wamp) on a debian lenny server and faces the following problem while running a task that works fine on my windows machine : /var/www/pi2010$ ./symfony import:pays Fatal error: Class 'Doctrine_Template_TimeStampable' not found in /var/ www/svnexp/pi2010/trunk-r269/lib/model/doctrine/base/ BasePays.class.php on line 66 My setup : * Symfony installed in /opt/symfony-1.4.3 * our project deployed from subversion in /var/www/svnexp/pi2010/trunk- version with symlink to /var/www/pi2010 in pi2010/ProjectConfiguration.php, we have : === if(!file_exists(dirname(__FILE__) . '/ConfigPerso.php')) { die('You need to create your own ConfigPerso.php'); } include (dirname(__FILE__) . '/ConfigPerso.php'); sfCoreAutoload::register(); class ProjectConfiguration extends sfProjectConfiguration { public function setup() { $this-enablePlugins(array( 'sfDoctrinePlugin', 'sfDoctrineGuardPlugin' )); $this-enablePlugins('sfDoctrineGraphvizPlugin'); $this-enablePlugins('sfJqueryReloadedPlugin'); $this-enablePlugins('sfAdminDashPlugin'); $this-enablePlugins('sfFormExtraPlugin'); } } and ConfigPerso.php == ?php require_once '/opt/symfony-1.4.3/lib/autoload/ sfCoreAutoload.class.php'; == Besides, installation seems ok from what the check says. php -v PHP 5.2.6-1+lenny8 with Suhosin-Patch 0.9.6.2 (cli) (built: Mar 14 2010 08:14:04) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies php.ini used by PHP: /etc/php5/apache2/php.ini ** WARNING ** * The PHP CLI can use a different php.ini file * than the one used with your web server. * If this is the case, please launch this * utility from your web server. ** WARNING ** ** Mandatory requirements ** OKPHP version is at least 5.2.4 (5.2.6-1+lenny8) ** Optional checks ** OKPDO is installed OKPDO has some drivers installed: mysql OKPHP-XML module is installed OKXSL module is installed OKThe token_get_all() function is available OKThe mb_strlen() function is available OKThe iconv() function is available OKThe utf8_decode() is available OKThe posix_isatty() is available OKA PHP accelerator is installed OKphp.ini has short_open_tag set to off OKphp.ini has magic_quotes_gpc set to off OKphp.ini has register_globals set to off OKphp.ini has session.auto_start set to off OKPHP version is not 5.2.9 Would anyone have an idea about what's wrong ? Regards, Mikael -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject.
[symfony-users] Re: doctrine autoloading pb while deploying on debian lenny
I forgot to mention that the model building operation went fine : /var/www/pi2010$ ./symfony doctrine:build --all --and-load --no- confirmation doctrine Dropping doctrine database doctrine Creating dev environment doctrine database doctrine generating model classes file+ /tmp/doctrine_schema_38623.yml ... ... doctrine Generated SQL successfully for models doctrine creating tables doctrine created tables successfully doctrine Loading data fixtures from /var/www/svnexp/pi2010/trunk-r269/data/fixtures doctrine Loading data fixtures from /var/www/svnexp/pi2010/trunk-r269/plugins/sfDoctrineGuardPlugin/data/fixtures doctrine Data was successfully loaded The line 66 of BasePays.class.php has this : $timestampable0 = new Doctrine_Template_TimeStampable(); $this-actAs($timestampable0); The ImportPaysTask does this : $databaseManager = new sfDatabaseManager($this-configuration); $connection = $databaseManager- getDatabase($options['connection'])-getConnection(); $row = 1; if (($handle = fopen( sfConfig::get(sf_data_dir) . / import/pays.csv, r)) !== FALSE) { $doctrine = $connection; $doctrine-query('TRUNCATE TABLE pays'); $doctrine-query('TRUNCATE TABLE nationalite'); unset($doctrine); while (($data = fgetcsv($handle, 1000, ;)) !== FALSE) { $row++; $pays = new Pays(); $pays-setCode(trim($data[0])); $pays-setNom(trim($data[1])); $pays-save(); Regards Mikael -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject.
[symfony-users] Re: doctrine autoloading pb while deploying on debian lenny
THANKS !!! Mikael -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject.
[symfony-users] Re: Admin generator, Doctrine, one-to-many relation
Hello, Not sure, but maybe the ahDoctrineEasyEmbeddedRelationsPlugin could help. I have a computer table and an interface table and this plugin has helped me to manage many interfaces for one computer. Regards Mikael On Feb 19, 12:04 pm, Johannes Trommer johannes.trom...@gmail.com wrote: Hello, I'm having a problem that and I was not able to figure it by myself. I want to create a backend for a gallery with the admin generator. When I open a Gallery I want display all pictures in it. Galleries and Pictures are stored in two seperate tables. How can I display all pictures of a gallery, when editing this gallery? See the screenshot. This is the gallery-edit. Below it I want to list all the pictures from that gallery. Here is my schema: Galleries: actAs: Timestampable: ~ Sluggable: unique: true fields: [name] canUpdate: false columns: name: { type: string(255), notnull: true } description: { type: string(99) } created_at: { type: timestamp, notnull: true } updated_at: { type: timestamp, notnull: true } relations: Pictures: { local: id, foreign: gallery_id } Pictures: actAs: { Timestampable: ~ } columns: gallery_id: { type: integer, notnull: true } file: { type: string(255), notnull: true, unique: true } caption: { type: string(255) } source: { type: string(255) } created_at: { type: timestamp, notnull: true } updated_at: { type: timestamp, notnull: true } Regards, Johannes Trommer Bild 1.png 22KViewDownload -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] create fieldsets in form class
Hello, I'm using the sfAdminThemejRollerPlugin which leads me to use fieldsets to neatly present all my widgets in tabs. The generator.yml looks like this : form: class: BackendPcForm edit: display: Inventaire: [ name, num_cmd, num_serie, date_liv, date_ins, position ] Technique: [ id_modele, puissance, thermique, bruit, microp, freq, mem ] Autres: [ peripheriques_list, users_list ] Now, I'm also using the ahDoctrineEasyEmbeddedRelationsPlugin which is not 100% compatible with the idea of specifying the list of widgets in generator.yml. Is there a way to specify my fieldsets in the BackendPcForm class ? Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] ahDoctrineEasyEmbeddedRelationsPlugin : how to hide some form widgets
Hello, I've installed the ahDoctrineEasyEmbeddedRelationsPlugin and set it up to manage Eth records linked to Pc ones. On the pc backend module, I've configured the form to only show some widgets (because pc inherits from Obj which many useless fields in the context of a pc). This gives us this in generator.yml : form: display: [id_type_obj, name, num_cmd, num_serie, date_liv, date_ins, position, garantie, id_typeOrdi, id_site, id_modele, puissance, thermique, bruit, microp, freq, mem, peripheriques_list, users_list, new_Eth ] Works well until I add Eth in order to see existing Eth records linked to existing Pcs. - If the pc object already has an interface, it shows up - If not, I get an error 500 : Widget Eth does not exist. Anyone an idea about how to deal with that ? Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: ahDoctrineEasyEmbeddedRelationsPlugin : how to hide some form widgets
On Feb 17, 2:34 pm, Stéphane stephane.er...@gmail.com wrote: Hi, In the BaseDoctrineForm, in the ::configure() method, I've coded something like this: $aConditions = array('ajax'=isAjax ? 'ajax:false, 'new'= isNew ? 'new': false, 'embedded'=isEmbedded?'embedded':false, ); $method = sprintf('_computeFields%s%s%s', $aConds['ajax'], $aConds['new'], $aConds['.) and finally try{ $this-useFields($this-$method()); }catch(Exception $e){} So I can compute the correct method to call to configure the fields according to the current situation. In the embedRelations, you can give args to the newed form class, this is where you'll give to it you are currently embedded and why not pass it the current embedding form and other needed stuffs. The main concern here is to make the form class able to determine by itself how it should react to its external conditions, without having to tell how it should act (what fields it should show, etc) everywhere in the code. This make these available in some places (the _configureFields%s%s%s..' methods). You can even go further by making an order of precedence (like ysfDimensionPlugin does in someway). So there is no more questions such as where is it said that this form show these fields ?, it's all in these methods of the concerned form. Hope this help, Cheers, Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Wed, Feb 17, 2010 at 8:12 PM, Daniel Lohse annismcken...@googlemail.comwrote: Hey there, there's only one way I can of, which you probably won't like. Just configure all the fields directly in the form. :) So, delete the form: display: key and just create another form inheriting from the form you are probably already using elsewhere and use $this-useFields() before calling this embedRelations(). Does that help? By the way, you really shouldn't use the form: display: key as you are likely to get confused and forgot to update the generator.yml when new fields are added. This is also prevents a security hole. I hope it will help but I must take some time to learn a bit more about these things. Anyway, thanks a lot ! Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] ahDoctrineEasyEmbeddedRelationsPlugin : use a relation from inherited object ?
Hello, I have a schema with 3 objects : Obj Pc Eth Obj has a relation with Eth (one to many) Pc inherits from Obj I've installed the ahDoctrineEasyEmbeddedRelationsPlugin and it works well with Obj, but I can't get it working on Pc. Would it be possible ? If so, how should I do it ? Thanks in advance, Mikael Kermorgant -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: ahDoctrineEasyEmbeddedRelationsPlugin : use a relation from inherited object ?
To be more precise, here's an extract from schema.yml : = Obj: columns: name: type: string(25) num_serie: type: string(45) notnull: true relations: Eth: class: Eth local: id foreign: id_obj type: many cascade: [delete] === Pc: inheritance: extends: Obj type: column_aggregation keyField: id_type_obj keyValue: 1 columns: id_typeOrdi: type: integer(2) notnull: false === Eth: columns: id_obj: type: integer notnull: true adr_ip: type: string(15) notnull: true adr_mac: type: string(17) notnull: true name: type: string(20) notnull: true relations: Obj: local: id_obj foreign: id foreignType: one = -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: ahDoctrineEasyEmbeddedRelationsPlugin : use a relation from inherited object ?
On 16 fév, 13:40, Daniel Lohse annismcken...@googlemail.com wrote: Hey there, I'm the plugin developer. There are few things that need work and I was much too fast to pull the trigger on the 'stable' designation. Won't happen again. To get to the point: may I see your schema.yml? And if you had a few fixtures for me to work with, I'd take a closer look. On another note: I have a more advanced and bugfixed version here but it's not ready yet. Hang in there while I finish this up but it won't be today, sorry. Cheers, Daniel Sent from my iPhone Hello, I sent you the complete schema.yml and some fixture on your email i...@asapdesign.de I guess my concern has something to do with the following line in lib / form / ahBaseFormDoctrine.class.php : $this-getObject()-getTable()-getRelation($relationName); Regards Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: ahDoctrineEasyEmbeddedRelationsPlugin : use a relation from inherited object ?
On Feb 16, 7:05 pm, Mikael mikael.kermorg...@gmail.com wrote: On 16 fév, 13:40, Daniel Lohse annismcken...@googlemail.com wrote: Hey there, I'm the plugin developer. There are few things that need work and I was much too fast to pull the trigger on the 'stable' designation. Won't happen again. To get to the point: may I see your schema.yml? And if you had a few fixtures for me to work with, I'd take a closer look. On another note: I have a more advanced and bugfixed version here but it's not ready yet. Ouch, stupid me : I was wrong from the beginning. The generator.yml for the 'pc' module was modified and the 'form' entry limited to some fields... Sorry for the trouble :( Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: ahDoctrineEasyEmbeddedRelationsPlugin : use a relation from inherited object ?
On Feb 16, 8:19 pm, Daniel Lohse annismcken...@googlemail.com wrote: So, to clarify: there was no issue here. Exactly. Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: default value in form extracted from session
Thanks a lot !!! Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: default value in form extracted from session
Hello, I'm may be almost done but I haven't found the way to preset or hide the id_obj field when creating the Eth entry. It could be because I've used the new template instead of creating a specific one but shouldn't the value be preset with the correct entry by default ? Here's more precisely what I have : * 2 modules : pc (Pc inherits from Obj) and eth * apps/backend/modules/pc/templates/_form_actions.php : added a button to save and add an interface * apps/backend/modules/pc/lib/pcGeneratorHelper.class.php : added a method linkToSaveAndAddInterface * apps/backend/modules/pc/actions/actions.class.php : methode processForm : if ($request-hasParameter('_save_and_add_interface')) { $this-getUser()-setFlash('notice', $notice. ' You can add an interface below.'); $this-redirect( 'eth/newForPc?id_obj='.$pc-getId()); } * apps/backend/modules/eth/actions/actions.class.php : public function executeNewForPc(sfWebRequest $request) { $this-eth = new Eth(); $this-eth-id_obj = $request-getParameter('id_obj'); $this-form = new EthForm($this-eth); $this-setTemplate('new'); // lazy : would prefer not write a specific template - would be ok just by preselecting the right pc in the dropdown list } Any idea about what to do ? Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: default value in form extracted from session
I must have made a mistake during my test : the right pc shows up by default in the dropdown list when creating a new interface. If I wanted to hide this dropdown list, would I have to create a specific template ? Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] default value in form extracted from session
Hi, My data model has a Pc table with a 1-n relation with an Eth table. I'd like to configure the backend forms in order to : 1 - Show 'New Pc form' with button 'save and add interface' 2 - When pc is saved (processForm), Pcs new id is put in session 3 - Then, the form for creating a new interface is shown At step 3, I want the form for the interface to avoid the selection of the Pc, which should be the one just created. I've tried to do this this way, but does not work : // lib/form/doctrine/EthForm.class.php class EthForm extends BaseEthForm { public function configure() { $this-setDefault('id_obj', sfUser::getAttribute('pc')); } } Could someone help me to do this right ? Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] [beginner] model design problem with common data in one table (should do multiple inheritance)
Hello, I'd like to rewrite an existing application as a way to learn symfony, and I face a design issue. The database will contain informations about our stock (computers, switches, etc.). We have created a common table with fields like these : Obj : id name_obj delivery_date warranty_expiry_date Then other tables for specific datas : Pc: id processor frequency Switch: id ports level Now, I've created the symfony project, built the model and created a 'pc' module following the 24 days tutorial, and my feeling is that the Pc class should be extended with BasePc and BaseObj but php won't permit it. Would someone know how to do this right ? Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: [beginner] model design problem with common data in one table (should do multiple inheritance)
On 21 déc, 19:11, Eno symb...@gmail.com wrote: On Mon, 21 Dec 2009, Mikael wrote: I'd like to rewrite an existing application as a way to learn symfony, and I face a design issue. The database will contain informations about our stock (computers, switches, etc.). We have created a common table with fields like these : Obj : id name_obj delivery_date warranty_expiry_date Then other tables for specific datas : Pc: id processor frequency Switch: id ports level Wouldn't it be better to generalize this more so you dont have specific tables for each asset? Well, we wanted to keep many details so the common table was meant to centralize some generic informations. We could change our schema and : - either use only one table with many fields (specific ones for printers, switches, computers) - or use separated tables for each type of device as now, but without the common table (each specific table would get its fields). But in the end, I'm not sure if there are some guidelines which would help to do the right choice. One table for everything evoques the kiss principle so maybe we should stick with that but if anyone has an opinion to share on that, I'd be pleased to know. Regards, Mikael -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.