summaryrefslogtreecommitdiffstats
path: root/app/models/document.rb
Commit message (Collapse)AuthorAgeFilesLines
* Updates copyright for 2016.Jean-Philippe Lang2016-03-131-1/+1
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@15238 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Raises 60-character limit for document titles to 255 (#12312).Jean-Philippe Lang2015-05-101-1/+1
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@14261 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Adds custom fields to documents (#7249).Jean-Philippe Lang2015-02-141-1/+2
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@14004 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Add support for multiple email addresses per user (#4244).Jean-Philippe Lang2015-01-171-0/+4
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@13886 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Copyright update.Jean-Philippe Lang2015-01-111-1/+1
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@13872 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rewrites search engine to properly paginate results (#18631).Jean-Philippe Lang2014-12-121-1/+1
| | | | | | Instead of counting and retrieving results based on their timestamps, we now load all result ids then load the appropriate results by their ids. This also brings a 2x performance improvement as we search tokens in one of the 2 queries only. git-svn-id: http://svn.redmine.org/redmine/trunk@13739 e93f8b46-1217-0410-a6f0-8f06a7374b81
* remove unneeded "references" of joinsToshi MARUYAMA2014-10-241-1/+0
| | | | | | "references" is needed for includes, but not needed for joins. git-svn-id: http://svn.redmine.org/redmine/trunk@13501 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Removed unneeded :foreign_key option on belongs_to associations.Jean-Philippe Lang2014-10-221-1/+1
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@13484 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Merged rails-4.1 branch (#14534).Jean-Philippe Lang2014-10-221-3/+7
| | | | git-svn-id: http://svn.redmine.org/redmine/trunk@13482 e93f8b46-1217-0410-a6f0-8f06a7374b81
* update copyright year (#15977)Toshi MARUYAMA2014-01-291-1/+1
| | | | | | Contributed by Daniel Felix. git-svn-id: http://svn.redmine.org/redmine/trunk@12736 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Use AR callbacks instead of observers (removed in Rails4) for notifications.Jean-Philippe Lang2013-07-141-0/+10
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@12021 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Split "Manage documents" permission into create, edit and delete permissions ↵Jean-Philippe Lang2013-01-201-1/+1
| | | | | | (#12401). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11206 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Copyright for 2013 (#12788).Jean-Philippe Lang2013-01-121-1/+1
| | | | | | Patch by Daniel Felix. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11169 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Rewrites named scopes with ARel queries.Jean-Philippe Lang2012-12-071-2/+3
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10950 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Replaces find(:first) calls.Jean-Philippe Lang2012-12-031-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10928 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Changes RedMine to Redmine in copyright notices.Jean-Philippe Lang2012-05-051-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9637 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Copyright update.Jean-Philippe Lang2012-05-051-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9636 e93f8b46-1217-0410-a6f0-8f06a7374b81
* model: replace Rails2 "named_scope" to Rails3 "scope"Toshi MARUYAMA2012-04-261-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9537 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Prevent mass-assignment when adding/updating a document (#10390).Jean-Philippe Lang2012-03-061-0/+3
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9130 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Order is already defined on attachments association.Jean-Philippe Lang2012-01-011-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8458 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Removed after_initialize methods.Jean-Philippe Lang2011-12-181-1/+2
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8288 e93f8b46-1217-0410-a6f0-8f06a7374b81
* remove trailing white-spaces from Document model source.Toshi MARUYAMA2011-05-151-9/+9
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5794 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Makes visible scopes accept projects option and deprecate Project.visible_by.Jean-Philippe Lang2011-04-051-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5324 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Adds visible scope to redmine links queries.Jean-Philippe Lang2011-01-231-0/+3
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4759 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Refactor: Move recipients method into acts_as_eventEric Davis2010-02-011-7/+0
| | | | | | | acts_as_event should be the standard interface to Redmine events, like mail notifications, so having a standard recipients implementation there makes sense. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3358 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Make sure users don't get notified for thing they can not view (#3589).Jean-Philippe Lang2009-12-131-0/+11
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3169 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Show last update datetime (last attachment added) on document list (#4232).Jean-Philippe Lang2009-11-261-0/+8
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3095 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Changed Enumerations to use a Single Table InheritanceEric Davis2009-05-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | * Added migrations to change Enumerations to an STI relationship * Added TimeEntryActivity model (STI) * Added DocumentCategory model (STI) * Added IssuePriority model (STI) * Added Enumeration#get_subclasses to get a list of the subclasses of Enumeration * Changed Enumeration to use the STI type field instead of the opt field * Changed Enumeration#opt to return the old opt values but with a deprecation warning. * Removed Enumeration::OPTIONS * Removed the dynamic named_scopes in favor of specific named_scopes. Kept for compatibility reasons. * Added Enumeration#default so each subclass can easily find it's default record. * Fixed Enumeration#default to use the STI scoping with a fake default scope for finding Enumeration's default. * Added a 'all' named scope for getting all records in order by position. * Added Deprecation warnings to the old named_scopes in Enumerations. * Moved various methods off of Enumeration and onto the concrete classes * Changed the EnumerationsController to use types * Updated the Enumeration list template * Added has_many relationships to the Enumeration STI classes. * Fixes for tests. #3007 git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2777 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Replaces Enumeration.get_values and Enumeration.default with named scopes.Jean-Philippe Lang2009-02-151-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2472 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Fixed: default category ignored when adding a document (#2328).Jean-Philippe Lang2008-12-121-0/+6
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2124 e93f8b46-1217-0410-a6f0-8f06a7374b81
* AttachmentsController now handles attachments deletion.Jean-Philippe Lang2008-12-091-1/+1
| | | | git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2116 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Activity refactoring.Jean-Philippe Lang2008-07-271-1/+2
| | | | git-svn-id: http://redmine.rubyforge.org/svn/trunk@1701 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Ability to search all projects or the projects the user belongs to (#791).Jean-Philippe Lang2008-05-181-1/+1
| | | | git-svn-id: http://redmine.rubyforge.org/svn/trunk@1435 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Fixed: error on activity page when displaying a document (undefined method ↵Jean-Philippe Lang2007-11-121-0/+1
| | | | | | 'author'). git-svn-id: http://redmine.rubyforge.org/svn/trunk@896 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Search engines now supports pagination.Jean-Philippe Lang2007-09-271-1/+3
| | | | | | Results are sorted in reverse chronological order. git-svn-id: http://redmine.rubyforge.org/svn/trunk@766 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Merged 0.6 branch into trunk.Jean-Philippe Lang2007-08-291-0/+2
| | | | | | | | | Permissions management was rewritten. Some permissions can now be specifically defined for non member and anonymous users. This migration: * is irreversible (please, don't forget to *backup* your database before upgrading) * resets role's permissions (go to "Admin -> Roles & Permissions" to set them after upgrading) git-svn-id: http://redmine.rubyforge.org/svn/trunk@674 e93f8b46-1217-0410-a6f0-8f06a7374b81
* Added several validates_length_ofJean-Philippe Lang2007-07-161-0/+1
| | | | git-svn-id: http://redmine.rubyforge.org/svn/trunk@593 e93f8b46-1217-0410-a6f0-8f06a7374b81
* added svn:eol-style native property on /app filesJean-Philippe Lang2007-03-121-22/+22
| | | | git-svn-id: http://redmine.rubyforge.org/svn/trunk@333 e93f8b46-1217-0410-a6f0-8f06a7374b81
* replaced deprecated ":dependent => true" statementsJean-Philippe Lang2006-12-261-1/+1
| | | | git-svn-id: http://redmine.rubyforge.org/svn/trunk@123 e93f8b46-1217-0410-a6f0-8f06a7374b81
* trunk moved from /trunk/redmine to /trunkJean-Philippe Lang2006-12-051-0/+24
git-svn-id: http://redmine.rubyforge.org/svn/trunk@67 e93f8b46-1217-0410-a6f0-8f06a7374b81