? And I am using restful_authentication ..so I have that
@current_user as well..
Thanks,
Shahroon
On Wed, Jun 10, 2009 at 5:58 PM, Matt Darby m...@matt-darby.com wrote:
On Jun 9, 9:09 am, shahroon ali shahroon@gmail.com wrote:
Hi All,
I am going to use restful_acl in my
On Jun 9, 9:09 am, shahroon ali shahroon@gmail.com wrote:
Hi All,
I am going to use restful_acl in my application on every record in
simple words i want to implement record based acl. I explored restful_acl
and I applied it too, but so for I am not successful in doing so.
I
tired for finding
out the solution.
Thanks Regards,
Shahroon
On Sat, Jan 17, 2009 at 6:31 PM, Matt Darby m...@matt-darby.com wrote:
RESTful_ACL requires the variable current_user to be present and
define the active user. This is the only real requirement.
On Jan 16, 5:45 am, shahroon ali
Thanks for using RESTful_ACL!
What you're trying to do is simple with v2.0+:
class Profile ActiveRecord::Base
logical_parent :number
belongs_to :number
# This method checks permissions for the :index action
def self.is_indexable_by(user, parent = nil)
user.number == parent
end
Jm Freitas wrote:
Many thanks for the reply, issue solved!!!
Keep up with the good work :)
1. Awesome.
2. Thanks ;)
--
Posted via http://www.ruby-forum.com/.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Ruby
RESTful_ACL requires the variable current_user to be present and
define the active user. This is the only real requirement.
On Jan 16, 5:45 am, shahroon ali shahroon@gmail.com wrote:
Hi All,
I have restful_authentication with restful_acl installed on my
app, now I want to use
shahroon ali wrote:
Yeah I checked it was installed properly, there was no error in
installing
it, i was just mistaken.
I wrote RESTful_ACL; are you using restful_authentication (like followed
their directions), or did you just install it a plugin?
This error indicates that you're not
Say I have this setup:
class Ticket ActiveRecord::Base
belongs_to :project
end
map.resources :projects do |p|
p.resources :tickets
end
How would I go about programatically figuring out that Ticket is
nested under Project?
--~--~-~--~~~---~--~~
You received
Future reference:
def get_parent_resource(target_klass, path)
# Convert the requested path into hash form
hash = ActionController::Routing::Routes.recognize_path
(path, :method = :get)
# Loop through path keys and see if any end in '_id' and our kid
class belongs_to the
Thanks for your help, it seems to have been having the hidden elements
outside a td.
I wouldn't think that having hidden elements outside a cell (but still
in the form) would be invalid, but then again, I didn't explicitly
validate.
Thanks for your help ;)
My app has a timesheet, which is a collection of many TimeCards, based
on a Date.
I have one user that can create new TimeCards just fine, except on
three associated Jobs. Each time he saves he gets a 500 error.
Looking at the params, they come across jumbled and my processing
method chokes:
On Dec 29, 9:50 am, MaD mayer.domi...@gmail.com wrote:
did you check if it is rendered correctly? whats your html output for
that code?
Yep, it renders correctly (below); as noted, it works for all but one
user...
tr class='entry'
input id=time_cards__time_card_date name=time_cards[]
honestly: this seems strange. some points to start looking for an
answer:
- are you able to reproduce the error, if you login as that user?
- what about that user? does he have any 'special qualities' (like:
has special rights or uses lynx to access the site *g*)?
- does your session
Anyone else by chance? It really seems like this is a lower level
error...
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Ruby
on Rails: Talk group.
To post to this group, send email to
Those first three fields are not enclosed in a cell.
That may cause IE to send the parameters in the wrong order.
Please log and post the raw_post string.
Ahh, IE, my old friend. Perhaps this is why I wasn't able to recreate
it.
Here is the raw POST:
Processing TimeCardsController#day (for
I have a timesheet in my app that simply displays the week range
based on a passed in date (params[:date]).
The view iterates through the Date::ABBR_DAYNAMES and shows a link to
the corresponding date.
Trouble is that about 40% of the time the calculated dates go bonkers.
Am I missing something?
What do you pass to get_work_week_date_range? Is it a string? Or an
instance of Date? Or Time?
I pull the date in from the params hash, and immediately parse it to a
Date:
Date.parse(params[:date]) rescue Date.today
If it worked once it should always work. Which suggests that maybe
Perhaps the key thing to note is that 1772-05-19 is about 236 years
and 7 months ago, which (get your calculators out) is about 86400, ie
the number of seconds in a day. Whereas on an instance of Time, +/- 1
means +/- 1 second, on instances of Date/DateTime +/- means +/- 1
second. That is I
It was the facets/time library. It was loaded in a totally separate
part of the app, in a method that had not much to do with anything.
Thanks again Frederick; that one got your a WWR recommendation ;)
--~--~-~--~~~---~--~~
You received this message because you
19 matches
Mail list logo