|
@@ -2,11 +2,15 @@
|
|
import { ref, unref } from 'vue';
|
|
import { ref, unref } from 'vue';
|
|
import { userApi } from '@/api/login';
|
|
import { userApi } from '@/api/login';
|
|
import { useUserStore } from '@/stores/modules/userStore';
|
|
import { useUserStore } from '@/stores/modules/userStore';
|
|
|
|
+import { AES_ECB_ENCRYPT } from "@/utils/crypto";
|
|
|
|
+
|
|
|
|
+const IMG_PATH = import.meta.env.VITE_IMGAGE_PATH;
|
|
|
|
|
|
const REMOTE_PATH = {
|
|
const REMOTE_PATH = {
|
|
- logo : 'https://static.fuxicarbon.com/bigModel/wechat/login/img-desc.png',
|
|
|
|
- username: 'https://static.fuxicarbon.com/bigModel/wechat/login/icon-username.png',
|
|
|
|
- password: 'https://static.fuxicarbon.com/bigModel/wechat/login/icon-password.png'
|
|
|
|
|
|
+ logoEn : IMG_PATH +'/login/img-en-logo.svg',
|
|
|
|
+ logoZh : IMG_PATH +'/login/img-zh-logo.svg',
|
|
|
|
+ username : IMG_PATH + '/login/icon-username.png',
|
|
|
|
+ password : IMG_PATH + '/login/icon-password.png'
|
|
}
|
|
}
|
|
|
|
|
|
const userStore = useUserStore();
|
|
const userStore = useUserStore();
|
|
@@ -14,7 +18,7 @@ const userStore = useUserStore();
|
|
const showPasswordIcon = ref(false);
|
|
const showPasswordIcon = ref(false);
|
|
const loading = ref(false);
|
|
const loading = ref(false);
|
|
const loginFormData = ref({
|
|
const loginFormData = ref({
|
|
- username: 'test1',
|
|
|
|
|
|
+ username: 'test11',
|
|
password: 'admin123',
|
|
password: 'admin123',
|
|
type: 0
|
|
type: 0
|
|
});
|
|
});
|
|
@@ -33,7 +37,7 @@ const handleSubmit = async () => {
|
|
loading.value = true;
|
|
loading.value = true;
|
|
|
|
|
|
try {
|
|
try {
|
|
- const { token } = await userApi.postLogin({ username, password, type: 0 });
|
|
|
|
|
|
+ const { token } = await userApi.postLogin({ username, password: AES_ECB_ENCRYPT(password), type: 0 });
|
|
|
|
|
|
userStore.setUserInfo({ token });
|
|
userStore.setUserInfo({ token });
|
|
|
|
|
|
@@ -57,7 +61,12 @@ const handleSubmit = async () => {
|
|
<BaseNavBar title-text="登录" class="nav-bar"></BaseNavBar>
|
|
<BaseNavBar title-text="登录" class="nav-bar"></BaseNavBar>
|
|
<view class="login-content">
|
|
<view class="login-content">
|
|
<view class="logo-inner">
|
|
<view class="logo-inner">
|
|
- <image :src="REMOTE_PATH.logo" class="img-desc"></image>
|
|
|
|
|
|
+ <view class="en-logo"><image :src="REMOTE_PATH.logoEn" class="img"></image></view>
|
|
|
|
+ <view class="zh-logo"><image :src="REMOTE_PATH.logoZh" class="img"></image></view>
|
|
|
|
+ <view class="text-desc">
|
|
|
|
+ <text>国内首家水务行业大模型,赋能水务行业,为水务行业主体</text>
|
|
|
|
+ <text>提供创新应用和全面支持</text>
|
|
|
|
+ </view>
|
|
</view>
|
|
</view>
|
|
<view class="form-inner">
|
|
<view class="form-inner">
|
|
<view class="login-form-item">
|
|
<view class="login-form-item">
|
|
@@ -77,7 +86,7 @@ const handleSubmit = async () => {
|
|
</button>
|
|
</button>
|
|
</view>
|
|
</view>
|
|
<view class="text-inner">
|
|
<view class="text-inner">
|
|
- <text>人工智能运营体智慧决策助手</text>
|
|
|
|
|
|
+ <text>内容由AI生成,仅供参考</text>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
@@ -99,9 +108,25 @@ const handleSubmit = async () => {
|
|
padding: 132rpx 60rpx 36rpx 60rpx;
|
|
padding: 132rpx 60rpx 36rpx 60rpx;
|
|
|
|
|
|
.logo-inner {
|
|
.logo-inner {
|
|
- .img-desc {
|
|
|
|
- width: 500rpx;
|
|
|
|
- height: 96rpx;
|
|
|
|
|
|
+ .en-logo {
|
|
|
|
+ width: 152rpx;
|
|
|
|
+ height: 36rpx;
|
|
|
|
+ }
|
|
|
|
+ .zh-logo {
|
|
|
|
+ width: 360rpx;
|
|
|
|
+ height: 76rpx;
|
|
|
|
+ }
|
|
|
|
+ .img {
|
|
|
|
+ width: 100%;
|
|
|
|
+ height: 100%;
|
|
|
|
+ }
|
|
|
|
+ .text-desc {
|
|
|
|
+ display: flex;
|
|
|
|
+ align-items: start;
|
|
|
|
+ flex-flow: column;
|
|
|
|
+ font-size: 24rpx;
|
|
|
|
+ color: #595959;
|
|
|
|
+ line-height: 36rpx;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -165,7 +190,7 @@ const handleSubmit = async () => {
|
|
padding-bottom: 50rpx;
|
|
padding-bottom: 50rpx;
|
|
font-size: 28rpx;
|
|
font-size: 28rpx;
|
|
text-align: center;
|
|
text-align: center;
|
|
- color: #727687;
|
|
|
|
|
|
+ color: rgba(114, 118, 135, 0.50);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|