feat: 请求body支持变量
This commit is contained in:
parent
8b2041bbd9
commit
2f1b8e9d1a
|
@ -937,6 +937,9 @@ class JMXGenerator {
|
||||||
let body = [];
|
let body = [];
|
||||||
if (request.body.isKV()) {
|
if (request.body.isKV()) {
|
||||||
body = this.filterKV(request.body.kvs);
|
body = this.filterKV(request.body.kvs);
|
||||||
|
body.forEach(arg => {
|
||||||
|
arg.value = calculate(arg.value);
|
||||||
|
});
|
||||||
} else {
|
} else {
|
||||||
httpSamplerProxy.boolProp('HTTPSampler.postBodyRaw', true);
|
httpSamplerProxy.boolProp('HTTPSampler.postBodyRaw', true);
|
||||||
body.push({name: '', value: request.body.raw, encode: false});
|
body.push({name: '', value: request.body.raw, encode: false});
|
||||||
|
|
Loading…
Reference in New Issue