增加研究覆盖审计及分类数据直达链接
This commit is contained in:
@@ -36,7 +36,12 @@ export default function AICompanyResearch() {
|
||||
const [error, setError] = useState(false);
|
||||
const [attempt, setAttempt] = useState(0);
|
||||
const [query, setQuery] = useState("");
|
||||
const [category, setCategory] = useState("");
|
||||
const [categoryChoice, setCategoryChoice] = useState<{ route: string; id: string } | null>(null);
|
||||
const linkedCategory = router.query.category;
|
||||
const category = categoryChoice && categoryChoice.route === router.asPath ? categoryChoice.id
|
||||
: router.isReady && typeof linkedCategory === "string" && data?.categories.some((c) => c.id === linkedCategory)
|
||||
? linkedCategory : "";
|
||||
function setCategory(id: string) { setCategoryChoice({ route: router.asPath, id }); }
|
||||
const [cohort, setCohort] = useState("");
|
||||
const [income, setIncome] = useState("");
|
||||
const [page, setPage] = useState(0);
|
||||
|
||||
Reference in New Issue
Block a user