validates_uniqueness_of :name
validates_length_of :name, :maximum => 30
validates_format_of :name, :with => /^[\w\s\'\-]*$/i
- validates_length_of :html_color, :is => 6
- validates_format_of :html_color, :with => /^[a-f0-9]*$/i
def before_save
IssueStatus.update_all "is_default=#{connection.quoted_false}" if self.is_default?
<p><label for="issue_status_is_default"><%=l(:field_is_default)%></label>
<%= check_box 'issue_status', 'is_default' %></p>
-<p><label for="issue_status_html_color"><%=l(:field_html_color)%><span class="required"> *</span></label>
-#<%= text_field 'issue_status', 'html_color', :maxlength => 6 %></p>
-
<!--[eoform:issue_status]-->
</div>
\ No newline at end of file
--- /dev/null
+class RemoveIssueStatusesHtmlColor < ActiveRecord::Migration
+ def self.up
+ remove_column :issue_statuses, :html_color
+ end
+
+ def self.down
+ raise IrreversibleMigration
+ end
+end
field_notes: Бележка
field_is_closed: Затворена задача
field_is_default: Статус по подразбиране
-field_html_color: Цвят
field_tracker: Тракер
field_subject: Тема
field_due_date: Крайна дата
field_notes: Poznámka
field_is_closed: Požadavek uzavřen
field_is_default: Výchozí stav
-field_html_color: Barva
field_tracker: Fronta
field_subject: Předmět
field_due_date: Po lhůtě
field_notes: Kommentare
field_is_closed: Problem erledigt
field_is_default: Default
-field_html_color: Farbe
field_tracker: Tracker
field_subject: Thema
field_due_date: Abgabedatum
field_notes: Notes
field_is_closed: Issue closed
field_is_default: Default value
-field_html_color: Color
field_tracker: Tracker
field_subject: Subject
field_due_date: Due date
field_notes: Notas
field_is_closed: Petición resuelta
field_is_default: Estado por defecto
-field_html_color: Color
field_tracker: Tracker
field_subject: Tema
field_due_date: Fecha debida
field_notes: Notes
field_is_closed: Demande fermée
field_is_default: Valeur par défaut
-field_html_color: Couleur
field_tracker: Tracker
field_subject: Sujet
field_due_date: Date d'échéance
field_notes: הערות
field_is_closed: נושא סגור
field_is_default: ערך ברירת מחדל
-field_html_color: צבע
field_tracker: עוקב
field_subject: שם נושא
field_due_date: תאריך סיום
field_notes: Note
field_is_closed: Chiude il contesto
field_is_default: Stato predefinito
-field_html_color: Colore
field_tracker: Tracker
field_subject: Oggetto
field_due_date: Data ultima
field_notes: 注記
field_is_closed: 終了した問題
field_is_default: デフォルトのステータス
-field_html_color: 色
field_tracker: トラッカー
field_subject: 題名
field_due_date: 期限日
field_notes: 노트
field_is_closed: 완료된 문제
field_is_default: 기본값
-field_html_color: 색상
field_tracker: 구분
field_subject: 제목
field_due_date: 완료 기한
field_notes: Notities
field_is_closed: Issue gesloten
field_is_default: Default status
-field_html_color: Kleur
field_tracker: Tracker
field_subject: Onderwerp
field_due_date: Verwachte datum gereed
field_notes: Notatki
field_is_closed: Zgłoszenie zamknięte
field_is_default: Domyślny status
-field_html_color: Kolor
field_tracker: Typ zgłoszenia
field_subject: Temat
field_due_date: Data oddania
field_notes: Notas\r
field_is_closed: Tarefa fechada\r
field_is_default: Status padrao\r
-field_html_color: Cor\r
field_tracker: Tipo\r
field_subject: Titulo\r
field_due_date: Data devida\r
field_notes: Notas
field_is_closed: Tarefa fechada
field_is_default: Status padrão
-field_html_color: Cor
field_tracker: Tipo
field_subject: Assunto
field_due_date: Data final
field_notes: Note
field_is_closed: Tichet rezolvat
field_is_default: Statut de baza
-field_html_color: Culoare
field_tracker: Tip tichet
field_subject: Subiect
field_due_date: Data finalizarii
field_notes: Beleške
field_is_closed: Greška zatvorena
field_is_default: Podrazumevana vrednost
-field_html_color: Boja
field_tracker: Tracker
field_subject: Subjekat
field_due_date: Do datuma
field_notes: Anteckningar
field_is_closed: Brist stängd
field_is_default: Defaultstatus
-field_html_color: Färg
field_tracker: Tracker
field_subject: Rubrik
field_due_date: Färdigdatum
field_notes: 说明
field_is_closed: 已关闭的任务
field_is_default: 默认状态
-field_html_color: 颜色
field_tracker: 跟踪
field_subject: 主题
field_due_date: 到期日
Tracker.create(:name => l(:default_tracker_support), :is_in_chlog => false, :is_in_roadmap => false, :position => 3)\r
\r
# issue statuses\r
- new = IssueStatus.create(:name => l(:default_issue_status_new), :is_closed => false, :is_default => true, :html_color => 'F98787', :position => 1)\r
- assigned = IssueStatus.create(:name => l(:default_issue_status_assigned), :is_closed => false, :is_default => false, :html_color => 'C0C0FF', :position => 2)\r
- resolved = IssueStatus.create(:name => l(:default_issue_status_resolved), :is_closed => false, :is_default => false, :html_color => '88E0B3', :position => 3)\r
- feedback = IssueStatus.create(:name => l(:default_issue_status_feedback), :is_closed => false, :is_default => false, :html_color => 'F3A4F4', :position => 4)\r
- closed = IssueStatus.create(:name => l(:default_issue_status_closed), :is_closed => true, :is_default => false, :html_color => 'DBDBDB', :position => 5)\r
- rejected = IssueStatus.create(:name => l(:default_issue_status_rejected), :is_closed => true, :is_default => false, :html_color => 'F5C28B', :position => 6)\r
+ new = IssueStatus.create(:name => l(:default_issue_status_new), :is_closed => false, :is_default => true, :position => 1)\r
+ assigned = IssueStatus.create(:name => l(:default_issue_status_assigned), :is_closed => false, :is_default => false, :position => 2)\r
+ resolved = IssueStatus.create(:name => l(:default_issue_status_resolved), :is_closed => false, :is_default => false, :position => 3)\r
+ feedback = IssueStatus.create(:name => l(:default_issue_status_feedback), :is_closed => false, :is_default => false, :position => 4)\r
+ closed = IssueStatus.create(:name => l(:default_issue_status_closed), :is_closed => true, :is_default => false, :position => 5)\r
+ rejected = IssueStatus.create(:name => l(:default_issue_status_rejected), :is_closed => true, :is_default => false, :position => 6)\r
\r
# workflow\r
Tracker.find(:all).each { |t|\r
issue_statuses_006: \r
name: Rejected\r
is_default: false\r
- html_color: F5C28B\r
is_closed: true\r
id: 6\r
issue_statuses_001: \r
name: New\r
is_default: true\r
- html_color: F98787\r
is_closed: false\r
id: 1\r
issue_statuses_002: \r
name: Assigned\r
is_default: false\r
- html_color: C0C0FF\r
is_closed: false\r
id: 2\r
issue_statuses_003: \r
name: Resolved\r
is_default: false\r
- html_color: 88E0B3\r
is_closed: false\r
id: 3\r
issue_statuses_004: \r
name: Feedback\r
is_default: false\r
- html_color: F3A4F4\r
is_closed: false\r
id: 4\r
issue_statuses_005: \r
name: Closed\r
is_default: false\r
- html_color: DBDBDB\r
is_closed: true\r
id: 5\r
get :list_documents, :id => 1\r
assert_response :success
assert_template 'list_documents'\r
- assert_not_nil assigns(:documents)\r
+ assert_not_nil assigns(:grouped)\r
end\r
\r
def test_list_issues\r