[symfony-users] Re: set or unset a field based on the user credentials

2010-01-18 Thread Ahsanul
Oh..! Thank you all for the solutions. Ya. My team-leader did the same in his case but I thought as my Forms should not know who the current user is and there might be a better way to do it in a better way...! No probs.. will go with your solution now :-) ~Cheerz~ On Jan 19, 8:13 am, ken wrote

Re: [symfony-users] Problem With User Management

2010-01-18 Thread Ashton Honnecke
In the past, when not using sfGuardDoctrineUser I have usually made a different "reset password" page, seperate from the rest of the user form. Ashton On Jan 18, 2010, at 16:31, Darren884 wrote: I have a form for the employees department and it has the information on the employee, includi

[symfony-users] Re: set or unset a field based on the user credentials

2010-01-18 Thread ken
You can pass the sfUser instance as an option of the form or sub class the form so you can switch form class in the controller based on user credentials. On Jan 19, 1:29 am, Darren884 wrote: > I had this problem before, you will have to take the user object and > pass it to the form class and che

[symfony-users] Problem With User Management

2010-01-18 Thread Darren884
I have a form for the employees department and it has the information on the employee, including the password. The problem is I do not want the employee to have to re-enter their password every time they fill out the form, so if the form is blank it would maintain the same password. Is this possibl

[symfony-users] Re: Trying to operate sfLightboxPlugin 1.0.11

2010-01-18 Thread Darren884
Why not just a javascript library for a lightbox instead of using a Symfony module? On Jan 18, 10:19 am, Martin Settle wrote: > In the call to light_modallink you need to point to the module action > that will return the contents of the lightbox... > > i.e. rather than 'sfLightboxPlugin/modal' yo

Re: [symfony-users] execute setPostValidator

2010-01-18 Thread Daniel Lohse
Look here: http://trac.symfony-project.org/ticket/5389 It's not so easy... Cheers, Daniel On 18.01.2010, at 16:44, DoRiaN wrote: > Hello (i'm french excuse me for my englise), > > Is it possible to execute setPostValidator() only if others validators > are valids ? > > Thanks, > Dorian > --

Re: [symfony-users] Trying to operate sfLightboxPlugin 1.0.11

2010-01-18 Thread Martin Settle
In the call to light_modallink you need to point to the module action that will return the contents of the lightbox... i.e. rather than 'sfLightboxPlugin/modal' you might have 'myModule/index' or whatever other action returns the information you want to display. Regards, Marti 2010/1/18 Javier

[symfony-users] How to get default sort method for models?

2010-01-18 Thread Darren884
Hello all, my customer model currently defaults to sorting by id asc. How do I change it to default to sort by name asc? Thanks, Darren -- 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...@googlegro

[symfony-users] Re: set or unset a field based on the user credentials

2010-01-18 Thread Darren884
I had this problem before, you will have to take the user object and pass it to the form class and check the credentials and then unset the widget there. If there is no user object you will have to unset it. On Jan 18, 9:25 am, Ahsanul wrote: > Hello all, > > I have a Doctrine table called "Comme

[symfony-users] set or unset a field based on the user credentials

2010-01-18 Thread Ahsanul
Hello all, I have a Doctrine table called "Comment" which has a field called "is_published" and as I have different type of users I don want my basic users see my "is_published" widget. But I can not unset this widget from a controller where I can check the credentials, on the other hand in a form

[symfony-users] Re: Doctrine Migration - Create enum type column

2010-01-18 Thread djones
If you are using symfony 1.3/1.4 you can add it to your schema.yml and use the doctrine:generate-migrations-diff task. config/doctrine/schema.yml [code] columns: ... my_column: type: enum values: [SomeValue, SomeOtherValue] default: SomeValue ... [/code] If you are using M

[symfony-users] execute setPostValidator

2010-01-18 Thread DoRiaN
Hello (i'm french excuse me for my englise), Is it possible to execute setPostValidator() only if others validators are valids ? Thanks, Dorian -- 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...@

[symfony-users] Re: Does the showSucess works same way a form?

2010-01-18 Thread wueb
Thanks for the help Filippo. -- 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

Re: [symfony-users] Best way to get 2 cache versions : anonymous / authenticated users

2010-01-18 Thread Eno
On Mon, 18 Jan 2010, Nicolas CHARLOT wrote: > I need to store 2 versions of a same action depending on user status > (authenticated and member or not). > > The solution I founded was to write my own viewCacheManager: > It works but all actions are cached twice and it's not necessary. I'm looking

[symfony-users] Doctrine and I18n

2010-01-18 Thread Evert Harmeling | fh
I have the following in my schema.yml MailMessage: connection: doctrine tableName: mail_message columns: name: type: string(120) fixed: false unsigned: false primary: true autoincrement: false priority: type: integer(2) fixed: false un

[symfony-users] Re: Get raw/unprocessed route in a Template

2010-01-18 Thread Donald
Well I managed to work out the answer myself. So if anyone else is interested, here it is: $routes = sfContext::getInstance()->getRouting()->getRoutes(); $raw_url = $routes['email_show']->getPattern(); On Jan 15, 9:34 am, Donald wrote: > I am trying to better integrate a Javascript Datagrid that

Re: [symfony-users] Re: Best way to get 2 cache versions : anonymous / authenticated users

2010-01-18 Thread Nicolas CHARLOT
Le 18 janv. 2010 à 13:57, Massimiliano Arione a écrit : > Nicholas, IMHO your solution is good. > I don't know any other solution for a such problem. > Why do you say that a double cache is not necessary? Indeed, it's > exactly what you need! Most of my actions are identical for members and anony

[symfony-users] Please help - use our facebook applications embedded in symfony

2010-01-18 Thread xhe
We just embedded facebook connect into our symfony framework project, if you have facebook account, can you please help to use it so that we can accumulate users and be accepted into facebook application directory? You just need to click following two links AFTER login into your facebook account.

Re: [symfony-users] Re: Save Embedded Forms

2010-01-18 Thread Germana Oliveira
i already overrride my saveEmbeddedForms, but i think i will have to do it deeper coz i need to control which embeddedForm it's saving The problem is that i have a 'special' required data in one of the embeddedForm that needs to use a method, but this have to be done by the system not by the us

[symfony-users] Re: Best way to get 2 cache versions : anonymous / authenticated users

2010-01-18 Thread ken
You can probably set up a filter to check for settings in cache.yml. like add a boolean setting but you will also need to override sfCacheConfigHandler to persist the setting into the cache. On Jan 18, 8:57 pm, Massimiliano Arione wrote: > On 18 Gen, 10:05, Nicolas CHARLOT wrote: > > > > > > >

[symfony-users] Re: Save Embedded Forms

2010-01-18 Thread ken
Override public function saveEmbeddedForms($con = null, $forms = null). I also suggest that you investigate about sfValidatorSchema, it helps a lot processing just any kind requirement that you may have. I'm just not sure if a merged post validator of a subform is actually taken into account by th

[symfony-users] Re: Does the showSucess works same way a form?

2010-01-18 Thread p16
Hi, If you need to change those "labels" frequently, maybe you should store them on the database: Lead: columns: id: ... id_label: ... name: ... name_label: ... So that you can do something like this: ... getIdLabel() ?> getId() ?> ... getNameLabel() ?> getName() ?> ... In the

[symfony-users] Save Embedded Forms

2010-01-18 Thread Germana Oliveira
Is there a way to save embedded Forms one by one??? I need to do this to fully fill my systems requirements... Thanks!!! -- Germana Oliveira germanaoliveirab arroba gmail punto com http://626f67.wordpress.com http://slcarabobo.wordpress.com -- You received this message because you are subscr

[symfony-users] Re: Best way to get 2 cache versions : anonymous / authenticated users

2010-01-18 Thread Massimiliano Arione
On 18 Gen, 10:05, Nicolas CHARLOT wrote: > I need to store 2 versions of a same action depending on user status > (authenticated and member or not). > > The solution I founded was to write my own viewCacheManager: > It works but all actions are cached twice and it's not necessary. I'm looking >

[symfony-users] Re: sfForm clean bind

2010-01-18 Thread ken
It doesn't have. And it is highly advisable that a redirect is executed after a form is processed. The only time no redirection will happen is if the form is invalid. On Jan 18, 7:02 pm, DoRiaN wrote: > Ok there are lot of solutions, buf does sfForm have a method to this ? > > On 15 jan, 14:39, T

[symfony-users] Trying to operate sfLightboxPlugin 1.0.11

2010-01-18 Thread Javier Garcia
Hi, i've just installed sfLightboxPlugin in sf 1.2.10 through: symfony plugin:install sfLightboxPlugin symfony plugin:publish-assets symfony cc Then i wrote this code (i copied it from sfLighboxplugin "Readme"): 'sfLightboxPlugin', 'size' => '550x200', 'speed' => '6' ); // or /

[symfony-users] Trying to operate sfLightboxPlugin 1.0.11

2010-01-18 Thread Javier Garcia
Hi, i've just installed sfLightboxPlugin in sf 1.2.10 through: symfony plugin:install sfLightboxPlugin symfony plugin:publish-assets symfony cc Then i wrote this code (i copied it from sfLighboxplugin "Readme"): 'sfLightboxPlugin', 'size' => '550x200', 'speed' => '6' ); // or /

[symfony-users] Does the showSucess works same way a form?

2010-01-18 Thread wueb
Hi, What i mean is, in a form we can define the labels for a field name in the form class, but on the showSucess we can't do it. We need write always the field names manual? Doesn't exist anything similiar to renderLabel() from forms? Instead of: Id: getId() ?>

[symfony-users] Doctrine Migration - Create enum type column

2010-01-18 Thread ruigoncalves
Hi there! Can anyone please tell me how can I create a new column of type enum to implement a Doctrine Migration? Thanks in advance, Best regards -- 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..

[symfony-users] Re: sfForm clean bind

2010-01-18 Thread DoRiaN
Ok there are lot of solutions, buf does sfForm have a method to this ? On 15 jan, 14:39, Tom Ptacnik wrote: > If you want to clear the form after it's proccessed, you can simply do > redirect to the same form (in the action) > > On 15 led, 12:23,DoRiaN wrote: > > > Hello, > > > How to delete valu

[symfony-users] have a confirmation password

2010-01-18 Thread l3ia-etu
Hi everyone ! I would like to confirm a username and password in a form (have 2 widget for the username, and 2 for the password, and test the equality): $this->useFields(array('username', 'password', 'profession_id')); $this->widgetSchema['confirmation_username']

Re: [symfony-users] Re: Errors following symfony 1.4 guide, is it error free?

2010-01-18 Thread Pau Peris
I just left it as downloaded. Nowhere in the manual sayd to customize it, at least i didn't saw it. Please tell me if i have to modify anything, thanks ;) http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";> http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en">

Re: [symfony-users] Best way to get 2 cache versions : anonymous / authenticated users

2010-01-18 Thread Nicolas CHARLOT
Le 18 janv. 2010 à 08:43, Alexandru-Emil Lupu a écrit : > Check here: > > http://www.symfony-project.org/book/1_2/12-Caching > > Some of the things that can be found in 1.2 are still valable in sf 1.4 Ok, but I don't see how slots can help for my purpose. I need to store 2 versions of a same

[symfony-users] Re: Same component different app?

2010-01-18 Thread Florian
Hi colin, You could also move your component logic into another class wich is in your /lib and then make your components in both frontend and backend inherit from this class instead of sfComponent. Hope you understand what I try to explain ? Cheers, Florian On 16 jan, 19:10, Colin wrote: > I h