请求地址

This commit is contained in:
余同学 2024-10-08 11:04:11 +08:00
parent 95a020789b
commit 0ad0c4cf99
3 changed files with 92 additions and 32 deletions

View File

@ -9,14 +9,15 @@
/**
* 生产环境
*/
;(function () {
(function () {
window.SITE_CONFIG = {};
// 在线api接口请求地址
window.SITE_CONFIG['baseUrl'] ="http://admin-test.damajishi.cn:8899"
window.SITE_CONFIG["baseUrl"] = "https://admin-test.damajishi.cn/";
// cdn地址 = 域名 + 版本号
window.SITE_CONFIG['domain'] = './'; // 域名
window.SITE_CONFIG['version'] = ''; // 版本号(年月日时分)
window.SITE_CONFIG['cdnUrl'] = window.SITE_CONFIG.domain + window.SITE_CONFIG.version;
window.SITE_CONFIG["domain"] = "./"; // 域名
window.SITE_CONFIG["version"] = ""; // 版本号(年月日时分)
window.SITE_CONFIG["cdnUrl"] =
window.SITE_CONFIG.domain + window.SITE_CONFIG.version;
})();

View File

@ -9,16 +9,18 @@
/**
* 开发环境
*/
;(function () {
(function () {
window.SITE_CONFIG = {};
// api接口请求地址
window.SITE_CONFIG['baseUrl'] ="http://admin-test.damajishi.cn:8899"
// 在线api接口请求地址
window.SITE_CONFIG["baseUrl"] = "https://admin-test.damajishi.cn/";
// 在线api接口请求地址
// window.SITE_CONFIG['baseUrl'] = 'http://119.29.103.250:8082/red-memory';
// 在线api接口请求地址
window.SITE_CONFIG['baseUrlComment'] = 'http://123.60.109.11:8081/red-memory-user';
// 在线api接口请求地址
window.SITE_CONFIG["baseUrlComment"] =
"http://123.60.109.11:8081/red-memory-user";
// cdn地址 = 域名 + 版本号
window.SITE_CONFIG['domain'] = './'; // 域名
window.SITE_CONFIG['version'] = ''; // 版本号(年月日时分)
window.SITE_CONFIG['cdnUrl'] = window.SITE_CONFIG.domain + window.SITE_CONFIG.version;
window.SITE_CONFIG["domain"] = "./"; // 域名
window.SITE_CONFIG["version"] = ""; // 版本号(年月日时分)
window.SITE_CONFIG["cdnUrl"] =
window.SITE_CONFIG.domain + window.SITE_CONFIG.version;
})();

View File

@ -13,15 +13,32 @@
</div>
<div class="login-main">
<h3 class="login-title">大妈集市商户端登录</h3>
<el-tabs v-if="false" :stretch="true" v-model="loginWay" @tab-click="loginWayClick">
<el-tabs
v-if="false"
:stretch="true"
v-model="loginWay"
@tab-click="loginWayClick"
>
<el-tab-pane label="账户登录" name="account_login">
<el-form :model="dataForm" :rules="dataRule" ref="dataForm" @keyup.enter.native="dataFormSubmit()"
status-icon>
<el-form
:model="dataForm"
:rules="dataRule"
ref="dataForm"
@keyup.enter.native="dataFormSubmit()"
status-icon
>
<el-form-item prop="userName">
<el-input v-model="dataForm.userName" placeholder="帐号"></el-input>
<el-input
v-model="dataForm.userName"
placeholder="帐号"
></el-input>
</el-form-item>
<el-form-item prop="password">
<el-input v-model="dataForm.password" type="password" placeholder="密码"></el-input>
<el-input
v-model="dataForm.password"
type="password"
placeholder="密码"
></el-input>
</el-form-item>
<!-- <el-form-item prop="captcha">
<el-row :gutter="20">
@ -35,45 +52,85 @@
</el-row>
</el-form-item> -->
<el-form-item>
<el-button class="login-btn-submit" type="primary" @click="dataFormSubmit()">登录</el-button>
<el-button
class="login-btn-submit"
type="primary"
@click="dataFormSubmit()"
>登录</el-button
>
</el-form-item>
</el-form>
</el-tab-pane>
<el-tab-pane label="验证码登录" name="code_login">
<el-form :model="loginByYZMForm" :rules="loginByYZMFormRule" ref="loginByYZMRef"
@keyup.enter.native="loginByYZMSubmit()" status-icon>
<el-form
:model="loginByYZMForm"
:rules="loginByYZMFormRule"
ref="loginByYZMRef"
@keyup.enter.native="loginByYZMSubmit()"
status-icon
>
<el-form-item prop="mobile">
<el-input v-model="loginByYZMForm.mobile" placeholder="手机号码"></el-input>
<el-input
v-model="loginByYZMForm.mobile"
placeholder="手机号码"
></el-input>
</el-form-item>
<el-form-item prop="code">
<el-input v-model="loginByYZMForm.code" placeholder="短信验证码">
<el-input
v-model="loginByYZMForm.code"
placeholder="短信验证码"
>
<template slot="append">
<el-button v-if="mobileCodeCountDown <= 0" @click="getCode">获取验证码</el-button>
<el-button
v-if="mobileCodeCountDown <= 0"
@click="getCode"
>获取验证码</el-button
>
<el-button v-else>{{ mobileCodeCountDown }}s</el-button>
</template>
</el-input>
</el-form-item>
<el-form-item>
<el-button class="login-btn-submit" type="primary" @click="loginByYZMSubmit()">登录</el-button>
<el-button
class="login-btn-submit"
type="primary"
@click="loginByYZMSubmit()"
>登录</el-button
>
</el-form-item>
</el-form>
</el-tab-pane>
</el-tabs>
<el-form :model="loginByYZMForm" :rules="loginByYZMFormRule" ref="loginByYZMRef"
@keyup.enter.native="loginByYZMSubmit()" status-icon>
<el-form
:model="loginByYZMForm"
:rules="loginByYZMFormRule"
ref="loginByYZMRef"
@keyup.enter.native="loginByYZMSubmit()"
status-icon
>
<el-form-item prop="mobile">
<el-input v-model="loginByYZMForm.mobile" placeholder="手机号码"></el-input>
<el-input
v-model="loginByYZMForm.mobile"
placeholder="手机号码"
></el-input>
</el-form-item>
<el-form-item prop="code">
<el-input v-model="loginByYZMForm.code" placeholder="短信验证码">
<template slot="append">
<el-button v-if="mobileCodeCountDown <= 0" @click="getCode">获取验证码</el-button>
<el-button v-if="mobileCodeCountDown <= 0" @click="getCode"
>获取验证码</el-button
>
<el-button v-else>{{ mobileCodeCountDown }}s</el-button>
</template>
</el-input>
</el-form-item>
<el-form-item>
<el-button class="login-btn-submit" type="primary" @click="loginByYZMSubmit()">登录</el-button>
<el-button
class="login-btn-submit"
type="primary"
@click="loginByYZMSubmit()"
>登录</el-button
>
</el-form-item>
</el-form>
</div>
@ -125,7 +182,7 @@ export default {
this.getCaptcha();
},
methods: {
loginWayClick(tab, event) { },
loginWayClick(tab, event) {},
//
dataFormSubmit() {
const _loginTypeMapper = {
@ -344,7 +401,7 @@ export default {
.login-captcha {
overflow: hidden;
>img {
> img {
width: 100%;
cursor: pointer;
}