|
|
@ -3,6 +3,8 @@
|
|
|
|
<el-dialog
|
|
|
|
<el-dialog
|
|
|
|
:visible.sync="dialogTableVisible"
|
|
|
|
:visible.sync="dialogTableVisible"
|
|
|
|
:show-close="false"
|
|
|
|
:show-close="false"
|
|
|
|
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
|
|
|
:close-on-press-escape="false"
|
|
|
|
width="20%"
|
|
|
|
width="20%"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<div class="bs-login-wrap">
|
|
|
|
<div class="bs-login-wrap">
|
|
|
@ -50,11 +52,15 @@
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="bs-login-wrap__btn--close" @click="onClose">
|
|
|
|
|
|
|
|
<img src="@/static/images/login/icon-close.png" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</el-dialog>
|
|
|
|
</el-dialog>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
|
|
|
|
import { mapState } from "vuex";
|
|
|
|
import { Message } from "element-ui";
|
|
|
|
import { Message } from "element-ui";
|
|
|
|
import { ApiGetCode, ApiPostLogin } from "@/plugins/api/account";
|
|
|
|
import { ApiGetCode, ApiPostLogin } from "@/plugins/api/account";
|
|
|
|
import { IsPhone } from "/plugins/utils";
|
|
|
|
import { IsPhone } from "/plugins/utils";
|
|
|
@ -94,6 +100,7 @@ export default {
|
|
|
|
};
|
|
|
|
};
|
|
|
|
},
|
|
|
|
},
|
|
|
|
computed: {
|
|
|
|
computed: {
|
|
|
|
|
|
|
|
...mapState(["token"]),
|
|
|
|
dialogTableVisible: {
|
|
|
|
dialogTableVisible: {
|
|
|
|
get() {
|
|
|
|
get() {
|
|
|
|
return this.visible;
|
|
|
|
return this.visible;
|
|
|
@ -140,16 +147,25 @@ export default {
|
|
|
|
Message.error("请勾选同意《用户协议》和《隐私协议》");
|
|
|
|
Message.error("请勾选同意《用户协议》和《隐私协议》");
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
await ApiPostLogin({ ...this.form });
|
|
|
|
const { result } = await ApiPostLogin({ ...this.form });
|
|
|
|
|
|
|
|
if (result) {
|
|
|
|
|
|
|
|
this.dialogTableVisible = false;
|
|
|
|
|
|
|
|
this.$store.commit("setToken", result.token);
|
|
|
|
|
|
|
|
this.$store.dispatch("getUserInfo");
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
onClose() {
|
|
|
|
|
|
|
|
this.dialogTableVisible = false;
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
.bs-login {
|
|
|
|
.bs-login {
|
|
|
|
/deep/.el-dialog {
|
|
|
|
/deep/.el-dialog {
|
|
|
|
|
|
|
|
border-radius: 4px;
|
|
|
|
.el-dialog__header {
|
|
|
|
.el-dialog__header {
|
|
|
|
display: none;
|
|
|
|
display: none;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -222,6 +238,17 @@ export default {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.bs-login-wrap__btn--close {
|
|
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
|
|
left: 50%;
|
|
|
|
|
|
|
|
transform: translate(-50%, 0);
|
|
|
|
|
|
|
|
bottom: -60px;
|
|
|
|
|
|
|
|
cursor: pointer;
|
|
|
|
|
|
|
|
img {
|
|
|
|
|
|
|
|
width: 30px;
|
|
|
|
|
|
|
|
height: 30px;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|