From 5941a69f96a0d899b9b2b8ca380118d9f6f486da Mon Sep 17 00:00:00 2001 From: wang_yp <357754663@qq.com> Date: Thu, 17 Oct 2024 00:44:14 +0800 Subject: [PATCH] fix(amap):core --- src/pages/home/homeLeft/orgin.tsx | 16 ++++++++++++---- src/pages/training/training.tsx | 4 ++-- src/static/org_tow.png | Bin 0 -> 370132 bytes 3 files changed, 14 insertions(+), 6 deletions(-) create mode 100644 src/static/org_tow.png diff --git a/src/pages/home/homeLeft/orgin.tsx b/src/pages/home/homeLeft/orgin.tsx index 2c7eb6e..3ed4cb6 100644 --- a/src/pages/home/homeLeft/orgin.tsx +++ b/src/pages/home/homeLeft/orgin.tsx @@ -1,6 +1,7 @@ import OrgChart from "@/pages/OrgChart"; import origin from "@/static/orgin.png"; import origin2 from "@/static/orgin2.png"; +import ogr from "@/static/org_tow.png"; import { Modal } from "antd"; import { Store } from "antd/es/form/interface"; import { inject, observer } from "mobx-react"; @@ -8,6 +9,7 @@ import { useEffect, useState } from "react"; const Orgin = (props: Store) => { const { homeStore } = props; const [isModalOpen, setIsModalOpen] = useState(false); + const [isSelf, setIsSelf] = useState(false); useEffect(() => { homeStore.getOgCount(); @@ -21,13 +23,19 @@ const Orgin = (props: Store) => { }; return ( <> -
-
+
+
{ + setIsSelf(true) + showModal() + }}> {homeStore.ogMap?.count ?? 0}

党组织数量

-
+
{ + setIsSelf(false) + showModal() + }}> {homeStore.ogMap?.member_count ?? 0}

党员数量

@@ -43,7 +51,7 @@ const Orgin = (props: Store) => { onCancel={handleCancel} footer={null} > - + {isSelf ? : org} ); diff --git a/src/pages/training/training.tsx b/src/pages/training/training.tsx index 102e11b..1c92b4b 100644 --- a/src/pages/training/training.tsx +++ b/src/pages/training/training.tsx @@ -46,7 +46,7 @@ const Trainings = (props: Store) => { { title: "任务结束时间", dataIndex: "end_time" ,width:200}, { title: "任务积分设置", dataIndex: "score" ,width:200}, { title: "任务类别", dataIndex: "category_name",width:200 }, - { title: "任务状态", dataIndex: "status",render: (status) => status===1?"已完成":"未完成",width:200}, + { title: "任务状态", dataIndex: "status",render: (status) => status===2?"已完成":"未完成",width:200}, { title: "物资归还状态",width:200, dataIndex: "supplies_status",render: (supplies_status) => supplies_status===2?"已归还":"未归还"}, { title: "操作", @@ -65,7 +65,7 @@ const Trainings = (props: Store) => { 编辑 { - record.status===0 ?