修改扣费下载逻辑

This commit is contained in:
Ember 2024-11-25 19:49:45 +08:00
parent c1b7e791fd
commit fd94cbbbeb
47 changed files with 1058 additions and 253 deletions

File diff suppressed because one or more lines are too long

View File

@ -6,7 +6,7 @@
<description>Recent content on NEU小站</description>
<generator>Hugo -- 0.127.0</generator>
<language>zh-cn</language>
<lastBuildDate>Mon, 18 Nov 2024 20:00:00 +0800</lastBuildDate>
<lastBuildDate>Mon, 25 Nov 2024 19:30:00 +0800</lastBuildDate>
<atom:link href="https://xn--xhq44jb2fzpc.com/index.xml" rel="self" type="application/rss+xml" />
<item>
<title>宿舍规格</title>
@ -37,6 +37,16 @@
您的设备无法正常显示PDF文件。 点击此处下载。
软件学院表格 此为软件学院认定表格更新时间为2023年5月。
您的设备无法正常显示PDF文件。 点击此处下载。</description>
</item>
<item>
<title>朗道 理论物理学教程 第一卷《力学》</title>
<link>https://xn--xhq44jb2fzpc.com/resources/%E6%9C%97%E9%81%93%E7%90%86%E8%AE%BA%E5%8A%9B%E5%AD%A6/</link>
<pubDate>Mon, 25 Nov 2024 19:30:00 +0800</pubDate>
<guid>https://xn--xhq44jb2fzpc.com/resources/%E6%9C%97%E9%81%93%E7%90%86%E8%AE%BA%E5%8A%9B%E5%AD%A6/</guid>
<description> 标签:#公共课 #理论力学 #理论物理 #课本 #PDF #电子版 #教材
此处收录了朗道 理论物理学教程 第一卷《力学》2007版
下载该资源需要5东币
点击下载 下载安全保护中 3秒后将开始下载... </description>
</item>
<item>
<title>《变分方法》课本</title>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/Python.7z";const i="popup-"+s;const r= 15 ;const a="《python文管类》PPT";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/Python.7z";const l="popup-"+i;const d= 15 ;const u="《python文管类》PPT";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/中级财务1.zip";const i="popup-"+s;const r= 10 ;const a="《中级财务1》PPT";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/中级财务1.zip";const l="popup-"+i;const d= 10 ;const u="《中级财务1》PPT";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/中级财务2.zip";const i="popup-"+s;const r= 10 ;const a="《中级财务2》PPT";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/中级财务2.zip";const l="popup-"+i;const d= 10 ;const u="《中级财务2》PPT";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/2022注会教材会计高清无水印.pdf";const i="popup-"+s;const r= 70 ;const a="《会计》课本";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/2022注会教材会计高清无水印.pdf";const l="popup-"+i;const d= 70 ;const u="《会计》课本";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/马工程《发展经济学》书.pdf";const i="popup-"+s;const r= 65 ;const a="《发展经济学》课本";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/马工程《发展经济学》书.pdf";const l="popup-"+i;const d= 65 ;const u="《发展经济学》课本";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/商务信息与管理.zip";const i="popup-"+s;const r= 15 ;const a="《商务信息与管理》PPT";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/商务信息与管理.zip";const l="popup-"+i;const d= 15 ;const u="《商务信息与管理》PPT";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/商务网站开发管理.zip";const i="popup-"+s;const r= 25 ;const a="《商务网站开发管理》PPT";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/商务网站开发管理.zip";const l="popup-"+i;const d= 25 ;const u="《商务网站开发管理》PPT";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

View File

@ -488,7 +488,7 @@
<div class="popup-content">3秒后将开始下载...</div>
</div>
<script>
let client;function getCookie(e){const n=e+"=";const o=document.cookie.split(";");for(let t=0;t<o.length;t++){let e=o[t];while(e.charAt(0)==" ")e=e.substring(1,e.length);if(e.indexOf(n)==0)return e.substring(n.length,e.length)}return null}async function fetchNoCache(e){const t=(new Date).getTime();const n=`${e}?timestamp=${t}`;return fetch(n)}async function f1(){try{const e=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const t=await e.json();const n=t.masterKey;const o=CryptoJS.SHA256(n);const s={region:d2(t.encryptedRegion,o),accessKeyId:d2(t.encryptedKeyId,o),accessKeySecret:d2(t.encryptedKeySecret,o),bucket:d2(t.encryptedBucket,o)};client=new OSS(s)}catch(e){console.error("Failed to fetch or decrypt OSS config:",e)}}function d2(e,t){e=e.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(e);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const s=CryptoJS.lib.WordArray.create(n.words.slice(4));const c=CryptoJS.AES.decrypt({ciphertext:s},t,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return c.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const s="download-1";const c="resources\/ba\/draft\/国际贸易.rar";const i="popup-"+s;const r= 15 ;const a="《国际贸易》PPT";const e=async()=>{const e=getCookie("token");if(!e){alert("请登录后下载!");window.location.href="/submission";return}if(r>0){try{const t=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:e},body:JSON.stringify({amount:r,title:a})});const n=await t.json();if(t.ok){const o=confirm(`当前下载操作扣除东币数:${r},是否继续?`);if(o){l(s,i,c)}}else if(t.status===400&&n.message==="Insufficient coins."){alert(`您的东币数量不够!当前资源要求东币数:${r},您的东币数:${n.currentCoins||0}。`)}else if(t.status===400&&n.message==="Coin system not activated. Please activate your coin system."){alert("您还未激活东币系统,请前往激活!")}else if(t.status===404&&n.message==="User not found."){alert("未找到您的账户信息,请重新登录!");window.location.href="/submission"}else{alert(`下载失败:${n.message}`)}}catch(e){console.error("Error during download request:",e);alert("无法处理您的请求,请稍后重试。")}}else{l(s,i,c)}};const l=(e,t,n)=>{let o=3;const s=document.getElementById(t);const c=s.querySelector(".popup-content");if(client){let e=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const i=e.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const r=()=>{if(o>0){c.textContent=`${o}秒后将开始下载...`;o--;setTimeout(r,1e3)}else{s.style.display="none";window.location.href=i}};s.style.display="block";r()}else{console.error("OSS client is not initialized.")}};document.getElementById(s).addEventListener("click",e)});function getCurrentTime(){const e=new Date;const t=new Date(e.getTime()+8*60*60*1e3);return t.toISOString().replace("T"," ").substring(0,19)}
let client;function getCookie(t){const n=t+"=";const o=document.cookie.split(";");for(let e=0;e<o.length;e++){let t=o[e];while(t.charAt(0)==" ")t=t.substring(1,t.length);if(t.indexOf(n)==0)return t.substring(n.length,t.length)}return null}async function fetchNoCache(t){const e=(new Date).getTime();const n=`${t}?timestamp=${e}`;return fetch(n)}async function f1(){try{const t=await fetchNoCache("https://download.xn--xhq44jb2fzpc.com/upload/json/s.json");const e=await t.json();const n=e.masterKey;const o=CryptoJS.SHA256(n);const c={region:d2(e.encryptedRegion,o),accessKeyId:d2(e.encryptedKeyId,o),accessKeySecret:d2(e.encryptedKeySecret,o),bucket:d2(e.encryptedBucket,o)};client=new OSS(c)}catch(t){console.error("Failed to fetch or decrypt OSS config:",t)}}function d2(t,e){t=t.replace(/\s/g,"");const n=CryptoJS.enc.Base64.parse(t);const o=CryptoJS.lib.WordArray.create(n.words.slice(0,4));const c=CryptoJS.lib.WordArray.create(n.words.slice(4));const s=CryptoJS.AES.decrypt({ciphertext:c},e,{iv:o,mode:CryptoJS.mode.CBC,padding:CryptoJS.pad.Pkcs7});return s.toString(CryptoJS.enc.Utf8)}f1();document.addEventListener("DOMContentLoaded",function(){const i="download-1";const a="resources\/ba\/draft\/国际贸易.rar";const l="popup-"+i;const d= 15 ;const u="《国际贸易》PPT";const t=async()=>{const t=getCookie("token");if(!t){alert("请登录后下载!");window.location.href="/submission";return}if(d>0){try{const e=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/remain",{method:"GET",headers:{Authorization:t}});if(!e.ok){if(e.status===401||e.status===403){alert("您的登录信息已过期,请重新登录!");window.location.href="/submission";return}throw new Error("无法检查余额")}const n=await e.json();const o=n.coin;if(o<d){alert(`您的东币数量不够当前资源要求东币数${d}您的东币数${o}`);return}const c=confirm(`当前下载操作扣除东币数:${d},您的东币数:${o},是否继续?`);if(!c){return}const s=await fetch("https://userlogin.xn--xhq44jb2fzpc.com/coin/download",{method:"POST",headers:{"Content-Type":"application/json",Authorization:t},body:JSON.stringify({amount:d,title:u})});const r=await s.json();if(s.ok){p(i,l,a)}else if(s.status===400&&r.message==="Insufficient coins."){alert(`您的东币数量不够当前资源要求东币数${d}`)}else{alert(`下载失败${r.message}`)}}catch(t){console.error("Error during download request:",t);alert("无法处理您的请求请稍后重试")}}else{p(i,l,a)}};const p=(t,e,n)=>{let o=3;const c=document.getElementById(e);const s=c.querySelector(".popup-content");if(client){let t=client.signatureUrl(n,{expires:20,response:{"content-disposition":"attachment"}});const r=t.replace("emberimg.oss-cn-beijing.aliyuncs.com","download.xn--xhq44jb2fzpc.com");const i=()=>{if(o>0){s.textContent=`${o}秒后将开始下载...`;o--;setTimeout(i,1e3)}else{c.style.display="none";window.location.href=r}};c.style.display="block";i()}else{console.error("OSS client is not initialized.")}};document.getElementById(i).addEventListener("click",t)});function getCurrentTime(){const t=new Date;const e=new Date(t.getTime()+8*60*60*1e3);return e.toISOString().replace("T"," ").substring(0,19)}
</script>
<hr>

Some files were not shown because too many files have changed in this diff Show More