【获取解析参数时,索引对应】

This commit is contained in:
weizhihong 2023-04-11 10:42:05 +08:00
parent d967a3c80f
commit 2890997cdd
2 changed files with 2 additions and 2 deletions

View File

@ -50,7 +50,7 @@ public class OperateParseServiceImpl implements VoiceTransactionalService {
// 参数处理出错
return;
}
paramArr[index] = paramExtractResults.get(paramRule.getIndexArr()[index]);
paramArr[index] = paramExtractResults.get(paramRule.getIndexArr()[index] - 1); // 这里因为配置是从1开始需要减1做对应
}
if (StringUtils.hasText(paramRule.getName())) {
operateResult.putParam(paramRule.getName(), paramRule.getParseRule().extractParam(simulation, paramArr));

View File

@ -41,7 +41,7 @@ public class ReplyParseServiceImpl implements VoiceTransactionalService {
// 参数处理出错
return;
}
paramArr[index] = paramExtractResults.get(paramRule.getIndexArr()[index]);
paramArr[index] = paramExtractResults.get(paramRule.getIndexArr()[index] - 1); // 这里因为配置是从1开始需要减1做对应
}
replyResult.addParams(paramRule.getParseRule().extractParam(simulation, paramArr));
}