Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
张重言
rails
提交
724eb9e6
R
rails
项目概览
张重言
/
rails
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rails
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
724eb9e6
编写于
3月 12, 2009
作者:
H
Henrik N
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix some typos, including a global "seperator" -> "separator".
上级
aaacc999
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
7 addition
and
7 deletion
+7
-7
actionpack/lib/action_view/helpers/date_helper.rb
actionpack/lib/action_view/helpers/date_helper.rb
+2
-2
actionpack/lib/action_view/helpers/number_helper.rb
actionpack/lib/action_view/helpers/number_helper.rb
+1
-1
actionpack/lib/action_view/helpers/text_helper.rb
actionpack/lib/action_view/helpers/text_helper.rb
+1
-1
activesupport/lib/active_support/inflector.rb
activesupport/lib/active_support/inflector.rb
+3
-3
未找到文件。
actionpack/lib/action_view/helpers/date_helper.rb
浏览文件 @
724eb9e6
...
...
@@ -876,8 +876,8 @@ def input_id_from_type(type)
input_name_from_type
(
type
).
gsub
(
/([\[\(])|(\]\[)/
,
'_'
).
gsub
(
/[\]\)]/
,
''
)
end
# Given an ordering of datetime components, create the selection
html
# and join them with their appropriate sep
erators
# Given an ordering of datetime components, create the selection
HTML
# and join them with their appropriate sep
arators.
def
build_selects_from_types
(
order
)
select
=
''
order
.
reverse
.
each
do
|
type
|
...
...
actionpack/lib/action_view/helpers/number_helper.rb
浏览文件 @
724eb9e6
...
...
@@ -140,7 +140,7 @@ def number_to_percentage(number, options = {})
# number_with_delimiter(12345678) # => 12,345,678
# number_with_delimiter(12345678.05) # => 12,345,678.05
# number_with_delimiter(12345678, :delimiter => ".") # => 12.345.678
# number_with_delimiter(12345678, :sep
e
rator => ",") # => 12,345,678
# number_with_delimiter(12345678, :sep
a
rator => ",") # => 12,345,678
# number_with_delimiter(98765432.98, :delimiter => " ", :separator => ",")
# # => 98 765 432,98
#
...
...
actionpack/lib/action_view/helpers/text_helper.rb
浏览文件 @
724eb9e6
...
...
@@ -538,7 +538,7 @@ def auto_link_urls(text, html_options = {})
punctuation
=
''
# detect already linked URLs
if
$`
=~
/<a\s[^>]*href="$/
# do not change string; URL is alreay linked
# do not change string; URL is alrea
d
y linked
href
else
# don't include trailing punctuation character as part of the URL
...
...
activesupport/lib/active_support/inflector.rb
浏览文件 @
724eb9e6
...
...
@@ -258,9 +258,9 @@ def demodulize(class_name_in_module)
# # => <a href="/person/1-donald-e-knuth">Donald E. Knuth</a>
def
parameterize
(
string
,
sep
=
'-'
)
re_sep
=
Regexp
.
escape
(
sep
)
#
replace accented chars with ther ascii equivalents
#
Replace accented chars with their ASCII equivalents.
parameterized_string
=
transliterate
(
string
)
# Turn unwanted chars into the sep
erator
# Turn unwanted chars into the sep
arator.
parameterized_string
.
gsub!
(
/[^a-z0-9\-_\+]+/i
,
sep
)
# No more than one of the separator in a row.
parameterized_string
.
squeeze!
(
sep
)
...
...
@@ -270,7 +270,7 @@ def parameterize(string, sep = '-')
end
# Replaces accented characters with their
ascii
equivalents.
# Replaces accented characters with their
ASCII
equivalents.
def
transliterate
(
string
)
Iconv
.
iconv
(
'ascii//ignore//translit'
,
'utf-8'
,
string
).
to_s
end
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录