more coolness
This commit is contained in:
parent
e05a88d340
commit
5fb8609dfe
|
@ -8,6 +8,12 @@ def find_attribute(name, value = nil)
|
||||||
attribute
|
attribute
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def has_attribute?(name, value)
|
||||||
|
attribute = find_attribute(name)
|
||||||
|
|
||||||
|
attribute.text == value
|
||||||
|
end
|
||||||
|
|
||||||
def find_input(name)
|
def find_input(name)
|
||||||
find("[name$='[#{name}]']")
|
find("[name$='[#{name}]']")
|
||||||
end
|
end
|
||||||
|
@ -98,3 +104,4 @@ def within_any(search, &block)
|
||||||
|
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -33,6 +33,10 @@ module SemanticRailsViewHelpers
|
||||||
action = nil
|
action = nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if action == :show
|
||||||
|
action = nil
|
||||||
|
end
|
||||||
|
|
||||||
options = Hash[options.collect { |k, v| [ k, CGI.escapeHTML(v.to_s) ] }]
|
options = Hash[options.collect { |k, v| [ k, CGI.escapeHTML(v.to_s) ] }]
|
||||||
|
|
||||||
route = model
|
route = model
|
||||||
|
|
Loading…
Reference in New Issue