管道基础大数据平台系统开发-【前端】-新系統界面
Surpriseplus
2022-11-19 5aa3a9bdd9001e53f245efd40b0d39263caa4bfc
src/components/login.vue
@@ -152,7 +152,7 @@
</template>
<script>
// import { login } from '../utils/api'
import { getPerms } from '../api/api';
import validCode from './verificationCode.vue';
import { mapActions } from 'vuex';
@@ -214,7 +214,16 @@
          this.loading = true;
          this.login(this.loginForm)
            .then((response) => {
              this.$router.push('/mochaitmo');
              getPerms().then((res) => {
                if (res.code == 200) {
                  this.$store.commit('getPermsEntity', res.result);
                  if (res.result.length != 0) {
                    this.$router.push('/');
                  }
                } else {
                  console.log('error submit!!');
                }
              });
              this.loading = false;
              //调用录接口