• 2. 前台传参到后台


      
    方式一:参数直接跟在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: "执行失败"
                    });
                }
            );
     
     
     
     
  • 相关阅读:
    mongodb教程
    redis高级知识
    memcached删除机制与大数据缓存问题
    nginx 运维基础
    mysql 集群与分区
    Memcached之缓存雪崩,缓存穿透,缓存预热,缓存算法
    git cz配置
    Angular零碎知识点-持续补充
    Vue学习笔记-组件
    Vue学习笔记-自定义指令生命周期函数
  • 原文地址:https://www.cnblogs.com/zkx4213/p/10397301.html
Copyright © 2020-2023  润新知