Add "View Sponsor Public Profile" to Sponsor Edit view template. Remove not needed <p> in home/public.html template. Add missing '$' at the end of some urls in site/map.py module.
Patch by: Pawel Solyga
Review by: to-be-reviewed
--- a/app/soc/logic/site/map.py Sun Oct 19 17:33:44 2008 +0000
+++ b/app/soc/logic/site/map.py Sun Oct 19 18:00:14 2008 +0000
@@ -206,7 +206,7 @@
# Sponsor Group public view
sponsor_profile = page.Page(
page.Url(
- r'^sponsor/profile/%s' % path_link_name.LINKNAME_ARG_PATTERN,
+ r'^sponsor/profile/%s$' % path_link_name.LINKNAME_ARG_PATTERN,
'soc.views.sponsor.profile.public'),
'Sponsor Public Profile',
parent=home)
@@ -236,7 +236,7 @@
site_sponsor_edit = page.Page(
page.Url(
- r'^site/sponsor/profile/%s' % path_link_name.LINKNAME_ARG_PATTERN,
+ r'^site/sponsor/profile/%s$' % path_link_name.LINKNAME_ARG_PATTERN,
'soc.views.site.sponsor.profile.edit'),
'Site: Modify Existing Sponsor',
short_name='Modify Site Sponsor',
--- a/app/soc/templates/soc/home/public.html Sun Oct 19 17:33:44 2008 +0000
+++ b/app/soc/templates/soc/home/public.html Sun Oct 19 18:00:14 2008 +0000
@@ -55,7 +55,6 @@
{% block missing_doc %}
This is the default home page can be edited via Settings.
{% endblock %}
-<p>
{% endif %}
{% if home_settings.feed_url %}
<div id="blog"></div>
--- a/app/soc/templates/soc/site/sponsor/profile/edit.html Sun Oct 19 17:33:44 2008 +0000
+++ b/app/soc/templates/soc/site/sponsor/profile/edit.html Sun Oct 19 18:00:14 2008 +0000
@@ -12,9 +12,13 @@
See the License for the specific language governing permissions and
limitations under the License.
{% endcomment %}
- {% block submit_buttons %}
- {{ block.super }}
+{% block submit_buttons %}
+{{ block.super }}
<td>
<input type="button" onclick="location.href='/site/{{ entity_type_short|lower }}/profile/delete/{{ entity.link_name }}'" value="Delete"/>
</td>
- {% endblock %}
+{% endblock %}
+{% block body %}
+{{ block.super }}
+<p><a href="/{{ entity_type_short|lower }}/profile/{{ entity.link_name }}">View Sponsor Public Profile</a></p>
+{% endblock %}
\ No newline at end of file