<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                企業??AI智能體構建引擎,智能編排和調試,一鍵部署,支持知識庫和私有化部署方案 廣告
                # 安裝 根目錄運行 ~~~ npm install axios -S ~~~ # 配置 在src/main.js配置 axios 導入 axios 并在 new Vue()中配置 ~~~ import axios from '../node_modules/axios' Vue.prototype.$axios = axios; new Vue({ el: '#app', router, store, axios, components: { App }, template: '<App/>' }) ~~~ 簡單使用: ~~~ .then 里是后臺返回結果 .catch 里是網絡錯誤或后臺服務器出bug等等 get方式 this.$axios.get('/user', { 數據 }) .then(function (response) { }) .catch(function (error) { }); post方式 this.$axios.post('/user' , { params: { 數據對象(此處根據情況) } }) .then(function (response) { }) .catch(function (error) { }); ~~~ vue 中配置跨域訪問后臺 ~~~ proxyTable: { '/api': { target: 'http://127.0.0.1:18080', // 后臺訪問地址 changeOrigin: true, pathRewrite: { '^/api': '' } } }, ~~~ ![](https://box.kancloud.cn/0776f0ba98a82e52441fd0267b15a38c_1091x568.png) 配置后可直接在npm run dev 時直接訪問后臺地址 前綴比真實后臺是多了個 /api ,就是 ~~~ this.$axios.post('/api/login/login', user) .then(function (response) { }) .catch(function (error) { }); ~~~
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看