Deprecated FormTag's "commandName" in favor of "modelAttribute"
Issue: SPR-14094
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2015 the original author or authors.
|
||||
* Copyright 2002-2016 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -147,7 +147,9 @@ public class FormTag extends AbstractHtmlElementTag {
|
||||
* Set the name of the form attribute in the model.
|
||||
* <p>May be a runtime expression.
|
||||
* @see #setModelAttribute
|
||||
* @deprecated as of Spring 4.3, in favor of {@link #setModelAttribute}
|
||||
*/
|
||||
@Deprecated
|
||||
public void setCommandName(String commandName) {
|
||||
this.modelAttribute = commandName;
|
||||
}
|
||||
@@ -155,7 +157,9 @@ public class FormTag extends AbstractHtmlElementTag {
|
||||
/**
|
||||
* Get the name of the form attribute in the model.
|
||||
* @see #getModelAttribute
|
||||
* @deprecated as of Spring 4.3, in favor of {@link #getModelAttribute}
|
||||
*/
|
||||
@Deprecated
|
||||
protected String getCommandName() {
|
||||
return this.modelAttribute;
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
version="2.0">
|
||||
|
||||
<description>Spring Framework JSP Form Tag Library</description>
|
||||
<tlib-version>4.0</tlib-version>
|
||||
<tlib-version>4.3</tlib-version>
|
||||
<short-name>form</short-name>
|
||||
<uri>http://www.springframework.org/tags/form</uri>
|
||||
|
||||
@@ -131,8 +131,7 @@
|
||||
<rtexprvalue>true</rtexprvalue>
|
||||
</attribute>
|
||||
<attribute>
|
||||
<description>Name of the model attribute under which the form object is exposed.
|
||||
Defaults to 'command'.</description>
|
||||
<description>DEPRECATED: Use "modelAttribute" instead.</description>
|
||||
<name>commandName</name>
|
||||
<required>false</required>
|
||||
<rtexprvalue>true</rtexprvalue>
|
||||
|
||||
Reference in New Issue
Block a user