事件中心的涨停原因里面和事件相关
This commit is contained in:
Binary file not shown.
@@ -209,6 +209,12 @@ def init_prediction_api(db, beijing_now):
|
|||||||
query = query.order_by(desc(PredictionTopic.views_count))
|
query = query.order_by(desc(PredictionTopic.views_count))
|
||||||
elif sort_by == 'participants':
|
elif sort_by == 'participants':
|
||||||
query = query.order_by(desc(PredictionTopic.participants_count))
|
query = query.order_by(desc(PredictionTopic.participants_count))
|
||||||
|
elif sort_by == 'ending_soon':
|
||||||
|
# 即将截止:按截止时间升序,最快截止的在前面(只显示未结算的)
|
||||||
|
query = query.order_by(PredictionTopic.deadline.asc())
|
||||||
|
elif sort_by == 'highest_pool':
|
||||||
|
# 奖池最高:按总奖池降序
|
||||||
|
query = query.order_by(desc(PredictionTopic.total_pool))
|
||||||
else:
|
else:
|
||||||
query = query.order_by(desc(PredictionTopic.created_at))
|
query = query.order_by(desc(PredictionTopic.created_at))
|
||||||
|
|
||||||
|
|||||||
@@ -523,7 +523,7 @@ const MainlineTimelineViewComponent = forwardRef(
|
|||||||
const [mainlineData, setMainlineData] = useState(null);
|
const [mainlineData, setMainlineData] = useState(null);
|
||||||
const [expandedGroups, setExpandedGroups] = useState({});
|
const [expandedGroups, setExpandedGroups] = useState({});
|
||||||
// 概念级别选择: 'lv1' | 'lv2' | 'lv3' | 具体概念ID(如 L1_TMT, L2_AI_INFRA, L3_AI_CHIP)
|
// 概念级别选择: 'lv1' | 'lv2' | 'lv3' | 具体概念ID(如 L1_TMT, L2_AI_INFRA, L3_AI_CHIP)
|
||||||
const [groupBy, setGroupBy] = useState("lv2");
|
const [groupBy, setGroupBy] = useState("lv3");
|
||||||
// 层级选项(从 API 获取)
|
// 层级选项(从 API 获取)
|
||||||
const [hierarchyOptions, setHierarchyOptions] = useState({ lv1: [], lv2: [], lv3: [] });
|
const [hierarchyOptions, setHierarchyOptions] = useState({ lv1: [], lv2: [], lv3: [] });
|
||||||
// 排序方式: 'event_count' | 'change_desc' | 'change_asc'
|
// 排序方式: 'event_count' | 'change_desc' | 'change_asc'
|
||||||
|
|||||||
@@ -2056,10 +2056,44 @@ const DetailModal = ({ isOpen, onClose, selectedDate, ztDetail, events, loading
|
|||||||
fontSize="md"
|
fontSize="md"
|
||||||
lineHeight="1.8"
|
lineHeight="1.8"
|
||||||
sx={{
|
sx={{
|
||||||
'& p': { mb: 4 },
|
// 确保所有文本元素都使用浅色
|
||||||
|
'& *': { color: 'inherit' },
|
||||||
|
'& p': { mb: 4, color: 'whiteAlpha.900' },
|
||||||
'& h1, & h2, & h3': { color: 'gold', mb: 3 },
|
'& h1, & h2, & h3': { color: 'gold', mb: 3 },
|
||||||
'& ul, & ol': { pl: 6 },
|
'& h4, & h5, & h6': { color: 'whiteAlpha.900', mb: 2 },
|
||||||
'& li': { mb: 2 },
|
'& ul, & ol': { pl: 6, color: 'whiteAlpha.900' },
|
||||||
|
'& li': { mb: 2, color: 'whiteAlpha.900' },
|
||||||
|
'& a': { color: 'cyan.300', textDecoration: 'underline' },
|
||||||
|
'& strong, & b': { color: 'gold', fontWeight: 'bold' },
|
||||||
|
'& em, & i': { color: 'whiteAlpha.800' },
|
||||||
|
'& code': {
|
||||||
|
color: 'orange.300',
|
||||||
|
bg: 'whiteAlpha.100',
|
||||||
|
px: 1,
|
||||||
|
borderRadius: 'sm',
|
||||||
|
fontSize: 'sm',
|
||||||
|
},
|
||||||
|
'& pre': {
|
||||||
|
bg: 'whiteAlpha.100',
|
||||||
|
p: 3,
|
||||||
|
borderRadius: 'md',
|
||||||
|
overflow: 'auto',
|
||||||
|
'& code': { bg: 'transparent', p: 0 },
|
||||||
|
},
|
||||||
|
'& blockquote': {
|
||||||
|
borderLeft: '3px solid',
|
||||||
|
borderColor: 'gold',
|
||||||
|
pl: 4,
|
||||||
|
ml: 0,
|
||||||
|
color: 'whiteAlpha.700',
|
||||||
|
fontStyle: 'italic',
|
||||||
|
},
|
||||||
|
'& table': {
|
||||||
|
width: '100%',
|
||||||
|
'& th': { color: 'gold', borderBottom: '1px solid rgba(255,215,0,0.3)', p: 2 },
|
||||||
|
'& td': { color: 'whiteAlpha.900', borderBottom: '1px solid rgba(255,255,255,0.1)', p: 2 },
|
||||||
|
},
|
||||||
|
'& hr': { borderColor: 'whiteAlpha.200', my: 4 },
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<ReactMarkdown>
|
<ReactMarkdown>
|
||||||
|
|||||||
@@ -85,10 +85,10 @@ const PredictionMarket: React.FC = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const response = await getTopics({
|
const response = await getTopics({
|
||||||
status: filterBy === 'all' ? undefined : filterBy,
|
status: filterBy === 'all' ? '' : filterBy,
|
||||||
sort: sortBy,
|
sort_by: sortBy === 'latest' ? 'created_at' : sortBy,
|
||||||
page: 1,
|
page: 1,
|
||||||
pageSize: 30,
|
per_page: 30,
|
||||||
});
|
});
|
||||||
|
|
||||||
if (response.success) {
|
if (response.success) {
|
||||||
|
|||||||
Reference in New Issue
Block a user