Sunday, August 2, 2015

Re: same field in two classes

You can use inheritance. Or content type. Or use signals to get the value of salary from one model and save it to another model.

On 2 Aug 2015 23:38, "Alex Heyden" <mindsbreath@gmail.com> wrote:
Sorry, I think there might be a bit of a language barrier. What do you mean by "take the value of employee salary to payroll salary?"

On Sun, Aug 2, 2015 at 12:12 PM, Giovanny Vizcaya <gio.vizcaya.666@gmail.com> wrote:
Good day,i'm new in django and i'm doing a project, i have a class "Employee" with atribute "salary", same time i have class "Payroll" with atribute "salary", how can i take the value of employee salary to payroll salary? thank you in advance for answers

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/5a479e43-4612-4b2e-92be-638b5eec9124%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CA%2Bv0ZYWmYsUj1v_q2h4ooK7u_UyrntYqzKGjB00FK3e6s410Zg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CA%2B4-nGqBBk-qYhVWKAeCqMv65A3-z%3DSb6LF6Be72nodi01Zmnw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment