struts2 annotation json returns multiple objects

/**
	 * Validation scoring rules
	 * @return
	 */
	@ActionDef(type = ActionType.PRIVATE)
	@Action(value = "verificationConditions", results = { @Result(type = "json", params = { "includeProperties", "success,msg" }) })
	public String verificationConditions() {
		String[] itemConditions = ServletActionContext.getRequest().getParameterValues("itemConditions");
		if (itemConditions!=null && itemConditions.length > 0) {
			success = true;
			for (String itemCondition : itemConditions) {
				itemCondition = ConditionWithRealUtil.getConditionWithReal(itemCondition);
				if (!kPIBiz.verificationCondition(itemCondition)) {
					success = false;
					msg = "Score rule "" + itemCondition + ""Illegal";
					break;
				}
				if (itemCondition.length() > 500) {
					success = false;
					msg = "Score rule "" + itemCondition + ""The length is too long and does not meet the requirements";
					break;
				}
			}
		}
		return SUCCESS;
	}

 

It is said that the list object needs to be listed.* params = { "includeProperties", "success,msg,list.*" }) }

The list object is systemconfigs written as  systemconfigs.*

Not yet tested

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326722241&siteId=291194637