方式一:参数直接跟在url后面(/queryModelList?name=1)
var queryParams = new URLSearchParams();
queryParams.append('runId', '1');
this.$load.open({text:'加载中......'});
executeUrl(queryParams).then(
response => {
this.$load.close();
if(response.success){
this.$message({
type: 'success',
message: "执行成功"
});
} else {
this.$message({
type: 'success',
message: "执行失败"
});
}
},
response => {
this.$message({
type: 'success',
message: "立即执行模型失败"
});
}
);
方式二:json方式
var queryParams = {
runId: "1"
}
this.$load.open({text:'加载中......'});
executeUrl(queryParams).then(
response => {
this.$load.close();
if(response.success){
this.$message({
type: 'success',
message: "执行成功"
});
} else {
this.$message({
type: 'success',
message: "执行失败"
});
}
},
response => {
this.$message({
type: 'success',
message: "执行失败"
});
}
);