Added formlet to remove a single table for an entity
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@501304 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -58,10 +58,13 @@ if (security.hasPermission("ENTITY_MAINT", session)) {
|
||||
} else if ("removetables".equals(option)) {
|
||||
Iterator modelEntityNameIter = modelEntityNames.iterator();
|
||||
while (modelEntityNameIter.hasNext()) {
|
||||
String modelEntityName = (String) modelEntityNameIter.next();
|
||||
ModelEntity modelEntity = (ModelEntity) modelEntities.get(modelEntityName);
|
||||
String modelEntityName = (String) modelEntityNameIter.next();
|
||||
ModelEntity modelEntity = (ModelEntity) modelEntities.get(modelEntityName);
|
||||
dbUtil.deleteTable(modelEntity, messages);
|
||||
}
|
||||
} else if ("removetable".equals(option)) {
|
||||
ModelEntity modelEntity = (ModelEntity) modelEntities.get(entityName);
|
||||
dbUtil.deleteTable(modelEntity, messages);
|
||||
} else if ("removepks".equals(option)) {
|
||||
Iterator modelEntityNameIter = modelEntityNames.iterator();
|
||||
while (modelEntityNameIter.hasNext()) {
|
||||
|
||||
@@ -40,9 +40,15 @@ under the License.
|
||||
<form method="post" action="${encodeURLCheckDb}" name="TablesRemoveForm">
|
||||
<input type="hidden" name="option" value="removetables"/>
|
||||
${uiLabelMap.WebtoolsGroupName}: <input type="text" class="inputBox" name="groupName" value="${groupName}" size="40"/>
|
||||
<input type="submit" value="${uiLabelMap.CommonRemove}" name="TablesRemoveButton" disabled/>
|
||||
<input type="submit" value="${uiLabelMap.CommonRemove}" name="TablesRemoveButton" disabled="disabled"/>
|
||||
<input type="button" value="${uiLabelMap.WebtoolsEnable}" onClick="enableTablesRemove();"/>
|
||||
</form>
|
||||
<form method="post" action="${encodeURLCheckDb}" name="TableRemoveForm">
|
||||
<input type="hidden" name="option" value="removetable"/>
|
||||
${uiLabelMap.WebtoolsGroupName}: <input type="text" class="inputBox" name="groupName" value="${groupName}" size="20"/>
|
||||
${uiLabelMap.WebtoolsEntityName}: <input type="text" class="inputBox" name="entityName" value="${entityName}" size="20"/>
|
||||
<input type="submit" value="${uiLabelMap.CommonRemove}" name="TablesRemoveButton"/>
|
||||
</form>
|
||||
<h3>${uiLabelMap.WebtoolsCreateRemoveAllPrimaryKeys}</h3>
|
||||
<form method="post" action="${encodeURLCheckDb}">
|
||||
<input type="hidden" name="option" value="createpks"/>
|
||||
|
||||
Reference in New Issue
Block a user