diff options
Diffstat (limited to 'modules/gallery/helpers')
-rw-r--r-- | modules/gallery/helpers/group.php | 10 | ||||
-rw-r--r-- | modules/gallery/helpers/movie.php | 3 | ||||
-rw-r--r-- | modules/gallery/helpers/photo.php | 3 | ||||
-rw-r--r-- | modules/gallery/helpers/user.php | 9 |
4 files changed, 14 insertions, 11 deletions
diff --git a/modules/gallery/helpers/group.php b/modules/gallery/helpers/group.php index 074a7b83..17dd7f70 100644 --- a/modules/gallery/helpers/group.php +++ b/modules/gallery/helpers/group.php @@ -91,7 +91,7 @@ class group_Core { * @return Group_Model the group object, or null if the id was invalid. */ static function lookup($id) { - return Identity::instance()->lookup_group($id); + return Identity::instance()->lookup_group_by_field("id", $id); } /** @@ -100,16 +100,16 @@ class group_Core { * @return Group_Core the group object, or null if the name was invalid. */ static function lookup_by_name($name) { - return Identity::instance()->lookup_group_by_name($name); + return Identity::instance()->lookup_group_by_field("name", $name); } /** * List the groups - * @param mixed options to apply to the selection of the user + * @param mixed options to apply to the selection of the user (@see Database.php) * @return array the group list. */ - static function groups($filter=array()) { - return Identity::instance()->list_groups($filter); + static function get_group_list($filter=array()) { + return Identity::instance()->get_group_list($filter); } /** diff --git a/modules/gallery/helpers/movie.php b/modules/gallery/helpers/movie.php index 98419387..9ca28fe6 100644 --- a/modules/gallery/helpers/movie.php +++ b/modules/gallery/helpers/movie.php @@ -141,7 +141,8 @@ class movie_Core { ->callback("item::validate_no_slashes") ->error_messages("no_slashes", t("The movie name can't contain a \"/\"")) ->callback("item::validate_no_trailing_period") - ->error_messages("no_trailing_period", t("The movie name can't end in \".\"")); + ->error_messages("no_trailing_period", t("The movie name can't end in \".\"")) + ->error_messages("illegal_extension", t("You cannot change the filename extension")); $group->input("slug")->label(t("Internet Address"))->value($movie->slug) ->callback("item::validate_url_safe") ->error_messages( diff --git a/modules/gallery/helpers/photo.php b/modules/gallery/helpers/photo.php index 99f28753..6677ddc9 100644 --- a/modules/gallery/helpers/photo.php +++ b/modules/gallery/helpers/photo.php @@ -169,7 +169,8 @@ class photo_Core { ->callback("item::validate_no_slashes") ->error_messages("no_slashes", t("The photo name can't contain a \"/\"")) ->callback("item::validate_no_trailing_period") - ->error_messages("no_trailing_period", t("The photo name can't end in \".\"")); + ->error_messages("no_trailing_period", t("The photo name can't end in \".\"")) + ->error_messages("illegal_extension", t("You cannot change the filename extension")); $group->input("slug")->label(t("Internet Address"))->value($photo->slug) ->callback("item::validate_url_safe") ->error_messages( diff --git a/modules/gallery/helpers/user.php b/modules/gallery/helpers/user.php index e3494fdf..f0509030 100644 --- a/modules/gallery/helpers/user.php +++ b/modules/gallery/helpers/user.php @@ -310,18 +310,19 @@ class user_Core { * @return User_Model the user object, or null if the id was invalid. */ static function lookup($id) { - return Identity::instance()->lookup_user($id); + return Identity::instance()->lookup_user_by_field("id", $id); } /** * Look up a user by name. - * @param integer $id the user name + * @param integer $name the user name * @return User_Model the user object, or null if the name was invalid. */ static function lookup_by_name($name) { return Identity::instance()->lookup_user_by_field("name", $name); } + /** * Look up a user by hash. * @param string $name the user name @@ -336,8 +337,8 @@ class user_Core { * @param mixed options to apply to the selection of the user(optional) * @return array the group list. */ - static function users($filter=array()) { - return Identity::instance()->list_users($filter); + static function get_user_list($filter=array()) { + return Identity::instance()->get_user_list($filter); } /** |