[symfony-users] Re: [Assetic] How to deal with images references in CSS

2011-06-15 Thread Francisco Facioni
I'm having the same problem, did you find how to solve it?

On Jun 2, 12:53 pm, dbenjamin bd.web...@gmail.com wrote:
 Ok, i added the cssrewrite filter to my assets but i'm not sure how to use
 it.

     {% stylesheets filter='cssrewrite,?yui_css'
         '@MvalSiteBundle/Resources/css/jquery/jquery-ui.css'
         '@MvalSiteBundle/Resources/css/reset.css'
         '@MvalSiteBundle/Resources/css/style.css'
     %}
         link href={{ asset_url }} rel=stylesheet media=screen /
     {% endstylesheets %}

 The paths are now ../../Resources/css/jquery/images/. Obviously it can't
 work.

 The assets src are in :

 MyBundle/
     Resources/
         css/
             jquery/
                 images/
                 jquery-ui.css
             reset.css
             style.css

 I don't see options for the cssrewrite filter. How should i do ?

 Thanks.

 *
 --
 Benjamin Dulau - anonymation CEO
 anonymation.com | code.anonymation.com
 ben...@anonymation.com
 *

-- 
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] ckWebServicePlugin and WSDL documentation tag

2010-04-12 Thread Francisco
Hello,
i have somes actions as webservices (with ckWebServicePlugin). I need
to include documentation tag in wsdl generated file, but it doesn't
work

it is an example of htdoc of webservice action:

/**
 * Devuelve coleccion de carteleras de la semana para un canal
 *
 * @WSMethod(name='ObtenerCartelerasDadoIdCanal',
webservice='internosWS')
 *
 *
 *...@param int $idCanal Identificador del canal
 *
 * @return FechaCartelera[] Coleccion de fechas que contienen
carteleras para el canal dado
 */



All is working perfect except the description of method (Devuelve
coleccion de carteleras de la semana para un canal), that is not
generated as documentation tag in a wsdl file.

I hope you can help me, thank !!!

-- 
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] how to create web services ??

2010-02-13 Thread Francisco
Hellow peoples, firstly i don't speak english, sorry for a mistake
i'll try to explain me.
Someone can help me to create a web services !?!?

the idea is use a model layer to retreive the information and publish
a wsdl with the methods.

searching in the web, i found the ckWebServicePlugin, but i don't know
if it is useful for generate web services (and wsdl) that bring a
collections of data that represents a complete records in a database.

for example a collections of Movies (gender, synopsis, poster,
director, title,...).

-- 
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: About embed forms

2009-10-13 Thread Francisco José Núñez Rivera
Can you show me the schema?
Maybe something its incorrect in the relations.





2009/10/10 Dennis gear...@sbcglobal.net


 Let's say you have a schema of:

 'User'
 'MovingBoxForBooks'
 'Book'.

 'User'-1-to-many-'MovingBoxForBooks'
 'MovingBoxForBooks'-1-to-many-'Book'

 'User' is a parent of 'MovingBoxForBooks'
 'MovingBoxForBooks' is a CHILD of 'User'

 'MovingBoxForBooks' is a parent of 'Book'
 'Book' is a CHILD of 'MovingBoxForBooks'

 If you use the default CRUD generator and scaffolding, (which I am
 beginning to believe that more advanced Symfony users don't use after
 awhile), and go to the 'MovingBoxForBooks' form, you will find a drop
 down list for 'User'. It will probably have a title like, No value
 available for User. (You need to define the __toString() method).
 That is the PARENT showing up in the CHILD form.

 BUT you will NOT see any form fields for 'Book' in the
 'MovingBoxForBooks' form, NO CHILDREN form fields show up
 automagically.

 Does this clear it up?

 On Oct 9, 12:42 am, elkrema elfra...@gmail.com wrote:
  Hi Dennis,
 
  thank you for your comments.
 
  About your problem adding a Children to the Parent Object, i don't
  understand it very well.
 
  I just take a look to your link about but i think it's more or less
  like im doing? Adding some embeds , right?
 
  Can you explain me more?
 
  Thank you.
 
  On 7 oct, 01:24, Dennis gear...@sbcglobal.net wrote:
 
 
 
   Try this for adding an object's PARENT form to the child form.
 http://www.symfony-project.org/blog/2008/11/07/new-in-symfony-1-2-doc...
 
   Where it says Edit/Add Author Exactly in the middle of the document.
 
   Me, I'm looking to add Chidren to the Parent Object, but not a large
   quanity of them like this guy did:
 http://www.thatsquality.com/articles/can-the-symfony-forms-framework-...
 
   Also, he had to go to a lot of trouble to get it to work.
 
   There's got to be a way to add the children, or a blank one without
   going to the trouble that he went tol.
 
   (doctrine btw)
   ParticularForm extends BaseParticularForm{
 
   function configuration(){
 $this-getObject()-getRelatedObjectForm
 
   On Oct 5, 11:20 pm, Francisco José Núñez Rivera elfra...@gmail.com
   wrote:
 
I tried it with
 
$opinion = new Opinion();
$opfeat = new $opinion-OpinionFeature;
 
but cant find the class OpinionFeature...
 
Otherwise i do the same you write (more or less). I think that when
 i'm
showing opinion form it creates a new Opinion(); variable.
Then i use that variable to set the new OpinionFeature var...
$opfeat-setOpinionId($this-getObject()-id);
$opfeat-setFeatureId($feature-getId());
 
$OFform = new OpinionFeatureForm($opfeat);
$this-embedForm('feature_'.$feature-getId(), $OFform);
 
But it doesnt work... i have to overwrite saveEmbedForms
 
public function saveEmbeddedForms($con = null, $forms = null)
  {
 
foreach($this-getEmbeddedForms() as $opinionForm)
{
 
$opinionForm-getObject()-setOpinionId($this-getObject()-getId());
}
 
parent::saveEmbeddedForms($con, $forms);
  }
 
I think there's a easier way to do this but.. i dont know. :(
 
2009/10/6 Dennis gear...@sbcglobal.net
 
 I got this off of a Fabien post, somewhere. If you look at it, it
 makes everything connect to the same parent record. It SHOULD save
 correctly. I am goin to try it in my project tonight. Let me know
 if
 it works for you.
 
 $user = new User();
 $profile = new $user-Profile;
 $userForm = new UserForm($user);
 $profileForm = new ProfileForm($profile);
 $userForm-embedForm('Profile', $profileForm);
 
 On Oct 5, 2:13 am, elkrema elfra...@gmail.com wrote:
  Hi Dennis,
 
  there is my schema:
 
  Feature:
tableName: feature
columns:
  id:
type: integer(8)
primary: true
autoincrement: true
  name:
type: string(255)
notnull: true
  created_at: timestamp(25)
  updated_at: timestamp(25)
relations:
  OpinionFeature:
local: id
foreign: feature_id
type: many
 
  Opinion:
tableName: opinion
columns:
  id:
type: integer(8)
primary: true
autoincrement: true
  title:
type: string(255)
notnull: true
  opiniontxt:
type: string(2147483647)
notnull: true
  is_active:
type: integer(1)
default: '0'
notnull: true
  token:
type: string(255)
notnull: true
  created_at: timestamp(25)
  updated_at: timestamp(25)
relations:
  OpinionFeature:
local: id
foreign: opinion_id
type: many
 
  OpinionFeature:
tableName: opinion_feature
columns

[symfony-users] Re: About embed forms

2009-10-06 Thread Francisco José Núñez Rivera
 foreign: feature_id
 type: one
 foreignType: many
 
See if this works :-)
 
   Personally, I like graphical database design tools. I make the design,
   have it spit out the code for the database that I'm using, then make
   the database, use Doctrine to build the schema (instead of composing
   it like above), make my model-forms-filters, and go.
 
   I've had good luck using DezignForDatabases. The guy who makes it is
   very helpful and friendly. It's not perfect, but it's great for the
   price.
   On Oct 2, 3:39 am, Francisco José Núñez Rivera elfra...@gmail.com
   wrote:
 
But all the opinions have the same features.
 
Feature - id , desc
1,Feature 1 ; 2, Feature2...
 
Opinion shows all the features..
Feature 1 -Score:
Feature 2 - Score:
 
OpinionFeature - opinion_id , feature_id , score
I only insert a row here when im scoring a feature.
 
I think my schema is right... no?
 
Thank you very much.
 
2009/10/1 Abraham Montilla amontil...@gmail.com
 
 elkrema, if you have I have an Opinion with many Features then the
 right
 schema is
 
 Feature is: id, opinion_id, desc
 OpinionFeature is: opinion_id, score
 
 that's why you have an integrity constraint violation I don't
 know how
 i missed that first time i read your post hehe, that's all the
 problem
 
 2009/10/1 elkrema elfra...@gmail.com
 
 With unsetting only option id doesn't work.
 
 The problem is that i am inserting the object of main form and the
 embedded objects too.
 
 But i found a solution... I rewrite the function saveEmbeddedForms
 in
 OpinionForm
 
  public function saveEmbeddedForms($con = null, $forms = null)
  {
 
foreach($this-getEmbeddedForms() as $opinionForm)
{
 
  $opinionForm-getObject()-setOpinionId($this-getObject()-getId
 ());
}
 
parent::saveEmbeddedForms($con, $forms);
  }
 
 I set the opinionid before saving the embed formsI dont know
 if is
 the good way..
 
 Otherwise i have a new problem..
 
 when i'm editing an opinion the value of the last feature is not
 showed.. ¿?
 
 Thank you!
 
 On 30 sep, 07:21, Abraham Montilla amontil...@gmail.com wrote:
  try just unsetting opinion_id, tell me if works
 
  2009/9/29 elkrema elfra...@gmail.com
 
   Hello Abraham,
 
   This is my code with i'm embedding forms in OpinionForm:
 
   foreach($this-getObject()-getFeatures() as $feature)
   {
$opinionf = new OpinionFeature();
$opinionf-setOpinionId($this-getObject()-id);
$opinionf-setFeatureId($feature-getId());
$this-embedForm($feature-getName(), new OpinionFeatureForm
   ($opinionf));
   }
 
   With this code in when saving always get this flash message in
 the
   first Feature...
 
  * Feature id: Invalid.
 
   And if i configure OpinionFeatureForm to unset the fields
 (just for
   testing)
 
  unset($this['opinion_id'], $this['feature_id']);
 
   I get ..
 
   SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot
 add or
   update a child row: a foreign key constraint fails
   (`opinion`.`opinion_feature`, CONSTRAINT
 `opinion_feature_ibfk_1`
   FOREIGN KEY (`opinion_id`) REFERENCES `opinion` (`id`) ON
 DELETE
   CASCADE)
 
   Thank you for helping
 
   On 29 sep, 01:25, Abraham Montilla amontil...@gmail.com
 wrote:
i think it's because when embedding the OpinionFeatureForms
 you're
 not
setting properly the foreign key to the objects, would be
 something
 like
 
for ( $i  . ){
$opfeat = new OpinionFeature();
$opfeat-setOpinionId($this-getObject-getId());
$OFform = new OpinionFeatureForm($opfeat);
$this-embedForm('Feature_'.$i, $OFform);
 
}
 
2009/9/28 elkrema elfra...@gmail.com
 
 Hello
 
 i have some problems with my embed forms and i can't find
 a
 solution...
 
 I have an Opinion with many Features..
 
 Feature is: id, desc
 OpinionFeature is: opinion_id, feature_id,score
 
 In OpinionForm i'm inserting with [for each] all the
 features, but
 when im creating a new opinion i always get [Integrity
 constraint
 violation]
 
 I'ts easy get the id of the feature but i can get the ID
 of the
 opinion because it isnt created yet... is null.
 
 Somebody can help me please? I get trought many forums and
 jobeet
 tutorial but i cant get the solution!
 
 PS. Sorry for me english!!
 
--
Have a nice day.
Abraham Montilla.
 
  --
  Have a nice day.
  Abraham Montilla.
 
 --
 Have a nice day.
 Abraham Montilla.
 
 
 


--~--~-~--~~~---~--~~
You received this message because you are subscribed

[symfony-users] Re: About embed forms

2009-10-02 Thread Francisco José Núñez Rivera
But all the opinions have the same features.

Feature - id , desc
1,Feature 1 ; 2, Feature2...

Opinion shows all the features..
Feature 1 -Score:
Feature 2 - Score:

OpinionFeature - opinion_id , feature_id , score
I only insert a row here when im scoring a feature.

I think my schema is right... no?

Thank you very much.







2009/10/1 Abraham Montilla amontil...@gmail.com

 elkrema, if you have I have an Opinion with many Features then the right
 schema is

 Feature is: id, opinion_id, desc
 OpinionFeature is: opinion_id, score

 that's why you have an integrity constraint violation I don't know how
 i missed that first time i read your post hehe, that's all the problem

 2009/10/1 elkrema elfra...@gmail.com


 With unsetting only option id doesn't work.

 The problem is that i am inserting the object of main form and the
 embedded objects too.

 But i found a solution... I rewrite the function saveEmbeddedForms in
 OpinionForm

  public function saveEmbeddedForms($con = null, $forms = null)
  {

foreach($this-getEmbeddedForms() as $opinionForm)
{

  $opinionForm-getObject()-setOpinionId($this-getObject()-getId
 ());
}


parent::saveEmbeddedForms($con, $forms);
  }

 I set the opinionid before saving the embed formsI dont know if is
 the good way..

 Otherwise i have a new problem..

 when i'm editing an opinion the value of the last feature is not
 showed.. ¿?

 Thank you!






 On 30 sep, 07:21, Abraham Montilla amontil...@gmail.com wrote:
  try just unsetting opinion_id, tell me if works
 
  2009/9/29 elkrema elfra...@gmail.com
 
 
 
 
 
   Hello Abraham,
 
   This is my code with i'm embedding forms in OpinionForm:
 
   foreach($this-getObject()-getFeatures() as $feature)
   {
$opinionf = new OpinionFeature();
$opinionf-setOpinionId($this-getObject()-id);
$opinionf-setFeatureId($feature-getId());
$this-embedForm($feature-getName(), new OpinionFeatureForm
   ($opinionf));
   }
 
   With this code in when saving always get this flash message in the
   first Feature...
 
  * Feature id: Invalid.
 
   And if i configure OpinionFeatureForm to unset the fields (just for
   testing)
 
  unset($this['opinion_id'], $this['feature_id']);
 
   I get ..
 
   SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or
   update a child row: a foreign key constraint fails
   (`opinion`.`opinion_feature`, CONSTRAINT `opinion_feature_ibfk_1`
   FOREIGN KEY (`opinion_id`) REFERENCES `opinion` (`id`) ON DELETE
   CASCADE)
 
   Thank you for helping
 
   On 29 sep, 01:25, Abraham Montilla amontil...@gmail.com wrote:
i think it's because when embedding the OpinionFeatureForms you're
 not
setting properly the foreign key to the objects, would be something
 like
 
for ( $i  . ){
$opfeat = new OpinionFeature();
$opfeat-setOpinionId($this-getObject-getId());
$OFform = new OpinionFeatureForm($opfeat);
$this-embedForm('Feature_'.$i, $OFform);
 
}
 
2009/9/28 elkrema elfra...@gmail.com
 
 Hello
 
 i have some problems with my embed forms and i can't find a
 solution...
 
 I have an Opinion with many Features..
 
 Feature is: id, desc
 OpinionFeature is: opinion_id, feature_id,score
 
 In OpinionForm i'm inserting with [for each] all the features, but
 when im creating a new opinion i always get [Integrity constraint
 violation]
 
 I'ts easy get the id of the feature but i can get the ID of the
 opinion because it isnt created yet... is null.
 
 Somebody can help me please? I get trought many forums and jobeet
 tutorial but i cant get the solution!
 
 PS. Sorry for me english!!
 
--
Have a nice day.
Abraham Montilla.
 
  --
  Have a nice day.
  Abraham Montilla.




 --
 Have a nice day.
 Abraham Montilla.

 


--~--~-~--~~~---~--~~
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] Filling widget selects with sfWidgetFormPropelChoice method

2009-08-21 Thread Francisco Calderón

Hi, im having some trouble with a select widget, i have 2 selects to
fill, one from a different table

i have a main_table and it have one field for each select, table_a_id
and table_b_id,

The problem is when i try to use that form to edit the one record from
main_table, i fill the first one in the Form Class like this

$this-widgetSchema['table_a_id'] = new sfWidgetFormPropelChoice(array
(
  'model' = 'TableA',
  'add_empty' = true,
));


it works fine, now i need to fill the other select with the data from
the table_b asociated with the table_a, like this

$this-widgetSchema['table_b_id'] = new sfWidgetFormPropelChoice(array
(
  'model' = 'TableB',
  'add_empty' = true,
  'criteria' = TableBPeer::getDataCriteria(1)
));



TableBPeer::getDataCriteria() is wroking with the 1 but i need to
send to that function the table_a_id value cause there is a relation
between the table_a with table_b

i've tried everything, things like this $this-widgetSchema['TableA']-
getValue() but nothing works, somebody knows how could i do this?

Thanks in advance.

Francisco Calderón

--~--~-~--~~~---~--~~
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] about custom query with criteria (postgis)

2009-08-14 Thread Francisco Calderón

Hi everybody, im new using symfony, im working in a GIS project, with
PostGIS, and i need to make a custom query like this:

SELECT b.gid, b.name FROM a, b WHERE a.the_geom  b.the_geom AND
a.gid=2

the problem is the operator , i add it in the begining of the
Criteria Class with other operator

const INTERSECTA = ;

and after that did this:

$criteria = new Criteria();
$criteria-add(APeer::THE_GEOM, BPeer::THE_GEOM,
Criteria::INTERSECTA);
$this-sectoresList = BPeer::doSelect($criteria);

do not work, then i saw in the Criteria class the function addJoin
receive an operator and i tried:

$criteria = new Criteria();
$criteria-addJoin(APeer::THE_GEOM, BPeer::THE_GEOM,
Criteria::INTERSECTA);
$this-sectoresList = BPeer::doSelect($criteria);

and nothing, which would be the best way to make this query work with
propel? there is a way to send the bare sql query? is it a good
practice?

Thanks in advance

Francisco Calderón

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---