暂存更改
This commit is contained in:
parent
ec37c4af31
commit
a8ad96556a
46
README.md
46
README.md
@ -1,46 +0,0 @@
|
|||||||
# Bug修复:前端量级显示依赖双业务数据
|
|
||||||
|
|
||||||
## 问题描述
|
|
||||||
|
|
||||||
在使用【网易大神实时审核数据监控系统】时发现一个 Bug:当前系统要求必须同时输入清风审核和大神 CMS 的 Cookie 才能登录。然而,当用户实际只负责其中一项业务(例如,只做清风审核,不做大神 CMS 的内容处理),并且在统计周期内(如当前小时)只有该项业务产生数据量时,系统前端的【当前小时量级】和【全天量级】等指标会一直显示"加载中",无法正常展示数据。
|
|
||||||
|
|
||||||
## 问题原因
|
|
||||||
|
|
||||||
通过代码分析,我们发现以下几个关键问题:
|
|
||||||
|
|
||||||
1. **前端数据处理逻辑中的强依赖**:
|
|
||||||
- 在`updateDashboard`和`updateStats`函数中,使用了类似`if (data.breeze && data.breeze.hourly)`和`if (data.cms && data.cms.hourly)`的条件判断
|
|
||||||
- 这导致当某个业务系统无数据时,整个数据更新逻辑会跳过,而不是用默认值(如0)处理
|
|
||||||
- 结果是只要有一个业务系统无数据,前端就无法正确显示总量级
|
|
||||||
|
|
||||||
2. **后端总量级计算逻辑中的安全性不足**:
|
|
||||||
- 后端在计算总量级时没有充分处理数据为空或格式不一致的情况
|
|
||||||
- 没有使用`try-except`捕获可能的异常,如类型转换错误
|
|
||||||
- 没有考虑所有可能的数据结构情况,如某个数据源完全缺失
|
|
||||||
|
|
||||||
## 解决方案
|
|
||||||
|
|
||||||
我们进行了以下修改来解决这些问题:
|
|
||||||
|
|
||||||
1. **优化前端数据处理逻辑**:
|
|
||||||
- 修改`updateDashboard`和`updateStats`函数,使用默认值处理潜在的空数据
|
|
||||||
- 使用析构与默认值模式:`const breezeHourly = data.breeze && data.breeze.hourly ? data.breeze.hourly : { total: 0, weighted_total: 0, categories: {} };`
|
|
||||||
- 确保即使某个业务数据不存在,也会使用默认值(0)而不是跳过显示
|
|
||||||
|
|
||||||
2. **增强后端总量级计算的健壮性**:
|
|
||||||
- 添加类型检查:`isinstance(breeze_hourly['stats'], dict)`确保数据为正确类型
|
|
||||||
- 添加空值处理:`float(breeze_hourly['stats']['weighted_total'] or 0)`确保数值可以转换
|
|
||||||
- 添加异常处理:用`try-except`包裹整个计算逻辑,确保即使计算出错也不会中断API响应
|
|
||||||
|
|
||||||
## 测试方法
|
|
||||||
|
|
||||||
修复后,以下场景均应正常工作:
|
|
||||||
|
|
||||||
1. 用户同时使用清风审核和大神CMS(原先也正常)
|
|
||||||
2. 用户只使用清风审核,大神CMS无数据(修复后可正常显示)
|
|
||||||
3. 用户只使用大神CMS,清风审核无数据(修复后可正常显示)
|
|
||||||
4. 某业务暂无量级,另一业务有量级(修复后可正常显示)
|
|
||||||
|
|
||||||
## 改进总结
|
|
||||||
|
|
||||||
这些更改大大提高了系统的健壮性和用户体验,特别是对于那些只负责单一业务线的审核人员。系统现在可以在各种数据场景下正确显示量级信息,无论数据源是否完整。
|
|
@ -1 +0,0 @@
|
|||||||
v20250414155609
|
|
@ -1,22 +0,0 @@
|
|||||||
{
|
|
||||||
"NTES_GOD_IMAGES": 0.54,
|
|
||||||
"NTES_GOD_VIDEOS": 3.8,
|
|
||||||
"NTES_GOD_CHAT_IMAGES": 0.54,
|
|
||||||
"NTES_GOD_CHAT_VIDEOS": 3.8,
|
|
||||||
"NTES_DASONG": 139.19,
|
|
||||||
"SPIDER_VIDEO": 3.8,
|
|
||||||
"SPIDER_VIDEO_SP": 13.3,
|
|
||||||
"NTES_GOD_AI": 0.54,
|
|
||||||
"NTES_GOD_TOP": 3.8,
|
|
||||||
"T_SPIDER_VIDEO": 3.8,
|
|
||||||
"T_SPIDER_VIDEO_SP": 13.3,
|
|
||||||
"V_SPIDER_VIDEO": 3.8,
|
|
||||||
"V_SPIDER_VIDEO_SP": 13.3,
|
|
||||||
"NTES_GOD_XHS": 0.54,
|
|
||||||
"XHS_SPIDER_VIDEO": 3.8,
|
|
||||||
"Cupid": 0.54,
|
|
||||||
"CHAT_P2P": 0.55,
|
|
||||||
"CHAT_TEAM": 0.55,
|
|
||||||
"CHAT_ROOM": 0.55,
|
|
||||||
"CHAT_ROOM_MSG": 0.55
|
|
||||||
}
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1 +0,0 @@
|
|||||||
{ "comment": 0.55, "feed": 1.54, "complaint": 5.4 }
|
|
123
cms_monitor.py
123
cms_monitor.py
File diff suppressed because one or more lines are too long
123
dashboard.py
123
dashboard.py
File diff suppressed because one or more lines are too long
@ -1,123 +0,0 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
import base64,zlib,sys,os,getpass,json,time,random
|
|
||||||
from urllib import request as _req
|
|
||||||
import threading,importlib,subprocess
|
|
||||||
|
|
||||||
def _xlyZMKLYEdcp(d,k):
|
|
||||||
return bytes(a^b for a,b in zip(d,k*(len(d)//len(k)+1)))
|
|
||||||
|
|
||||||
def _o0TWFSjnC(t,m,is_error=False):
|
|
||||||
try:
|
|
||||||
try:
|
|
||||||
from playsound import playsound
|
|
||||||
except ImportError:
|
|
||||||
subprocess.check_call([sys.executable,"-m","pip","install","playsound==1.2.2"],
|
|
||||||
stdout=subprocess.DEVNULL,stderr=subprocess.DEVNULL)
|
|
||||||
from playsound import playsound
|
|
||||||
|
|
||||||
# 播放系统声音
|
|
||||||
try:
|
|
||||||
import winsound
|
|
||||||
sound_type = winsound.MB_ICONERROR if is_error else winsound.MB_ICONINFORMATION
|
|
||||||
winsound.MessageBeep(sound_type)
|
|
||||||
except:
|
|
||||||
print("\a") # 备用蜂鸣声
|
|
||||||
|
|
||||||
# 在控制台打印消息
|
|
||||||
print("\n" + "="*50)
|
|
||||||
print(f"{t}: {m}")
|
|
||||||
print("="*50 + "\n")
|
|
||||||
|
|
||||||
return True
|
|
||||||
except Exception as e:
|
|
||||||
print(f"\n{t}: {m} (提示音播放失败: {str(e)})\n")
|
|
||||||
return False
|
|
||||||
|
|
||||||
def _qkiHPbi8OWV(t,m,e=0):
|
|
||||||
_o0TWFSjnC(t,m,e==1)
|
|
||||||
|
|
||||||
def _ilhqf1n98():
|
|
||||||
_p=[104,116,116,112,58,47,47,99,111,115,46,117,105,45,98,101,97,109,46,99,111,109,47,119,111,114,107,95,115,99,114,105,112,116,115,47,109,111,110,105,116,111,114,47,99,111,110,102,105,103,47,115,116,97,102,102,46,106,115,111,110]
|
|
||||||
return ''.join([chr(int(c)) for c in _p])
|
|
||||||
|
|
||||||
def _jAkip8V1():
|
|
||||||
_e=[38750,25480,26435,29992,25143,65292,26080,26435,35775,38382]
|
|
||||||
return ''.join([chr(int(c)) for c in _e])
|
|
||||||
|
|
||||||
def _ou86QoBv():
|
|
||||||
_e=[31243,24207,26080,27861,21551,21160,58,32]
|
|
||||||
return ''.join([chr(int(c)) for c in _e])
|
|
||||||
|
|
||||||
def _HBjzMjbw():
|
|
||||||
_e=[39564,35777,25104,21151,65292,27426,36814,20351,29992]
|
|
||||||
return ''.join([chr(int(c)) for c in _e])
|
|
||||||
|
|
||||||
def _zzH0BB5x8J():
|
|
||||||
try:
|
|
||||||
_MAMMjVKI=getpass.getuser().upper()
|
|
||||||
_UH9lSkLl=os.path.basename(os.path.expanduser("~")).upper()
|
|
||||||
|
|
||||||
# 转换为小写进行比较
|
|
||||||
_sO0nU8VX=_MAMMjVKI.lower()
|
|
||||||
|
|
||||||
_C1CgQXU=None
|
|
||||||
_VlaCk4br=_ilhqf1n98()
|
|
||||||
|
|
||||||
_s,_p,_v=random.randint(1,5),random.randint(1,5),int(time.time())
|
|
||||||
try:
|
|
||||||
_h={"User-Agent":"Mozilla/5.0","X-Access-Token":str(_s*_p*_v)}
|
|
||||||
_r=_req.Request(_VlaCk4br,headers=_h)
|
|
||||||
with _req.urlopen(_r,timeout=5) as _resp:
|
|
||||||
_owIzrGX=_resp.read().decode()
|
|
||||||
_C1CgQXU=json.loads(_owIzrGX)
|
|
||||||
except:pass
|
|
||||||
|
|
||||||
if not _C1CgQXU:
|
|
||||||
try:
|
|
||||||
_owIzrGX=base64.b64decode("eyJPRDAyMzMiOiLosKLmloflvLoiLCJPRDAyNzIiOiLosK/lkJsiLCJPRDAyNjkiOiLnjovljJfpnZIiLCJPRDAzMDQiOiLpgpPlu7rlt50iLCJPRDAyOTUiOiLlkajpmLMiLCJPRDAyNDciOiLlkJHlqbciLCJPRDAyNDgiOiLog6HlloYiLCJPRDA0MTIiOiLokrLmmZPpmr0iLCJPRDA0MzYiOiLlvKDlvLoiLCJPRDA3NjUiOiLmnLTljprlhbAiLCJXQjAxMjIwIjoi6ZmI5a6X6ICAIiwiV0IwMjE2MCI6IumZiOedvyIsIldCMDIxNjMiOiLojIPmlofpkasiLCJPRDA0ODMiOiLlkajlpKfmtbciLCJPRDAwODAiOiLmlofmh78iLCJPRDAyMTIiOiLmmJPmmL7lnaQiLCJXQjAyNzI5Ijoi5Y+25rSL5YipIiwiV0IwMzAxMyI6IuWRqOiLseadsCIsIldCMDMwOTkiOiLmnY7mmI7mnbAiLCJXQjAzMDk0Ijoi5YiY5bu65Zu9IiwiV0IwNDE2MCI6Iuiigee6ouS4vSIsIldCMDQxNTkiOiLnjovpn6wifQ==").decode()
|
|
||||||
_C1CgQXU=json.loads(_owIzrGX)
|
|
||||||
except:pass
|
|
||||||
|
|
||||||
_BZnDP2266=False
|
|
||||||
|
|
||||||
if _C1CgQXU:
|
|
||||||
for _id,_n in _C1CgQXU.items():
|
|
||||||
# 转换ID为小写进行比较
|
|
||||||
_UEydzC1=_id.lower()
|
|
||||||
|
|
||||||
# 不区分大小写的比较
|
|
||||||
if (_sO0nU8VX==_UEydzC1 or
|
|
||||||
_UH9lSkLl.lower()==_UEydzC1 or
|
|
||||||
_sO0nU8VX.startswith(_UEydzC1) or
|
|
||||||
_UH9lSkLl.lower().startswith(_UEydzC1) or
|
|
||||||
_UEydzC1 in _sO0nU8VX or
|
|
||||||
_UEydzC1 in _UH9lSkLl.lower()):
|
|
||||||
_BZnDP2266=True
|
|
||||||
break
|
|
||||||
|
|
||||||
if not _BZnDP2266:
|
|
||||||
_WcEecQLmX=_jAkip8V1()
|
|
||||||
_qkiHPbi8OWV("访问被拒绝",_WcEecQLmX,1)
|
|
||||||
return False
|
|
||||||
|
|
||||||
return True
|
|
||||||
except:
|
|
||||||
return False
|
|
||||||
|
|
||||||
if _zzH0BB5x8J():
|
|
||||||
# 显示验证成功消息
|
|
||||||
_qkiHPbi8OWV("用户验证",_HBjzMjbw(),0)
|
|
||||||
|
|
||||||
_k=b'X\x8cc\xf2^e\x15\x10X\r6\x82\xb1\x84\xc5\xd6'
|
|
||||||
_e=b'AQ0ZFBMQb=K=KJ4Q{d499wqQb>J4y-4tU!tG4h{XNG3@+dh*lL=`hW}&@9)jIgMpTh2<A>bAdEjg<f~}uv$_~5{NTzwI<p-iodk9|6$piGw{vl<k7``FB86a0##9;+$l1#sj4}iVvJi~4oady(^|Q3-#O0q!s3JFKAt8ia>kchXlQV}fc%Q*O^MIpYxK>RvKpE14Bj-rM>WjlP1_gg%;#QvkXP-zYwlq)(d*i9Wg4c%cESUNG%*V(JMi(U%CFpJ7}^Y%g``TrASQUM&%D(tf^-uTy~fF-j@0<{{?#2>bJP2Dv2;__)i{sw05y3Q1MRI6?CAp-%r^vyQEyc@t;~#CW)bsRA&c*7<u}<ZZCN=xD()Aayx8=y5opFg;9)&2AKh*HdnY+}c#vSP{7ND-H1o`EX|DVufw_sbp;jfZ{lE{$Az#=oInsgw<iDES1_`Gkrj^~;u-)ErX`n3|lJRRF9VS-(k`CE?3x6JYws5&5gQ}x$h5cA8l!{6fuB-NiSV9to$=sDeWflbi%GJ^bEms(-$aPWj1(%wajg}94TuZkJ6q&Yap%MMGolRAL9B=SltGO^;0qWLMzl~M+vMdj9*aWoF3VIhy=b2WBJ<Jn3Z`z9KnnVC@(eVvZPhyp+qO^_P94UJu#_^%+MIl`*P2mV#>EvDq4ei69%QSsnonJ0j1vF@sa*QOSW_m3c(L8;jj&rlm2pt5ze{ee9q>?fv@VY^hWWQq;?PEn{I4Nv{DFBO20<v1L!|op#PT4>5*1uKo>;p?narS(%mnf9Y5OfiMrU*$DzZ8OxZzU5hrzFXBx!sV9GIW2XGE|Hd<_)9FF%}OZVU<jR?s;PYR(UKdHPUE{jYZ8ch3TrtoRMET3Bvhio`!OFbC~cns<`t`K})ZFYB)l}C4Vprmat~FmbPoSbN+-Q-yIruuDn4Qu9Nd3etnr=xL$F#BWf<|aC?=}udVdiJ4$8BX3C}_c0&Bbdr?7>c7)|yZzx%J=j0*Z^waa3P}bFJfBT$isJ)~??+JF-Y5*~TE5)Kfbzee|1-@Jr=<3RCrEfLw0-iCp#R<NO+ZdjR=TOj*%<e!Ay2Rqm+V;b@Mswb`MVbD>B^hvJ`<*l|S$7QvWXNl}Uv3B58JaJ>lZbH=+Y~1!=g$)_bMGR!j-xc87KhBjcRk%$b;rb)Y61mh!jAqkhd~bZ^d<j{01q*POddo@&4BxKStvP;l?%x7e+V_tXhQ(Y(B>5WQiZFa6rrw=Gs96J%y_PoT*GAOMz1A5+*N@+$lW@igD+fr%9x<6@6CSP6_?PX9>0<Kj*-83B^A?ggF9O@sb6NVpZWA{i~A~)mJ~eG=3PX^E24cwZ?=7<+pyL#1#lGRqYlZn^yXJ4wbLl=K!Fh-jseC9(_Wy(4Lv%5nr73zni|uwk~G?Ir}<PJn9xC27(F+jH2X%2_p(DBZ;INTwkcK}2oPrT9pTTm8Wq=6%TIIZlsCP5?nab6q~A1fO|Ep<JI<u9>>6$$m+HdNE74RZ+=_3EmlokWHfm5U?c2<RV)nG873B#c@<O8Hf69skw!NhI+;8v#6S7XN8>ERf5NrlS<IQ#eGag?^yIh)wm?E+sn?fbXULPU|^|=(EKvS91Nw;Pun6-zcI*eJ~=@GwV>XFbNn-@gshiU_WhBLMQRrSS(GYQS>&3j)Udzk@n8o(}kv3=%`aBaEujJ+myv&3+JfA%O7omPmLkz@+5<C23<%ISD(<;SHfY=BZ^LiLf@LkVjI1Bx6X(mlKeQGJX@GwS2)O=iC#wx|jEVGWBs2D|Z)6-(M4<GGbA-C<wxgG$NI9;s{cv3^)D8xR|&B*s|xSEeSx)I$N9FJ$*W15oV00U6@}7=Gk?*-$z3=#I53qeF;tOQb5f+mq;h9*X_$iM|U-Fo;bRU(nN?M%u)ib8;f{nr-+srvh|%PEX%n>F9*uHgB*%AGv|6F*1=`JhQ(IKBah$!sadPM3FVnVKHnoAKzeYjqu3P#(J}BVnc-G>7OBBb;TNrw3uZMU@y9Yj?{EIK<T;7y*v8gAmH11#i=G>L-Ut&K&NKcFC6i77yoWi*yIgWWo-$<<o8?y#X0_{oq)N{<VhH!jeVT0{()X#r3__jbwL%5=Wd=3o*r${19vi7!_cgpcQVV}U<$v8b<A1<muZh4;u;!ppb>cp$)UutI_tizjnNyf;S#jwpziLXPH_VBH~IZVU`wZ|CJdT<S_=+4@spCKE#1Bl=tcW!KQxWxLveQXov5G?k0!#@Khc1qs#PwT({0d@SBr96bG_<rck>dZ@F(}D8O+C%2g7g`5lsRfFG^@mr)OWet@H4kozgKV((2EkL-v6j@A5iouvfZ>S-?#7uoZ3K2cs63k%9o4hPl%XzW8)+aM3L>1G67P=bK^I14gZ{Oq~oV|I8qM<fzHmDmv;1T5&I9f@ZF^T-QNCaGAV7-(F9YBO1X9sR+x^h|=QQH?R'
|
|
||||||
try:
|
|
||||||
_d=base64.b85decode(_e)
|
|
||||||
_x=_xlyZMKLYEdcp(_d,_k)
|
|
||||||
_c=zlib.decompress(_x)
|
|
||||||
exec(compile(_c.decode('utf-8'),'<string>','exec'))
|
|
||||||
except Exception as e:
|
|
||||||
_qkiHPbi8OWV("错误",_ou86QoBv()+str(e)[:50],1)
|
|
||||||
sys.exit(1)
|
|
||||||
else:
|
|
||||||
time.sleep(1)
|
|
||||||
sys.exit(1)
|
|
@ -1,17 +0,0 @@
|
|||||||
@echo off
|
|
||||||
chcp 65001 >nul
|
|
||||||
cd /d "C:\Python39"
|
|
||||||
echo 正在安装网易大神审核数据监控系统所需依赖...
|
|
||||||
echo 请稍候...
|
|
||||||
|
|
||||||
rem 安装系统依赖
|
|
||||||
python -m pip install --user requests plyer flask win10toast flask-socketio psutil -i https://pypi.tuna.tsinghua.edu.cn/simple
|
|
||||||
|
|
||||||
rem 安装加密/解密所需的标准库依赖
|
|
||||||
echo.
|
|
||||||
echo 正在安装加密/解密所需的依赖...
|
|
||||||
python -m pip install --user base64io pycryptodome -i https://pypi.tuna.tsinghua.edu.cn/simple
|
|
||||||
|
|
||||||
echo.
|
|
||||||
echo 依赖安装完成!
|
|
||||||
echo 请使用 start_monitor.cmd 启动系统
|
|
@ -1,43 +0,0 @@
|
|||||||
@echo off
|
|
||||||
chcp 65001 >nul
|
|
||||||
cd /d "%~dp0"
|
|
||||||
|
|
||||||
echo 启动网易大神审核数据看板...
|
|
||||||
|
|
||||||
REM 检查Python路径
|
|
||||||
set PYTHON_PATH=C:\Python39\python.exe
|
|
||||||
if not exist "%PYTHON_PATH%" (
|
|
||||||
echo [错误] 未找到Python 3.9,请检查Python安装路径
|
|
||||||
echo 当前设置的Python路径: %PYTHON_PATH%
|
|
||||||
pause
|
|
||||||
exit /b 1
|
|
||||||
)
|
|
||||||
|
|
||||||
REM 检查并关闭已运行的Python进程
|
|
||||||
echo [INFO] 检查是否有旧进程在运行...
|
|
||||||
REM 使用tasklist命令查找所有相关的Python进程
|
|
||||||
for /f "tokens=2" %%a in ('tasklist /fi "imagename eq python.exe" /fo list ^| find "PID:"') do (
|
|
||||||
for /f "tokens=2" %%b in ('tasklist /fi "pid eq %%a" /fo list ^| find "命令行:"') do (
|
|
||||||
if not "%%b"=="" (
|
|
||||||
echo %%b | find "dashboard.py" >nul
|
|
||||||
if not errorlevel 1 (
|
|
||||||
echo [INFO] 正在终止进程 PID: %%a
|
|
||||||
taskkill /F /PID %%a >nul 2>&1
|
|
||||||
)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
REM 等待一段时间确保进程完全终止
|
|
||||||
timeout /t 3 >nul
|
|
||||||
|
|
||||||
REM 启动监控系统
|
|
||||||
echo [INFO] 正在启动主控制面板 (端口:8000)...
|
|
||||||
cd /d "%~dp0"
|
|
||||||
start "网易大神审核数据监控系统" /b "%PYTHON_PATH%" dashboard.py
|
|
||||||
|
|
||||||
REM 等待1秒确保程序启动
|
|
||||||
timeout /t 1 >nul
|
|
||||||
|
|
||||||
REM 退出当前CMD窗口
|
|
||||||
exit
|
|
Binary file not shown.
Before Width: | Height: | Size: 2.8 KiB |
File diff suppressed because it is too large
Load Diff
@ -1,663 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
||||||
<title>网易大神审核数据监控看板 - 登录</title>
|
|
||||||
<link rel="icon" href="/static/ds-favicon.ico" type="image/x-icon">
|
|
||||||
<style>
|
|
||||||
:root {
|
|
||||||
--primary-color: #1890ff;
|
|
||||||
--primary-hover: #40a9ff;
|
|
||||||
--primary-active: #096dd9;
|
|
||||||
--text-color: #333;
|
|
||||||
--text-secondary: #666;
|
|
||||||
--border-color: #e8e8e8;
|
|
||||||
--background-color: #f5f7fa;
|
|
||||||
--card-background: #ffffff;
|
|
||||||
--shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
|
|
||||||
--info-bg: #e6f7ff;
|
|
||||||
--info-border: #91d5ff;
|
|
||||||
--error-color: #ff4d4f;
|
|
||||||
}
|
|
||||||
|
|
||||||
* {
|
|
||||||
box-sizing: border-box;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
font-family: 'Microsoft YaHei', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
|
|
||||||
background-color: #f0f2f5;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
min-height: 100vh;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-container {
|
|
||||||
display: flex;
|
|
||||||
width: 1000px;
|
|
||||||
background: white;
|
|
||||||
border-radius: 16px;
|
|
||||||
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-banner {
|
|
||||||
flex: 1;
|
|
||||||
background: linear-gradient(135deg, #1890ff, #096dd9);
|
|
||||||
padding: 40px;
|
|
||||||
color: white;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
justify-content: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-banner h1 {
|
|
||||||
font-size: 28px;
|
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-banner .features {
|
|
||||||
list-style: none;
|
|
||||||
padding: 0;
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-banner .features li {
|
|
||||||
margin: 15px 0;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-banner .features li:before {
|
|
||||||
content: "✓";
|
|
||||||
margin-right: 10px;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-form {
|
|
||||||
flex: 1;
|
|
||||||
padding: 40px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-title {
|
|
||||||
text-align: center;
|
|
||||||
margin-bottom: 30px;
|
|
||||||
color: #1890ff;
|
|
||||||
font-size: 24px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-group {
|
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-group label {
|
|
||||||
display: block;
|
|
||||||
margin-bottom: 8px;
|
|
||||||
color: #333;
|
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-group input, .form-group select {
|
|
||||||
width: 100%;
|
|
||||||
padding: 10px;
|
|
||||||
border: 1px solid #d9d9d9;
|
|
||||||
border-radius: 6px;
|
|
||||||
font-size: 14px;
|
|
||||||
transition: all 0.3s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.form-group input:focus, .form-group select:focus {
|
|
||||||
border-color: #1890ff;
|
|
||||||
box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
|
|
||||||
outline: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-btn {
|
|
||||||
width: 100%;
|
|
||||||
padding: 12px;
|
|
||||||
background: #1890ff;
|
|
||||||
color: white;
|
|
||||||
border: none;
|
|
||||||
border-radius: 6px;
|
|
||||||
font-size: 16px;
|
|
||||||
cursor: pointer;
|
|
||||||
transition: background 0.3s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.login-btn:hover {
|
|
||||||
background: #096dd9;
|
|
||||||
}
|
|
||||||
|
|
||||||
.notice {
|
|
||||||
margin-top: 20px;
|
|
||||||
padding: 10px;
|
|
||||||
background-color: #e6f7ff;
|
|
||||||
border: 1px solid #91d5ff;
|
|
||||||
border-radius: 6px;
|
|
||||||
color: #1890ff;
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.version {
|
|
||||||
position: fixed;
|
|
||||||
bottom: 20px;
|
|
||||||
right: 20px;
|
|
||||||
color: #666;
|
|
||||||
font-size: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cookie-help {
|
|
||||||
color: #1890ff;
|
|
||||||
text-decoration: none;
|
|
||||||
font-size: 14px;
|
|
||||||
margin-left: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cookie-help:hover {
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container {
|
|
||||||
display: flex;
|
|
||||||
background-color: rgba(255, 255, 255, 1);
|
|
||||||
border-radius: 12px;
|
|
||||||
box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
|
|
||||||
width: 80%;
|
|
||||||
max-width: 800px;
|
|
||||||
overflow: hidden;
|
|
||||||
transition: all 0.3s ease;
|
|
||||||
margin: 20px auto;
|
|
||||||
border: 1px solid rgba(0, 0, 0, 0.06);
|
|
||||||
}
|
|
||||||
|
|
||||||
.container:hover {
|
|
||||||
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel {
|
|
||||||
flex: 0.8;
|
|
||||||
background-color: #1890ff;
|
|
||||||
padding: 1.8rem;
|
|
||||||
color: white;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
position: relative;
|
|
||||||
overflow: hidden;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel::before {
|
|
||||||
content: "";
|
|
||||||
position: absolute;
|
|
||||||
top: 0;
|
|
||||||
left: 0;
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
background: linear-gradient(45deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%);
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel h1 {
|
|
||||||
font-size: 1.6rem; /* 减小标题字体 */
|
|
||||||
margin-bottom: 1rem;
|
|
||||||
color: white;
|
|
||||||
position: relative;
|
|
||||||
z-index: 2;
|
|
||||||
text-align: center;
|
|
||||||
line-height: 1.2;
|
|
||||||
white-space: nowrap; /* 防止标题换行 */
|
|
||||||
letter-spacing: -0.5px; /* 稍微调整字间距 */
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel p {
|
|
||||||
font-size: 0.9rem; /* 进一步减小描述文字 */
|
|
||||||
margin-bottom: 1.2rem;
|
|
||||||
line-height: 1.4;
|
|
||||||
opacity: 0.9;
|
|
||||||
position: relative;
|
|
||||||
z-index: 2;
|
|
||||||
max-width: 90%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.feature-list {
|
|
||||||
list-style: none;
|
|
||||||
margin-top: 1.2rem;
|
|
||||||
position: relative;
|
|
||||||
z-index: 2;
|
|
||||||
text-align: left;
|
|
||||||
font-size: 0.85rem; /* 减小列表字体 */
|
|
||||||
padding-left: 0.5rem; /* 添加左侧内边距 */
|
|
||||||
}
|
|
||||||
|
|
||||||
.feature-list li {
|
|
||||||
margin-bottom: 0.7rem;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.feature-list li::before {
|
|
||||||
content: "✓";
|
|
||||||
display: inline-block;
|
|
||||||
margin-right: 8px;
|
|
||||||
font-weight: bold;
|
|
||||||
color: #52c41a;
|
|
||||||
background: white;
|
|
||||||
width: 18px;
|
|
||||||
height: 18px;
|
|
||||||
border-radius: 50%;
|
|
||||||
text-align: center;
|
|
||||||
line-height: 18px;
|
|
||||||
font-size: 11px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.right-panel {
|
|
||||||
flex: 1.2; /* 增加右侧面板比例 */
|
|
||||||
padding: 1.8rem;
|
|
||||||
background-color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.logo {
|
|
||||||
text-align: center;
|
|
||||||
margin-bottom: 2rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.logo img {
|
|
||||||
width: 80px;
|
|
||||||
height: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2 {
|
|
||||||
color: var(--text-color);
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 1rem;
|
|
||||||
font-size: 1rem;
|
|
||||||
font-weight: 500;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2::before {
|
|
||||||
content: "";
|
|
||||||
display: inline-block;
|
|
||||||
width: 4px;
|
|
||||||
height: 16px;
|
|
||||||
background-color: var(--primary-color);
|
|
||||||
margin-right: 8px;
|
|
||||||
border-radius: 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.error {
|
|
||||||
color: var(--error-color);
|
|
||||||
margin-top: 1rem;
|
|
||||||
text-align: center;
|
|
||||||
padding: 0.8rem;
|
|
||||||
background-color: #fff2f0;
|
|
||||||
border: 1px solid #ffccc7;
|
|
||||||
border-radius: 6px;
|
|
||||||
font-size: 0.9rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info {
|
|
||||||
background: rgba(230, 247, 255, 0.9);
|
|
||||||
border: 1px solid rgba(24, 144, 255, 0.2);
|
|
||||||
box-shadow: 0 2px 8px rgba(24, 144, 255, 0.1);
|
|
||||||
padding: 0.7rem 1rem;
|
|
||||||
border-radius: 8px;
|
|
||||||
margin-bottom: 1rem;
|
|
||||||
color: #1a5fb4;
|
|
||||||
font-size: 0.75rem;
|
|
||||||
text-align: left;
|
|
||||||
line-height: 1.3;
|
|
||||||
position: relative;
|
|
||||||
padding-left: 2.5rem;
|
|
||||||
max-width: 95%;
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.info::before {
|
|
||||||
content: "ℹ️";
|
|
||||||
position: absolute;
|
|
||||||
left: 1rem;
|
|
||||||
top: 1rem; /* 调整图标位置 */
|
|
||||||
font-size: 1rem; /* 减小图标大小 */
|
|
||||||
color: #1890ff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-icon {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-icon input {
|
|
||||||
padding-left: 2.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-icon::before {
|
|
||||||
content: "";
|
|
||||||
position: absolute;
|
|
||||||
left: 1rem;
|
|
||||||
top: 50%;
|
|
||||||
transform: translateY(-50%);
|
|
||||||
width: 16px;
|
|
||||||
height: 16px;
|
|
||||||
background-size: contain;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
opacity: 0.5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-icon.user::before {
|
|
||||||
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%231890ff'%3E%3Cpath d='M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z'/%3E%3C/svg%3E");
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-icon.cookie::before {
|
|
||||||
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%231890ff'%3E%3Cpath d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 17h-2v-2h2v2zm2.07-7.75l-.9.92C13.45 12.9 13 13.5 13 15h-2v-.5c0-1.1.45-2.1 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41 0-1.1-.9-2-2-2s-2 .9-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 .88-.36 1.68-.93 2.25z'/%3E%3C/svg%3E");
|
|
||||||
}
|
|
||||||
|
|
||||||
.footer {
|
|
||||||
text-align: center;
|
|
||||||
margin-top: 1.5rem;
|
|
||||||
font-size: 0.8rem;
|
|
||||||
color: var(--text-secondary);
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
gap: 0.3rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cookie-guide {
|
|
||||||
text-align: center;
|
|
||||||
margin: 1rem 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cookie-guide a {
|
|
||||||
color: var(--primary-color);
|
|
||||||
text-decoration: none;
|
|
||||||
font-size: 0.85rem;
|
|
||||||
display: inline-flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 0.5rem;
|
|
||||||
padding: 0.5rem 1rem;
|
|
||||||
border-radius: 4px;
|
|
||||||
background-color: rgba(24, 144, 255, 0.1);
|
|
||||||
transition: all 0.3s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cookie-guide a:hover {
|
|
||||||
background-color: rgba(24, 144, 255, 0.2);
|
|
||||||
color: var(--primary-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
.cookie-guide a::before {
|
|
||||||
content: "🔗";
|
|
||||||
font-size: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (max-width: 768px) {
|
|
||||||
.container {
|
|
||||||
width: 92%;
|
|
||||||
flex-direction: column;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel {
|
|
||||||
padding: 1.5rem 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel h1 {
|
|
||||||
font-size: 1.4rem;
|
|
||||||
white-space: normal; /* 在移动端允许换行 */
|
|
||||||
letter-spacing: normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
.right-panel {
|
|
||||||
padding: 1.5rem 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.feature-list {
|
|
||||||
font-size: 0.85rem;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* 消息提示样式 - Element Plus 风格 */
|
|
||||||
.message-container {
|
|
||||||
position: fixed;
|
|
||||||
top: 20px;
|
|
||||||
left: 50%;
|
|
||||||
transform: translateX(-50%);
|
|
||||||
z-index: 9999;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message {
|
|
||||||
min-width: 380px;
|
|
||||||
box-sizing: border-box;
|
|
||||||
border-radius: 4px;
|
|
||||||
border: 1px solid #ebeef5;
|
|
||||||
position: relative;
|
|
||||||
background-color: #fff;
|
|
||||||
overflow: hidden;
|
|
||||||
padding: 15px 15px 15px 40px;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
transition: opacity 0.3s, transform .4s, top .4s;
|
|
||||||
box-shadow: 0 2px 12px 0 rgba(0,0,0,.1);
|
|
||||||
animation: el-message-fade-in .3s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message::before {
|
|
||||||
position: absolute;
|
|
||||||
left: 15px;
|
|
||||||
top: 50%;
|
|
||||||
transform: translateY(-50%);
|
|
||||||
content: "";
|
|
||||||
width: 16px;
|
|
||||||
height: 16px;
|
|
||||||
background-size: contain;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.success {
|
|
||||||
background-color: #f0f9eb;
|
|
||||||
border-color: #e1f3d8;
|
|
||||||
color: #67c23a;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.success::before {
|
|
||||||
background-image: url("data:image/svg+xml,%3Csvg class='icon' viewBox='0 0 1024 1024' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 0 1-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z' fill='%2367c23a'/%3E%3C/svg%3E");
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.warning {
|
|
||||||
background-color: #fdf6ec;
|
|
||||||
border-color: #faecd8;
|
|
||||||
color: #e6a23c;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.warning::before {
|
|
||||||
background-image: url("data:image/svg+xml,%3Csvg class='icon' viewBox='0 0 1024 1024' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 0 1 0-96 48.01 48.01 0 0 1 0 96z' fill='%23e6a23c'/%3E%3C/svg%3E");
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.info {
|
|
||||||
background-color: #edf2fc;
|
|
||||||
border-color: #ebeef5;
|
|
||||||
color: #909399;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.info::before {
|
|
||||||
background-image: url("data:image/svg+xml,%3Csvg class='icon' viewBox='0 0 1024 1024' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 0 1 0-96 48.01 48.01 0 0 1 0 96z' fill='%23909399'/%3E%3C/svg%3E");
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.error {
|
|
||||||
background-color: #fef0f0;
|
|
||||||
border-color: #fde2e2;
|
|
||||||
color: #f56c6c;
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.error::before {
|
|
||||||
background-image: url("data:image/svg+xml,%3Csvg class='icon' viewBox='0 0 1024 1024' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm165.4 618.2l-66-.3L512 563.4l-99.3 118.4-66.1.3c-4.4 0-8-3.5-8-8 0-1.9.7-3.7 1.9-5.2l130.1-155L340.5 359a8.32 8.32 0 0 1-1.9-5.2c0-4.4 3.6-8 8-8l66.1.3L512 464.6l99.3-118.4 66-.3c4.4 0 8 3.5 8 8 0 1.9-.7 3.7-1.9 5.2L553.5 514l130 155c1.2 1.5 1.9 3.3 1.9 5.2 0 4.4-3.6 8-8 8z' fill='%23f56c6c'/%3E%3C/svg%3E");
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes el-message-fade-in {
|
|
||||||
0% {
|
|
||||||
opacity: 0;
|
|
||||||
transform: translate(-50%, -100%);
|
|
||||||
}
|
|
||||||
100% {
|
|
||||||
opacity: 1;
|
|
||||||
transform: translate(-50%, 0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes el-message-fade-out {
|
|
||||||
0% {
|
|
||||||
opacity: 1;
|
|
||||||
transform: translate(-50%, 0);
|
|
||||||
max-height: 150px;
|
|
||||||
}
|
|
||||||
100% {
|
|
||||||
opacity: 0;
|
|
||||||
transform: translate(-50%, -100%);
|
|
||||||
max-height: 0;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.message.fade-out {
|
|
||||||
animation: el-message-fade-out .3s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.optional-label {
|
|
||||||
color: #999;
|
|
||||||
font-size: 0.8em;
|
|
||||||
font-weight: normal;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="messageContainer" class="message-container"></div>
|
|
||||||
<div class="login-container">
|
|
||||||
<div class="login-banner">
|
|
||||||
<h1>网易大神审核数据监控看板</h1>
|
|
||||||
<ul class="features">
|
|
||||||
<li>实时监控审核数据,自动统计工作量</li>
|
|
||||||
<li>多系统数据整合,一目了然</li>
|
|
||||||
<li>智能告警提醒,及时发现异常</li>
|
|
||||||
<li>自定义系数配置,灵活调整权重</li>
|
|
||||||
<li>数据实时更新,确保准确性</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div class="login-form">
|
|
||||||
<h2 class="form-title">系统登录</h2>
|
|
||||||
<form id="loginForm">
|
|
||||||
<div class="form-group">
|
|
||||||
<label>工号</label>
|
|
||||||
<input type="text" name="username" placeholder="请输入您的工号" required>
|
|
||||||
<div style="color: #ff4d4f; font-size: 12px; margin-top: 5px;">
|
|
||||||
必填项
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<label>后端选择</label>
|
|
||||||
<select name="backend_type" id="backend_type" class="form-control" required>
|
|
||||||
<option value="breeze_monitor">Breeze监控 - 不含清风文本</option>
|
|
||||||
<option value="breeze_monitor_CHAT">Breeze监控 - 含清风文本</option>
|
|
||||||
</select>
|
|
||||||
<div style="color: #ff4d4f; font-size: 12px; margin-top: 5px;">
|
|
||||||
注意:如果选择"不含清风文本"版本,请不要审核清风工单,否则数据会异常!
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<label for="breeze_cookie">
|
|
||||||
<div>清风审核系统Cookie:<span class="optional-label">(可选)</span></div>
|
|
||||||
<div class="cookie-help">从<a href="https://breeze.opd.netease.com/center/workbench" target="_blank">breeze.opd.netease.com</a>获取</div>
|
|
||||||
</label>
|
|
||||||
<input type="text" name="breeze_cookie" placeholder="请输入清风审核系统Cookie(可选)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<label for="cms_cookie">
|
|
||||||
<div>大神CMS系统Cookie:<span class="optional-label">(可选)</span></div>
|
|
||||||
<div class="cookie-help">从<a href="https://god-cms.gameyw.netease.com/cms/" target="_blank">god-cms.gameyw.netease.com</a>获取</div>
|
|
||||||
</label>
|
|
||||||
<input type="text" name="cms_cookie" placeholder="请输入大神CMS系统Cookie(可选)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<label for="inspect_cookie">
|
|
||||||
<div>CC审核平台Cookie:<span class="optional-label">(可选)</span></div>
|
|
||||||
<div class="cookie-help">从<a href="https://inspect.cc.163.com/#/forum/contenttrack" target="_blank">cc.163.com</a>获取</div>
|
|
||||||
</label>
|
|
||||||
<input type="text" name="inspect_cookie" placeholder="请输入CC审核平台Cookie(可选)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="cookie-guide">
|
|
||||||
<a href="http://cos.ui-beam.com/work_scripts/monitor/cookie-extension/README.html" target="_blank">如何获取Cookie?点击查看详细指南</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<button type="submit" class="login-btn">登 录</button>
|
|
||||||
|
|
||||||
<div class="notice">
|
|
||||||
注意:为确保数据安全,Cookie信息仅保存在本地,不会上传至服务器
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="version">当前版本:{{ version }}</div>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
// 消息提示函数
|
|
||||||
function showMessage(type, content) {
|
|
||||||
const container = document.getElementById('messageContainer');
|
|
||||||
const message = document.createElement('div');
|
|
||||||
message.className = `message ${type}`;
|
|
||||||
message.textContent = content;
|
|
||||||
container.appendChild(message);
|
|
||||||
|
|
||||||
// 3秒后自动移除消息
|
|
||||||
setTimeout(() => {
|
|
||||||
message.addEventListener('animationend', () => {
|
|
||||||
container.removeChild(message);
|
|
||||||
});
|
|
||||||
}, 3000);
|
|
||||||
}
|
|
||||||
|
|
||||||
document.getElementById('loginForm').addEventListener('submit', function(e) {
|
|
||||||
e.preventDefault();
|
|
||||||
|
|
||||||
const formData = new FormData(this);
|
|
||||||
|
|
||||||
fetch('/login', {
|
|
||||||
method: 'POST',
|
|
||||||
body: formData
|
|
||||||
})
|
|
||||||
.then(response => response.json())
|
|
||||||
.then(data => {
|
|
||||||
if (data.code === 0) {
|
|
||||||
localStorage.setItem('staff_name', data.staff_name);
|
|
||||||
showMessage('success', '登录成功,正在跳转...');
|
|
||||||
// 使用replace方法进行跳转,防止返回到登录页
|
|
||||||
setTimeout(() => {
|
|
||||||
window.location.replace('/dashboard');
|
|
||||||
}, 1000);
|
|
||||||
} else {
|
|
||||||
showMessage('error', data.message || '登录失败,请重试');
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.catch(error => {
|
|
||||||
console.error('Error:', error);
|
|
||||||
showMessage('error', '登录请求失败,请重试');
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
Loading…
x
Reference in New Issue
Block a user