正式环境更改

main
严飞永 4 weeks ago
parent 64b8d3d570
commit c8e23745b7

@ -32,9 +32,7 @@ router.beforeEach((to, from, next) => {
const signature = params.get("signature"); const signature = params.get("signature");
const timespan = params.get("timespan"); const timespan = params.get("timespan");
// ============================= // clienttoken 企业单点登录
// 🔑 新增:处理 clienttoken 登录企业单点登录逻辑
// =============================
if (window.location.href.includes("clienttoken=")) { if (window.location.href.includes("clienttoken=")) {
const reg = /[?&]clienttoken=([^&#]+)/; const reg = /[?&]clienttoken=([^&#]+)/;
const match = window.location.href.match(reg); const match = window.location.href.match(reg);
@ -58,9 +56,6 @@ router.beforeEach((to, from, next) => {
.dispatch("SingleSignOnGetInfo", { clientToken: clienttoken }) .dispatch("SingleSignOnGetInfo", { clientToken: clienttoken })
.then(() => { .then(() => {
isRelogin.show = false; isRelogin.show = false;
console.log("✅ 单点登录成功");
console.log("当前 token:", getToken());
console.log("当前角色:", store.getters.roles);
// 清除 URL 中的 clienttoken 并刷新页面 // 清除 URL 中的 clienttoken 并刷新页面
window.history.replaceState({}, "", modifiedUrl); window.history.replaceState({}, "", modifiedUrl);
@ -75,8 +70,8 @@ router.beforeEach((to, from, next) => {
// console.error("单点登录失败:", err); // console.error("单点登录失败:", err);
store.dispatch("LogOut").then(() => { store.dispatch("LogOut").then(() => {
Message.error("单点登录失败,请重试"); Message.error("单点登录失败,请重试");
// window.location.href = window.location.href =
// "https://qytt.sipac.gov.cn/ecobrainportal/index.html"; "https://qytt.sipac.gov.cn/ecobrainportal/index.html";
}); });
}); });
@ -85,9 +80,7 @@ router.beforeEach((to, from, next) => {
} }
} }
// ============================= // 政务单点登录
// 📦 原有政务参数处理逻辑
// =============================
if (from.path === to.path && store.getters.token) { if (from.path === to.path && store.getters.token) {
next(); next();
return; return;
@ -155,9 +148,7 @@ router.beforeEach((to, from, next) => {
return; return;
} }
// ============================= //调用原始登录
// 🔐 原始本地登录逻辑
// =============================
if (getToken()) { if (getToken()) {
to.meta.title && store.dispatch("settings/setTitle", to.meta.title); to.meta.title && store.dispatch("settings/setTitle", to.meta.title);
/* has token*/ /* has token*/

@ -20,19 +20,32 @@
<div class="itemhead"> <div class="itemhead">
<span>关联项目</span> <span>关联项目</span>
</div> </div>
<div class="mainarea" style="height: 22rem; overflow: auto;"> <div class="mainarea" style="height: 22rem; overflow: auto">
<div v-if="postList.length > 0"> <div v-if="postList.length > 0">
<div class="mainareaitem" v-for="(item, index) in postList" :key="index"> <div
class="mainareaitem"
v-for="(item, index) in postList"
:key="index"
>
<div class="itemleft"> <div class="itemleft">
<div class="xmmctitle" @click="getInfo(item, 'detail')">{{ item.name }}</div> <div class="xmmctitle" @click="getInfo(item, 'detail')">
{{ item.name }}
</div>
<div class="lefttwo"> <div class="lefttwo">
<div style="display: flex;"> <div style="display: flex">
现状分类<dict-tag :options="dict.type.xzfl" :value="item.xzfl" /> 现状分类<dict-tag
:options="dict.type.xzfl"
:value="item.xzfl"
/>
</div> </div>
<div>总投资额{{ item.ztze }}</div> <div>总投资额{{ item.ztze }}</div>
<div>填报时间{{ item.updateTime }}</div> <div>填报时间{{ item.updateTime }}</div>
<div style="display: flex;align-items: center;"> <div style="display: flex; align-items: center">
状态<dict-tag :options="dict.type.tbzt" :value="item.status" /> 状态
<dict-tag
:options="dict.type.tbzt"
:value="item.status"
/>
</div> </div>
</div> </div>
</div> </div>
@ -41,9 +54,7 @@
</div> </div>
</div> </div>
</div> </div>
<div v-else class="no-data"> <div v-else class="no-data">暂无数据</div>
暂无数据
</div>
</div> </div>
</div> </div>
<div class="grid-item item-2"> <div class="grid-item item-2">
@ -59,39 +70,28 @@
</template> </template>
<script> <script>
import AllArea2 from '@/views/components/analysis/allcompany.vue' import AllArea2 from "@/views/components/analysis/allcompany.vue";
import Message2 from '@/views/components/analysis/messagecompany.vue' import Message2 from "@/views/components/analysis/messagecompany.vue";
import daiban from '@/views/components/analysis/daiban.vue' import daiban from "@/views/components/analysis/daiban.vue";
import { getBasicInformationPage } from "@/api/ManageApi/index"; import { getBasicInformationPage } from "@/api/ManageApi/index";
export default { export default {
name: "Pc2FbEcharts", name: "Pc2FbEcharts",
dicts:['xzfl','tbzt'], dicts: ["xzfl", "tbzt"],
components: { components: {
AllArea2, AllArea2,
Message2, Message2,
daiban daiban,
}, },
data() { data() {
return { return {
// //
postList: [], postList: [],
//
statusColors: {
'审核通过': '#6EDABE',
'待填报': '#FFBF6B',
'待审核': '#7693D8'
},
// //
statusMap: { statusMap: {
1: '待填报', 1: "待填报",
2: '待审核', 2: "待审核",
3: '审核通过' 3: "审核通过",
},
xzflMap: {
1: '已建',
2: '在建',
3: '拟建'
}, },
// //
loading: true, loading: true,
@ -105,25 +105,30 @@ export default {
getInfo(row, type) { getInfo(row, type) {
this.$store.commit("SET_CRUMBS", "项目详情"); this.$store.commit("SET_CRUMBS", "项目详情");
const id = row.id || this.ids[0]; const id = row.id || this.ids[0];
this.$router.push({ path: `/manage-info/${id}`, query: { action: type } }); this.$router.push({
path: `/manage-info/${id}`,
query: { action: type },
});
}, },
getStatusClass(status) { getStatusClass(status) {
const statusClasses = { const statusClasses = {
1: 'status-red', 1: "status-red",
2: 'status-yellow', 2: "status-yellow",
3: 'status-green' 3: "status-green",
}; };
return statusClasses[status] || ''; return statusClasses[status] || "";
}, },
/** 查询项目列表 */ /** 查询项目列表 */
getList() { getList() {
this.loading = true; this.loading = true;
getBasicInformationPage().then((response) => { getBasicInformationPage()
.then((response) => {
this.postList = response.data.records; this.postList = response.data.records;
this.loading = false; this.loading = false;
}).catch(error => { })
console.error('查询失败:', error); .catch((error) => {
console.error("查询失败:", error);
this.loading = false; this.loading = false;
}); });
}, },
@ -135,25 +140,21 @@ export default {
.grid-container { .grid-container {
display: grid; display: grid;
grid-template-columns: repeat(2, 1fr); grid-template-columns: repeat(2, 1fr);
/* 三列 */
grid-template-rows: auto auto auto; grid-template-rows: auto auto auto;
/* 三行 */
gap: 1rem; gap: 1rem;
/* 模块之间的间隔 */
padding: 1rem; padding: 1rem;
/* 容器内边距 */
} }
.grid-item { .grid-item {
background-color: #FFFFFF; background-color: #ffffff;
border-radius: 0.5rem 0.5rem 0.5rem 0.5rem; border-radius: 0.5rem 0.5rem 0.5rem 0.5rem;
} }
.item-2{ .item-2 {
width: auto; width: auto;
} }
.itemhead { .itemhead {
border-left: 0.25rem solid #2B62F1; border-left: 0.25rem solid #2b62f1;
margin: 0.94rem 0; margin: 0.94rem 0;
height: 1.25rem; height: 1.25rem;
display: flex; display: flex;
@ -165,7 +166,7 @@ export default {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi; font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 600; font-weight: 600;
font-size: 1rem; font-size: 1rem;
color: #3D424C; color: #3d424c;
line-height: 1.69rem; line-height: 1.69rem;
text-align: left; text-align: left;
font-style: normal; font-style: normal;
@ -180,9 +181,7 @@ export default {
gap: 1rem; gap: 1rem;
} }
/* 第一行:第一个模块占两列 */
.item-1 { .item-1 {
/* background-image: url(@/src/assets/images/allbg.png); */
background-size: 100% 100%; background-size: 100% 100%;
background-repeat: no-repeat; background-repeat: no-repeat;
} }
@ -193,10 +192,8 @@ export default {
padding: 1rem 1.5rem; padding: 1rem 1.5rem;
} }
/* 最后一行:一个模块占一整行 */
.item-6 { .item-6 {
grid-column: span 3; grid-column: span 3;
/* 占三列 */
} }
.mainareaitem { .mainareaitem {
@ -207,7 +204,7 @@ export default {
} }
.itemleft { .itemleft {
padding: .5rem 0 .5rem .5rem; padding: 0.5rem 0 0.5rem 0.5rem;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
width: 70%; width: 70%;
@ -233,15 +230,15 @@ export default {
} }
.status-red { .status-red {
background-color: #FFC77C; background-color: #ffc77c;
} }
.status-yellow { .status-yellow {
background-color: #7F99DB; background-color: #7f99db;
} }
.status-green { .status-green {
background-color: #74DCC1; background-color: #74dcc1;
} }
.bottombox { .bottombox {
@ -249,7 +246,7 @@ export default {
} }
.xmmctitle { .xmmctitle {
color: #2B62F1; color: #2b62f1;
cursor: pointer; cursor: pointer;
} }
@ -258,7 +255,7 @@ export default {
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
} }
.no-data{ .no-data {
color: gray; color: gray;
} }
</style> </style>

@ -50,7 +50,6 @@
<!-- <el-button <!-- <el-button
type="primary" type="primary"
icon="el-icon-plus" icon="el-icon-plus"
:loading="exportLoading" :loading="exportLoading"
@click="handleExport" @click="handleExport"
>项目手册导出</el-button >项目手册导出</el-button
@ -213,7 +212,7 @@
></el-input> ></el-input>
</div> </div>
</div> </div>
<div class="form-row"> <!-- <div class="form-row">
<div class="form-col-full"> <div class="form-col-full">
<label class="form-label">封面图片</label> <label class="form-label">封面图片</label>
<file-upload <file-upload
@ -223,7 +222,7 @@
:file-type="['png', 'jpg', 'jpeg', 'gif']" :file-type="['png', 'jpg', 'jpeg', 'gif']"
></file-upload> ></file-upload>
</div> </div>
</div> </div> -->
</div> </div>
</div> </div>
@ -353,7 +352,7 @@
<div v-if="activeStep === 3" class="step-content"> <div v-if="activeStep === 3" class="step-content">
<div class="cover-form"> <div class="cover-form">
<div class="form-row"> <!-- <div class="form-row">
<div class="form-col-full"> <div class="form-col-full">
<label class="form-label">封尾图片</label> <label class="form-label">封尾图片</label>
<file-upload <file-upload
@ -363,7 +362,7 @@
:file-type="['png', 'jpg', 'jpeg', 'gif']" :file-type="['png', 'jpg', 'jpeg', 'gif']"
></file-upload> ></file-upload>
</div> </div>
</div> </div> -->
<div class="form-row" style="margin-bottom: 10px"> <div class="form-row" style="margin-bottom: 10px">
<div class="form-col"> <div class="form-col">
<label class="form-label">单位名称</label> <label class="form-label">单位名称</label>
@ -405,6 +404,8 @@
placeholder="请输入" placeholder="请输入"
></el-input> ></el-input>
</div> </div>
<div class="form-col">
</div>
</div> </div>
</div> </div>
</div> </div>

@ -1,60 +0,0 @@
<template>
<div>
<!-- 显示当前页 -->
<pdf
v-if="show"
:src="pdfUrl"
@num-pages="pageCount = $event"
@link-clicked="gotoPage($event)"
style="border: 1px solid black;"
></pdf>
<!-- 控制按钮 -->
<button @click="prevPage"></button>
{{ currentPage }} / {{ pageCount }}
<button @click="nextPage"></button>
</div>
</template>
<script>
import pdf from "vue-pdf";
export default {
components: {
pdf,
},
data() {
return {
show: false, //
pdfUrl: "", // PDF
currentPage: 1, //
pageCount: 0, //
};
},
mounted() {
this.loadPdf();
},
methods: {
loadPdf() {
// PDF
this.pdfUrl = "pdf/模板.pdf";
this.show = true;
},
gotoPage(pageNumber) {
if (pageNumber >= 1 && pageNumber <= this.pageCount) {
this.currentPage = pageNumber;
}
},
prevPage() {
if (this.currentPage > 1) {
this.currentPage--;
}
},
nextPage() {
if (this.currentPage < this.pageCount) {
this.currentPage++;
}
},
},
};
</script>

@ -114,7 +114,7 @@ export default {
title: undefined, title: undefined,
startTime: undefined, startTime: undefined,
}, },
// // 使
allPostList: [ allPostList: [
{ {
id: 1, id: 1,

@ -208,6 +208,7 @@ export default {
this.$modal.confirm(`是否确认删除"${pjys}"的数据项?`).then(() => { this.$modal.confirm(`是否确认删除"${pjys}"的数据项?`).then(() => {
return deleteProjectEvaluation(postIds); return deleteProjectEvaluation(postIds);
}).then(() => { }).then(() => {
this.queryParams.current = 1;
this.getList(); this.getList();
this.$modal.msgSuccess('删除成功'); this.$modal.msgSuccess('删除成功');
}).catch(() => { }); }).catch(() => { });

@ -18,7 +18,7 @@ export default {
this.$router.push({path:"/statistics"}) this.$router.push({path:"/statistics"})
}else{ }else{
// //
this.$router.push({path:"/tongjifenxi"}) this.$router.push({path:"/Home"})
} }
} }
}; };

@ -252,6 +252,9 @@ export default {
zjzmj: 0, zjzmj: 0,
ztze: 0, ztze: 0,
zydmj: 0, zydmj: 0,
jhtze: "",
ml: "",
xfcy: "",
}, },
planInformation: { planInformation: {
bzcjzmj: 0, bzcjzmj: 0,
@ -457,7 +460,6 @@ export default {
}, },
// //
async submitAll() { async submitAll() {
// //
const loading = this.$loading({ const loading = this.$loading({
lock: true, lock: true,
@ -465,7 +467,45 @@ export default {
spinner: "el-icon-loading", spinner: "el-icon-loading",
background: "rgba(0, 0, 0, 0.7)", background: "rgba(0, 0, 0, 0.7)",
}); });
// basicInformation
const basicRequiredFields = [
"acceptanceTime",
"begainTime",
"endTime",
"fj",
"introduction",
"issuingTime",
"jsdd",
"jsjd",
"jsms",
"label",
"latitude",
"longitude",
"name",
"nature",
"phone",
"prioritize",
"projectLeader",
"sgdw",
"sjdw",
"ssgnq",
"tyshxydm",
"unitIntroduction",
"xmfrdwxz",
"xzfl",
"ztze",
"jhtze",
"ml",
"xfcy",
];
const basicMissingFields = basicRequiredFields.filter(
(field) => !this.basicInformation[field]
);
if (basicMissingFields.length > 0) {
this.$message.error("请填写完整的基本信息");
loading.close();
return;
}
// //
if (!this.hasBuildingData) { if (!this.hasBuildingData) {
this.$message.error("请填写建筑信息"); this.$message.error("请填写建筑信息");
@ -496,8 +536,16 @@ export default {
"zydmj", "zydmj",
"rjl", "rjl",
"zjzmj", "zjzmj",
"bzcjzmj",
"jrjljzmj",
"jzmd",
"ldl",
"jzds", "jzds",
"dsjzmj",
"dxjzmj",
"zgjzcs", "zgjzcs",
"jdctcw",
"fjdctcw",
"fhdj", "fhdj",
]; ];
const planMissingFields = planRequiredFields.filter( const planMissingFields = planRequiredFields.filter(
@ -509,22 +557,7 @@ export default {
return; return;
} }
// basicInformation
const basicRequiredFields = [
"ssgnq",
"begainTime",
"endTime",
"xzfl",
"jsms",
];
const basicMissingFields = basicRequiredFields.filter(
(field) => !this.basicInformation[field]
);
if (basicMissingFields.length > 0) {
this.$message.error("请填写完整的基本信息");
loading.close();
return;
}
// //
const submitData = this.prepareSubmitData(); const submitData = this.prepareSubmitData();

@ -669,6 +669,7 @@ export default {
return deleteBasicInformation(ids); return deleteBasicInformation(ids);
}) })
.then(() => { .then(() => {
this.queryParams.current = 1;
this.getList(); this.getList();
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");
}) })

@ -299,6 +299,7 @@ export default {
return deleteBasicInformation(ids); return deleteBasicInformation(ids);
}) })
.then(() => { .then(() => {
this.queryParams.current = 1; //
this.getList(); this.getList();
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");
}) })

@ -476,6 +476,7 @@ export default {
return deleteCatalog([catalogIds]); return deleteCatalog([catalogIds]);
}) })
.then(() => { .then(() => {
this.queryParams.current = 1;
this.getList(catalogIds); this.getList(catalogIds);
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");
}) })

@ -491,6 +491,7 @@ export default {
return deleteXfcygl([catalogIds]); return deleteXfcygl([catalogIds]);
}) })
.then(() => { .then(() => {
this.queryParams.current = 1;
this.getList(); this.getList();
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");
}) })

Loading…
Cancel
Save