<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智能體構建引擎,智能編排和調試,一鍵部署,支持知識庫和私有化部署方案 廣告
                html 表單提交 ~~~ <el-form ref="form" :model="form" :rules="rules" label-width="120px"> <el-form-item label="關鍵詞" prop="keyword"> <el-input v-model.trim="form.keyword" class="w-500" :maxlength="12"></el-input> </el-form-item> <el-form-item label="內容" prop="text"> <el-input v-model="form.text" type="textarea" :rows="4" class="w-500"></el-input> </el-form-item> <el-form-item> <el-button type="primary" @click="add('form')" :loading="isLoading">提交</el-button> <el-button @click="goback()">取消</el-button> </el-form-item> </el-form> ~~~ vue方法 后臺接口 ~~~ add() { this.$refs.form.validate((pass) => { if (pass) { this.isLoading = !this.isLoading this.apiPost('admin/text', this.form).then((res) => { this.handelResponse(res, (data) => { _g.toastMsg('success', '提交成功') this.isLoading = !this.isLoading setTimeout(() => { this.goback() }, 1500) }, () => { this.isLoading = !this.isLoading }) }) } }) } ~~~ 完整添加頁面代碼 ~~~ <template> <div> <div class="crumbs"> <el-breadcrumb separator="/"> <el-breadcrumb-item><i class="el-icon-menu"></i> 添加文本回復</el-breadcrumb-item> </el-breadcrumb> </div> <div class="form-box"> <el-form ref="form" :model="form" :rules="rules" label-width="120px"> <el-form-item label="關鍵詞" prop="keyword"> <el-input v-model.trim="form.keyword" class="w-500" :maxlength="12"></el-input> </el-form-item> <el-form-item label="內容" prop="text"> <el-input v-model="form.text" type="textarea" :rows="4" class="w-500"></el-input> </el-form-item> <el-form-item> <el-button type="primary" @click="add('form')" :loading="isLoading">提交</el-button> <el-button @click="goback()">取消</el-button> </el-form-item> </el-form> </div> </div> </template> <script> import http from '../../../../assets/js/http' import fomrMixin from '../../../../assets/js/form_com' export default { data() { return { isLoading: false, form: { keyword: '', text: '' }, rules: { keyword: [ { required: true, message: '請輸入關鍵詞' } ], text: [ { required: true, message: '請輸入內容' } ], } } }, methods: { add() { this.$refs.form.validate((pass) => { if (pass) { this.isLoading = !this.isLoading this.apiPost('admin/text', this.form).then((res) => { this.handelResponse(res, (data) => { _g.toastMsg('success', '提交成功') this.isLoading = !this.isLoading setTimeout(() => { this.goback() }, 1500) }, () => { this.isLoading = !this.isLoading }) }) } }) } }, created() { _g.closeGlobalLoading() }, mixins: [http, fomrMixin] } </script> ~~~ **## 需要注意** #### 不要忘記引進 ~~~ import http from '../../../../assets/js/http' import fomrMixin from '../../../../assets/js/form_com' ~~~ #### 更換接口地址 ~~~ this.apiPost('admin/text', this.form).then((res) ~~~
                  <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>

                              哎呀哎呀视频在线观看