Defect #5822 » Redmine_SQL_Server_Dates_Patch.patch
| models/issue.rb (working copy) | ||
|---|---|---|
|
after_destroy :destroy_children
|
||
|
after_destroy :update_parent_attributes
|
||
|
|
||
|
coerce_sqlserver_date :start_date, :due_date
|
||
|
|
||
|
# Returns true if usr or current user is allowed to view the issue
|
||
|
def visible?(usr=nil)
|
||
|
(usr || User.current).allowed_to?(:view_issues, self.project)
|
||
| models/project.rb (working copy) | ||
|---|---|---|
|
named_scope :all_public, { :conditions => { :is_public => true } }
|
||
|
named_scope :visible, lambda { { :conditions => Project.visible_by(User.current) } }
|
||
|
|
||
|
coerce_sqlserver_date :start_date, :due_date
|
||
|
|
||
|
def identifier=(identifier)
|
||
|
super unless identifier_frozen?
|
||
|
end
|
||
| models/version.rb (working copy) | ||
|---|---|---|
|
named_scope :open, :conditions => {:status => 'open'}
|
||
|
named_scope :visible, lambda {|*args| { :include => :project,
|
||
|
:conditions => Project.allowed_to_condition(args.first || User.current, :view_issues) } }
|
||
|
coerce_sqlserver_date :start_date, :due_date, :effective_date
|
||
|
|
||
|
# Returns true if +user+ or current user is allowed to view the version
|
||
|
def visible?(user=User.current)
|
||
|
user.allowed_to?(:view_issues, self.project)
|
||
- « Previous
- 1
- 2
- Next »