⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

unset_list



KaBaDaBrA

KaBaDaBrA
  • profile picture
  • Member

Posted 24 March 2012 - 21:43 PM

Hi :)

Another arb request - anyway there is a unset_list() method? Basically the user will only be able to see the edit page and edit / view his data here. I ahve already unset the delete and add. I used jQuery to hide the "Back to list" text but was wondering if there is a built in function? Or do you see this is rather useless :P

EDIT: Oh ya also when you press cancel to change the redirect URL?

thanks!!!! :D

web-johnny

web-johnny
  • profile picture
  • Administrator
  • 1,166 posts

Posted 25 March 2012 - 12:33 PM

No it is not useless. Even me sometimes I am so boring to create for example an email form and I use grocery CRUD for this with a callback to send email :) .

It was just that it was not so quick to do as I need to remove the back to list go back on update, the cancel button and small things like that. Perhaps I will add it to the next version , we 'll see. It always depends of how much time I have.

Thanks

KaBaDaBrA

KaBaDaBrA
  • profile picture
  • Member

Posted 25 March 2012 - 17:17 PM

True man and you have done sooooooo much! THANKS!!!!!!!

I did something like this for now to force them to always see the edit page:


if($this->uri->segment(4) != $this->Globals->get_client_id()) {
redirect('profile/index/edit/'.$this->Globals->get_client_id());
}


The delete and add have been unset, and if it doesn't detect an ID in the URI then it forces to redirect. This for now solves me needs. I totally get you on the laziness part haha....Grocery CRUD has changed the way I do things now :P time is valuable - quicker code gets done the better!!!! :D

Luan

Luan
  • profile picture
  • Member

Posted 27 March 2012 - 03:19 AM

Another thing missing is a unset_field, since we have unset_colums.
Gotta write a lot of fields or make the ones i dont want hidden.

Im also ansious for the READ part in the groceryCRUD(native). As soon as i get my international credit card(and some money), i will surelly make a donation for your project.

Thanks for the work! I appreciate it.

web-johnny

web-johnny
  • profile picture
  • Administrator
  • 1,166 posts

Posted 27 March 2012 - 19:24 PM

Thanks [member='Luan'] I really appreciate it.

And yes you are right. The unset_field, unset_add_field and unset_edit_field will be useful too. Not promising anything but probably will be at the next version .

web-johnny

web-johnny
  • profile picture
  • Administrator
  • 1,166 posts

Posted 27 March 2012 - 20:34 PM

Well I couldn't wait!

Here is your unset_add_fields, unset_edit_fields and unset_fields - https://github.com/s...0b87a70e304228f

I think you don't need any documentation for how to use it. ;)

Luan

Luan
  • profile picture
  • Member

Posted 28 March 2012 - 03:40 AM

[quote name='web-johnny' timestamp='1332876276' post='958']
Not promising anything but probably will be at the next version .
[/quote]

1 Hour later... Here is your(not mine, maybe our?) unset_add_fields, unset_edit_fields and unset_fields - https://github.com/s...0b87a70e304228f

Im already using it, hehe. Thanks for the attention.