diff --git a/web/client/assets/images/point.png b/web/client/assets/images/point.png new file mode 100644 index 0000000..0aef8a2 Binary files /dev/null and b/web/client/assets/images/point.png differ diff --git a/web/client/assets/images/top.png b/web/client/assets/images/top.png new file mode 100644 index 0000000..3a591ee Binary files /dev/null and b/web/client/assets/images/top.png differ diff --git a/web/client/src/sections/homePage/components/activityColumns.js b/web/client/src/sections/homePage/components/activityColumns.js deleted file mode 100644 index e0dde14..0000000 --- a/web/client/src/sections/homePage/components/activityColumns.js +++ /dev/null @@ -1,339 +0,0 @@ -import React, { useState, useEffect } from "react"; -import { connect } from "react-redux"; -import { Table } from "antd"; -import { push } from "react-router-redux"; -import moment from "moment"; -import { getDataList } from "../actions/profile"; -let xinwen = "../../../../assets/images/xinweng.png"; -let BARBG = "../../../../assets/images/barbg.png"; -let shangxinli = "../../../../assets/images/shangxinli_title.png"; -function ActivityColumns(props) { - const { dispatch } = props; - const [activities, setActivities] = useState([]); //活动风采 - const more = (id) => { - dispatch(push("/more", { type: 0, status: 1 })); - }; - useEffect(() => { - dispatch(getDataList({ type: 0, status: 1 })).then((res) => { - res.payload ? setActivities(res.payload.data.data) : ""; - }); - }, []); - const renderInfoBar = (title) => { - return ( -
-
- {title} -
-
{ - more("123"); - }} - > - {"更多 >>"} -
-
- ); - }; - const activityColumns = [ - { - title: "Name", - dataIndex: "name", - key: "name", - ellipsis: true, - sorter: (a, b) => { - const atime = a.createTime - .slice(0, 10) - .replace("-", "") - .replace("-", ""); - - const btime = b.createTime - .slice(0, 10) - .replace("-", "") - .replace("-", ""); - return atime - btime; - }, - defaultSortOrder: "bscend", - render: (text, record) => ( - <> -
{ - dispatch( - push("/particulars", { - id: record.id, - title: record.title, - }) - ); - }} - > - - - {record?.title || ""} - - - [{record?.createTime.slice(0, 10) || ""}] - -
- - ), - }, - ]; - return ( -
-
- {renderInfoBar("活动风采")} -
-
- huodong -
-
- 习近平致首届大国工匠创新交流大会的贺信 -
-
- 值此首届大国工匠创新交流大会召开之际,我向大会的举办… -
-
-
-
- - - -
- tu -
- {shangxinliArr.map(({ avatar, name, award }, index) => { - let src = `../../../../assets/images/shangxinli/${avatar}`; - return ( -
- 头像 -
{name}
-
{award}
-
- ); - })} -
-
- - - ); -} -function mapStateToProps(state) { - const { auth, global, articlesfrom } = state; - return { - user: auth.user, - actions: global.actions, - articlesfrom: articlesfrom, - }; -} -export default connect(mapStateToProps)(ActivityColumns); -const shangxinliArr = [ - { - name: "邹全锦", - avatar: "zouquanjin.png", - award: "爱岗敬业", - }, - { - name: "欧阳华强", - avatar: "ouyanghuaqiang.png", - award: "爱岗敬业", - }, - { - name: "田汉鑫", - avatar: "tianhanxin.png", - award: "爱岗敬业", - }, - { - name: "张俊", - avatar: "zhangjun.png", - award: "爱岗敬业", - }, - { - name: "付兵兵", - avatar: "fubingbing.png", - award: "爱岗敬业", - }, - { - name: "吴承云", - avatar: "wuchengyun.png", - award: "最佳执行", - }, - { - name: "周宏晟", - avatar: "zhouhongsheng.png", - award: "最佳执行", - }, - { - name: "杨威", - avatar: "yangwei.png", - award: "最佳执行", - }, - { - name: "丁锦", - avatar: "dingjin.png", - award: "最佳执行", - }, - { - name: "刘琦", - avatar: "liuqi.png", - award: "最佳执行", - }, - { - name: "张文君", - avatar: "zhangwenjun.png", - award: "创新卓越", - }, - { - name: "陈涛", - avatar: "chentao.png", - award: "创新卓越", - }, - { - name: "张文", - avatar: "zhangwen.png", - award: "最佳新人", - }, - { - name: "胡文惠", - avatar: "huwenhui.png", - award: "最佳新人", - }, - { - name: "张子扬", - avatar: "zhangziyang.png", - award: "最佳新人", - }, - { - name: "喻从文", - avatar: "yucongwen.png", - award: "最佳新人", - }, - { - name: "朱琼", - avatar: "zhuqiong.png", - award: "最佳新人", - }, - { - name: "黄钰薇", - avatar: "huangyuwei.png", - award: "宣传大使", - }, -]; diff --git a/web/client/src/sections/homePage/components/partyColumns.js b/web/client/src/sections/homePage/components/partyColumns.js deleted file mode 100644 index 0778aa8..0000000 --- a/web/client/src/sections/homePage/components/partyColumns.js +++ /dev/null @@ -1,148 +0,0 @@ -import React, { useState, useEffect } from "react"; -import { connect } from "react-redux"; -import { Table } from "antd"; -import { push } from "react-router-redux"; -import moment from "moment"; -import { getDataList } from "../actions/profile"; -let BARBG = "../../../../assets/images/barbg.png"; - -function PartyColumns(props) { - const { dispatch } = props; - const [partyinformation, setPartyInformation] = useState([]); //党建资讯 - const more = (id) => { - dispatch(push("/more", { type: 1, status: 1 })); - }; - useEffect(() => { - dispatch(getDataList({ type: 1, status: 1 })).then((res) => { - res.payload ? setPartyInformation(res.payload.data.data) : ""; - }); - }, []); - const renderInfoBar = (title) => { - return ( -
-
- {title} -
-
{ - more("123"); - }} - > - {"更多 >>"} -
-
- ); - }; - const activityColumns = [ - { - title: "Name", - dataIndex: "name", - key: "name", - sorter: (a, b) => { - const atime = a.publishTime - .slice(0, 10) - .replace("-", "") - .replace("-", ""); - - const btime = b.publishTime - .slice(0, 10) - .replace("-", "") - .replace("-", ""); - return atime - btime; - }, - defaultSortOrder: "bscend", - render: (text, record) => ( -
{ - dispatch( - push("/particulars", { id: record.id, title: record.title }) - ); - }} - > - - - {record?.title || ""} - - - [{record?.createTime.slice(0, 10) || ""}] - -
- ), - }, - ]; - return ( -
-
- {renderInfoBar("党建资讯")} -
-
- - - - ); -} -function mapStateToProps(state) { - const { auth, global, articlesfrom } = state; - return { - user: auth.user, - actions: global.actions, - articlesfrom: articlesfrom, - }; -} -export default connect(mapStateToProps)(PartyColumns); diff --git a/web/client/src/sections/homePage/components/unionColumns.js b/web/client/src/sections/homePage/components/unionColumns.js deleted file mode 100644 index 0832704..0000000 --- a/web/client/src/sections/homePage/components/unionColumns.js +++ /dev/null @@ -1,148 +0,0 @@ -import React, { useState, useEffect } from "react"; -import { connect } from "react-redux"; -import { Table } from "antd"; -import { push } from "react-router-redux"; -import moment from "moment"; -import { getDataList } from "../actions/profile"; -let BARBG = "../../../../assets/images/barbg.png"; - -function UnionColumns(props) { - const { dispatch } = props; - const [unioninformation, setUnionInformation] = useState(); //工会资讯 - const more = (id) => { - dispatch(push("/more", { type: 2, status: 1 })); - }; - useEffect(() => { - dispatch(getDataList({ type: 2, status: 1 })).then((res) => { - res.payload ? setUnionInformation(res.payload.data.data) : ""; - }); - }, []); - const renderInfoBar = (title) => { - return ( -
-
- {title} -
-
{ - more(); - }} - > - {"更多 >>"} -
-
- ); - }; - const activityColumns = [ - { - title: "Name", - dataIndex: "name", - key: "name", - sorter: (a, b) => { - const atime = a.publishTime - .slice(0, 10) - .replace("-", "") - .replace("-", ""); - - const btime = b.publishTime - .slice(0, 10) - .replace("-", "") - .replace("-", ""); - return atime - btime; - }, - defaultSortOrder: "bscend", - render: (text, record) => ( -
{ - dispatch( - push("/particulars", { id: record.id, title: record.title }) - ); - }} - > - - - {record?.title || ""} - - - [{record?.createTime.slice(0, 10) || ""}] - -
- ), - }, - ]; - return ( -
-
- {renderInfoBar("工会资讯")} -
-
- - - - ); -} -function mapStateToProps(state) { - const { auth, global, articlesfrom } = state; - return { - user: auth.user, - actions: global.actions, - articlesfrom: articlesfrom, - }; -} -export default connect(mapStateToProps)(UnionColumns); diff --git a/web/client/src/sections/homePage/containers/index.js b/web/client/src/sections/homePage/containers/index.js index 85c2e19..a112d7d 100644 --- a/web/client/src/sections/homePage/containers/index.js +++ b/web/client/src/sections/homePage/containers/index.js @@ -1,274 +1,186 @@ /* eslint-disable react-hooks/exhaustive-deps */ import React, { useState, useEffect } from "react"; import { connect } from "react-redux"; -import { Spin, Tabs } from "antd"; +import { Spin, Tabs, Table } from "antd"; import { LayoutContent } from "@peace/components"; import classnames from "classnames/bind"; import styles from "./index.less"; import { push } from "react-router-redux"; import moment from "moment"; -import ActivityColumns from "../components/activityColumns"; -import PartyColumns from "../components/partyColumns"; -import UnionColumns from "../components/unionColumns"; import { getPartyMember } from "../actions/profile"; -const ROOTLESSNAME = "ly-alarm-configure-container-indexjs"; +// const ROOTLESSNAME = "ly-alarm-configure-container-indexjs"; const CX = classnames.bind(styles); -const { TabPane } = Tabs; -function cx_(name) { - return CX(`${ROOTLESSNAME}${name}`); -} -const _style = { - chaxun: cx_(`__btn-chaxun`), - chaxunWraper: cx_(`__chaxunWraper`), -}; +// function cx_(name) { +// return CX(`${ROOTLESSNAME}${name}`); +// } -let BG = "/assets/images/pagebg.png"; -let DYREANSHUBG = "/assets/images/renshu_bg.png"; -let GONGHUIBG = "/assets/images/gonghui_bg.png"; -let zhuyaochengyuan_bg = "/assets/images/zhuyaochengyuan_bg.png"; +const topImg = "/assets/images/top.png"; +const pointImg = "/assets/images/point.png"; -let avatar1 = "../../../../assets/images/avatar_1.png"; -let yaojianjun = "../../../../assets/images/avatar/yaojianjun.png"; +function Management(props) { + const { dispatch, user } = props; -let xinwen = "../../../../assets/images/xinweng.png"; -let shangxinli = "../../../../assets/images/shangxinli_title.png"; + const [dataSource, setDataSource] = useState([]) -let BARBG = "../../../../assets/images/barbg.png"; -// export const transformSacle = `scale(${Math.min( -// document.body.clientWidth / 1920, -// document.body.clientHeight / 1080 -// )})`; -const _huoJiang = Array(20) - .fill(0) - .map((t, i) => { - return { - name: "卞学前", - award: "最佳执行者", - avatar: avatar1, - }; - }); -const _zhuyaochengyuan1 = [ - { - avatar: "../../../../assets/images/avatar/liuwei.png", - name: "刘玮", - }, - { - avatar: "../../../../assets/images/avatar/jiangzheng.png", - name: "姜珍", - }, -]; -const organization = [ - { - avatar: "../../../../assets/images/avatar/yanwenzhi.png" /* avatar: - "../../../../assets/images/avatar/wenzhe.png", */, - }, - { - avatar: "../../../../assets/images/avatar/liuwei2.png", - }, - { - avatar: "../../../../assets/images/avatar/liwenguo.png", - }, - { - avatar: "../../../../assets/images/avatar/yaowenting2.png", - }, -]; -const organization2 = [ - { - avatar: "../../../../assets/images/avatar/mmexport.png", - }, - { - avatar: "../../../../assets/images/avatar/zhangjing.png", - }, - { - avatar: "../../../../assets/images/avatar/wulongbiao.png", - }, -]; -const _zhuyaochengyuan2 = [ - { - avatar: "../../../../assets/images/avatar/yaowenting.png", - }, - { - avatar: "../../../../assets/images/avatar/wulongbiao.png", - }, - { - avatar: "../../../../assets/images/avatar/zhangbo.png", - }, - { - avatar: "../../../../assets/images/avatar/guofei.png", - }, -]; + const currentCol = [ + { + title: '项目名称', + dataIndex: 'name', + key: 'name', + align: 'center' + }, + { + title: '投入人力', + dataIndex: 'worker', + key: 'worker', + align: 'center' + }, + { + title: '构建时间', + dataIndex: 'buildTime', + key: 'buildTime', + align: 'center' + }, + { + title: '发布时间', + dataIndex: 'releaseTime', + key: 'releaseTime', + align: 'center' + }, + { + title: '进度', + dataIndex: 'progress', + key: 'progress', + align: 'center' + }, + ]; + + const peopleCol = [ + { + title: '姓名', + dataIndex: 'name', + key: 'name', + align: 'center' + }, + { + title: '部门', + dataIndex: 'dept', + key: 'dept', + align: 'center' + }, + { + title: '11.28', + dataIndex: 'monday', + key: 'monday', + align: 'center', + onCell: (record, index) => { + console.log("record, index: ", record, index); + return { + className: "cell-class", + colSpan: 2 + }; + } + }, + { + title: '11.29', + dataIndex: 'tuesday', + key: 'tuesday', + align: 'center' + }, + { + title: '11.30', + dataIndex: 'wednesday', + key: 'wednesday', + align: 'center' + }, + { + title: '12.1', + dataIndex: 'thursday', + key: 'thursday', + align: 'center' + }, + { + title: '12.2', + dataIndex: 'friday', + key: 'friday', + align: 'center' + }, + ]; + + const waitCol = [ + { + title: '项目', + dataIndex: 'name', + key: 'name', + align: 'center' + }, + { + title: '需求来源', + dataIndex: 'source', + key: 'source', + align: 'center' + }, + { + title: '对接人', + dataIndex: 'head', + key: 'head', + align: 'center' + }, + { + title: '处理进度', + dataIndex: 'progress', + key: 'progress', + align: 'center' + }, + ]; -function Management(props) { - const { dispatch, party, user, loding } = props; useEffect(() => { - dispatch(getPartyMember()).then((res) => {}); + // dispatch(getPartyMember()).then((res) => { }); + let nextData = [] + for (let i = 1; i <= 34; i++) { + nextData.push({ + key: i, + name: i, + age: 32, + address: '西湖区湖底公园1号', + }) + } + setDataSource(nextData) }, []); - const renderCell = ({ title, src, time }, index) => { - return ( -
-
-
{ - dispatch(push("/particulars", title)); - }} - > - {title} -
-
{moment(time).format("YYYY-MM-DD")}
-
- ); - }; - const renderRenshu = (title, number) => { - let bg = /党员/.test(title) ? DYREANSHUBG : GONGHUIBG; - return ( - -
-
- - {title}: - - - {number} - + return ( + <> +
+ +
+
+ +
本周在研项目
+
/Research project this week
+ +
+ - - - ); - }; - const renderBarTitle = (title) => { - return ( -
- {title} -
-
- ); - }; - const renderJieGouPeople = ({ name, work, desc, avatar }) => { - return ( -
- 头像 -
-
-
- {name} -
-
- {work} -
+
+ +
人员情况
+
/Information on Personnel
+
-
- {desc} +
+ +
待研发项目
+
/Project to be developed
+
- ); - }; - return ( - + - 后台维护 + 进入后台 - -
-
-
- {renderRenshu( - "党员人数", - party.data ? party.data.partyNumber : null - )} - {renderRenshu( - "工会人数", - party.data ? party.data.laborUnion : null - )} -
- -
-
{renderBarTitle("党支部结构")}
-
- {renderJieGouPeople({ - avatar: avatar1, - name: "党伟", - work: "党支部书记、工会主席", - desc: "主持党支部的全面工作。负责召集党支部委员会议和党员大会,认真贯彻执行党的路线、方针、政策、宣传和执行党的决议组织和带领全体党员及干部努力完成党组织各项任务。带头抓好党组织建设,不断增强党组织的凝聚力、战斗力,充分发挥党组织的集体领导作用,充分发挥党员在各项工作中先锋模范作用。", - })} - {renderJieGouPeople({ - avatar: yaojianjun, - name: "姚建军", - work: "南昌小蓝经济技术开发区管委会四级调研员、财政局局长、飞尚科技党建指导员", - desc: "党建指导员是区党工委派往非公有制经济组织基层党组织,开展党的建设工作的党员。其主要职责任务是宣传党的政策、发展党员、组建党的基层组织,推动党的路线方针政策在基层的落实,加强党组织同群众的联系,把基层党组织建设成为区域领导核心或政治核心。", - })} -
-
- -
- - - 党组织主要成员 - - } - key="1" - > -
-
- 照片 -
-
-
- {organization.map((d, index) => { - return ( -
- 头像 -
- ); - })} -
-
- {organization2.map((d, index) => { - return ( -
- 头像 -
- ); - })} -
-
-
-
- - 工会主要成员 - - } - key="2" - > -
-
- 照片 -
-
-
- {_zhuyaochengyuan1.map((d, index) => { - return ( -
- 头像 -
- ); - })} -
-
- {_zhuyaochengyuan2.map((d, index) => { - return ( -
- 头像 -
- ); - })} -
-
-
-
-
-
-
-
- -
- - -
-
-
-
+ ); } function mapStateToProps(state) { - const { auth, global, tunnels, party, articlesfrom } = state; + const { auth, global, party, articlesfrom } = state; return { loding: party.isRequesting, user: auth.user, diff --git a/web/client/src/sections/homePage/containers/index.less b/web/client/src/sections/homePage/containers/index.less index adc3dc4..63a315b 100644 --- a/web/client/src/sections/homePage/containers/index.less +++ b/web/client/src/sections/homePage/containers/index.less @@ -7,49 +7,56 @@ .fsdj-scroll-boxer { -ms-overflow-style: none; /* IE and Edge */ - scrollbar-width : none; + scrollbar-width: none; /* Firefox */ } -.laborunion{ - .ant-tabs-ink-bar{ +.laborunion { + .ant-tabs-ink-bar { height: 1px !important; background-color: #ba0000 !important; } } -.ant-tabs-top > .ant-tabs-nav::before, .ant-tabs-bottom > .ant-tabs-nav::before, .ant-tabs-top > div > .ant-tabs-nav::before, .ant-tabs-bottom > div > .ant-tabs-nav::before{ +.ant-tabs-top>.ant-tabs-nav::before, +.ant-tabs-bottom>.ant-tabs-nav::before, +.ant-tabs-top>div>.ant-tabs-nav::before, +.ant-tabs-bottom>div>.ant-tabs-nav::before { border-color: #eab2b2 !important; } -.complete{ + +.complete { background: "url(../../../../assets/images/pagebg.png)"; - .danghui:hover{ - cursor:not-allowed; + + .danghui:hover { + cursor: not-allowed; } - .tupian{ - .image-wrap{ - img{ - overflow: auto !important; + + .tupian { + .image-wrap { + img { + overflow: auto !important; } } - + } } + @media screen and (max-height:1440px) { .loginBox { - top: 25%; + top: 25%; } } @media screen and (max-height: 768px) { .loginBox { - top: 20%; + top: 20%; } } @media screen and (max-height: 630px) { .loginBox { - top: 10%; + top: 10%; } } @@ -60,38 +67,98 @@ right: 6.5%; z-index: 20; background-color: #fff5e1; - .login-form-button{ + + .login-form-button { width: 100%; width: 80%; height: 40px; left: 10%; background-color: #af251b; } - .user{ + + .user { width: 80%; height: 40px; left: 10%; background-color: #ffebe9 !important; } - .pass{ + + .pass { width: 80%; height: 40px; left: 10%; background-color: #ffebe9 !important; } - .loginfont{ + + .loginfont { margin-top: 10%; - margin-left: 10%; + margin-left: 10%; font-size: 31px; color: #af251b; } - #normal_login_username{ + + #normal_login_username { background-color: #ffebe9 !important; } - #normal_login_password{ + + #normal_login_password { background-color: #ffebe9 !important; } } -#article-container{ + +#article-container { height: 90% !important; } + +.index { + text-align: center; + + &-img { + width: 100%; + } + + &-main { + display: flex; + justify-content: space-evenly; + + &-box { + width: 32%; + min-height: 200px; + max-height: 800px; + overflow-y: auto; + box-shadow: 0px 0px 5px 0px rgba(0, 0, 0, 0.5); + text-align: left; + padding: 5px; + + &-point { + width: 14px; + height: 14px; + margin: 0 10px 7px 10px; + } + + &-title { + display: inline; + font-family: PangMenZhengDao; + font-size: 20px; + color: #20196C; + letter-spacing: 3.33px; + } + + &-en { + display: inline; + color: rgba(110, 120, 199, 1); + font-size: 12px; + font-face: DIN; + font-weight: 500; + line-height: 0; + letter-spacing: 0; + paragraph-spacing: 0; + text-align: left; + } + } + } +} + +.cell-class { + background-color: skyblue; +} \ No newline at end of file