fixes #119: bad text on post flags

This commit is contained in:
albert
2011-10-14 17:12:03 -04:00
parent eb10aacdce
commit c03ed4f644
4 changed files with 14 additions and 4 deletions

View File

@@ -8,11 +8,13 @@
}
Danbooru.j_alert = function(title, msg) {
$('<div title="' + title + '"></div>').html(msg).dialog({modal: true});
this.notice(msg);
// $('<div title="' + title + '"></div>').html(msg).dialog({modal: true});
}
Danbooru.j_error = function(msg) {
this.j_alert("Error", msg);
this.notice(msg);
// this.j_alert("Error", msg);
}
Danbooru.ajax_start = function(target) {

View File

@@ -10,7 +10,7 @@ module Admin
@user = User.find(params[:id])
@user.level = params[:user][:level]
@user.save
redirect_to edit_admin_user_path(@user, :notice => "User updated")
redirect_to edit_admin_user_path(@user, :notice => "User updated"), :notice => "User updated"
end
end
end

View File

@@ -7,7 +7,7 @@ class PostFlag < ActiveRecord::Base
validate :validate_creator_is_not_limited
validate :validate_post_is_active
before_validation :initialize_creator, :on => :create
validates_uniqueness_of :creator_id, :scope => :post_id, :message => "has already flagged this post"
validates_uniqueness_of :creator_id, :scope => :post_id, :message => "have already flagged this post"
before_save :update_post
scope :resolved, where("is_resolved = ?", true)
scope :unresolved, where("is_resolved = ?", false)

View File

@@ -3,3 +3,11 @@
en:
hello: "Hello world"
activerecord:
attributes:
post_flag:
creator: "You"
creator_id: "You"
post_vote:
user: "You"
user_id: "You"