提交 7651ad1a authored 作者: coderBryanFu's avatar coderBryanFu

feta:数据资源库更新

上级 1c13c291
......@@ -18,7 +18,7 @@ const setChart = (option, chartId, allowClick, selectParam) => {
if (params.componentType === 'series' && params.seriesType === 'pie') {
console.log('点击的扇形名称:', params.name);
if (selectParam.key === '领域') {
selectParam.domains = JSON.stringify([params.name])
selectParam.domains = params.name
} else if (selectParam.key === '议院委员会') {
if (params.name === '众议院' || params.name === '参议院') {
selectParam.selectedCongress = params.name
......@@ -45,6 +45,21 @@ const setChart = (option, chartId, allowClick, selectParam) => {
query: selectParam
});
window.open(route.href, "_blank");
} else {
console.log('当前点击', selectParam, params.seriesName, params.name);
if (params.seriesName !== '通过率') {
selectParam = {
selectedDate: params.name,
status: params.seriesName === '通过法案' ? 1 : 0,
...selectParam
}
const route = router.resolve({
path: "/dataLibrary/countryBill",
query: selectParam
});
window.open(route.href, "_blank");
}
}
}
......
......@@ -821,7 +821,14 @@ const handleBox5 = async () => {
return p ? ((pass / p) * 100).toFixed(2) : 0;
});
const box5Chart = getMultiLineChart(box5Data.value.title, proposed, passed, rate);
setChart(box5Chart, "box5Chart");
const domain = categoryList.value.filter(item => {
return item.id === box5Select.value
})[0]?.name
const selectParam = {
moduleType: '国会法案',
domains: domain
}
setChart(box5Chart, "box5Chart", true, selectParam);
}
};
......@@ -866,7 +873,7 @@ const handleBox7Data = async () => {
if (t1 !== t2) return t1 - t2;
return (b.value ?? 0) - (a.value ?? 0);
});
const selectParam = {
moduleType: '国会法案',
key: '议院委员会',
......@@ -993,6 +1000,7 @@ const handleBox9Data = async () => {
);
const selectParam = {
moduleType: '国会法案',
key: '领域',
selectedDate: box9selectetedTime.value,
status: box9LegislativeStatus.value === '提出法案' ? 0 : 1,
isInvolveCn: 1
......@@ -1175,7 +1183,7 @@ const handleBox8Data = async () => {
const selectParam = {
moduleType: '国会法案',
key: '领域',
key: '所处阶段',
selectedDate: box8selectetedTime.value,
isInvolveCn: 1
}
......@@ -1208,7 +1216,7 @@ const handleBox8Data = async () => {
box8StageList.value = data.stages;
await nextTick();
const box8Chart = getBox8ChartOption(data.stages);
box8ChartInstance = setChart(box8Chart, "box8Chart" , true, selectParam);
box8ChartInstance = setChart(box8Chart, "box8Chart", true, selectParam);
} else {
box8HasData.value = false;
box8Summary.value = 0;
......
......@@ -34,7 +34,7 @@
@close="handleCloseCurTag(tag, index)" />
</div>
<div class="header-footer-right">
<HeaderBtnBox :isShowAll="isFolderAll" @show-all="handleSwitchFolderAll" />
<HeaderBtnBox :isShowAll="isFolderAll" @show-all="handleSwitchFolderAll" @clear="handleClear" @confirm="handleConfirm" />
</div>
</div>
</div>
......@@ -162,6 +162,7 @@ import { useRoute } from "vue-router";
import { getPostOrgList, getPostMemberList } from '@/api/bill/billHome'
import { search } from '@/api/comprehensiveSearch'
import { ElMessage } from 'element-plus'
const route = useRoute();
// 图表/数据
......@@ -607,9 +608,26 @@ const handleSelectStauts = value => {
}
// 是否涉华
const isInvolveCn = ref(true)
const isInvolveCn = ref(false)
const handleInvolveCnChange = () => {
}
// 清空条件
const handleClear = () => {
selectedArea.value = '全部领域'
selectedDate.value = ''
selectedParty.value = '全部党派'
selectedCongress.value = '全部议院'
selectedOrg.value = '全部委员会'
selectedmember.value = '全部议员'
selectedStauts.value = '全部阶段'
isInvolveCn.value = false
ElMessage.success('已清空条件!')
}
// 确定
const handleConfirm = () => {
fetchTableData()
}
// 展开全部 / 收起
......@@ -663,8 +681,8 @@ const fetchTableData = async () => {
keyword: '',
type: 1, // type 1= 法案 2= 政令 3 =智库 4=智库报告 5=实体清单【制裁记录】 6= 人物 7= 机构 8=新闻 9= 社媒
domains: selectedArea.value === '全部领域' ? null : [selectedArea.value],
proposedDateStart: selectedDate.value ? selectedDate.value : null,
proposedDateEnd: null,
proposedDateStart: null,
proposedDateEnd: selectedDate.value ? selectedDate.value : null,
affiliation: selectedParty.value === '全部党派' ? null : selectedParty.value,
originChamber: selectedCongress.value === '全部议院' ? null : selectedCongress.value,
originDepart: selectedOrg.value === '全部委员会' ? null : selectedOrg.value,
......@@ -836,10 +854,16 @@ const curChartData = ref(null)
// 跳转到当前页 初始化筛选条件
const initParam = () => {
selectedArea.value = route.query.domains ? JSON.parse(route.query.domains)[0] : '全部领域'
selectedArea.value = route.query.domains ? route.query.domains : '全部领域'
selectedDate.value = route.query.selectedDate,
isInvolveCn.value = route.query.isInvolveCn ? true : false
selectedStauts.value = route.query.status === '1' ? '通过' : '提出'
if (route.query.status) {
selectedStauts.value = route.query.status === '1' ? '通过' : '提出'
} else {
selectedStauts.value = '全部阶段'
}
selectedCongress.value = route.query.selectedCongress ? route.query.selectedCongress : '全部议院'
selectedOrg.value = route.query.selectedOrg ? route.query.selectedOrg : '全部委员会'
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论