Hi All,
I'm pretty new to ROR.
I got 3 tables:
Team, with columns name, world_ranking, star_player and img_url
Result with columns round, score and team_name
Player with columns first_name, last_name, position and player_number
my models relationships look like this
class Team
Hi Helpers,
I am new to Ruby in Rails and I have difficulty it
passing the instance varaibles to the view. Earlier I was reading the
values from the table directly in the view. Now I want to do that part in
controller
below is my code before changes
view
%=
In the index view of team write the code of index view of player and
select only the team players by @team.player:
table
tr
thName/th
thPosition/th
thNumber/th
/tr
% @team.players.each do |team_player| %
tr
td%= team_player.first_name % %= team_player.last_name
%/td
I have a many-to-many relationship in my course model in this way:
has_many :course_paragraphs
has_many :paragraphs, :through = :course_paragraphs
I use an inner join to select the paragraphs of my course:
Paragraph.joins(:course_paragraphs = :course)
The problem is with the domain name as loader.js tries to do a split on
the domain name. So if you are hitting the page localhost:3000 which has
the sharethis widget it will not show up as it cannot split localhost.
However if you map your machine(127.0.0.1) to something like a.b then
On Thursday, February 14, 2013 5:31:38 PM UTC-5, Nick Apperley wrote:
Managed to access the website by adding *Listen 1025* to the Apache
config file, and adding an entry to the hosts file. Have used a different
port for the website (in its VirtualHost entry). Port 80 is already taken
by
On 15 February 2013 10:05, Lorenz Blackbird li...@ruby-forum.com wrote:
I have a many-to-many relationship in my course model in this way:
has_many :course_paragraphs
has_many :paragraphs, :through = :course_paragraphs
I use an inner join to select the paragraphs of my course:
I have a technical problem. I will fix it today. Sorry for inconvenience.
Le 2013-02-14 08:33, Scott Eisenberg a écrit :
It's a good idea. Will try it.
Keep pushing the feature set!
On Feb 14, 2013, at 7:52 AM, Guirec Corbel guirec.cor...@gmail.com
mailto:guirec.cor...@gmail.com wrote:
On Fri, Feb 15, 2013 at 6:41 AM, Jim jim...@gmail.com wrote:
You can serve multiple sites from the same IP address and port if Apache is
set up correctly.
Or you can eliminate a whole lot of configuration nonsense by using
Pow (http://pow.cx/) for development :-) and simply access your app
Colin Law wrote in post #1097096:
Paragraph.joins(:course_paragraphs = :course)
.where('course_paragraphs.course_id' = @course.id)
You don't need to do that. If you have a course in @course then its
paragraphs are just @course.paragraphs. It is rare to have to use
joins when
sups wrote in post #1097037:
Hi Helpers,
I am new to Ruby in Rails and I have difficulty it
passing the instance varaibles to the view. Earlier I was reading the
values from the table directly in the view. Now I want to do that part
in
controller
below is my code before
On Feb 15, 2013, at 10:12 AM, Colin Law wrote:
On 15 February 2013 10:05, Lorenz Blackbird li...@ruby-forum.com wrote:
I have a many-to-many relationship in my course model in this way:
has_many :course_paragraphs
has_many :paragraphs, :through = :course_paragraphs
I use an inner join
I have answered you in there.
On Sunday, 10 February 2013 09:07:17 UTC+1, Gjaldon wrote:
Hi all, I just posted a question on SO and it would be great if you guys
could help out.
I have answered you in there.
On Sunday, 10 February 2013 09:07:17 UTC+1, Gjaldon wrote:
Hi all, I just posted a question on SO and it would be great if you guys
could help out.
Found via google. I made a quick script for this. Sorry for reviving..
class TrueClass
def to_s(style = :boolean)
case style
when :word then 'yes'
when :Word then 'Yes'
when :number then '1'
else 'true'
end
end
end
class FalseClass
def to_s(style =
I am building a small website. I want to have a scrolling window of news
headlines, where you click on the headline and a page with a copy of the
press release get s displayed.
I don't want to run a db, so is there anyway to predefine the relationships
between headline and the text file?
On Fri, Feb 15, 2013 at 8:13 PM, xscr...@gmail.com xscr...@gmail.com wrote:
I am building a small website. I want to have a scrolling window of news
headlines, where you click on the headline and a page with a copy of the
press release get s displayed.
I don't want to run a db, so is there
Hi,
I have posted a question on SO. It would be great if anyone could help me
out.
http://stackoverflow.com/questions/14907316/how-to-catch-missingtitle-error-for-media-wiki-gem
--
Thanks and Regards
Prateek Papriwal
B.Tech, Electrical
IIT Delhi
--
You received this message because you are
18 matches
Mail list logo