search for: brutyn_nick

Displaying 20 results from an estimated 27 matches for "brutyn_nick".

2005 Dec 19
6
how to do security??
hey, i have maded some security in my website based on http://www.chaconforcongress.com/accounts/login Here they work with users, roles and persmission, and they check it like this, user.has_permission(permission). I have extended this to: users and groups with roles and permissions. With permissions like "view records","edit records","delete records",... def
2006 Jan 23
1
Help with hmabt relationships
hey, I want to have this table structure with users and groups A user can be in more than 1 group and a group has more than 1 user. class User < ActiveRecord::Base has_many_and_belongs_to :groups end class Group < ActiveRecord::Base has_many_and_belongs_to :users end I was wondering if i can do this for group in user.groups ...do stuff end -AND- for user in group.users ...do stuff end
2005 Dec 21
1
how to sort records??
hey, ยต i have these records in my database, in a many-to-many relationship clients_users 1;66 2;66 3;66 5;66 6;66 7;66 8;66 14;66 15;66 16;66 17;66 18;66 19;66 20;66 21;66 22;66 clients 1;VME Complex Foster 2;VME Res. Canada 3;Twodecode 5;Index 6;Verleye bvba 7;Venus bvba 8;All Building Services nv 14;Vitro-Service sa 15;Vitro-Clean 16;Vecom nv 17;Ultra lean bvba 18;Solar Cleaning Services nv
2005 Dec 21
2
what is print_r in rails
hey, i know u have in php print_r or echo, so that the browser print the variable on top of page, no matter what what is this in rails?? put doesnt seem to work Thanks Nick
2005 Dec 15
3
How to delete a record
hey, i my database i have users and groups, each user can get in different groups my db structure: table groups: id, name, basegroup, firm_id table users: id, firstname, lastname, email table groups_users: group_id, user_id my relation is a many to many: class Group < ActiveRecord::Base has_and_belongs_to_many :users end class User < ActiveRecord::Base has_and_belongs_to_many
2005 Dec 29
3
Post problem with select lists
hey, i have this problem how come i always get -1 for the select list?? rhtml First, select a client. <select id="client_id" name="client[id]" onChange="submit();" > <%= options_for_select(@client_options, @client_id.to_i) %> </select><%= @client_id %> controller if @request.post? if @request.xml_http_request? #called by ajax,
2006 Nov 04
0
filter function with parameter
hey, i have found your post about filter function with parameters: Hi! I want to add a function with a static paramter ("2" in the example) to a filter, but somehow Rails seems to be looking for another syntax. before_filter :check_quantity(2), :only => [:show] doesn''t work. What''s the right way to do this? Thanks a lot! --------------------------------- Can
2006 Feb 06
0
Spreadsheet problems
Hey, I want to regenerate a excel spreadsheet and send it to the browser. The excel sheet does maybe have 5 tabwindows and a lot of formulas. I use to make spreadsheet just for exporting records, but that was just making a rhtml with ";" as delimiter and set @headers["Content-Type"] = "application/vnd.ms-excel;charset=iso-8859-1" I have tried spreadsheet-0.3.2
2006 Jan 03
0
has_and_belongs_to_many include problem
hey, i have users who are in groups, and i have a search form, where i can search on group, user lastname, and user firstname. All this is also with pagination. these are my models class User < ActiveRecord::Base has_and_belongs_to_many :groups end class Group < ActiveRecord::Base has_and_belongs_to_many :users end in my controller i do this THIS works (but in need pagination) @users2
2006 Jan 04
1
Rails and document managament
hey all, does anyone know any good rails document managament system or good blog? thanks Nick.
2006 Jan 09
0
bugs in generated drag and drop js (ajax)
hey, i have a site with ajax, i made a blank project with rails 1.0, putted all my pages in thier, and while testing the drag and drop doesnt work correct anymore. this is my problem i get: i have select a item from a select list, and then the popup jump a bit to the bottom right. Now i have just copied my old js files over the generated ones, and now it works fine. Anyone has also this
2006 Jan 23
1
How to call C# webservices
hey, i have created some webservices in C# with vb.net and IIS. i can go to them with http://localhost/Twodecode.Webservices/webservices.asmx Like: [Webservice] AddCity(string zip, string city) { ...do some stuff return "SUCCES"; } How must i call this from ruby?? I save an object, and then call the services. city = City.new() if city.save //call webservice else //do
2006 Jan 24
0
Calling webservices
Hey, I found this on the web. http://groups.google.be/group/comp.lang.ruby/browse_thread/thread/1e4015385d29fbae/1c75bbd325fffd80?lnk=st&q=ruby+Server+did+not+recognize+the+value+of+HTTP+Header+SOAPAction&rnum=1&hl=nl&utoken=1E3jSjEAAABJvF0LfsU_y2vKQdUqO05-SuWh7Qp4TDjaLpMsabUfgs6vFyhVbm91Ec8wnlUJkMJ1cPkfXpSLv0-5C4lVNC3B ''A newbie query about Soap4R and dot net web
2005 Dec 14
0
Question about testing (chapter 12)
Hey, i have created my website, and i saw in the book about testing and stuff, started reading that, but a lot is over data, like the correct types and validation. In my website i have model validation and that works fine, i was wondering if with that testing my site would benefit more?? I know you should test first and then create the website, but i did that any way. Thanks Nick
2005 Dec 14
0
how to get these records in has_and_belongs_to_many relation
hey, i my database i have users and groups, each user can get in different groups my db structure: table groups: id, name, basegroup, firm_id table users: id, firstname, lastname, email table groups_users: group_id, users_id my relation is a many to many: class Group < ActiveRecord::Base has_and_belongs_to_many :users end class User < ActiveRecord::Base has_and_belongs_to_many
2005 Dec 22
0
conditions on model
hey, this is the situation, an user may only access x clients (ex , 1, 5 ,6 ,7), so i make a string with those ids and paste it to the sql statement, the user is from the session #creating a list of all the client record ids the user may access and paste it in the sql statement if user.has_permission(''admin'') || user.view_all == 1 text = "" else text =
2005 Dec 23
1
pagination problem
hey, i have this problem in the database i have 32 records and the sql filtered 4 records #getting the callerid records depending on the given paramaters and paginate it @callerid_pages = Paginator.new self, CallerId.count, 10, @params[''page''] @caller_ids = CallerId.find(:all, :conditions =>["geotags.firm_id = ? ", @firm_id], :order => " geotags.address1
2005 Sep 28
0
search engine, select the selected option
hey, i have a search engine that let u search on the an employee how can i make that if the user select "employee1" , on the next page "employee1" is selected this is my code (rhtml) <tr> <td><label for="employee_id">Employee</label></td> <td colspan="3"><%= select "employee", "id",
2005 Oct 19
1
TZInfo::Timezone problem selected value
hey, i have a record in the database gtm_zone with value ''Europe/London'' i want to have a select box with all the zones and the corrected selected @firm.gmt_zone = Europe/London TimeZone from ruby (trying to expand with TZinfo) dont want to select Europe/London, and not sorted <select id="firm_gmt_zone" name="firm[gmt_zone]"> <%=
2005 Dec 01
0
problem with options_from_collection_for_select() need id not name
hey, i need a select list with a id property and not name, cuz i just ajax with this list and it checks on id not name if @request.post? #called by ajax if @request.xml_http_request? #called by ajax @geotag_id=params[:geotag_id].nil? ? -2 : params[:geotag_id] else @geotag_id=params[:geotag][:id].blank? ? -1:params[:geotag][:id] end else @geotag_id = -1 end i use this @geotags =