axio安装及使用
先安装
npm install axios --save
再导入
import $ from "jquery";
import axios from "axios";
import Vueaxios from "vue-axios";
import { constants } from 'crypto';
使用方法
axios.get("/api/TradeSystem/TradeSystemForTest/UIService/InvestorService.svc/rest/GetAccountPortfolios?opKey=&accountId=d22b1a31-14ab-4a2a-956b-3ca89ea39c54")
.then(function(res) {
that.groupData=res.data
console.log(that.groupData)
});
参考 https://www.cnblogs.com/ldlx-mars/p/7816316.html