修改样式、功能完成,待测试
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/apply.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/mianfei.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
+28
-155
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/cai.css" />
|
||||
</head>
|
||||
<body>
|
||||
@@ -83,6 +84,7 @@
|
||||
<div class="cxz-period-bar">
|
||||
<div class="cxz-period-title" id="tableTitle">预测列表</div>
|
||||
<div class="cxz-period-select">
|
||||
<button class="cxz-period-btn" data-size="5">近5期</button>
|
||||
<button class="cxz-period-btn active" data-size="10">近10期</button>
|
||||
<button class="cxz-period-btn" data-size="20">近20期</button>
|
||||
<button class="cxz-period-btn" data-size="50">近50期</button>
|
||||
@@ -92,6 +94,13 @@
|
||||
<!-- Article Table -->
|
||||
<div class="cxz-table-box">
|
||||
<table class="cxz-data-table">
|
||||
<colgroup>
|
||||
<col class="cxz-col-expert" />
|
||||
<col class="cxz-col-issue" />
|
||||
<col class="cxz-col-recommend" />
|
||||
<col class="cxz-col-rate" />
|
||||
<col class="cxz-col-action" />
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>专家</th>
|
||||
@@ -119,37 +128,6 @@
|
||||
<div class="cxz-pagination" id="pagination"></div>
|
||||
</div>
|
||||
|
||||
<!-- Expert Ranking -->
|
||||
<div class="cxz-ranking-box">
|
||||
<div class="cxz-ranking-header">
|
||||
<div class="cxz-ranking-title">专家排行榜</div>
|
||||
</div>
|
||||
<table class="cxz-rank-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>排名</th>
|
||||
<th>专家</th>
|
||||
<th>命中率</th>
|
||||
<th>方案数</th>
|
||||
<th>操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody id="rankBody">
|
||||
<tr>
|
||||
<td
|
||||
colspan="5"
|
||||
style="
|
||||
text-align: center;
|
||||
color: var(--text-muted);
|
||||
padding: 30px;
|
||||
"
|
||||
>
|
||||
加载中...
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
<!-- Footer -->
|
||||
@@ -284,7 +262,6 @@
|
||||
renderPlanFilter();
|
||||
renderTypeFilter();
|
||||
loadArticles();
|
||||
loadRanking();
|
||||
updateBreadcrumb();
|
||||
});
|
||||
$box.append(btn);
|
||||
@@ -361,7 +338,6 @@
|
||||
renderTypeFilter();
|
||||
syncCurrentUrl();
|
||||
loadArticles();
|
||||
loadRanking();
|
||||
});
|
||||
$box.append(btn);
|
||||
});
|
||||
@@ -416,7 +392,6 @@
|
||||
$(this).addClass("active");
|
||||
syncCurrentUrl();
|
||||
loadArticles();
|
||||
loadRanking();
|
||||
});
|
||||
$box.append(btn);
|
||||
});
|
||||
@@ -439,6 +414,10 @@
|
||||
return String(activeTypeId || currentTypeId || "");
|
||||
}
|
||||
|
||||
function getCurrentTypeName() {
|
||||
return $.trim($("#typeFilter .cxz-filter-btn.active").text() || "");
|
||||
}
|
||||
|
||||
function escapeText(value) {
|
||||
return CommonUtil.escapeHtml ? CommonUtil.escapeHtml(String(value || "")) : String(value || "");
|
||||
}
|
||||
@@ -467,11 +446,16 @@
|
||||
const issue = item.latestIssue || item.issue || item.expect || item.period || item.issueNo || "";
|
||||
if (!issue) return "--";
|
||||
const lotteryName = currentLottery ? currentLottery.name : item.lotteryName || item.menuName || "";
|
||||
return (lotteryName ? lotteryName + "-第" : "第") + issue + "期";
|
||||
return (lotteryName ? lotteryName + "-" : "") + issue + "期";
|
||||
}
|
||||
|
||||
function getRecommendTitle(item) {
|
||||
const currentName = getCurrentTypeName();
|
||||
return (
|
||||
currentName ||
|
||||
item.playName ||
|
||||
item.typeName ||
|
||||
item.menuName ||
|
||||
item.latestTitle ||
|
||||
item.title ||
|
||||
item.articleTitle ||
|
||||
@@ -518,26 +502,6 @@
|
||||
return "--";
|
||||
}
|
||||
|
||||
function getRatePercentText(item) {
|
||||
const raw =
|
||||
item.hitRate ??
|
||||
item.successRate ??
|
||||
item.correctRate ??
|
||||
item.winRate ??
|
||||
item.rate ??
|
||||
"";
|
||||
if (raw !== "" && raw !== null && raw !== undefined) {
|
||||
if (String(raw).indexOf("%") >= 0) return String(raw);
|
||||
const value = Number(raw);
|
||||
if (Number.isFinite(value)) {
|
||||
return (value > 0 && value <= 1 ? value * 100 : value).toFixed(2) + "%";
|
||||
}
|
||||
}
|
||||
const hit = Number(item.correctCount ?? item.hitCount ?? item.hit ?? 0);
|
||||
const total = Number(item.totalCount ?? item.total ?? item.articleCount ?? 0);
|
||||
return total > 0 ? ((hit / total) * 100).toFixed(2) + "%" : "0.00%";
|
||||
}
|
||||
|
||||
function buildCaiinfoUrl(item) {
|
||||
const params = new URLSearchParams();
|
||||
params.set("createBy", getExpertId(item));
|
||||
@@ -593,20 +557,25 @@
|
||||
const periodText = getIssueText(item);
|
||||
const predictHtml = getRecommendTitle(item);
|
||||
const avatarHtml = avatar
|
||||
? '<img src="' + escapeText(avatar) + '" class="table-img" />'
|
||||
: '<span class="cxz-expert-avatar">' +
|
||||
? '<img src="' + escapeText(avatar) + '" class="table-img" alt="' + escapeText(expertName) + '" />'
|
||||
: '<span class="cxz-table-avatar-placeholder">' +
|
||||
escapeText(expertName).charAt(0) +
|
||||
"</span>";
|
||||
const linkUrl = buildCaiinfoUrl(item);
|
||||
const rankNo = (currentPage - 1) * currentRowPageSize + i + 1;
|
||||
$body.append(
|
||||
"<tr>" +
|
||||
'<td><a href="' +
|
||||
escapeText(linkUrl) +
|
||||
'" class="cxz-expert-cell">' +
|
||||
'<span class="cxz-expert-rank">' +
|
||||
rankNo +
|
||||
"</span>" +
|
||||
avatarHtml +
|
||||
"<span>" +
|
||||
'<span class="cxz-expert-name">' +
|
||||
escapeText(expertName) +
|
||||
"</span></a></td>" +
|
||||
"</span>" +
|
||||
"</a></td>" +
|
||||
"<td>" +
|
||||
escapeText(periodText) +
|
||||
"</td>" +
|
||||
@@ -655,101 +624,6 @@
|
||||
});
|
||||
}
|
||||
|
||||
// Load expert ranking
|
||||
function loadRanking() {
|
||||
const typeId = getCurrentTypeId();
|
||||
if (!typeId) {
|
||||
$("#rankBody").html(
|
||||
'<tr><td colspan="5" style="text-align:center;color:var(--text-muted);padding:30px;">暂无数据</td></tr>',
|
||||
);
|
||||
return;
|
||||
}
|
||||
ApiClient.get(ApiClient.API.payArticleExpertRank, {
|
||||
menuId: typeId,
|
||||
issueCount: 50,
|
||||
pageNum: 1,
|
||||
pageSize: currentRowPageSize,
|
||||
}).then(function (res) {
|
||||
if (ApiClient.isSuccess(res) && ApiClient.pickData(res, null)) {
|
||||
const data = ApiClient.pickData(res, {}) || {};
|
||||
renderRanking(data.records || data.rows || ApiClient.asArray(data));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function renderRanking(list) {
|
||||
const $body = $("#rankBody");
|
||||
$body.empty();
|
||||
if (!list || list.length === 0) {
|
||||
$body.html(
|
||||
'<tr><td colspan="5" style="text-align:center;color:var(--text-muted);padding:30px;">暂无数据</td></tr>',
|
||||
);
|
||||
return;
|
||||
}
|
||||
const experts = list
|
||||
.map(function (item) {
|
||||
const total = Number(item.totalCount || item.total || 0);
|
||||
const hit = Number(item.correctCount || item.hit || 0);
|
||||
const rateText = getRatePercentText(item);
|
||||
const hitText = getCorrectDisplayText(item);
|
||||
const rateNum = rateText
|
||||
? parseFloat(String(rateText).replace("%", ""))
|
||||
: total > 0
|
||||
? (hit / total) * 100
|
||||
: 0;
|
||||
return {
|
||||
raw: item,
|
||||
name: getExpertName(item),
|
||||
createBy: getExpertId(item),
|
||||
total: total || item.articleCount || item.totalCount || 0,
|
||||
hit,
|
||||
hitText,
|
||||
rate: Number.isFinite(rateNum) ? rateNum : 0,
|
||||
rank: item.rank,
|
||||
accountType: item.accountType,
|
||||
};
|
||||
})
|
||||
.sort(function (a, b) {
|
||||
return (a.rank || 9999) - (b.rank || 9999) || b.rate - a.rate;
|
||||
})
|
||||
.slice(0, 10);
|
||||
|
||||
$.each(experts, function (i, exp) {
|
||||
const rate = exp.rate.toFixed(1);
|
||||
const badgeClass =
|
||||
i === 0
|
||||
? "cxz-rank-1"
|
||||
: i === 1
|
||||
? "cxz-rank-2"
|
||||
: i === 2
|
||||
? "cxz-rank-3"
|
||||
: "cxz-rank-n";
|
||||
$body.append(
|
||||
"<tr>" +
|
||||
'<td><span class="cxz-rank-badge ' +
|
||||
badgeClass +
|
||||
'">' +
|
||||
(i + 1) +
|
||||
"</span></td>" +
|
||||
'<td><a href="' +
|
||||
escapeText(buildCaiinfoUrl(exp.raw)) +
|
||||
'" class="cxz-expert-link">' +
|
||||
escapeText(exp.name) +
|
||||
"</a></td>" +
|
||||
'<td><span style="color:#de2103;font-weight:700;">' +
|
||||
escapeText(exp.hitText !== "--" ? exp.hitText : rate + "%") +
|
||||
"</span></td>" +
|
||||
"<td>" +
|
||||
exp.total +
|
||||
"</td>" +
|
||||
'<td><a href="' +
|
||||
escapeText(buildCaiinfoUrl(exp.raw)) +
|
||||
'" class="cxz-btn-buy">查看</a></td>' +
|
||||
"</tr>",
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
// Period selector
|
||||
$(document).on("click", ".cxz-period-btn", function () {
|
||||
$(".cxz-period-btn").removeClass("active");
|
||||
@@ -765,7 +639,6 @@
|
||||
CommonUtil.loadPageConfig();
|
||||
setTimeout(function () {
|
||||
loadArticles();
|
||||
loadRanking();
|
||||
updateBreadcrumb();
|
||||
}, 300);
|
||||
});
|
||||
|
||||
+228
-24
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/caiinfo.css" />
|
||||
</head>
|
||||
<body>
|
||||
@@ -58,10 +59,16 @@
|
||||
<!-- Main -->
|
||||
<main class="cxz-main">
|
||||
<div class="cxz-breadcrumb">
|
||||
<a href="index.html">首页</a><span class="sep">></span>
|
||||
<a href="cai.html?id=" id="breadcrumbCai">预测推荐</a
|
||||
><span class="sep">></span>
|
||||
<span id="breadcrumbExpert">专家详情</span>
|
||||
<a href="javascript:history.back();" class="cxz-breadcrumb-back" id="breadcrumbBack">
|
||||
<i class="layui-icon layui-icon-left"></i>
|
||||
<span>返回上一页</span>
|
||||
</a>
|
||||
<div class="cxz-breadcrumb-trail" id="breadcrumbTrail">
|
||||
<a href="index.html">首页</a><span class="sep">></span>
|
||||
<a href="cai.html?id=" id="breadcrumbCai">预测推荐</a
|
||||
><span class="sep">></span>
|
||||
<span id="breadcrumbExpert">专家详情</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Expert Card -->
|
||||
@@ -279,6 +286,7 @@
|
||||
let currentWalletOverview = {};
|
||||
let expertCollected = false;
|
||||
let currentArticleList = [];
|
||||
let currentMenuMeta = { lottery: null, parent: null, current: null };
|
||||
const purchasedArticleIds = new Set();
|
||||
const purchasedArticleKeys = new Set();
|
||||
|
||||
@@ -344,6 +352,94 @@
|
||||
});
|
||||
}
|
||||
|
||||
function findMenuMeta(menus) {
|
||||
let lottery = null;
|
||||
let parent = null;
|
||||
let current = null;
|
||||
const targetCode = String(code || "").toLowerCase();
|
||||
const targetMenuId = String(parentId || "");
|
||||
|
||||
function walk(items, parentNode, rootNode) {
|
||||
$.each(items || [], function (_, item) {
|
||||
const root = rootNode || item;
|
||||
const itemCode = String(item.code || item.suoxie || "").toLowerCase();
|
||||
const itemId = String(item.id || item.menuId || "");
|
||||
|
||||
if (targetCode && itemCode === targetCode) {
|
||||
lottery = root;
|
||||
}
|
||||
|
||||
if (targetMenuId && itemId === targetMenuId) {
|
||||
lottery = root;
|
||||
current = item;
|
||||
parent = parentNode && parentNode !== root ? parentNode : null;
|
||||
}
|
||||
|
||||
if (item.children && item.children.length) {
|
||||
walk(item.children, item, root);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
walk(menus || [], null, null);
|
||||
return { lottery: lottery, parent: parent, current: current };
|
||||
}
|
||||
|
||||
function loadBreadcrumbMenuMeta() {
|
||||
return ApiClient.loadMenuCompat()
|
||||
.then(function (res) {
|
||||
const menus = ApiClient.asArray(ApiClient.pickData(res, []));
|
||||
currentMenuMeta = findMenuMeta(menus);
|
||||
return currentMenuMeta;
|
||||
})
|
||||
.catch(function () {
|
||||
currentMenuMeta = { lottery: null, parent: null, current: null };
|
||||
return currentMenuMeta;
|
||||
});
|
||||
}
|
||||
|
||||
function getReturnListHref() {
|
||||
const referrer = document.referrer || "";
|
||||
if (referrer && referrer.indexOf(location.origin) === 0) {
|
||||
return referrer;
|
||||
}
|
||||
return buildCaiListUrl();
|
||||
}
|
||||
|
||||
function updateBreadcrumb(expertName) {
|
||||
const lottery = currentMenuMeta.lottery || {};
|
||||
const parent = currentMenuMeta.parent || {};
|
||||
const current = currentMenuMeta.current || {};
|
||||
const lotteryName = lottery.name || lottery.title || code || "预测推荐";
|
||||
const lotteryCode = lottery.code || lottery.suoxie || code || "";
|
||||
const listHref = buildCaiListUrl(lotteryCode);
|
||||
const items = [
|
||||
{ text: "首页", href: "index.html" },
|
||||
{ text: lotteryName, href: listHref },
|
||||
];
|
||||
|
||||
if (parent.name) {
|
||||
items.push({ text: parent.name, href: listHref });
|
||||
}
|
||||
if (current.name && current.name !== parent.name) {
|
||||
items.push({ text: current.name, href: listHref });
|
||||
}
|
||||
items.push({ text: expertName || "专家详情" });
|
||||
|
||||
const html = items
|
||||
.map(function (item, index) {
|
||||
const text = CommonUtil.escapeHtml(item.text || "");
|
||||
const node = item.href
|
||||
? '<a href="' + CommonUtil.escapeHtml(item.href) + '">' + text + "</a>"
|
||||
: '<span id="breadcrumbExpert">' + text + "</span>";
|
||||
return index === 0 ? node : '<span class="sep">></span>' + node;
|
||||
})
|
||||
.join("");
|
||||
|
||||
$("#breadcrumbTrail").html(html);
|
||||
$("#breadcrumbBack").attr("href", getReturnListHref());
|
||||
}
|
||||
|
||||
function getArticleId(item) {
|
||||
return String(
|
||||
(item &&
|
||||
@@ -388,6 +484,11 @@
|
||||
);
|
||||
}
|
||||
|
||||
function formatIssueText(issue) {
|
||||
const value = String(issue || "").trim();
|
||||
return /^\d{7,}$/.test(value) ? value.slice(-3) : value;
|
||||
}
|
||||
|
||||
function getArticleExpertId(item) {
|
||||
return String((item && (item.expertId || item.createBy || item.accountId)) || createBy || "");
|
||||
}
|
||||
@@ -529,6 +630,7 @@
|
||||
return { code: 500, msg: error.message || "获取专家预测详情失败", data: [] };
|
||||
}),
|
||||
loadPurchasedRecordsForCurrentExpert(),
|
||||
loadBreadcrumbMenuMeta(),
|
||||
]).then(function ([profileRes, listRes]) {
|
||||
const profile = ApiClient.pickData(profileRes, {}) || {};
|
||||
const listData = ApiClient.pickData(listRes, []) || [];
|
||||
@@ -583,7 +685,7 @@
|
||||
"专家";
|
||||
if (avatar) $("#expertAvatar").attr("src", avatar);
|
||||
$("#expertName").text(name);
|
||||
$("#breadcrumbExpert").text(name || "专家详情");
|
||||
updateBreadcrumb(name || "专家详情");
|
||||
expertCollected = isExpertCollected(data);
|
||||
applyExpertCollectState(expertCollected);
|
||||
}
|
||||
@@ -611,9 +713,15 @@
|
||||
const predictedCode = getArticleRecommend(item);
|
||||
const hasDrawResult = isArticleDrawn(item, openCode);
|
||||
const isLatestIssue = isLatestArticle(item, list);
|
||||
const price = Number(getArticlePrice(item));
|
||||
const unlockedByVisibleRecommend =
|
||||
predictedCode && !isMaskedRecommendText(predictedCode);
|
||||
const purchased = isArticlePurchased(item);
|
||||
isLatestIssue &&
|
||||
!hasDrawResult &&
|
||||
price > 0 &&
|
||||
!isArticleMasked(item) &&
|
||||
predictedCode &&
|
||||
!isMaskedRecommendText(predictedCode);
|
||||
const purchased = isArticlePurchased(item) || unlockedByVisibleRecommend;
|
||||
const canShowRecommend = canShowArticleRecommend(
|
||||
item,
|
||||
isLatestIssue,
|
||||
@@ -621,17 +729,21 @@
|
||||
unlockedByVisibleRecommend,
|
||||
);
|
||||
const articleStatus = getArticleStatus(item);
|
||||
let recommendOptions = null;
|
||||
let recommendText = "";
|
||||
let openCodeHtml = renderOpenCodeBalls(openCode, item);
|
||||
let predictHtml = "";
|
||||
if (isPendingPublishText(predictedCode)) {
|
||||
predictHtml = '<span style="color:var(--text-muted);">待发布</span>';
|
||||
const pendingPublish = isPendingPublishArticle(item, articleStatus, predictedCode);
|
||||
if (pendingPublish) {
|
||||
predictHtml = '<span class="cxz-pending-publish-text">' + getPendingPublishText() + '</span>';
|
||||
} else if (canShowRecommend && predictedCode) {
|
||||
const recommendOptions = getRecommendRenderOptions(item, articleStatus.text);
|
||||
recommendOptions = getRecommendRenderOptions(item, articleStatus.text);
|
||||
recommendText = formatRecommendText(predictedCode, Infinity, recommendOptions);
|
||||
predictHtml =
|
||||
buildRecommendHtml(predictedCode, Infinity, recommendOptions) +
|
||||
' <button class="cxz-btn-copy" onclick="copyCode(\'' +
|
||||
escapeJs(predictedCode) +
|
||||
"')\">复制</button>";
|
||||
'<span class="cxz-recommend-wrap"><span class="cxz-recommend-content"></span>' +
|
||||
'<button class="cxz-btn-copy" onclick="event.stopPropagation(); copyCode(\'' +
|
||||
escapeJs(recommendText) +
|
||||
"')\">复制</button></span>";
|
||||
} else if (predictedCode) {
|
||||
predictHtml =
|
||||
'<span style="color:var(--text-muted);">' +
|
||||
@@ -654,7 +766,7 @@
|
||||
actionHtml =
|
||||
'<button class="cxz-btn-prebuy" onclick="openPrePurchaseDialog(' +
|
||||
i +
|
||||
')">预购</button> ';
|
||||
')">购买</button> ';
|
||||
} else if (shouldShowBuyButton(item, isLatestIssue, hasDrawResult, purchased) && articleId) {
|
||||
actionHtml =
|
||||
'<button class="cxz-btn-buy" onclick="openBuyDialog(\'' +
|
||||
@@ -678,7 +790,7 @@
|
||||
$body.append(
|
||||
"<tr>" +
|
||||
"<td>" +
|
||||
CommonUtil.escapeHtml(getArticleIssue(item) || "--") +
|
||||
CommonUtil.escapeHtml(formatIssueText(getArticleIssue(item)) || "--") +
|
||||
"</td>" +
|
||||
"<td>" +
|
||||
openCodeHtml +
|
||||
@@ -694,6 +806,17 @@
|
||||
"</td>" +
|
||||
"</tr>",
|
||||
);
|
||||
if (canShowRecommend && predictedCode && recommendOptions) {
|
||||
const $recommendCell = $body.children("tr").last().find(".cxz-recommend-content");
|
||||
const isFolded = fitRecommendCell($recommendCell, predictedCode, recommendOptions);
|
||||
if (isFolded) {
|
||||
$recommendCell
|
||||
.addClass("recommend-clickable")
|
||||
.on("click", function () {
|
||||
showFullRecommend(predictedCode, recommendOptions);
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -764,7 +887,25 @@
|
||||
}
|
||||
|
||||
function isPendingPublishText(value) {
|
||||
return String(value || "").trim() === "待发布";
|
||||
const text = String(value || "").trim();
|
||||
return text === "待发布" || text === getPendingPublishText() || text.indexOf("发布中") >= 0;
|
||||
}
|
||||
|
||||
function getPendingPublishText() {
|
||||
return "号码发布中请稍等";
|
||||
}
|
||||
|
||||
function isPendingPublishArticle(item, articleStatus, recommend) {
|
||||
const statusText = String(
|
||||
getExplicitStatusText(item) ||
|
||||
(articleStatus && articleStatus.text) ||
|
||||
"",
|
||||
).trim();
|
||||
return Boolean(
|
||||
isPendingPublishText(recommend) ||
|
||||
isPendingPublishText(statusText) ||
|
||||
(isArticlePrePurchase(item) && !getArticleRecommend(item)),
|
||||
);
|
||||
}
|
||||
|
||||
function isCodeResultsAllCorrect(item) {
|
||||
@@ -914,7 +1055,6 @@
|
||||
isLatestIssue &&
|
||||
!hasDrawResult &&
|
||||
isArticleMasked(item) &&
|
||||
!isArticlePrePurchase(item) &&
|
||||
!purchased,
|
||||
);
|
||||
}
|
||||
@@ -923,8 +1063,8 @@
|
||||
return Boolean(
|
||||
!purchased &&
|
||||
!isArticlePrePurchased(item) &&
|
||||
!getArticleId(item) &&
|
||||
getArticleStatus(item).text === "待发布",
|
||||
(isArticlePrePurchase(item) ||
|
||||
(!getArticleId(item) && isPendingPublishArticle(item))),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -942,7 +1082,21 @@
|
||||
}
|
||||
|
||||
function buildRecommendHtml(recommend, limit, options) {
|
||||
const nums = splitRecommendValues(recommend);
|
||||
const contentHtml = buildRecommendContentHtml(recommend, limit, options || {});
|
||||
const more =
|
||||
Number.isFinite(limit) && nums.length > limit
|
||||
? '<span class="recommend-view-all">点击查看全部</span>'
|
||||
: "";
|
||||
if (more) {
|
||||
return (
|
||||
'<span class="fushi234item"><span class="recommend-preview-text">' +
|
||||
contentHtml +
|
||||
"</span>" +
|
||||
more +
|
||||
"</span>"
|
||||
);
|
||||
}
|
||||
return (
|
||||
'<span class="fushi234item">' +
|
||||
(contentHtml || CommonUtil.escapeHtml(formatRecommendText(recommend, limit, options || {}))) +
|
||||
@@ -950,6 +1104,52 @@
|
||||
);
|
||||
}
|
||||
|
||||
function fitRecommendCell($cell, recommend, options) {
|
||||
const nums = splitRecommendValues(recommend);
|
||||
const previewLimit = 4;
|
||||
if (nums.length <= previewLimit) {
|
||||
$cell.html(buildRecommendHtml(recommend, Infinity, options || {}));
|
||||
return false;
|
||||
}
|
||||
|
||||
$cell.html(buildRecommendHtml(recommend, Infinity, options || {}));
|
||||
const cellEl = $cell.get(0);
|
||||
const contentEl = $cell.find(".fushi234item").get(0);
|
||||
if (cellEl && contentEl && contentEl.scrollWidth <= cellEl.clientWidth) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$cell.html(buildRecommendHtml(recommend, previewLimit, options || {}));
|
||||
return true;
|
||||
}
|
||||
|
||||
function showFullRecommend(recommend, options) {
|
||||
const fullText = formatRecommendText(recommend, Infinity, options || {});
|
||||
if (!fullText) return;
|
||||
layui.layer.open({
|
||||
title: "完整推荐号码",
|
||||
area: ["520px", "auto"],
|
||||
skin: "recommend-number-layer",
|
||||
btn: ["确定"],
|
||||
content:
|
||||
'<div class="recommend-number-dialog">' +
|
||||
'<div class="recommend-number-content">' +
|
||||
buildRecommendHtml(recommend, Infinity, options || {}) +
|
||||
"</div>" +
|
||||
'<div class="recommend-number-actions">' +
|
||||
'<button class="recommend-dialog-copy" type="button">复制全部</button>' +
|
||||
"</div>" +
|
||||
"</div>",
|
||||
});
|
||||
setTimeout(function () {
|
||||
$(".recommend-dialog-copy")
|
||||
.off("click")
|
||||
.on("click", function () {
|
||||
copyCode(fullText);
|
||||
});
|
||||
}, 0);
|
||||
}
|
||||
|
||||
function buildRecommendContentHtml(recommend, limit, options) {
|
||||
const groups = parseRecommendGroups(recommend);
|
||||
if (!groups.length) return "";
|
||||
@@ -1332,6 +1532,10 @@
|
||||
let text = statusText || "待开奖";
|
||||
let style = "color:#8c8c8c;";
|
||||
|
||||
if (isPendingPublishText(text)) {
|
||||
text = "待开奖";
|
||||
}
|
||||
|
||||
if (isWinStatusText(text)) {
|
||||
style = "color:#de2103;";
|
||||
}
|
||||
@@ -1885,7 +2089,7 @@
|
||||
return;
|
||||
}
|
||||
|
||||
ApiClient.get(ApiClient.API.walletPrepurchasePayArticle, params, {
|
||||
ApiClient.post(ApiClient.API.walletPrepurchasePayArticle, params, {
|
||||
headers: CommonUtil.authHeaders(),
|
||||
}).then(function (res) {
|
||||
if (ApiClient.isSuccess(res)) {
|
||||
@@ -1899,15 +2103,15 @@
|
||||
});
|
||||
}
|
||||
|
||||
function buildCaiListUrl() {
|
||||
function buildCaiListUrl(lotteryCode) {
|
||||
const params = new URLSearchParams();
|
||||
params.set("id", code || "ssq");
|
||||
params.set("id", lotteryCode || code || "ssq");
|
||||
if (parentId) params.set("parentId", parentId);
|
||||
return "cai.html?" + params.toString();
|
||||
}
|
||||
|
||||
// Breadcrumb
|
||||
$("#breadcrumbCai").attr("href", buildCaiListUrl());
|
||||
updateBreadcrumb("专家详情");
|
||||
|
||||
// Init
|
||||
$(function () {
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/publish.css" />
|
||||
<link rel="stylesheet" href="../public/css/finance.css" />
|
||||
<link rel="stylesheet" href="../public/css/chongzhi.css" />
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/js/wangeditor-v5/style.css" />
|
||||
<link rel="stylesheet" href="../public/css/fabumianfeiwenzhang.css" />
|
||||
</head>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/distribution.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
<title id="page-title">神彩算 - 发布付费文章</title>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/fufei.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/gonggao.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/gonggao.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
<title id="page-title">神彩算 - 多文章彩票预测首页</title>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/index.css" />
|
||||
<script src="../public/css/layui/layui.js"></script>
|
||||
<script src="../config.js"></script>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/finance.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/kaijiang.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
<script src="../public/js/purify.min.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/mianfei.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/mianfei.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/mianfei.css" />
|
||||
<link rel="stylesheet" href="../public/css/publish.css" />
|
||||
<link rel="stylesheet" href="../public/css/mianfeishoucang.css" />
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/trend.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/publish.css" />
|
||||
<link rel="stylesheet" href="../public/css/tixian.css" />
|
||||
</head>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/publish.css" />
|
||||
<link rel="stylesheet" href="../public/css/pagination.css" />
|
||||
<link rel="stylesheet" href="../public/css/tixianlist.css" />
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
<script src="../public/js/qrcode.min.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/distribution.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/usercenter.css" />
|
||||
<link rel="stylesheet" href="../public/css/usercenter-signin.css" />
|
||||
</head>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/distribution.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/static.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<script src="../utils/CommonUtil.js"></script>
|
||||
<link rel="stylesheet" href="../public/css/layui/css/layui.css" />
|
||||
<link rel="stylesheet" href="../public/css/public.css" />
|
||||
<link rel="stylesheet" href="../public/css/layout-fix.css" />
|
||||
<link rel="stylesheet" href="../public/css/static.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
Reference in New Issue
Block a user