首次提交

This commit is contained in:
34701892@qq.com 2025-08-10 16:44:02 +08:00
commit b136869cb1
593 changed files with 71527 additions and 0 deletions

3
.env Normal file
View File

@ -0,0 +1,3 @@
# 基础配置
VITE_SHARE_DOMAIN = https://cankao.cs.com.cn
VITE_SHARE_REDIRECT = https://cankao.cs.com.cn/redirect.html

11
.env.development Normal file
View File

@ -0,0 +1,11 @@
# 开发环境
ENV = development
# 本地环境接口地址
# VITE_API_URL = http://123.60.153.169:8040/apih5
# VITE_API_URL = https://4155gf93ll13.vicp.fun/apih5
# VITE_API_URL = http://123.60.79.143:8041/apih5
# VITE_API_URL =http://ukfba3.natappfree.cc/apih5
VITE_API_URL = https://cankao.cs.com.cn/apih5
VITE_API_DATAV_URL = https://cankao.cs.com.cn/zzck_datav

11
.env.production Normal file
View File

@ -0,0 +1,11 @@
# 线上环境
ENV = production
# 线上环境接口地址
# VITE_API_URL = https://cankao.cs.com.cn/mini
# VITE_API_URL = http://123.60.153.169:8040/apih5
VITE_API_URL = https://cankao.cs.com.cn/apih5
# VITE_API_URL = http://123.60.79.143:8041/apih5
VITE_API_DATAV_URL = https://cankao.cs.com.cn/zzck_datav

21
.gitignore vendored Normal file
View File

@ -0,0 +1,21 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
node_modules
.DS_Store
dist
*.local
# Editor directories and files
.idea
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

BIN
caokao-h5.zip Normal file

Binary file not shown.

112
index.html Normal file
View File

@ -0,0 +1,112 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<script>
var coverSupport =
"CSS" in window &&
typeof CSS.supports === "function" &&
(CSS.supports("top: env(a)") || CSS.supports("top: constant(a)"));
document.write(
'<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' +
(coverSupport ? ", viewport-fit=cover" : "") +
'" />'
);
</script>
<!-- <script
type="text/javascript"
src="//res.wx.qq.com/open/js/jweixin-1.6.0.js"
></script>
<script>
window.jWeixin = window.wx;
delete window.wx;
</script>
<script src="https://www.cs.com.cn/js/2020/jquery-3.4.1.min.js"></script> -->
<link rel="icon" href="/src/assets/favicon.ico" />
<title></title>
<!--preload-links-->
<!--app-context-->
</head>
<body>
<div id="app"><!--app-html--></div>
<script type="module" src="/src/main.ts"></script>
<!-- <script type="text/javascript">
var link = location.href.split("#")[0];
console.log("🚀 ~ link:", link);
var link2 = location.href.split("#")[1];
console.log("🚀 ~ link2:", link2);
$.ajax({
url: "https://cankao.cs.com.cn/mini/wechat/share",
type: "GET",
data: {
url: link,
},
async: true,
dataType: "json",
success: function (res) {
const { data } = res;
console.log("🚀 ~ data:", data);
jWeixin.config({
debug: false,
appId: data.appId,
timestamp: data.timestamp,
nonceStr: data.nonceStr,
signature: data.signature,
jsApiList: [
"updateAppMessageShareData",
"updateTimelineShareData",
"onMenuShareTimeline",
"onMenuShareAppMessage",
],
});
jWeixin.error(function (res) {
console.log(res);
});
jWeixin.ready(function () {
jWeixin.updateAppMessageShareData({
title: "中证参考",
desc: "天下事 早知道",
link: link,
imgUrl: "https://cankao.cs.com.cn/static/share-default.jpg",
success: function () {},
});
jWeixin.updateTimelineShareData({
title: "中证参考",
desc: "天下事 早知道",
link: link,
imgUrl: "https://cankao.cs.com.cn/static/share-default.jpg",
success: function () {},
});
jWeixin.onMenuShareAppMessage({
title: "中证参考",
desc: "天下事 早知道",
link: link,
imgUrl: "https://cankao.cs.com.cn/static/share-default.jpg",
trigger: function (res) {},
success: function (res) {},
cancel: function (res) {},
fail: function (res) {},
});
jWeixin.onMenuShareTimeline({
title: "中证参考",
desc: "天下事 早知道",
link: link,
imgUrl: "https://cankao.cs.com.cn/static/share-default.jpg",
trigger: function (res) {},
success: function (res) {},
cancel: function (res) {},
fail: function (res) {},
});
});
},
error: function (error) {},
});
</script> -->
</body>
</html>

12537
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

87
package.json Normal file
View File

@ -0,0 +1,87 @@
{
"name": "uni-preset-vue",
"version": "0.0.1",
"scripts": {
"dev:h5": "uni",
"build:h5": "uni build",
"dev:h5:ssr": "uni --ssr",
"dev:mp-weixin": "uni -p mp-weixin",
"dev:mp-alipay": "uni -p mp-alipay",
"dev:app": "uni -p app",
"dev:app-android": "uni -p app-android",
"dev:app-ios": "uni -p app-ios",
"dev:custom": "uni -p",
"dev:mp-baidu": "uni -p mp-baidu",
"dev:mp-jd": "uni -p mp-jd",
"dev:mp-kuaishou": "uni -p mp-kuaishou",
"dev:mp-lark": "uni -p mp-lark",
"dev:mp-qq": "uni -p mp-qq",
"dev:mp-toutiao": "uni -p mp-toutiao",
"dev:quickapp-webview": "uni -p quickapp-webview",
"dev:quickapp-webview-huawei": "uni -p quickapp-webview-huawei",
"dev:quickapp-webview-union": "uni -p quickapp-webview-union",
"build:app": "uni build -p app",
"build:app-android": "uni build -p app-android",
"build:app-ios": "uni build -p app-ios",
"build:custom": "uni build -p",
"build:h5:ssr": "uni build --ssr",
"build:mp-alipay": "uni build -p mp-alipay",
"build:mp-baidu": "uni build -p mp-baidu",
"build:mp-jd": "uni build -p mp-jd",
"build:mp-kuaishou": "uni build -p mp-kuaishou",
"build:mp-lark": "uni build -p mp-lark",
"build:mp-qq": "uni build -p mp-qq",
"build:mp-toutiao": "uni build -p mp-toutiao",
"build:mp-weixin": "uni build -p mp-weixin",
"build:quickapp-webview": "uni build -p quickapp-webview",
"build:quickapp-webview-huawei": "uni build -p quickapp-webview-huawei",
"build:quickapp-webview-union": "uni build -p quickapp-webview-union",
"type-check": "vue-tsc --noEmit"
},
"dependencies": {
"@dcloudio/uni-app": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-app-plus": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-components": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-h5": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-alipay": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-baidu": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-jd": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-kuaishou": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-lark": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-qq": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-toutiao": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-mp-weixin": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-quickapp-webview": "3.0.0-alpha-3070720230316001",
"address-parse": "^1.2.19",
"axios": "^1.7.9",
"clipboard": "^2.0.11",
"dayjs": "^1.11.9",
"echarts": "^5.6.0",
"js-cookie": "^3.0.5",
"js-md5": "^0.8.3",
"pinia": "^2.0.36",
"qs": "^6.11.2",
"vue": "^3.2.45",
"vue-count-to": "^1.0.13",
"vue-i18n": "^9.1.9",
"weixin-js-sdk": "^1.6.5",
"wxmp-rsa": "^2.1.0"
},
"devDependencies": {
"@dcloudio/types": "^3.3.2",
"@dcloudio/uni-automator": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-cli-shared": "3.0.0-alpha-3070720230316001",
"@dcloudio/uni-stacktracey": "3.0.0-alpha-3070720230316001",
"@dcloudio/vite-plugin-uni": "3.0.0-alpha-3070720230316001",
"@types/qs": "^6.9.17",
"@vue/tsconfig": "^0.1.3",
"sass": "^1.66.1",
"sass-loader": "^13.3.2",
"typescript": "^4.9.4",
"vite": "4.0.4",
"vue-tsc": "^1.0.24"
},
"engines": {
"node": ">=14.0.0"
}
}

46
redirect.html Normal file
View File

@ -0,0 +1,46 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<meta
name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover"
/>
<script>
console.log("重定向跳转");
function getQueryParam(param) {
var search = window.location.search.substring(1); // 获取URL中?后面的部分
var params = search.split("&"); // 将每个参数分隔开
for (var i = 0; i < params.length; i++) {
var pair = params[i].split("="); // 将每个参数的键和值分开
if (pair[0] == param) {
return decodeURIComponent(pair[1] || ""); // 返回解码后的值
}
}
return null; // 如果参数不存在返回null
}
window.onload = function () {
console.log('output >>>>> window.loa',window.location.href);
var tourl = "https://cankao.cs.com.cn/#/";
var path = getQueryParam("path");
var query = getQueryParam("query");
if (path) {
tourl += path;
}
if (query) {
query = JSON.parse(query);
query = new URLSearchParams(query).toString();
tourl += "?" + query;
}
console.log('output >>>>> tourl',tourl);
window.location.href = tourl;
};
</script>
<title></title>
</head>
<body></body>
</html>

25
src/App.vue Normal file
View File

@ -0,0 +1,25 @@
<script setup lang="ts">
import { onLaunch, onShow, onHide } from "@dcloudio/uni-app";
import { useShareStore } from "@/stores/shareStore";
const stores = useShareStore();
onLaunch(() => {
console.log("App Launch");
stores.initWxConfig();
});
onShow(() => {});
onHide(() => {
console.log("App Hide");
});
</script>
<style lang="scss">
/* 注意要写在第一行同时给style标签加入lang="scss"属性 */
@import "@/uni_modules/uview-plus/index.scss";
#app,
uni-app,
uni-page,
uni-page-wrapper {
height: calc(100vh - 131rpx);
}
</style>

42
src/api/detail.ts Normal file
View File

@ -0,0 +1,42 @@
import request from "@/utils";
/**
*
* @param data
* @id * id number
* @returns
*/
export const fetchArticleDetail = (data: any) => {
return request.get(`/news/detail/${data.id}`);
};
/**
*
* @param data
* @id * id number
* @returns
*/
export const fetchArticleLike = (data: any) => {
return request.post("/user/like", data);
};
/**
*
* @param data
* @id * id number
* @returns
*/
export const fetchArticleFavorate = (data: any) => {
return request.post("/user/favorite", data);
};
// 热门行业
export const getListByTagIndustry = (data: any) => {
return request.get(`/news/list/industry?name=${data.name}`);
};
// 概念标签
export const getListByTag = (data: any) => {
return request.get(`/news/list/tag?name=${data.name}`);
};

64
src/api/index.ts Normal file
View File

@ -0,0 +1,64 @@
import Request from "@/utils";
// 获取验证码
export const getCaptcha = (data: any) => {
return Request.post("/common/sms", data);
};
// 用户登录
export const login = (data: any) => {
return Request.post("/common/login", data);
};
// 微信分享签名
export const getWeChatSdkData = (data: any) => {
return Request.post("/wechat/share", data);
};
// 获取实时快讯
export const getNewsFast = (data: any) => {
return Request.post("/news/pageIndex", data);
};
// 检查是否有新的快讯
export const checkNews = (data: any) => {
return Request.post("/news/pageIndexCheck", data);
};
// 新闻/快讯,点赞功能
export const likeNews = (data: any) => {
return Request.post("/news/like", data);
};
// 获取栏目列表
export const getNewsColumn = (data: any) => {
return Request.post("/news/column", data);
};
// 获取标签列表
export const getNewsTag = (data: any) => {
return Request.post("/news/tag", data);
};
// 获取新闻列表
export const getNewsList = (data: any) => {
return Request.post("/news/newsList", data);
};
// 栏目解锁接口
export const unlockColumn = (data: any) => {
return Request.post("/user/unlock", data);
};
// 我订阅的栏目列表
export const getUnlockList = (data: any) => {
return Request.post("/user/unlockList", data);
};
// 全文搜索
//
export const searchNews = (data: any) => {
return Request.post("/news/search", data);
};

36
src/api/newsInfo.ts Normal file
View File

@ -0,0 +1,36 @@
import request from "@/utils/indexDatav";
// 咨询评分分布区间柱状图以及分布饼图
export const newsInfoScore = (data: any) => {
return request.get("/news_info/score", data);
};
// 行业分类贴标
export const getindustryCount = (data: any) => {
return request.get("/news_info/industry/count", data);
};
// 概念标签贴标
export const getConceptCount = (data: any) => {
return request.get("/news_info/concept/count", data);
};
// 概念标签贴标
export const getTopNews = (data: any) => {
return request.get("/top_news_h5_d", data);
};
// 热门行业top10
export const getTopIndustry_d = (data: any) => {
return request.get("/top_industry_d", data);
};
// 风口概念池top10
export const getTopConcept_d = (data: any) => {
return request.get("/top_concept_d", data);
};
// 今日精选:
export const getNews_cnt_d = (data: any) => {
return request.get("/news_cnt_d", data);
};

18
src/api/users.ts Normal file
View File

@ -0,0 +1,18 @@
import request from "@/utils";
// 订阅栏目 ---------- 我的
export const fetchUnlockList = (data: any) => {
return request.post("/user/unlockList", data);
};
// 收藏列表 ---------- 我的
export const fetchFavList = (data: any) => {
return request.post("/user/favPage", data);
};
// 喜欢列表 ---------- 我的
export const fetchLikeList = (data: any) => {
return request.post("/user/likePage", data);
};
// 浏览记录 ---------- 我的
export const fetchTrackList = (data: any) => {
return request.post("/user/viewPage", data);
};

BIN
src/assets/favicon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

Binary file not shown.

15
src/assets/fonts/font.css Normal file
View File

@ -0,0 +1,15 @@
@font-face {
font-family: "SourceHanSansCN-Regular";
font-style: normal;
src: url("./PingFang_Medium.ttf") format("opentype");
}
@font-face {
font-family: "SourceHanSansCN-Medium";
font-style: normal;
src: url("./SourceHanSansCN-Medium.otf") format("opentype");
}
html,
body {
font-family: "SourceHanSansCN-Regular";
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 480 B

BIN
src/assets/images/arrow.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 989 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 233 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 994 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

BIN
src/assets/images/down.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 258 B

BIN
src/assets/images/fire.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 646 B

BIN
src/assets/images/flash.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 851 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 701 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 234 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 470 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 707 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 536 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 860 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 800 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 237 KiB

BIN
src/assets/images/like.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 639 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

BIN
src/assets/images/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

BIN
src/assets/images/logo1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

BIN
src/assets/images/news.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 416 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 839 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 238 B

BIN
src/assets/images/radio.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 388 B

BIN
src/assets/images/share.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 580 B

BIN
src/assets/images/star.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 735 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 142 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

BIN
src/assets/images/time.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 892 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 37 KiB

BIN
src/assets/images/vip.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

View File

@ -0,0 +1,8 @@
:root {
--h1-font-size: 16px;
--h2-font-size: 14px;
--h3-font-size: 13px;
--h4-font-size: 12px;
--h5-font-size: 11px;
--h6-font-size: 10px;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 466 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 502 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 231 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 269 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 122 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

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