@@ -106,7 +106,10 @@ router.beforeEach(async (to, from, next) => {
const userStore = useUserStore()
userStore.clearUsername()
if (whiteList.includes(from.path)) {
- ElMessage.warning('Please log in to use this feature.')
+ ElMessage.warning({
+ message: 'Please log in to use this feature.',
+ grouping: true
+ })
next(false)
return
} else {
@@ -236,6 +236,9 @@ div.el-message {
display: flex;
justify-content: center;
width: 800px;
+ .el-badge.el-message__badge {
+ display: none;
+ }
}
div.el-message--error {
--el-message-bg-color: #faebec;
@@ -60,7 +60,10 @@ class HttpAxios {
router.push('/login')
} else if (response.data.code !== 200 && response.data.code !== 400) {
ElMessageBox.alert(
response.data?.data?.msg || 'The request failed. Please try again later',
@@ -13,6 +13,9 @@ const headerSearch = useHeaderSearch()
const searchValue = ref('')
const handleSearch = () => {
+ if (!searchValue.value) {
+ return
// 先判断是否登录
// 未登录
if (!localStorage.getItem('username')) {
@@ -115,7 +115,10 @@ const whiteList = ['/login', '/public-tracking', '/public-tracking/detail', '/re
const isAllowJump = (path: any) => {
// 判断是否登录
if (!whiteList.includes(path) && !localStorage.getItem('username')) {
activeMenu.value = route.path // 保持选中状态不变
return false
@@ -30,6 +30,9 @@ watch(
const loading = ref(false)
const handleSearchNo = () => {
+ if (!inputVModel.value) {
loading.value = true
$api
.getPublicTrackingDetail({ reference_number: inputVModel.value })