Displaying 20 results from an estimated 100 matches similar to: "Newbie question: undefined method 'number_with_delimiter'(probably configuration problem)"
2006 Feb 28
4
number_to_currency UK pounds
I work in the UK and therefore most of my currency figures will be in UK
pounds. I realise that to format a number to a currency format I can
use:
number_to_currency(amt, :unit => "?")
but it would be more convenient to set ? as the default currency symbol.
What is the best way to do that?
Should I edit line 39 of this file:
2006 Jan 24
7
formatting numbers with commas
I needed to format numbers with commas to make it more human
readable. Here''s how I did it.
def commify(number)
c = { :value => "", :length => 0 }
r = number.to_s.reverse.split("").inject(c) do |t, e|
iv, il = t[:value], t[:length]
iv += '','' if il % 3 == 0 && il != 0
{ :value => iv + e, :length =>
2006 May 02
2
Autotest doesn''t work on WinXP?
When I try to run autotest (zenspider) (which looks VERY cool), I get this
error:
(run from within a Rails app directory)
C:\ruby_home\analysis>autotest -rails
# Testing updated files
+ c:/ruby/bin/ruby -Ilib:test -e ''["test/unit/user_test.rb",
"test/unit/role_test.rb"].each { |f| load f }'' | unit_diff -u
''c:'' is not recognized
2007 May 12
4
Multiply and format with thousands separator
I have just started with Ruby and Rails and am still greatly confuse,
finding the usual tutorials not much help.
What I want to do is take two numbers from my database, multiply them
together and display them in a list with a comma for the thousands
separator. This would be very easy to do in a spreadsheet, so I assumed
it would be easy to do in Ruby on Rails but I can''t work out how.
I
2006 Apr 12
4
Instant Rails SCGI Problem
I have installed instant rails and configured it
http://instantrails.rubyforge.org/wiki/wiki.pl?Getting_Started
I can get typo and webrick to work on webrick localhost:3000 but cant
get anything to work with scgi.
When i start the scgi server i get a blank dos window screen. When i
type www.mycookbook.com into the browser i get the following
Unable to connect
Firefox can''t
2009 Sep 30
2
What is this view syntax? Old beast forum code...
Hey folks
A long time ago, before i started working at this company, we used a
Beast forum. The beast code (models, controllers and views) were all
just lumped in with our app code, but when we moved to a new version
(about a year and a half ago) the forum section of our site was closed
off (simply by not linking to it anywhere).
I''ve been tasked with resurrecting it, and the first
2008 Feb 20
1
text_field_tag - different parameter name
Hi, I have one problem with validation
I am creating e-shop and I have products. This view look like this:
<% for product in @category.products %>
<div class="produktyBox">
<%= product.title %><br />
Price: <br />
<div style="color:red; font-size:large; font-weight:bold; margin-
bottom:5px"><%=
2007 Dec 06
3
number_to_currency
I am using the number to currency function because i live in the uk and
the company want me to only show values of the pound of course.I have
created all my application using ruby script/generate
scaffold_resource.... I have come across with a problem... this code is
in my applcation:
def number_to_currency(number, options = {})
options = options.stringify_keys
precision, unit, separator,
2007 Oct 23
1
MGE Pulsar Ellipse 800 offearly or box shutdown late
I'm struggling to configuring nut for MGE Pulsar Ellipse 800 (at least
Ellipse 800) for two boxes - home firewall and file server. I'm using
Debian 4.0 Etch, every one of them.
I'm built (after some dangerouse experiments) a testing configuration,
where boxes are plugged to line, server playing as a master, firewall as a
slave, and UPS connected to an electric heater about 300 Wats (no
2006 Sep 06
1
WEBrick mime-type configuration
Does anyone know how I can get at the guts of how WEBrick handles
mime-types?
I have a suspicion that it is returning an incorrect mime-type in a
response.
Wes
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group,
2006 May 16
25
Ruby on Rails Searchable and Annotatable Docs
I recently updated my Rannotate application. The interface has been
completely redone and there are lots of new features. The basic idea is
to create searchable and user annotatable documentation for the Ruby on
Rails API (think php.net).
Check it out at - http://rails.outertrack.com
* What is Rannotate?
Rannotate is a Rails application and RDoc YAML generator that work
together to provide
2006 Feb 21
4
displaying double digits
Hi,
I have a question about displaying digits in Rails.
whenever I print the price of an item, if the last digit is a zero or
double zeros then it doesn''t display properly.
How do I display a number so that it looks like currency?
thank you!
--
Posted via http://www.ruby-forum.com/.
2023 May 27
2
unable to connect to APC UPS Connection Refused
I've not been able to connect to my ups using NUT 2.7.4 or NUT 2.8.0.
2.7.4 was installed as a package, 2.8.O was compiled from source.
I've messed with permissons, everything is root:root and has the approprate read/execute permissons. I've tried two differnt UPS(es) APC & CyperPower. I'm running PI OS (Raspbian) on a Raspberry Pi3 model B. The port 3493 is open (UFW). I can
2009 Jan 23
7
RubyOnRails with MS SQL - Connectivity Error
Hi all...
Please help me solve the issue.
While trying to create a connection with MS SQL database in RubyOnRails,
I''m getting a ‘Deprecated ..’ error. (I referenced a doc posted in net
for the same.)
System details: OS: Windows Xp
Ruby version: 1.8.6
Rails: 2.1.2
Gems: 1.3.1
RadRails: 0.7.2
2008 Dec 06
0
Problem in number_helper.rb ?
Hello,
Today I noticed that the number_to_currency helper didn''t work anymore
(it just returned the numeric value, without any currency).
I tracked down the error and saw that editing line 89
( number_to_currency method) as follows solved the problem :
Old piece of code :
begin
format.gsub(/%n/, number_with_precision(number,
:precision => precision,
:delimiter =>
2005 Dec 28
6
coverage does not work
Hi,
I''ve installed coverage (gem install coverage) and try to run tests with
-rcoverage option on, but following error occurs:
ruby: No such file to load -- coverage (LoadError)
I try:
ruby -rcoverage mytest.rb
1. I have rubygems in evn var RUBYOPT
2. Gem seems to be installed properly (I can read doc via gems, the files
exist in the ../gem/... dirs)
Does anyone know what is the
2009 Aug 17
4
number in R
Hi,
i export data from an csv file like this :
Data <- read.csv2("c:/Art.csv",sep=",") # import data into R
> Data <- Data [1:5,1:5]# extracting the first 5 rows and columns
> Data
Policy.Number AXA.Entity Country LoB ccy.data
1 6e+13 BNL BNL P EUR
2 6e+13 USA BNL P EUR
3 6e+13 UK BNL
2006 Aug 24
2
my error with augPred
Dear all
I try to refine my nlme models and with partial success. The model is
refined and fitted (using Pinheiro/Bates book as a tutorial) but when
I try to plot
plot(augPred(fit4))
I obtain
Error in predict.nlme(object, value[1:(nrow(value)/nL), , drop =
FALSE], :
Levels (0,3.5],(3.5,5],(5,7],(7,Inf] not allowed for
vykon.fac
>
Is it due to the fact that I have unbalanced
2013 Nov 13
3
Modelos Log Lineales
Estimados,
Existe algún package especifico para modelos lob lineales en R? Idealmente
algo que funcione como el programa LEM.
Muchas gracias por su ayuda,
Saludos
--
Pablo Reyes
[[alternative HTML version deleted]]
2004 Oct 12
3
problem with lapack.so under Debian Sid
Dear list,
I am sorry to bother you with this.
I just upgraded yesterday to R 2.0.0 (using apt-get under Debian Sid), and
now have problems running e.g., summary(lm(...))
the lm is calculated, but the summary statement gives me the following
error:
Error in La.chol2inv(x, size) : lapack routines cannot be loaded
In addition: Warning message:
unable to load shared library