Soleilw pirms 1 mēnesi
vecāks
revīzija
dc29dd447a

+ 1
- 1
dist/index.html Parādīt failu

@@ -8,6 +8,6 @@
</head>
<body>
<div id="root"></div>
<script src="/umi.fcb755e3.js"></script>
<script src="/umi.47646223.js"></script>
</body>
</html>

+ 1
- 0
dist/p__Company__Department__index.b8009e04.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 0
- 1
dist/p__Company__Department__index.f4d01f9d.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 0
- 1
dist/p__Company__List__index.06cf4537.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 1
- 0
dist/p__Company__List__index.d0ea64b9.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 1
- 0
dist/p__Company__Post__index.739791d0.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 0
- 1
dist/p__Company__Post__index.e0d9c44c.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 0
- 1
dist/p__Company__Vip__index.36cb2475.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 1
- 0
dist/p__Company__Vip__index.bc5ab70f.async.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


dist/umi.47646223.js
Failā izmaiņas netiks attēlotas, jo tās ir par lielu
Parādīt failu


+ 10
- 1
src/components/Render/Main/Company/Department/table/index.tsx Parādīt failu

@@ -21,10 +21,19 @@ const PagesMainCompanyDepartmentTable: React.FC = ({ dispatch, getId, openModel

useEffect(() => {
if (!openModel.openModal) {
actionRef.current.reload();
actionRef.current?.reload();
}

return () => {
sessionStorage.removeItem('company_info')
sessionStorage.removeItem('post_company_info')
sessionStorage.removeItem('vip_company_info')

};
}, [openModel.openModal])



return (
<>
<ConfigProvider

+ 15
- 9
src/components/Render/Main/Company/List/table/index.tsx Parādīt failu

@@ -1,3 +1,4 @@

import { useRef, useState, useEffect } from 'react';
import { connect, history, Link } from '@umijs/max';
import type { ActionType, ProFormInstance } from '@ant-design/pro-components';
@@ -338,8 +339,12 @@ const PagesMainCompanyListTable: React.FC = ({ dispatch, openModel, getId }: any
})
})
}}>企业职位</Button>,
<Link to={`/company/vip?full_name=${record.full_name}`}>会员信息</Link>,
<Button key='4' type='link' onClick={() => {
sessionStorage.setItem('vip_company_info', JSON.stringify(record))
history.push({
pathname: '/company/vip'
})
}}>会员信息</Button>,
<Button key='5' type='link' onClick={() => {
setId(record.id)
dispatch({ type: 'openModel/getOpenBindModal', payload: true })
@@ -398,26 +403,27 @@ const PagesMainCompanyListTable: React.FC = ({ dispatch, openModel, getId }: any
<Radio value={1}>开通账号</Radio>
</Col>
<Col span={12}>
<Radio value={1}>禁用1天</Radio>
<Radio value={2}>关闭账号</Radio>
</Col>
<Col span={12}>
<Radio value={1}>禁用3天</Radio>
<Radio value={3}>禁用1天</Radio>
</Col>
<Col span={12}>
<Radio value={1}>禁用7天</Radio>
<Radio value={4}>禁用3天</Radio>
</Col>
<Col span={12}>
<Radio value={1}>禁用15天</Radio>
<Radio value={5}>禁用7天</Radio>
</Col>
<Col span={12}>
<Radio value={1}>禁用30天</Radio>
<Radio value={6}>禁用15天</Radio>
</Col>
<Col span={12}>
<Radio value={1}>永久禁用</Radio>
<Radio value={7}>禁用30天</Radio>
</Col>
<Col span={12}>
<Radio value={2}>关闭账号</Radio>
<Radio value={8}>永久禁用</Radio>
</Col>

</Row>
</Radio.Group>
</>),

+ 7
- 0
src/components/Render/Main/Company/Post/table/index.tsx Parādīt failu

@@ -24,6 +24,13 @@ const PagesMainCompanyPostTable: React.FC = ({ dispatch, getId, openModel }: any
if (!openModel.openModal) {
actionRef.current?.reload();
}

return () => {
sessionStorage.removeItem('company_info')
sessionStorage.removeItem('post_company_info')
sessionStorage.removeItem('vip_company_info')

};
}, [openModel.openModal])



+ 27
- 28
src/components/Render/Main/Company/Vip/table/index.tsx Parādīt failu

@@ -1,5 +1,5 @@
import { useRef, useState, useEffect } from 'react';
import { useSearchParams, connect } from '@umijs/max';
import { connect } from '@umijs/max';
import type { ActionType, ProFormInstance } from '@ant-design/pro-components';
import {
ProTable
@@ -13,12 +13,11 @@ import { Imageprefix } from '@/constants';

const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
const actionRef = useRef<ActionType>();
const [searchParams, setSearchParams] = useSearchParams();
const [list, setList] = useState<object[]>([])
const [total, setTotal] = useState<number>(0)
const [page, setPage] = useState<number>(1)
const [pageSize, setPageSize] = useState<number>(10)
const [fullname, setFullname] = useState<any>(sessionStorage.getItem('vip_company_info') ? JSON.parse(sessionStorage.getItem('vip_company_info')).full_name : '')

const setId = (id: number) => {
getId(id)
@@ -29,6 +28,13 @@ const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
actionRef.current?.reload();

}

return () => {
sessionStorage.removeItem('company_info')
sessionStorage.removeItem('post_company_info')
sessionStorage.removeItem('vip_company_info')

};
}, [openModel.openModal])

useEffect(() => {
@@ -70,7 +76,7 @@ const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
actionRef={actionRef}
dataSource={list}
search={{
span: 8, labelWidth: 'auto',
span: 8, labelWidth: 'auto'
}}
rowSelection={{
type: 'checkbox'
@@ -84,14 +90,6 @@ const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
dataIndex: 'date_range',
hidden: true,
valueType: 'dateRange',
search: {
transform: (value) => {
return {
start_date: value[0],
end_date: value[1],
};
},
},
},
{
title: 'ID',
@@ -102,17 +100,14 @@ const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
title: '企业名称',
dataIndex: 'full_name',
width: 200,
renderFormItem: (_, { type, defaultRender }) => {
valueType: 'input',
renderFormItem: () => {
return (
<Input
placeholder="请输入企业名称"
defaultValue={searchParams.get('full_name')}
onChange={(e) => {
console.log(e.target.value);
}}
/>
<><Input placeholder="请输入企业名称" value={fullname} onChange={(e) => {
setFullname(e.target.value)
}} /></>
)
},
}
},
{
title: '会员类型',
@@ -202,16 +197,21 @@ const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
pagesize: pageSize,
sort: 'id',
sortby: 'desc',
keyword: searchParams.get('full_name') ? searchParams.get('full_name') : params.full_name,
id: params.id,
start_date: params.start_date,
end_date: params.end_date,
keyword: fullname,
start_date: params.date_range ? params.date_range[0] : '',
end_date: params.date_range ? params.date_range[1] : '',
}).then(res => {
setList(res.data.list)
setTotal(res.data.total)
})
}

onReset={() => {
if (sessionStorage.getItem('vip_company_info')) {
sessionStorage.removeItem('vip_company_info')
}
setFullname('')
actionRef.current?.reload();
}}
headerTitle="VIP企业列表"
toolBarRender={() => [
<Button type="primary" onClick={() => {
@@ -293,5 +293,4 @@ const CompanyListPage: React.FC = ({ dispatch, getId, openModel }: any) => {
export default connect(({ dictModel, openModel }: any) => ({
dictModel,
openModel
}))(CompanyListPage);

}))(CompanyListPage);

Notiek ielāde…
Atcelt
Saglabāt