# HG changeset patch # User Lennard de Rijk # Date 1233431215 0 # Node ID 9bdbb18d622ea9bc91dc10a11dd0d93eb1dcfd4f # Parent a98a165c13004196b76f127575b11da083a869d6 Added view and templates for mentors. Mentors can be invited or send a request to become a mentor for a specific org. Patch by: Lennard de Rijk Reviewed by: to-be-reviewed diff -r a98a165c1300 -r 9bdbb18d622e app/soc/templates/soc/mentor/list/heading.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/app/soc/templates/soc/mentor/list/heading.html Sat Jan 31 19:46:55 2009 +0000 @@ -0,0 +1,4 @@ + + Organization ID + Admin ID + diff -r a98a165c1300 -r 9bdbb18d622e app/soc/templates/soc/mentor/list/row.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/app/soc/templates/soc/mentor/list/row.html Sat Jan 31 19:46:55 2009 +0000 @@ -0,0 +1,8 @@ + +
{{ list.item.scope_path }} +
+ + + diff -r a98a165c1300 -r 9bdbb18d622e app/soc/templates/soc/mentor/manage.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/app/soc/templates/soc/mentor/manage.html Sat Jan 31 19:46:55 2009 +0000 @@ -0,0 +1,28 @@ +{% extends "soc/mentor/public.html" %} +{% comment %} +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +{% endcomment %} + +{% block header_title %} +{{ page_name }} {{ entity.link_id }} for {{ entity.scope_path }} +{% endblock %} + +{% block manage %} + + + Please select the appropriate action:
+ + + + +{% endblock %} diff -r a98a165c1300 -r 9bdbb18d622e app/soc/templates/soc/mentor/public.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/app/soc/templates/soc/mentor/public.html Sat Jan 31 19:46:55 2009 +0000 @@ -0,0 +1,31 @@ +{% extends "soc/base.html" %} +{% comment %} +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +{% endcomment %} +{% load forms_helpers %} + +{% block header_title %} +{{ page_name }} {{ entity.link_id }} for {{ entity.scope_path }} +{% endblock %} + +{% block body %} +

+ + {% readonly_field_as_table_row entity.fields.link_id.label entity.link_id %} + {% readonly_field_as_table_row entity.fields.display_name.label entity.display_name %} + {% readonly_field_as_table_row entity.fields.im_handle.label entity.im_handle %} + {% readonly_field_as_table_row entity.fields.res_country.label entity.res_country %} +
+

+{% block manage %} {% endblock %} +{% endblock %} diff -r a98a165c1300 -r 9bdbb18d622e app/soc/views/sitemap/build.py --- a/app/soc/views/sitemap/build.py Sat Jan 31 19:33:40 2009 +0000 +++ b/app/soc/views/sitemap/build.py Sat Jan 31 19:46:55 2009 +0000 @@ -30,6 +30,7 @@ from soc.views.models import club_member from soc.views.models import document from soc.views.models import host +from soc.views.models import mentor from soc.views.models import notification from soc.views.models import organization from soc.views.models import org_admin @@ -62,6 +63,7 @@ sidebar.addMenu(program.view.getExtraMenus) sidebar.addMenu(organization.view.getSidebarMenus) sidebar.addMenu(org_admin.view.getSidebarMenus) +sidebar.addMenu(mentor.view.getSidebarMenus) sitemap.addPages(club.view.getDjangoURLPatterns()) sitemap.addPages(club_admin.view.getDjangoURLPatterns()) @@ -69,6 +71,7 @@ sitemap.addPages(club_member.view.getDjangoURLPatterns()) sitemap.addPages(document.view.getDjangoURLPatterns()) sitemap.addPages(host.view.getDjangoURLPatterns()) +sitemap.addPages(mentor.view.getDjangoURLPatterns()) sitemap.addPages(notification.view.getDjangoURLPatterns()) sitemap.addPages(organization.view.getDjangoURLPatterns()) sitemap.addPages(org_admin.view.getDjangoURLPatterns())