Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Ayuda con "has_and_belongs_to"
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  3 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
~Albert  
View profile   Translate to Translated (View Original)
 More options Apr 22 2012, 6:12 pm
From: ~Albert <soyalbertgar...@gmail.com>
Date: Sun, 22 Apr 2012 15:12:17 -0700 (PDT)
Local: Sun, Apr 22 2012 6:12 pm
Subject: Ayuda con "has_and_belongs_to"

Hola, estoy desarrollando una aplicación para la universidad, tengo dos
tablas una de Modulos y otra de Perfiles, la relación es: *Un perfil puede
tener muchos módulos y un módulo puede estar en muchos perfiles*, les
agradecería que me colaboraran con esta relación que no se como hacer en
los modelos de KumbiaPHP.

He leído sobre una aplicación de ejemplo llamada: *treeGrid, *pero no la
veo por ningún lado, no se de donde descargarla.
Si pudieran darme un ejemplo de código, les estaré muy agradecido.

Gracias a todos por su ayuda.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
HenrySAM  
View profile   Translate to Translated (View Original)
 More options Apr 23 2012, 8:58 pm
From: HenrySAM <maxter2...@gmail.com>
Date: Mon, 23 Apr 2012 17:58:07 -0700 (PDT)
Local: Mon, Apr 23 2012 8:58 pm
Subject: Re: Ayuda con "has_and_belongs_to"

Hola,

Siendo estrictos con la normalización de base de datos, no pueden existir
relación muchos a muchos y se debe descomponer añadiendo una tabla que las
relacione.

Por ejemplo:

modulos
*modulos_perfil*
perfil

Entonces modulo_perfil sus campos son:

*modulos_perfil*: id, modulos_id, perfil_id

Aquí hay una app similar ejemplo:
https://github.com/KumbiaPHP/backend_kumbia/tree/bootstrap_2/app/models

Es una respuesta rápida espero te ayude.

El domingo, 22 de abril de 2012 17:12:17 UTC-5, ~Albert escribió:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
~Albert  
View profile   Translate to Translated (View Original)
 More options Apr 24 2012, 12:14 am
From: ~Albert <soyalbertgar...@gmail.com>
Date: Mon, 23 Apr 2012 21:14:41 -0700 (PDT)
Local: Tues, Apr 24 2012 12:14 am
Subject: Re: Ayuda con "has_and_belongs_to"

Hola Henry,

Muchas gracias por responder, sin duda el ejemplo me será muy útil, aún así
veo que la implementación es muy manual, quisiera saber entonces que
sentido tiene la función *has_and_belgons_to* de la cual leí que existe
precisamente para representar la relación N:M.

Gracias por tu ayuda.

El lunes, 23 de abril de 2012 19:58:07 UTC-5, HenrySAM escribió:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »