Yii Framework Forum: Submit Multiple Rows In One Table - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Submit Multiple Rows In One Table Rate Topic: -----

#1 User is offline   Tris 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 09-December 12

Posted 09 December 2012 - 02:03 AM

Hello, I'm a newbie so please forgive if my question is silly
I have 2 tables.
+ Bill(bill_id, order_id, create_date)
+ Bill_detail(bill_id, product_id, product_seri, status)
(1 to many relationship)

+ Order_detail(order_id, product_id)

Now I created the form that
- foreach product in order_detail(within one order), i created an input field for product_seri
then I click submit

for example:
-In order 1
Product:A Seri:AXC
Product:A Seri:BXD
Product:B Seri:TTT

Then I click submit, But the $Post['Bill_detail']['Seri'] ony take the final value, TTT.

To sum up: How can I submit the same input field (with the same label in form) but different value to Server
0

#2 User is offline   softark 

  • Keep It Simple
  • Yii
  • Group: Moderators
  • Posts: 2,047
  • Joined: 16-February 11
  • Location:Japan

Posted 09 December 2012 - 02:29 AM

Hi Tris,
Welcome to the forum.

I hope this section of the guide will be a help.
http://www.yiiframew...1/en/form.table
0

#3 User is offline   Tris 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 09-December 12

Posted 09 December 2012 - 02:33 AM

Thanks softark. Been searching for this whole morning !!! :)
0

#4 User is offline   Nur Rochim 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 42
  • Joined: 04-February 13
  • Location:Indonesia

Posted 19 April 2013 - 02:00 PM

Good discussion. Thanks Softark and Tris
:rolleyes:
:rolleyes:
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users