显示样式微调
This commit is contained in:
@@ -92,6 +92,18 @@
|
||||
<version>${springdoc.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- swagger-annotations 显式指定版本,防止 Spring Boot BOM 覆盖 -->
|
||||
<dependency>
|
||||
<groupId>io.swagger.core.v3</groupId>
|
||||
<artifactId>swagger-annotations</artifactId>
|
||||
<version>2.2.21</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.swagger.core.v3</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
<version>2.2.21</version>
|
||||
</dependency>
|
||||
|
||||
<!-- io常用工具类 -->
|
||||
<dependency>
|
||||
<groupId>commons-io</groupId>
|
||||
|
||||
@@ -52,7 +52,7 @@ public class AIController {
|
||||
|
||||
String prompt = "你是一个机票票务AI助手。请根据当前中国民航市场情况,生成当前最热门的国内航线列表。" +
|
||||
"请直接返回JSON数组,不要加markdown代码块标记,格式为:[{\"route\": \"北京-上海\", \"reason\": \"商务航线,客流量大\", \"rank\": 1}]。" +
|
||||
"返回8条,按热门程度排序,每条reason用中文简要描述热门原因。";
|
||||
"返回7条,按热门程度排序,每条reason用中文简要描述热门原因。";
|
||||
|
||||
String aiResponse = chatClient.prompt()
|
||||
.system("你是一个民航数据分析助手,只返回纯JSON数组,不要任何其他文字和markdown标记。")
|
||||
|
||||
@@ -28,10 +28,6 @@ public class SpringDocConfig
|
||||
@Value("${springdoc.enabled}")
|
||||
private boolean enabled;
|
||||
|
||||
/** 设置请求的统一前缀 */
|
||||
@Value("${springdoc.pathMapping}")
|
||||
private String pathMapping;
|
||||
|
||||
/**
|
||||
* 创建API
|
||||
*/
|
||||
|
||||
@@ -232,10 +232,14 @@ pagehelper:
|
||||
springdoc:
|
||||
# 是否开启springdoc
|
||||
enabled: true
|
||||
# 请求前缀
|
||||
pathMapping: /dev-api
|
||||
# 扫描包路径
|
||||
packages-to-scan: com.ruoyi.web.controller
|
||||
|
||||
api-docs:
|
||||
enabled: false # 开发环境true,生产环境改为false
|
||||
swagger-ui:
|
||||
enabled: true
|
||||
|
||||
# 防止XSS攻击
|
||||
xss:
|
||||
# 过滤开关
|
||||
|
||||
@@ -234,11 +234,12 @@ pagehelper:
|
||||
springdoc:
|
||||
# 是否开启springdoc
|
||||
enabled: true
|
||||
# 请求前缀
|
||||
pathMapping: /dev-api
|
||||
# 扫描包路径
|
||||
packages-to-scan: com.ruoyi.web.controller
|
||||
|
||||
api-docs:
|
||||
enabled: true # 开发环境true,生产环境改为false
|
||||
swagger-ui:
|
||||
enabled: true
|
||||
# 防止XSS攻击
|
||||
xss:
|
||||
# 过滤开关
|
||||
|
||||
@@ -268,7 +268,7 @@ const sendMessage = async () => {
|
||||
.ai-chat-float-btn {
|
||||
position: fixed;
|
||||
top: 8px;
|
||||
right: 110px;
|
||||
right: 115px;
|
||||
z-index: 999;
|
||||
width: 34px !important;
|
||||
height: 34px !important;
|
||||
|
||||
@@ -778,7 +778,7 @@ progress[value]::-webkit-progress-value {
|
||||
|
||||
// 3秒内紧急倒计时样式
|
||||
.countdown-urgent {
|
||||
background: rgba(255, 143, 145, 0.9);
|
||||
background: rgb(246 90 95 );
|
||||
color: #fff;
|
||||
font-size: 15px;
|
||||
font-weight: bold;
|
||||
@@ -891,7 +891,7 @@ progress[value]::-webkit-progress-value {
|
||||
display: flex !important;
|
||||
align-items: center !important;
|
||||
flex: 0 0 auto !important;
|
||||
padding-right: 10px;
|
||||
padding-right: 15px;
|
||||
}
|
||||
|
||||
.user-dropdown {
|
||||
|
||||
@@ -1,157 +0,0 @@
|
||||
<template>
|
||||
<div id="userLayout" :class="['user-layout-wrapper']">
|
||||
<div class="container">
|
||||
<div class="loginbox" style="width: 500px; height: 350px; padding: 20px; position: relative; top: -105px;">
|
||||
|
||||
<div class="main" style="float: none;height: 350px; margin: 0 auto;">
|
||||
<a-form id="loginForm" ref="loginFormRef" class="user-layout-login" :model="loginFormModel" :rules="loginFormRules" :scrollToFirstError="true">
|
||||
<!-- <a-page-header title="智汇票务" style="padding:10px;text-align: center;margin:10px; display: block" />-->
|
||||
<!-- <img src="/src/assets/images/login-icon.png" class="logo" alt="logo" style="margin-top:60px;width: 200px;height:100px" />-->
|
||||
<!-- Form校验时,需要给a-form-item添加name属性 -->
|
||||
<h1 style=" text-align: center; padding: 10px; margin: 10px; display: block;font-size: 24px;">智汇票务b</h1>
|
||||
<a-form-item name="username">
|
||||
<!-- 双向绑定,必须使用v-model:value -->
|
||||
<a-input v-model:value="loginFormModel.username" size="large" placeholder="用户名">
|
||||
<template #prefix>
|
||||
<UserOutlined style="padding-right: 5px; color: blue" />
|
||||
</template>
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
<a-form-item name="password">
|
||||
<a-input-password v-model:value="loginFormModel.password" size="large" placeholder="密码">
|
||||
<template #prefix>
|
||||
<LockOutlined style="padding-right: 5px; color: blue" />
|
||||
</template>
|
||||
</a-input-password>
|
||||
</a-form-item>
|
||||
<a-form-item name="code">
|
||||
<a-row :gutter="16">
|
||||
<a-col class="gutter-row" :span="16">
|
||||
<a-input v-model:value="loginFormModel.code" size="large" type="text" autocomplete="off" placeholder="验证码">
|
||||
<template #prefix>
|
||||
<SecurityScanOutlined style="padding-right: 5px; color: blue" />
|
||||
</template>
|
||||
</a-input>
|
||||
</a-col>
|
||||
<a-col class="gutter-row" :span="8">
|
||||
<img class="getCaptcha" :src="loginFormModel.codeUrl" @click="getVerifyCode" />
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-item>
|
||||
<a-form-item>
|
||||
<a-button size="large" type="primary" htmlType="submit" class="login-button" :disabled="loginFormModel.loginButtonDisabled" :loading="loginFormModel.loginButtonLoading" @click="submitForm()">{{ loginFormModel.loginButtonName }}</a-button>
|
||||
</a-form-item>
|
||||
<!-- <a-form-item>-->
|
||||
<!-- <div style="float: left; line-height: 30px">-->
|
||||
<!-- 还没有账号?-->
|
||||
<!-- <a-button type="link">立即注册</a-button>-->
|
||||
<!-- <a-button type="link">忘记密码</a-button>-->
|
||||
<!-- <!– <a-input v-model:value="loginFormModel.uuid"></a-input> –>-->
|
||||
<!-- </div>-->
|
||||
<!-- </a-form-item>-->
|
||||
</a-form>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="footer">
|
||||
<div class="links">
|
||||
<a href="https://github.com/fuzui/AiDex-Antdv" target="_blank">帮助</a>
|
||||
<a href="https://github.com/fuzui/AiDex-Antdv" target="_blank">隐私</a>
|
||||
<a href="https://github.com/fuzui/AiDex-Antdv" target="_blank">条款</a>
|
||||
</div>
|
||||
<div class="copyright">
|
||||
Copyright © 2021 <a target="_blank"></a>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { getVerifyCodeImg } from '../api/login.js';
|
||||
import {ref, reactive, onMounted} from 'vue';
|
||||
import { useRoute, useRouter } from 'vue-router';
|
||||
import { useStore } from 'vuex';
|
||||
import { UserOutlined, LockOutlined, SecurityScanOutlined } from '@ant-design/icons-vue';
|
||||
|
||||
// 获取router变量
|
||||
const vueRouter = useRouter();
|
||||
// 获取store变量
|
||||
const vueStore = useStore();
|
||||
|
||||
const loginFormRef = ref();
|
||||
// 定义表单对象
|
||||
const loginFormModel = reactive({
|
||||
// username: "",admin
|
||||
// password: "",admin123
|
||||
// code: "",
|
||||
username: '',
|
||||
password: '',
|
||||
code: '',
|
||||
uuid: '',
|
||||
codeUrl: '',
|
||||
loginButtonDisabled: false,
|
||||
loginButtonLoading: false,
|
||||
loginButtonName: '登录',
|
||||
});
|
||||
// 定义表单校验规则
|
||||
const loginFormRules = reactive({
|
||||
username: [{ required: true, message: '请输入用户名!', trigger: 'blur' }],
|
||||
password: [{ required: true, message: '请输入密码!', trigger: 'blur' }],
|
||||
code: [{ required: true, message: '请输入验证码!', trigger: 'blur' }],
|
||||
});
|
||||
|
||||
// 获取验证码
|
||||
const getVerifyCode = () => {
|
||||
getVerifyCodeImg().then((res) => {
|
||||
// this.captchaOnOff = res.data.captchaOnOff === undefined ? true : res.data.captchaOnOff;
|
||||
// if (this.captchaOnOff) {
|
||||
loginFormModel.codeUrl = 'data:image/gif;base64,' + res.img;
|
||||
loginFormModel.uuid = res.uuid;
|
||||
// }
|
||||
});
|
||||
};
|
||||
|
||||
// 提交表单方法
|
||||
const submitForm = () => {
|
||||
loginFormModel.loginButtonDisabled = true;
|
||||
loginFormModel.loginButtonLoading = true;
|
||||
loginFormModel.loginButtonName = '登录中...';
|
||||
loginFormRef.value
|
||||
.validate()
|
||||
.then(() => {
|
||||
vueStore
|
||||
.dispatch('Login_Action', loginFormModel)
|
||||
.then(() => {
|
||||
// 登陆成功,跳转到主页
|
||||
vueRouter.push({ path: '/home' }).catch(() => {});
|
||||
})
|
||||
.catch(() => {
|
||||
loginFormModel.loginButtonDisabled = false;
|
||||
loginFormModel.loginButtonLoading = false;
|
||||
loginFormModel.loginButtonName = '登录';
|
||||
// this.loading = false;
|
||||
// if (this.captchaOnOff) {
|
||||
// this.getCode();
|
||||
// }
|
||||
});
|
||||
})
|
||||
.catch((error) => {
|
||||
loginFormModel.loginButtonDisabled = false;
|
||||
loginFormModel.loginButtonLoading = false;
|
||||
loginFormModel.loginButtonName = '登录';
|
||||
console.log('error', error);
|
||||
});
|
||||
};
|
||||
// 重置表单方法
|
||||
const resetForm = () => {
|
||||
loginFormRef.value.resetFields();
|
||||
};
|
||||
onMounted(async ()=>{
|
||||
// 默认调用获取验证码方法
|
||||
getVerifyCode();
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="less">
|
||||
@import '@/assets/styles/loginPage/loginPageStyles.less';
|
||||
</style>
|
||||
@@ -668,7 +668,7 @@ defineExpose({ showOrderDetail });
|
||||
}
|
||||
|
||||
.ticketedCell {
|
||||
background-color: #24e72a;
|
||||
background-color: #66d36a;
|
||||
color: #ffffff;
|
||||
height: 22px;
|
||||
text-align: center;
|
||||
|
||||
@@ -1211,7 +1211,7 @@ const tongchengNotify = async () => {
|
||||
padding: 0 6px;
|
||||
}
|
||||
.orderTable .ticketedCell {
|
||||
background-color: #24e72a;
|
||||
background-color: #66d36a;
|
||||
color: #ffffff;
|
||||
height: 22px;
|
||||
text-align: center;
|
||||
|
||||
Reference in New Issue
Block a user