search for: user_page

Displaying 20 results from an estimated 24 matches for "user_page".

Did you mean: user_pages
2006 Apr 06
3
scaffold question
...ngs on a scaffold that i would like to use without the whole thing. is it better to generate one and then cut it down to only what you''ll use? are all of the things in a scaffold available to just build by hand? for instance, i have a scaffold for my users. in the list action, it has @user_pages, so that you can put @user_pages.current.next or something like that - is that something i can do with any of my model automatically just by having @model_pages in the action? -- Posted via http://www.ruby-forum.com/.
2007 Jul 19
2
Transform URLs from: "url.com/Bob+Doe" to "url.com/bob_doe"
Is that possible, and would you know how I can do that? I''m creating individual pages for users based on their first and last names. In my routes.rb, I have: map.client '':user_full_name'', :controller => ''user'', :action => ''individual_user_page'' Then in my controller, I have: def individual_user_page @user = User.find(:first, :conditions => [''first_name = ?'', params[:user_full_name]]) render :layout => "user_page" end Right now, the url is in this format: "url.com/Bob+Doe"...
2016 Nov 25
3
[PATCH 0/3] virtio/vringh: kill off ACCESS_ONCE()
On Fri, Nov 25, 2016 at 04:21:39PM +0100, Dmitry Vyukov wrote: > > READ/WRITE_ONCE imply atomicity. Even if their names don't spell it (a > function name doesn't have to spell all of its guarantees). Most of > the uses of READ/WRITE_ONCE will be broken if they are not atomic. In practice, this is certainly the assumption made by many/most users of the *_ONCE() accessors.
2023 Feb 16
0
[RFC PATCH v1 07/12] vsock/virtio: MGS_ZEROCOPY flag support
On Mon, Feb 06, 2023 at 07:00:35AM +0000, Arseniy Krasnov wrote: >This adds main logic of MSG_ZEROCOPY flag processing for packet >creation. When this flag is set and user's iov iterator fits for >zerocopy transmission, call 'get_user_pages()' and add returned >pages to the newly created skb. > >Signed-off-by: Arseniy Krasnov <AVKrasnov at sberdevices.ru> >--- > net/vmw_vsock/virtio_transport_common.c | 212 ++++++++++++++++++++++-- > 1 file changed, 195 insertions(+), 17 deletions(-) > >diff --git a/...
2006 Apr 26
1
List shows always first page
...39;'s fine except that the pagination. Be default the list shows 10 records per page. I clicked "Next Page" and the page refreshed but the data is still same as the first page. The URL shows page=2 parameter. I opened the controller code and found the following code. def list @user_pages, @users = paginate :users, :per_page => 10 end I changed 10 to 100 and the page showed 100 records but still the 2nd page showed the 1st page. Did I miss something? Or should I add code to make the pagination work? Thanks. Sam -- Posted via http://www.ruby-forum.com/.
2006 Mar 31
2
Silly question
Hi there, I know this is be a very minor issue, but considering @users = User.find :all, :order => ''name'' _AND_ @user_pages, @users = paginate :user, :order_by => ''name'' by simplicity, shouldn''t the symbols :order and :order_by be the same or both to both cases ? I stumbled on them a couple of times yet :) Thanks, Andre -- Posted via http://www.ruby-forum.com/.
2006 Jan 24
1
Pagination
Hello, maybe that I''m a stupid, but I don''t know how I can working with pagination. In all examples is written (for example) next: def user_list @user_pages, @users = paginate(:users, :order_by => ''name'') end So, it''s OK (as a scaffold) for all set of users. But I need a little other functionality. For example I need paginate only a little bit of this set. I have sort user by their function in laboratory and I don'...
2016 Nov 25
3
[PATCH 0/3] virtio/vringh: kill off ACCESS_ONCE()
...time.c:297:18: note: in expansion of macro ?ACCESS_ONCE? time_t result = ACCESS_ONCE(gtod->wall_time_sec); kernel/events/ring_buffer.c:160:10: error: call to ?__compiletime_assert_160? declared with attribute error: Need native word sized stores/loads for atomicity. tail = READ_ONCE(rb->user_page->data_tail); kernel/events/core.c:5145:16: error: call to ?__compiletime_assert_5145? declared with attribute error: Need native word sized stores/loads for atomicity. aux_offset = ACCESS_ONCE(rb->user_page->aux_offset); ^ kernel/events/core.c:5146:14: error: call to ?_...
2016 Nov 25
3
[PATCH 0/3] virtio/vringh: kill off ACCESS_ONCE()
...time.c:297:18: note: in expansion of macro ?ACCESS_ONCE? time_t result = ACCESS_ONCE(gtod->wall_time_sec); kernel/events/ring_buffer.c:160:10: error: call to ?__compiletime_assert_160? declared with attribute error: Need native word sized stores/loads for atomicity. tail = READ_ONCE(rb->user_page->data_tail); kernel/events/core.c:5145:16: error: call to ?__compiletime_assert_5145? declared with attribute error: Need native word sized stores/loads for atomicity. aux_offset = ACCESS_ONCE(rb->user_page->aux_offset); ^ kernel/events/core.c:5146:14: error: call to ?_...
2006 Jul 05
3
list of users
...;'m not getting the list of projects done by each user.. This is my code:: <% for user in @users %> <%=link_to user.login,:action=>"list",:controller=>"projects",:id=>user.id%> <%end%> In the controller def list @user = User.find_all @user_pages, @users = paginate :user, :per_page => 20 end This is the error when i click on the user:: You have a nil object when you didn''t expect it! You might have expected an instance of Array. The error occured while evaluating nil.[] Could any please help?? -Harish -- Posted via ht...
2006 Aug 01
3
paginate, search, sort with ajax problem
hello I hope somebody can help me figure this out. found this great tutorial at http://dev.nozav.org/rails_ajax_table.html. got it working except for one thing. I can''t seem to make the pagination work. The link_to_remote defined in the helper is pointing to the wrong url. I have set up things like so: defined a search method in de project_controller located in apps/admin/project.
2006 Aug 12
0
Help needed in specifying conditions in pagination
Hi, In a controller, I add to the default list action a condition, thus: def list @user_pages, @users = paginate :users, :conditions => @query, :per_page => 10 end and @query is defined somewhere in the controller as @query = "user_name like ''%Smith%''" where user_name is an attribute of User. Result: The condition pulls out the whole table,...
2006 Jun 29
1
search action/ in different groups
...for group in @groups %> <input type=checkbox name=group#{group.id}> <% end %> </form> and then in my controller i put def index @users = User.find(:all) # annitiate the variable @groups = Group.find(:all) if params[:searchbar] != nil # no search @user_pages, @users = paginate :users, :include => :groups, :order => ''lastname'' , :per_page => 10 else # search done @groups.each {|group| if params["group#{id}"] == "on" #checbox is checked ass...
2006 Feb 15
0
Confused by this error when trying to use ''pagination''
Trying to create stuff without resorting to scaffold command. I have a list view in my login_controller.rb file... def list_users @user_pages, @users = paginate :users, :per_page => 14 end I have a command in my list_users.rhtml file which undoubtedly calls this pagination... <% odd_or_even = 0 for user in @users odd_or_even = 1 - odd_or_even %> and instead of being presented a list (like those that I started out with scaf...
2006 Jan 03
0
has_and_belongs_to_many include problem
...id = " + @group_id.to_s + " and groups_users.group_id = groups.id and groups_users.user_id = users.id and users.last_name like ''%" + @last_name.to_s + "%'' order by users.last_name ASC, users.first_name ASC") i get an error on this (can anyone help me???) @user_pages, @users = paginate :user, :conditions => [''users.firm_id = ? and users.first_name like ? and users.last_name like ?'', @firm_id, "%#{@first_name}%", "%#{@last_name}%"] ,:include => [:groups], :order_by => "users.last_name ASC, users.first_name ASC...
2006 Jan 04
1
Passing parameters along
...list comes back around do display page 2, it still remembers what conditions we are using? Assuming that I have to pass them explicitly, is there a shorthand way to simply say "take everything that''s already in params"? I tried this: link_to "Next", { :page => @user_pages.current.next, params } in the hopes that it would just append params onto the list, but got a syntax error. Duane -- Posted via http://www.ruby-forum.com/.
2006 Jul 27
1
response from ajax request
...partial template have been stripped, leaving only the elements inserted via the <%= statements. I would appreciate any hints. Best, Eric here is the controller action that responds to the ajax request: =============================== def find_users @user_is_admin = is_admin @user_pages, @users = paginate :users, :order_by => ''login'', :per_page => 10, :conditions => "name like ''%kyle%'' or children like ''%kyle%''" # add error checking later render :partial => "listing_table", :la...
2019 Jul 25
0
[PATCH 00/12] block/bio, fs: convert put_page() to put_user_page*()
On 7/24/19 12:25 PM, john.hubbard at gmail.com wrote: > From: John Hubbard <jhubbard at nvidia.com> > > Hi, > > This is mostly Jerome's work, converting the block/bio and related areas > to call put_user_page*() instead of put_page(). Because I've changed > Jerome's patches, in some cases significantly, I'd like to get his > feedback before we actually leave him listed as the author (he might > want to disown some or all of these). > Could you add some background to the commit...
2019 Jul 24
20
[PATCH 00/12] block/bio, fs: convert put_page() to put_user_page*()
From: John Hubbard <jhubbard at nvidia.com> Hi, This is mostly Jerome's work, converting the block/bio and related areas to call put_user_page*() instead of put_page(). Because I've changed Jerome's patches, in some cases significantly, I'd like to get his feedback before we actually leave him listed as the author (he might want to disown some or all of these). I added a new patch, in order to make this work with Christoph He...
2019 Jul 24
20
[PATCH 00/12] block/bio, fs: convert put_page() to put_user_page*()
From: John Hubbard <jhubbard at nvidia.com> Hi, This is mostly Jerome's work, converting the block/bio and related areas to call put_user_page*() instead of put_page(). Because I've changed Jerome's patches, in some cases significantly, I'd like to get his feedback before we actually leave him listed as the author (he might want to disown some or all of these). I added a new patch, in order to make this work with Christoph He...