Yii Framework Forum: Adding A "back To List" Button In The Crud Generated Forms - Yii Framework Forum

Jump to content

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

Adding A "back To List" Button In The Crud Generated Forms

#1 User is offline   dannythebestguy 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 39
  • Joined: 27-June 12

Posted 07 November 2013 - 01:58 PM

Was wondering if it will be a Good idea to add "Back to List" Button in the create, update and view pages of the CRUD.

For example,

When a User clicks on the create page and changes his mind then there is no button for him to take back to the index or list page. He can always do it from the top Breadcrumb link. But what if the breadcrumb is to be hidden in the UI design.

Also in the Update page, What if the user wants to go back without updating anything.

Thnx

Dinesh
0

#2 User is offline   chandran 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 495
  • Joined: 08-October 12
  • Location:Austria

Posted 08 November 2013 - 04:35 AM

Hi,

I hope it will help.. cheers.

For go back to listarray('label'=>' Back to List', 'url'=>array('admin'))

for just one page back
array('label'=>yii::t('deutsch','back'), 'url'=>empty(Yii::app()->request->urlReferrer)?'#':Yii::app()->request->urlReferrer,),
Thanks
chandran nepolean

My own extension:
http://www.yiiframew...sion/ejqueryte/

My wiki
http://www.yiiframew...checkboxcolumn/

If it work dont hesitate to click +1 button
0

#3 User is offline   nineinchnick 

  • Master Member
  • PipPipPipPip
  • Yii
  • Group: Members
  • Posts: 622
  • Joined: 12-September 11
  • Location:Bialystok, Poland

Posted 08 November 2013 - 07:33 AM

Just create a custom template for gii.
Don't be a dick.
0

#4 User is offline   dannythebestguy 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 39
  • Joined: 27-June 12

Posted 08 November 2013 - 12:53 PM

Thnx for the inputs.

Chandran,it was a suggestion to the Dev team to include it in the Gii so that one has to not add the link.
0

#5 User is offline   CeBe 

  • Advanced Member
  • Yii
  • Group: Yii Dev Team
  • Posts: 534
  • Joined: 16-July 10
  • Location:Berlin. Germany

Posted 09 November 2013 - 03:35 AM

You have a link in the breadcrumbs that brings you back to the list.
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