| <?xml version="1.0"?> |
| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one or more |
| contributor license agreements. See the NOTICE file distributed with |
| this work for additional information regarding copyright ownership. |
| The ASF licenses this file to You 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. |
| --> |
| <!-- $Id$ --> |
| <page:page xmlns:c="http://apache.org/cocoon/templates/jx/1.0" |
| xmlns="http://www.w3.org/1999/xhtml" |
| xmlns:i18n="http://apache.org/cocoon/i18n/2.1" |
| xmlns:page="http://apache.org/cocoon/lenya/cms-page/1.0" > |
| |
| <page:title> |
| <i18n:text>Deactivate Document</i18n:text> |
| </page:title> |
| <page:body> |
| <div class="lenya-box"> |
| <div class="lenya-box-title"> |
| <i18n:translate> |
| <i18n:text key="deactivate-doc"/> |
| <i18n:param> |
| <q> |
| <jx:out value="${usecase.getParameter('documentid')}"/> |
| </q> |
| </i18n:param> |
| </i18n:translate> |
| </div> |
| <div class="lenya-box-body"> |
| <jx:choose> |
| <jx:when test="${not(empty(usecase.getParameter('message')))}"> <!-- there is a warning --> |
| <form method="get" id="form-deactivate"> |
| <div class="lenya-box"> |
| <div class="lenya-box-title"><i18n:text>Deactivate Document</i18n:text></div> |
| <div class="lenya-box-body"> |
| <table class="lenya-table-noborder"> |
| <tr> |
| <td class="lenya-entry-caption"><i18n:text>Document</i18n:text>:</td> |
| <td><jx:out value="${usecase.getParameter('documentid')}"/> [<jx:out value="${usecase.getParameter('language')}"/>]</td> |
| </tr> |
| <tr> |
| <td valign="top" class="lenya-entry-caption"><i18n:text>Problem</i18n:text>:</td> |
| <td> |
| <span class="lenya-form-error"><i18n:text key="cannot-deactivate-unless-children-deactivated"/>:</span> |
| <ul> |
| <jx:forEach var="item" items="${usecase.getParameter('livechildren')}"> |
| <li><a href="{@href}"><jx:out value="${item.id}"/> [<jx:out value="${item.language}"/>]</a></li> |
| </jx:forEach> |
| </ul> |
| </td> |
| </tr> |
| </table> |
| </div> |
| </div> |
| <input onClick="location.href='{$request-uri}';" type="button" value="Cancel" name="input-cancel"/> |
| </form> |
| </jx:when> |
| <jx:otherwise> <!-- no warning --> |
| <form method="get" action=""> |
| <input type="hidden" name="lenya.usecase" value="deactivate"/> |
| <table class="lenya-table-noborder"> |
| <tr> |
| <td> |
| <br/> |
| <i18n:translate> |
| <i18n:text key="deactivate-doc?"/> |
| <i18n:param> |
| <strong> |
| <jx:out value="${usecase.getParameter('documentid')}"/> |
| </strong> |
| </i18n:param> |
| </i18n:translate> |
| </td> |
| </tr> |
| <tr> |
| <jx:if test="${not(empty(usecase.getParameter('inconsistentdocument')))}"> |
| <td class="lenya-entry-caption"> |
| <span class="lenya-form-message-error"><i18n:text key="docs-have-links-to-doc"/>:</span> |
| </td> |
| <td valign="top"> |
| <jx:forEach var="item" items="${usecase.getParameter('inconsistentdocument')}"> |
| <a target="_blank" href="{@href}"><jx:out value="${item.id}"/><jx:out value="."/></a><br/> |
| </jx:forEach> |
| </td> |
| </jx:if> |
| </tr> |
| <tr> |
| <td> |
| <br/><input i18n:attr="value" type="submit" value="Deactivate" name="input-deactivate"/>  |
| <input i18n:attr="value" type="button" onClick="location.href='${requesturi}';" value="Cancel" name="input-cancel"/> |
| </td> |
| </tr> |
| </table> |
| </form> |
| </jx:otherwise> |
| </jx:choose> |
| </div> |
| </div> |
| </page:body> |
| </page:page> |