-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello,
Attached is a small patch for the jsp page that is used for editing system notes. It hides the "delete note" link when a system note is currently being created. This is done by including the toolbar within the <c:choose> element. Clicking this link during the creation of a new note will otherwise lead to internal server error (NPE), because (of course) the nid is still null. Regards, Johannes Renner - -- SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.15 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJNbMnuAAoJEGYafiwbDR5pQVAH/i2Wrx2jaO3ZvQBTWKSqxVkX rlCIJrAXEXrYyBF/IkPgBCZ9BZ26A4sQo494Sb8stTAZZ+WdLsERgVqOoa3bSxBw 5+qOnogY581FPuEn/3OnP0hQ+JV8tktUb33L4qw7pJCtz0TTEEs3uwZt8XZ5/a/I nH66i/Yil4DebmytXDZrvcwFmWCdCeIcDSxpERXHzwT64OcAfCIM/Aes4Lwq/J8l KgXyqpV3y2zgA+ID1m2gsSQ7waKWVfLDdZt90nB0Fv1GpScmFBHB6d4yCkY31ER/ xJ9vDuID3c/Fq8St1ffh3sReCWTZzIeFX5E9FNBlvJfXAJCcJPzZHa31avTsDu4= =MqUC -----END PGP SIGNATURE-----
>From ea324e8b7b6907f24d010b7b4439bc1e00e8f8bf Mon Sep 17 00:00:00 2001 From: Johannes Renner <jren...@suse.de> Date: Thu, 17 Feb 2011 11:20:52 +0100 Subject: [PATCH] do not show delete link on creation of notes (bnc#672090) --- .../webapp/WEB-INF/pages/systems/sdc/note_edit.jsp | 15 ++++++++------- 1 files changed, 8 insertions(+), 7 deletions(-) diff --git a/java/code/webapp/WEB-INF/pages/systems/sdc/note_edit.jsp b/java/code/webapp/WEB-INF/pages/systems/sdc/note_edit.jsp index 408780d..87d60f4 100644 --- a/java/code/webapp/WEB-INF/pages/systems/sdc/note_edit.jsp +++ b/java/code/webapp/WEB-INF/pages/systems/sdc/note_edit.jsp @@ -9,18 +9,19 @@ <%@ include file="/WEB-INF/pages/common/fragments/systems/system-header.jspf" %> - <rhn:toolbar base="h2" img="/img/rhn-icon-note.gif" - deletionUrl="/rhn/systems/details/DeleteNote.do?sid=${system.id}&nid=${n.id}" - deletionType="note" - > - <bean:message key="sdc.details.notes.header"/> - </rhn:toolbar> - <c:choose> <c:when test="${empty param.nid}"> + <rhn:toolbar base="h2" img="/img/rhn-icon-note.gif"> + <bean:message key="sdc.details.notes.header"/> + </rhn:toolbar> <c:set var="urlParam" scope="request" value="sid=${system.id}"/> </c:when> <c:otherwise> + <rhn:toolbar base="h2" img="/img/rhn-icon-note.gif" + deletionUrl="/rhn/systems/details/DeleteNote.do?sid=${system.id}&nid=${n.id}" + deletionType="note"> + <bean:message key="sdc.details.notes.header"/> + </rhn:toolbar> <c:set var="urlParam" scope="request" value="sid=${system.id}&nid=${n.id}"/> </c:otherwise> </c:choose> -- 1.7.1
hide-delete-link-on-creation-of-notes.patch.sig
Description: PGP signature
_______________________________________________ Spacewalk-devel mailing list Spacewalk-devel@redhat.com https://www.redhat.com/mailman/listinfo/spacewalk-devel