AjaxResult重写put方法,以方便链式调用
This commit is contained in:
parent
e504c3bf9d
commit
94aed5b405
@ -145,4 +145,18 @@ public class AjaxResult extends HashMap<String, Object>
|
|||||||
{
|
{
|
||||||
return new AjaxResult(code, msg, null);
|
return new AjaxResult(code, msg, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 方便链式调用
|
||||||
|
*
|
||||||
|
* @param key 键
|
||||||
|
* @param value 值
|
||||||
|
* @return 数据对象
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public AjaxResult put(String key, Object value)
|
||||||
|
{
|
||||||
|
super.put(key, value);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user