This commit is contained in:
ylj20011123 2025-07-17 19:51:49 +08:00
parent 010680be5a
commit 8540a9d612
36 changed files with 2235 additions and 871 deletions

View File

@ -1,4 +1,4 @@
// 卡券适用规则 // 卡券适用规则 卡券规则设置
import { connect } from "umi"; import { connect } from "umi";
import type { CurrentUser } from "umi"; import type { CurrentUser } from "umi";
import type { ConnectState } from "@/models/connect"; import type { ConnectState } from "@/models/connect";
@ -19,6 +19,7 @@ import moment from 'moment'
import ProForm, { ProFormSelect, ProFormText } from "@ant-design/pro-form"; import ProForm, { ProFormSelect, ProFormText } from "@ant-design/pro-form";
import './index.less' import './index.less'
import { handleSetlogSave } from "@/utils/format"; import { handleSetlogSave } from "@/utils/format";
import ModalFooter from "@/pages/travelMember/scenicSpotConfig/component/modalFooter";
const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) => { const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) => {
@ -65,6 +66,12 @@ const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) =>
align: 'center', align: 'center',
hideInSearch: true, hideInSearch: true,
ellipsis: true, ellipsis: true,
render: (_, record) => {
return record?.COOPSHOP_RULE_NAME ? <a onClick={() => {
setShowDetail(true)
setCurrentRow(record)
}}>{record?.COOPSHOP_RULE_NAME}</a> : "-"
}
}, },
{ {
title: "关联门店", title: "关联门店",
@ -118,28 +125,28 @@ const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) =>
return record?.CREATE_DATE ? moment(record?.CREATE_DATE).format('YYYY-MM-DD') : "-" return record?.CREATE_DATE ? moment(record?.CREATE_DATE).format('YYYY-MM-DD') : "-"
} }
}, },
{ // {
title: "操作", // title: "操作",
dataIndex: "option", // dataIndex: "option",
width: 120, // width: 120,
fixed: 'right', // fixed: 'right',
align: 'center', // align: 'center',
hideInSearch: true, // hideInSearch: true,
ellipsis: true, // ellipsis: true,
render: (_, record) => { // render: (_, record) => {
return <Space> // return <Space>
<a onClick={() => { // <a onClick={() => {
setShowDetail(true) // setShowDetail(true)
setCurrentRow(record) // setCurrentRow(record)
}}></a> // }}>编辑</a>
<Popconfirm title={"确认删除该规则?"} onConfirm={async () => { // <Popconfirm title={"确认删除该规则?"} onConfirm={async () => {
await handleDeleteShopRule(record?.COOPSHOP_RULE_ID) // await handleDeleteShopRule(record?.COOPSHOP_RULE_ID)
}}> // }}>
<a></a> // <a>删除</a>
</Popconfirm> // </Popconfirm>
</Space> // </Space>
} // }
} // }
] ]
// 同步规则记录 // 同步规则记录
@ -192,10 +199,13 @@ const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) =>
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
message.success(data.Result_Desc) message.success(data.Result_Desc)
actionRef.current?.reload() actionRef.current?.reload()
ModalFormRef?.current?.resetFields()
setCurrentRow(undefined)
setShowDetail(false)
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
} }
handleSetlogSave('卡券规则的删除') // handleSetlogSave('卡券规则的删除')
} }
return ( return (
@ -278,7 +288,12 @@ const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) =>
}} }}
destroyOnClose destroyOnClose
confirmLoading={modalLoading} confirmLoading={modalLoading}
width={'70%'} // width={'70%'}
width={900}
bodyStyle={{
height: '700px', // 你可以根据需要调整高度
overflowY: 'auto',
}}
title={currentRow?.COOPSHOP_RULE_ID ? currentRow?.COOPSHOP_RULE_NAME : "新增规则"} title={currentRow?.COOPSHOP_RULE_ID ? currentRow?.COOPSHOP_RULE_NAME : "新增规则"}
onOk={() => { onOk={() => {
ModalFormRef?.current?.validateFields().then(async (res) => { ModalFormRef?.current?.validateFields().then(async (res) => {
@ -286,6 +301,24 @@ const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) =>
await handleSynchroCOOPSHOPRULE(res) await handleSynchroCOOPSHOPRULE(res)
}) })
}} }}
footer={<ModalFooter
hideDelete={!currentRow?.COOPSHOP_RULE_ID}
handleDelete={async () => {
await handleDeleteShopRule(currentRow?.COOPSHOP_RULE_ID)
}}
handleCancel={() => {
ModalFormRef?.current?.resetFields()
setCurrentRow(undefined)
setShowDetail(false)
}}
handleOK={() => {
ModalFormRef?.current?.validateFields().then(async (res) => {
console.log('res', res)
await handleSynchroCOOPSHOPRULE(res)
})
}}
/>}
> >
<ProForm formRef={ModalFormRef} layout={'horizontal'} submitter={false} initialValues={{ <ProForm formRef={ModalFormRef} layout={'horizontal'} submitter={false} initialValues={{
@ -295,7 +328,9 @@ const CardCouponApplicRules: React.FC<{ currentUser: CurrentUser }> = (props) =>
UPDATE_DATE: moment().format('YYYY-MM-DD HH:mm:ss'), UPDATE_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
OPERATINGUNIT_NAME: currentUser?.OwnerUnitId, OPERATINGUNIT_NAME: currentUser?.OwnerUnitId,
ISOFFLINE: currentRow?.ISOFFLINE || 0 ISOFFLINE: currentRow?.ISOFFLINE || 0
}}> }}
labelCol={{ style: { width: 80 } }}
>
<Divider orientation="left"></Divider> <Divider orientation="left"></Divider>
<Row gutter={8}> <Row gutter={8}>
<Col span={12}> <Col span={12}>

View File

@ -14,13 +14,14 @@ import ProTable from "@ant-design/pro-table";
import ReactHTMLTableToExcel from "react-html-table-to-excel"; import ReactHTMLTableToExcel from "react-html-table-to-excel";
import LeftSelectTree from "@/pages/reports/settlementAccount/component/leftSelectTree"; import LeftSelectTree from "@/pages/reports/settlementAccount/component/leftSelectTree";
import PageTitleBox from "@/components/PageTitleBox"; import PageTitleBox from "@/components/PageTitleBox";
import { handleGetCOOPSHOP_RULEList, handleGetCOUPONList, handleSynchroCOUPONService } from "../service"; import { handleDeleteCOUPON, handleGetCOOPSHOP_RULEList, handleGetCOUPONList, handleSynchroCOUPONService } from "../service";
import ProForm, { ProFormDatePicker, ProFormSelect, ProFormText, ProFormTextArea, ProFormUploadButton } from "@ant-design/pro-form"; import ProForm, { ProFormDatePicker, ProFormSelect, ProFormText, ProFormTextArea, ProFormUploadButton } from "@ant-design/pro-form";
import session from "@/utils/session"; import session from "@/utils/session";
import './index.less' import './index.less'
import { handleSetlogSave } from "@/utils/format"; import { handleSetlogSave } from "@/utils/format";
import moment from 'moment' import moment from 'moment'
import { uploadPicture } from "@/services/picture"; import { uploadPicture } from "@/services/picture";
import ModalFooter from "@/pages/travelMember/scenicSpotConfig/component/modalFooter";
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png'; const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
@ -102,6 +103,17 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
align: 'left', align: 'left',
hideInSearch: true, hideInSearch: true,
ellipsis: true, ellipsis: true,
render: (_, record) => {
return record?.COUPON_NAME ? <a onClick={() => {
setShowDetail(true)
setCurrentRow(record)
if (record.COUPON_IMAGEURL) {
setFileList([
{ name: "-", url: record.COUPON_IMAGEURL }
])
}
}}>{record?.COUPON_NAME}</a> : "-"
}
}, },
{ {
title: "运营单位", title: "运营单位",
@ -138,39 +150,54 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
hideInSearch: true, hideInSearch: true,
ellipsis: true, ellipsis: true,
}, },
{ // {
title: "操作", // title: "操作",
dataIndex: "options", // dataIndex: "options",
width: 120, // width: 120,
align: 'center', // align: 'center',
hideInSearch: true, // hideInSearch: true,
render: (_, record) => { // render: (_, record) => {
return <Space> // return <Space>
<a onClick={() => { // <a onClick={() => {
console.log('record', record); // console.log('record', record);
setShowDetail(true) // setShowDetail(true)
setCurrentRow(record) // setCurrentRow(record)
if (record.COUPON_IMAGEURL) { // if (record.COUPON_IMAGEURL) {
setFileList([ // setFileList([
{ name: "-", url: record.COUPON_IMAGEURL } // { name: "-", url: record.COUPON_IMAGEURL }
]) // ])
} // }
}}> // }}>
// 编辑
</a> // </a>
<Popconfirm title={"确认删除该规则?"} onConfirm={async () => { // <Popconfirm title={"确认删除该规则?"} onConfirm={async () => {
await handleDeleteShopRule(record?.COOPSHOP_RULE_ID) // await handleDeleteShopRule(record?.COOPSHOP_RULE_ID)
}}> // }}>
<a></a> // <a>删除</a>
</Popconfirm> // </Popconfirm>
</Space> // </Space>
} // }
} // }
] ]
// 删除的方法 // 删除的方法
const handleDeleteShopRule = async (id: any) => { const handleDeleteShopRule = async (id: any) => {
const req: any = {
COUPONId: id
}
const data = await handleDeleteCOUPON(req)
if (data.Result_Code === 100) {
message.success(data.Result_Desc)
actionRef.current?.reload()
ModalFormRef?.current?.resetFields()
setCurrentRow(null)
setShowDetail(false)
setFileList([])
} else {
message.error(data.Result_Desc)
}
} }
@ -220,9 +247,6 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
handleSetlogSave(currentRow?.COOPSHOP_RULE_ID ? '卡券的编辑' : '卡券的新增') handleSetlogSave(currentRow?.COOPSHOP_RULE_ID ? '卡券的编辑' : '卡券的新增')
} }
return ( return (
<div ref={(el) => { <div ref={(el) => {
// 打印报表 // 打印报表
@ -254,7 +278,8 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
const req: any = { const req: any = {
SearchParameter: { SearchParameter: {
OWNERUNIT_ID: 911, OWNERUNIT_ID: 911,
COUPON_TYPES: params?.COUPON_TYPES || "" COUPON_TYPES: params?.COUPON_TYPES || "",
COUPON_ISVALID: 1
}, },
PageIndex: 1, PageIndex: 1,
PageSize: 999999 PageSize: 999999
@ -306,7 +331,11 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
setFileList([]) setFileList([])
}} }}
confirmLoading={modalLoading} confirmLoading={modalLoading}
width={'70%'} width={900}
bodyStyle={{
height: '700px', // 你可以根据需要调整高度
overflowY: 'auto',
}}
destroyOnClose destroyOnClose
title={currentRow?.COUPON_ID ? currentRow?.COUPON_NAME : "新增卡券"} title={currentRow?.COUPON_ID ? currentRow?.COUPON_NAME : "新增卡券"}
onOk={() => { onOk={() => {
@ -314,9 +343,27 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
await handleSynchroCOUPON(res) await handleSynchroCOUPON(res)
}) })
}} }}
footer={<ModalFooter
hideDelete={!currentRow?.COUPON_ID}
handleDelete={async () => {
await handleDeleteShopRule(currentRow?.COUPON_ID)
}}
handleCancel={() => {
ModalFormRef?.current?.resetFields()
setCurrentRow(null)
setShowDetail(false)
setFileList([])
}}
handleOK={() => {
ModalFormRef?.current?.validateFields().then(async (res) => {
await handleSynchroCOUPON(res)
})
}}
/>}
> >
<div className="CardInformationManagerModalContent" style={{}}> <div className="CardInformationManagerModalContent" style={{}}>
<ProForm formRef={ModalFormRef} layout={'horizontal'} submitter={false} initialValues={{ <ProForm formRef={ModalFormRef} layout={'horizontal'} submitter={false} labelCol={{ style: { width: 80 } }} initialValues={{
...currentRow, ...currentRow,
OWNERUNIT_ID: currentRow?.OWNERUNIT_ID || currentUser?.OwnerUnitId, OWNERUNIT_ID: currentRow?.OWNERUNIT_ID || currentUser?.OwnerUnitId,
COUPON_TYPE: currentRow?.COUPON_TYPE ? currentRow?.COUPON_TYPE : COUPONTYPEList && COUPONTYPEList.length > 0 ? COUPONTYPEList[0].value : "", COUPON_TYPE: currentRow?.COUPON_TYPE ? currentRow?.COUPON_TYPE : COUPONTYPEList && COUPONTYPEList.length > 0 ? COUPONTYPEList[0].value : "",

View File

@ -88,4 +88,17 @@ export async function handleSynchroCOUPONService(params: any) {
} }
return data return data
} }
// 删除卡券
export async function handleDeleteCOUPON(params: any) {
const data = await requestEncryption(`/Coupon/DeleteCOUPON`, {
method: 'POST',
data: {
...params,
requestEncryption: true
}
})
if (data.Result_Code !== 100) {
return []
}
return data
}

View File

@ -186,8 +186,9 @@ const saleRankReport: React.FC<{ currentUser: CurrentUser }> = (props) => {
"微信公众号": "微信公众号", "微信公众号": "微信公众号",
"驿商云客户端": "驿商云客户端", "驿商云客户端": "驿商云客户端",
"彩云驿出行": "彩云驿出行", "彩云驿出行": "彩云驿出行",
"出行平台": "出行平台",
}, },
initialValue: '驿商云平台' initialValue: currentUser?.ProvinceCode === "530000" ? '出行平台' : '驿商云平台'
}, },
{ {
title: '操作系统', title: '操作系统',

View File

@ -28,6 +28,7 @@ import { deletePicture, uploadPicture } from '@/services/picture';
import { handleGetServerPartShopNewList } from '@/pages/basicManage/serviceArea/service'; import { handleGetServerPartShopNewList } from '@/pages/basicManage/serviceArea/service';
import { handleGetServerpartShopList } from '@/pages/DataVerification/service'; import { handleGetServerpartShopList } from '@/pages/DataVerification/service';
import ModalFooter from '@/pages/travelMember/scenicSpotConfig/component/modalFooter'; import ModalFooter from '@/pages/travelMember/scenicSpotConfig/component/modalFooter';
import { handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png'; const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
@ -136,10 +137,18 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
placeholder: "请输入商户名称" placeholder: "请输入商户名称"
} }
}, },
{
dataIndex: 'SERVERPART_NAME',
title: '服务区名称',
align: 'center',
width: 200,
ellipsis: true,
hideInSearch: true,
},
{ {
dataIndex: 'SELLER_NAME', dataIndex: 'SELLER_NAME',
title: '商家名称', title: '商家名称',
width: 300, width: 200,
align: 'center', align: 'center',
hideInSearch: true, hideInSearch: true,
ellipsis: true, ellipsis: true,
@ -147,7 +156,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
return record?.SELLER_NAME ? <a onClick={() => { return record?.SELLER_NAME ? <a onClick={() => {
setCurrentRow({ ...record }); setCurrentRow({ ...record });
handleModalVisible(true); handleModalVisible(true);
}}>{`${record?.SERVERPART_NAME || ""}${record?.SELLER_NAME}`}</a> : "-" }}>{`${record?.SELLER_NAME}`}</a> : "-"
} }
}, },
{ {
@ -631,6 +640,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
await handleUploadAllImage(res, data) await handleUploadAllImage(res, data)
handleSetlogSave(`更新【${currentRow?.SELLER_NAME}】商家信息成功`)
message.success(data.Result_Desc) message.success(data.Result_Desc)
formRef?.current?.resetFields() formRef?.current?.resetFields()
handleConfirmLoading(false) handleConfirmLoading(false)
@ -644,6 +654,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.SELLER_NAME}】商家信息失败`)
} }
}; };
@ -930,6 +941,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
} }
console.log('reqreqreqreq', req); console.log('reqreqreqreq', req);
const data = await handleGetMEMBERADDRESSList(req); const data = await handleGetMEMBERADDRESSList(req);
handleSetlogSave(`点击查询按钮`)
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
@ -947,6 +959,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
onClick={() => { onClick={() => {
setShowAddModal(true) setShowAddModal(true)
// handleModalVisible(true); // handleModalVisible(true);
handleSetlogSave(`点击新增服务区商家信息`)
}} }}
> >
@ -1172,6 +1185,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
}}></Button> */} }}></Button> */}
<Button type={"primary"} loading={revenueLoading} onClick={() => { <Button type={"primary"} loading={revenueLoading} onClick={() => {
handleGetRevenueData() handleGetRevenueData()
handleSetlogSave(`点击获取营收按钮`)
}}></Button> }}></Button>
</div> </div>
: <div></div> : <div></div>
@ -1245,6 +1259,10 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
} }
setInteriorImageList(list3); setInteriorImageList(list3);
if (!currentRow?.SELLER_ID) {
handleGetRevenueData()
}
// if (currentRow?.SELLER_ID) { // if (currentRow?.SELLER_ID) {
// let req: any = { // let req: any = {
@ -1354,6 +1372,34 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
await handleAddUpdate(newValue); await handleAddUpdate(newValue);
}} }}
> >
<Tabs
onChange={(e: any) => {
setSelectTab(e)
if (currentRow?.SELLER_ID) {
if (e === '1') {
handleSetlogSave(`查询【${currentRow?.SELLER_NAME}】商家信息`)
} else if (e === '2') {
handleSetlogSave(`查询【${currentRow?.SELLER_NAME}】门店信息`)
} else if (e === '3') {
handleSetlogSave(`查询【${currentRow?.SELLER_NAME}】评论信息`)
} else if (e === '4') {
handleSetlogSave(`查询【${currentRow?.SELLER_NAME}】商家图片`)
}
}
}}
activeKey={selectTab}
type="card"
items={[
{ label: "商家信息", key: "1" },
{ label: "门店信息", key: "2" },
{ label: "评论信息", key: "3" },
{ label: "商家图片", key: "4" },
]}
/>
<div style={{ display: selectTab === '1' ? 'block' : 'none' }}>
<Row gutter={8}> <Row gutter={8}>
<Col span={8}> <Col span={8}>
<ProFormText <ProFormText
@ -1458,12 +1504,24 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
<ProFormText <ProFormText
name="SELLER_LINKMAN" name="SELLER_LINKMAN"
label="联系人员" label="联系人员"
rules={[
{
required: true,
message: '请输入联系人员'
}
]}
/> />
</Col> </Col>
<Col span={8}> <Col span={8}>
<ProFormText <ProFormText
name="SELLER_TELEPHONE" name="SELLER_TELEPHONE"
label="商家电话" label="商家电话"
rules={[
{
required: true,
message: '请输入商家电话'
}
]}
/> />
</Col> </Col>
<Col span={8}> <Col span={8}>
@ -1482,36 +1540,30 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
<ProFormTextArea <ProFormTextArea
name="SELLER_DESC" name="SELLER_DESC"
label="商家介绍" label="商家介绍"
/> rules={[
</Col> {
required: true,
message: '请输入商家介绍'
</Row> }
<Tabs
onChange={(e: any) => {
setSelectTab(e)
}}
activeKey={selectTab}
type="card"
items={[
{ label: "门店信息", key: "1" },
{ label: "评论信息", key: "2" },
]} ]}
/> />
</Col>
</Row>
</div>
<ProTable <ProTable
search={false} search={false}
options={false} options={false}
columns={shopColumns} columns={shopColumns}
bordered bordered
style={{ display: selectTab === '1' ? 'block' : 'none' }} style={{ display: selectTab === '2' ? 'block' : 'none' }}
dataSource={currentShopData} dataSource={currentShopData}
/> />
<div style={{ display: selectTab === '1' ? 'block' : 'none' }}> <div style={{ display: selectTab === '4' ? 'block' : 'none' }}>
<Row gutter={8}> <Row gutter={8}>
<Col span={8}> <Col span={8}>
<ProFormUploadButton <ProFormUploadButton
@ -1666,7 +1718,7 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
options={false} options={false}
bordered bordered
columns={commentColumns} columns={commentColumns}
style={{ display: selectTab === '2' ? 'block' : 'none' }} style={{ display: selectTab === '3' ? 'block' : 'none' }}
request={async () => { request={async () => {
if (!currentRow?.SELLER_ID) { if (!currentRow?.SELLER_ID) {
return { data: [], success: true } return { data: [], success: true }

View File

@ -26,6 +26,8 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow }: Detail
// const [currentRow, setCurrentRow] = useState<any>(); // const [currentRow, setCurrentRow] = useState<any>();
const [bounds, setBounds] = useState<{ left: number, right: number, top: number, bottom: number }>() // 移动的位置 const [bounds, setBounds] = useState<{ left: number, right: number, top: number, bottom: number }>() // 移动的位置
const [disabled, setDraggleDisabled] = useState<boolean>() // 是否拖动 const [disabled, setDraggleDisabled] = useState<boolean>() // 是否拖动
// 订单详情
const [orderDetail, setOrderDetail] = useState<any>()
const onDraggaleStart = (event, uiData) => { const onDraggaleStart = (event, uiData) => {
const { clientWidth, clientHeight } = window.document.documentElement; const { clientWidth, clientHeight } = window.document.documentElement;
@ -129,6 +131,16 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow }: Detail
layout={'horizontal'} layout={'horizontal'}
formRef={modalRef} formRef={modalRef}
submitter={false} submitter={false}
// request={async () => {
// console.log('currentRow', currentRow);
// if (currentRow) {
// return {
// ...currentRow
// }
// } else {
// return {}
// }
// }}
initialValues={currentRow ? { initialValues={currentRow ? {
...currentRow, ...currentRow,
ORDER_DATE: currentRow?.ORDER_DATE ? moment(currentRow?.ORDER_DATE).format('YYYY-MM-DD HH:mm:ss') : '' ORDER_DATE: currentRow?.ORDER_DATE ? moment(currentRow?.ORDER_DATE).format('YYYY-MM-DD HH:mm:ss') : ''
@ -302,6 +314,14 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow }: Detail
style={{ marginBottom: '16px' }} style={{ marginBottom: '16px' }}
/> />
</Col> </Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"ORDER_PERSON"}
label={"收货人"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
</Row> </Row>
</div> </div>
</ProForm> </ProForm>
@ -325,6 +345,7 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow }: Detail
console.log('dasdas', data); console.log('dasdas', data);
let obj: any = data.List && data.List.length > 0 ? data.List[0] : null let obj: any = data.List && data.List.length > 0 ? data.List[0] : null
SALEBILL_ID = obj.SALEBILL_ID SALEBILL_ID = obj.SALEBILL_ID
setOrderDetail(obj)
modalRef.current?.setFieldsValue({ modalRef.current?.setFieldsValue({
SALEBILL_CODE: obj.SALEBILL_CODE || "", SALEBILL_CODE: obj.SALEBILL_CODE || "",
@ -344,7 +365,6 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow }: Detail
PACK_TYPE: obj.PACK_TYPE || "", PACK_TYPE: obj.PACK_TYPE || "",
TAKE_NUMBER: obj.TAKE_NUMBER || "", TAKE_NUMBER: obj.TAKE_NUMBER || "",
}) })
} }
const req: any = { const req: any = {
@ -367,9 +387,9 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow }: Detail
<tr> <tr>
<td colSpan={2} style={{ textAlign: 'center', fontWeight: 'bold' }}></td> <td colSpan={2} style={{ textAlign: 'center', fontWeight: 'bold' }}></td>
<td /> <td />
<td style={{ textAlign: 'center', fontWeight: 'bold' }}>{currentRow?.TOTAL_COUNT || 0}</td> <td style={{ textAlign: 'center', fontWeight: 'bold' }}>{orderDetail?.TOTAL_COUNT || 0}</td>
<td /> <td />
<td style={{ textAlign: 'center', fontWeight: 'bold' }}>{currentRow?.ORDER_AMOUNT?.toFixed(2) || '0.00'}</td> <td style={{ textAlign: 'center', fontWeight: 'bold' }}>{orderDetail?.ORDER_AMOUNT?.toFixed(2) || '0.00'}</td>
</tr> </tr>
) )
}} }}

View File

@ -18,10 +18,11 @@ import { handleGetCONSUMPTIONRECORDList } from "../service";
import moment from 'moment' import moment from 'moment'
import session from "@/utils/session"; import session from "@/utils/session";
import OrderDetailModal from "../BookingMealOrder/components/orderDetailModal"; import OrderDetailModal from "../BookingMealOrder/components/orderDetailModal";
import { handleSetlogSave } from "@/utils/format";
const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props) => { const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: boolean, parentDetail?: any }> = (props) => {
const { currentUser } = props const { currentUser, isComponent, parentDetail } = props
const downloadBtnRef = useRef<any>() const downloadBtnRef = useRef<any>()
const actionRef = useRef<ActionType>(); const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>(); const formRef = useRef<FormInstance>();
@ -119,6 +120,14 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
}}>{record?.TICKET_CODE}</a> : "-" }}>{record?.TICKET_CODE}</a> : "-"
} }
}, },
{
title: "服务区名称",
width: 150,
dataIndex: "SERVERPART_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{ {
title: "门店名称", title: "门店名称",
width: 150, width: 150,
@ -207,8 +216,13 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
}} > }} >
<div style={{ backgroundColor: '#fff', display: 'flex' }}> <div style={{ backgroundColor: '#fff', display: 'flex' }}>
{
isComponent ? '' : <LeftSelectTree setSelectedId={setSelectedId} setCollapsible={setCollapsible} collapsible={collapsible} showYN={true} />
}
<div style={{ <div style={{
width: '100%', width: isComponent ? '100%' : !collapsible ? 'calc(100% - 300px)' : 'calc(100% - 60px)',
paddingTop: 0, paddingTop: 0,
paddingBottom: 0, paddingBottom: 0,
paddingRight: 0 paddingRight: 0
@ -222,11 +236,29 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
expandRowByClick: true expandRowByClick: true
}} }}
headerTitle={<PageTitleBox props={props} />} headerTitle={<PageTitleBox props={props} />}
scroll={{ x: '100%', y: 'calc(100vh - 450px)' }} scroll={{ x: '100%', y: isComponent ? '300px' : 'calc(100vh - 430px)' }}
search={{ span: 6 }} search={isComponent ? false : { span: 6 }}
request={async (params) => { request={async (params) => {
const req: any = { let req: any = {}
if (isComponent) {
req = {
SearchParameter: { SearchParameter: {
PROVINCE_CODE: currentUser?.ProvinceCode || "",
OWNERUNIT_ID: 911,
MEMBERSHIP_ID: parentDetail?.MEMBERSHIP_ID
},
PageIndex: params?.current,
PageSize: params?.pageSize,
sortStr: "CONSUMPTIONRECORD_DATE desc"
}
} else {
if (!selectedId) {
return
}
req = {
SearchParameter: {
SERVERPART_IDS: selectedId,
PROVINCE_CODE: currentUser?.ProvinceCode || "", PROVINCE_CODE: currentUser?.ProvinceCode || "",
OWNERUNIT_ID: 911, OWNERUNIT_ID: 911,
CONSUMPTIONRECORD_TYPE: params?.CONSUMPTIONRECORD_TYPE === '0' ? '' : params?.CONSUMPTIONRECORD_TYPE CONSUMPTIONRECORD_TYPE: params?.CONSUMPTIONRECORD_TYPE === '0' ? '' : params?.CONSUMPTIONRECORD_TYPE
@ -236,9 +268,13 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
keyWord: { keyWord: {
Key: "MEMBERSHIP_NAME,MEMBERSHIP_MOBILEPHONE", Key: "MEMBERSHIP_NAME,MEMBERSHIP_MOBILEPHONE",
Value: params?.searchText || "" Value: params?.searchText || ""
},
sortStr: "CONSUMPTIONRECORD_DATE desc"
} }
} }
const data = await handleGetCONSUMPTIONRECORDList(req) const data = await handleGetCONSUMPTIONRECORDList(req)
handleSetlogSave(`点击查询按钮`)
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -17,10 +17,11 @@ import PageTitleBox from "@/components/PageTitleBox";
import { handleGetMEMBERGROWTHList } from "../service"; import { handleGetMEMBERGROWTHList } from "../service";
import moment from 'moment' import moment from 'moment'
import session from "@/utils/session"; import session from "@/utils/session";
import { handleSetlogSave } from "@/utils/format";
const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props) => { const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boolean, parentDetail?: any }> = (props) => {
const { currentUser } = props const { currentUser, isComponent, parentDetail } = props
const downloadBtnRef = useRef<any>() const downloadBtnRef = useRef<any>()
const actionRef = useRef<ActionType>(); const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>(); const formRef = useRef<FormInstance>();
@ -75,6 +76,14 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
align: 'center', align: 'center',
ellipsis: true, ellipsis: true,
}, },
{
title: "会员昵称",
width: 150,
dataIndex: "MEMBERSHIP_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{ {
title: "累计成长值", title: "累计成长值",
width: 120, width: 120,
@ -132,12 +141,12 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
}, },
{ {
title: "操作时间", title: "操作时间",
width: 120, width: 180,
dataIndex: "OPERATE_DATE", dataIndex: "OPERATE_DATE",
align: 'center', align: 'center',
hideInSearch: true, hideInSearch: true,
render: (_, record) => { render: (_, record) => {
return record?.OPERATE_DATE ? moment(record?.OPERATE_DATE).format('YYYY-MM-DD') : "-" return record?.OPERATE_DATE ? moment(record?.OPERATE_DATE).format('YYYY-MM-DD HH:mm:ss') : "-"
} }
}, },
] ]
@ -169,9 +178,19 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
expandRowByClick: true expandRowByClick: true
}} }}
headerTitle={<PageTitleBox props={props} />} headerTitle={<PageTitleBox props={props} />}
search={{ span: 6 }} scroll={{ x: '100%', y: isComponent ? '300px' : 'calc(100vh - 430px)' }}
search={isComponent ? false : { span: 6 }}
request={async (params) => { request={async (params) => {
const req: any = { const req: any = isComponent ? {
searchParameter: {
OWNERUNIT_ID: 911,
SCORESETTING_STATE: 1,
MEMBERSHIP_ID: parentDetail?.MEMBERSHIP_ID,
},
PageIndex: params?.current,
PageSize: 20,
sortStr: "OPERATE_DATE desc"
} : {
searchParameter: { searchParameter: {
// PROVINCE_CODE: currentUser?.ProvinceCode || "", // PROVINCE_CODE: currentUser?.ProvinceCode || "",
OPERATE_DATE_Start: params?.OPERATE_DATE_Start || "", OPERATE_DATE_Start: params?.OPERATE_DATE_Start || "",
@ -182,9 +201,12 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props)
GROWTH_TYPE: params?.GROWTH_TYPE === "-2" ? '' : params?.GROWTH_TYPE GROWTH_TYPE: params?.GROWTH_TYPE === "-2" ? '' : params?.GROWTH_TYPE
}, },
PageIndex: params?.current, PageIndex: params?.current,
PageSize: 20 PageSize: 20,
sortStr: "OPERATE_DATE desc"
} }
const data = await handleGetMEMBERGROWTHList(req); const data = await handleGetMEMBERGROWTHList(req);
handleSetlogSave(`点击查询按钮`)
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -28,7 +28,7 @@ import classNames from 'classnames';
import session from '@/utils/session'; import session from '@/utils/session';
import ModalFooter from '../../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../../scenicSpotConfig/component/modalFooter';
import { handeDeleteFIELDENUM, handeGetFIELDEXPLAINList, handeGetNestingFIELDENUMList, handeSynchroFIELDENUM } from '../../service'; import { handeDeleteFIELDENUM, handeGetFIELDEXPLAINList, handeGetNestingFIELDENUMList, handeSynchroFIELDENUM } from '../../service';
import { convertTreeToLabelValue } from '@/utils/format'; import { convertTreeToLabelValue, handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -202,8 +202,10 @@ const GrowthConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
const result = await handeDeleteFIELDENUM(req) const result = await handeDeleteFIELDENUM(req)
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】成功`)
actionRef.current?.reload() actionRef.current?.reload()
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -231,6 +233,7 @@ const GrowthConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
message.success("新增成功!") message.success("新增成功!")
handleSetlogSave(`更新【${currentRow?.FIELDENUM_NAME}】成功`)
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
handleModalVisible(false) handleModalVisible(false)
@ -239,6 +242,7 @@ const GrowthConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.FIELDENUM_NAME}】失败`)
} }
} }
@ -270,6 +274,8 @@ const GrowthConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
const data = await handeGetNestingFIELDENUMList(req); const data = await handeGetNestingFIELDENUMList(req);
console.log('dasjkdas', data); console.log('dasjkdas', data);
handleSetlogSave(`查看了成长值枚举配置列表`)
if (data && data.length > 0) { if (data && data.length > 0) {
setTypeTreeData(data) setTypeTreeData(data)
if (data && data.length > 0) { if (data && data.length > 0) {

View File

@ -26,6 +26,7 @@ import session from '@/utils/session';
import PageTitleBox from '@/components/PageTitleBox'; import PageTitleBox from '@/components/PageTitleBox';
import ModalFooter from '../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../scenicSpotConfig/component/modalFooter';
import GrowthConfig from './components/growthConfig'; import GrowthConfig from './components/growthConfig';
import { handleSetlogSave } from '@/utils/format';
@ -93,6 +94,7 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
hideInDescriptions: true, hideInDescriptions: true,
render: (_, record) => { render: (_, record) => {
return record?.GROWTHSETTING_NAME ? <a onClick={() => { return record?.GROWTHSETTING_NAME ? <a onClick={() => {
handleSetlogSave(`查看了${record?.GROWTHSETTING_NAME}的规则详情`)
setCurrentRow({ ...record }); setCurrentRow({ ...record });
handleModalVisible(true); handleModalVisible(true);
}}>{record?.GROWTHSETTING_NAME}</a> : '-' }}>{record?.GROWTHSETTING_NAME}</a> : '-'
@ -227,8 +229,10 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
}); });
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除${currentRow?.GROWTHSETTING_NAME}失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除${currentRow?.GROWTHSETTING_NAME}成功`)
actionRef.current?.reload() actionRef.current?.reload()
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -256,12 +260,14 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
} }
const data = await handleSynchroGROWTHSETTING(req); const data = await handleSynchroGROWTHSETTING(req);
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
handleSetlogSave(`更新${currentRow?.GROWTHSETTING_NAME}成功`)
message.success(data.Result_Desc) message.success(data.Result_Desc)
formRef?.current?.resetFields() formRef?.current?.resetFields()
setCurrentRow(undefined) setCurrentRow(undefined)
handleModalVisible(false) handleModalVisible(false)
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
handleSetlogSave(`更新${currentRow?.GROWTHSETTING_NAME}失败`)
message.error(data.Result_Desc) message.error(data.Result_Desc)
} }
}; };
@ -297,6 +303,7 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
} }
const data = await handleGetGROWTHSETTINGList(req); const data = await handleGetGROWTHSETTINGList(req);
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
handleSetlogSave(`查看了成长规则配置列表`)
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }
return { data: [], success: true } return { data: [], success: true }

View File

@ -29,8 +29,8 @@ import session from '@/utils/session';
import LeftSelectMallType from '../ProductListingManagement/component/LeftSelectMallType'; import LeftSelectMallType from '../ProductListingManagement/component/LeftSelectMallType';
const MallEvaluationManage: React.FC<{ currentUser: CurrentUser | undefined }> = (props) => { const MallEvaluationManage: React.FC<{ currentUser: CurrentUser | undefined, isComponent?: boolean, parentDetail?: any }> = (props) => {
const { currentUser } = props const { currentUser, isComponent, parentDetail } = props
const actionRef = useRef<ActionType>(); const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>(); const formRef = useRef<FormInstance>();
const [currentRow, setCurrentRow] = useState<COMMODITYModel>(); const [currentRow, setCurrentRow] = useState<COMMODITYModel>();
@ -249,16 +249,20 @@ const MallEvaluationManage: React.FC<{ currentUser: CurrentUser | undefined }> =
return ( return (
<div> <div>
<div style={{ backgroundColor: '#fff', display: 'flex' }}> <div style={{ backgroundColor: '#fff', display: 'flex' }}>
{
isComponent ? '' :
<LeftSelectMallType setSelectedId={setSelectedId} setCollapsible={setCollapsible} collapsible={collapsible} setData={setLeftTreeData} /> <LeftSelectMallType setSelectedId={setSelectedId} setCollapsible={setCollapsible} collapsible={collapsible} setData={setLeftTreeData} />
}
<div style={{ <div style={{
width: !collapsible ? 'calc(100% - 300px)' : 'calc(100% - 60px)', width: isComponent ? '100%' : !collapsible ? 'calc(100% - 300px)' : 'calc(100% - 60px)',
paddingTop: 0, paddingTop: 0,
paddingBottom: 0, paddingBottom: 0,
paddingRight: 0 paddingRight: 0
}}> }}>
{/* 最外层的列表 */} {/* 最外层的列表 */}
<ProTable<COMMODITYModel> <ProTable<COMMODITYModel>
scroll={{ x: "100%", y: 'calc(100vh - 370px)' }} scroll={{ x: "100%", y: isComponent ? '300px' : 'calc(100vh - 370px)' }}
rowKey={(record) => { rowKey={(record) => {
return `${record?.COMMODITY_ID}` return `${record?.COMMODITY_ID}`
}} }}
@ -266,10 +270,10 @@ const MallEvaluationManage: React.FC<{ currentUser: CurrentUser | undefined }> =
bordered bordered
headerTitle={<PageTitleBox props={props} />} // 列表表头 headerTitle={<PageTitleBox props={props} />} // 列表表头
actionRef={actionRef} actionRef={actionRef}
search={{ span: 6, labelWidth: 'auto' }} search={isComponent ? false : { span: 6, labelWidth: 'auto' }}
// 请求数据 // 请求数据
request={async (params, sorter) => { request={async (params, sorter) => {
const req: any = { const req: any = isComponent ? {
searchParameter: { searchParameter: {
OWNERUNIT_ID: currentUser?.OwnerUnitId, OWNERUNIT_ID: currentUser?.OwnerUnitId,
PROVINCE_CODE: currentUser?.ProvinceCode, PROVINCE_CODE: currentUser?.ProvinceCode,
@ -280,8 +284,18 @@ const MallEvaluationManage: React.FC<{ currentUser: CurrentUser | undefined }> =
PageIndex: 1, PageIndex: 1,
PageSize: 999999, PageSize: 999999,
SortStr: "CREATE_DATE desc", SortStr: "CREATE_DATE desc",
} : {
searchParameter: {
OWNERUNIT_ID: currentUser?.OwnerUnitId,
PROVINCE_CODE: currentUser?.ProvinceCode,
ISVALID: 1,
MEMBERSHIP_ID: parentDetail?.MEMBERSHIP_ID,
},
PageIndex: 1,
PageSize: 999999,
SortStr: "CREATE_DATE desc",
keyWord: { keyWord: {
Key: "SELLER_NAME,MEMBERSHIP_NAME", Key: "MEMBERSHIP_NAME",
Value: params?.searchText || "" Value: params?.searchText || ""
}, },
} }

View File

@ -9,6 +9,7 @@ import Draggable from "react-draggable";
import ProForm, { ProFormSelect, ProFormText, ProFormTextArea } from "@ant-design/pro-form"; import ProForm, { ProFormSelect, ProFormText, ProFormTextArea } from "@ant-design/pro-form";
import moment from 'moment' import moment from 'moment'
import ModalFooter from "../../scenicSpotConfig/component/modalFooter"; import ModalFooter from "../../scenicSpotConfig/component/modalFooter";
import { handleSetlogSave } from "@/utils/format";
type DetailProps = { type DetailProps = {
currentBigRow: any currentBigRow: any
@ -51,7 +52,7 @@ const AddressDetail = ({ currentBigRow, currentUser }: DetailProps) => {
return record?.USER_NAME ? <a return record?.USER_NAME ? <a
onClick={() => { onClick={() => {
console.log('record', record); console.log('record', record);
handleSetlogSave(`查看【${record?.ADDRESS || ""}】地址信息`)
setProvince(record?.RECEIVE_PROVINCE) setProvince(record?.RECEIVE_PROVINCE)
setCity(record?.RECEIVE_CITY) setCity(record?.RECEIVE_CITY)
setCounty(record?.RECEIVE_COUNTY) setCounty(record?.RECEIVE_COUNTY)
@ -227,10 +228,13 @@ const AddressDetail = ({ currentBigRow, currentUser }: DetailProps) => {
console.log('resultresultresult', result); console.log('resultresultresult', result);
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.ADDRESS || ""}】失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
modalActionRef.current?.reload() modalActionRef.current?.reload()
handleSetlogSave(`删除【${currentRow?.ADDRESS || ""}】成功`)
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
setProvince("") setProvince("")
@ -274,12 +278,14 @@ const AddressDetail = ({ currentBigRow, currentUser }: DetailProps) => {
} }
const data = await handleSynchroMEMBERADDRESS(req); const data = await handleSynchroMEMBERADDRESS(req);
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
handleSetlogSave(`更新【${currentRow?.ADDRESS || ""}】成功`)
message.success(data.Result_Desc) message.success(data.Result_Desc)
formRef?.current?.resetFields() formRef?.current?.resetFields()
setCurrentRow(undefined) setCurrentRow(undefined)
handleModalVisible(false) handleModalVisible(false)
modalActionRef.current?.reload() modalActionRef.current?.reload()
} else { } else {
handleSetlogSave(`更新【${currentRow?.ADDRESS || ""}】失败`)
message.error(data.Result_Desc) message.error(data.Result_Desc)
} }
}; };

View File

@ -22,6 +22,7 @@ import type { FormInstance } from 'antd';
import { handeGetMemberAddressCombineList, handleDeleteMEMBERADDRESS, handleGetMEMBERADDRESSList, handleSynchroMEMBERADDRESS } from '../service'; import { handeGetMemberAddressCombineList, handleDeleteMEMBERADDRESS, handleGetMEMBERADDRESSList, handleSynchroMEMBERADDRESS } from '../service';
import PageTitleBox from '@/components/PageTitleBox'; import PageTitleBox from '@/components/PageTitleBox';
import AddressDetail from './components/addressDetail'; import AddressDetail from './components/addressDetail';
import { handleSetlogSave } from '@/utils/format';
@ -432,6 +433,7 @@ const MemberAddress: React.FC<{ currentUser: CurrentUser | undefined }> = (props
}); });
console.log('resultresultresult', result); console.log('resultresultresult', result);
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
@ -521,6 +523,7 @@ const MemberAddress: React.FC<{ currentUser: CurrentUser | undefined }> = (props
console.log('reqreqreqreqreqreqreq', req); console.log('reqreqreqreqreqreqreq', req);
const data = await handeGetMemberAddressCombineList(req) const data = await handeGetMemberAddressCombineList(req)
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
handleSetlogSave(`查询了会员地址管理列表`)
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -9,6 +9,7 @@ import { handeGetPointGrowthSummary, handleGetMEMBERGROWTHList, handleGetPOINTRE
import moment from 'moment' import moment from 'moment'
import addIcon from '@/assets/detail/addIcon.png' import addIcon from '@/assets/detail/addIcon.png'
import reduceIcon from '@/assets/detail/reduceIcon.png' import reduceIcon from '@/assets/detail/reduceIcon.png'
import staticSumTotalBg from '@/assets/detail/staticSumTotalBg.png'
import session from "@/utils/session"; import session from "@/utils/session";
import ProForm, { ProFormDateRangePicker } from "@ant-design/pro-form"; import ProForm, { ProFormDateRangePicker } from "@ant-design/pro-form";
@ -329,7 +330,8 @@ const MemberSummaryStatistics: React.FC<{ currentUser: CurrentUser | undefined }
<div className="MemberSummaryStatisticsItemOther"> <div className="MemberSummaryStatisticsItemOther">
<div className={selectTab === 1 ? 'MemberSummaryStatisticsOtherItem MemberSummaryStatisticsOtherItemSelect' : 'MemberSummaryStatisticsOtherItem'} onClick={() => { <div className={selectTab === 1 ? 'MemberSummaryStatisticsOtherItem MemberSummaryStatisticsOtherItemSelect' : 'MemberSummaryStatisticsOtherItem'}
onClick={() => {
handleChangeTab(1) handleChangeTab(1)
}}> }}>
<div className="otherItemTitle"></div> <div className="otherItemTitle"></div>

View File

@ -28,6 +28,7 @@ import defaultIcon from '../../../assets/brand/defaultIcon.png'
import classNames from 'classnames'; import classNames from 'classnames';
import session from '@/utils/session'; import session from '@/utils/session';
import ModalFooter from '../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../scenicSpotConfig/component/modalFooter';
import { handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -164,8 +165,10 @@ const MemberTagManage: React.FC<{ currentUser: CurrentUser | undefined }> = (pro
const result = await handeDeleteAUTOTYPE(req) const result = await handeDeleteAUTOTYPE(req)
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.AUTOTYPE_NAME}】失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除【${currentRow?.AUTOTYPE_NAME}】成功`)
actionRef.current?.reload() actionRef.current?.reload()
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -201,6 +204,7 @@ const MemberTagManage: React.FC<{ currentUser: CurrentUser | undefined }> = (pro
const data = await handeSynchroAUTOTYPE(req) const data = await handeSynchroAUTOTYPE(req)
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
handleSetlogSave(`更新【${currentRow?.AUTOTYPE_NAME}】成功`)
message.success("新增成功!") message.success("新增成功!")
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
@ -210,6 +214,7 @@ const MemberTagManage: React.FC<{ currentUser: CurrentUser | undefined }> = (pro
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.AUTOTYPE_NAME}】失败`)
} }
} }
@ -240,6 +245,7 @@ const MemberTagManage: React.FC<{ currentUser: CurrentUser | undefined }> = (pro
} }
const data = await handeGetNestingAUTOTYPEList(req); const data = await handeGetNestingAUTOTYPEList(req);
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
handleSetlogSave(`点击查询按钮`)
if (data && data.length > 0) { if (data && data.length > 0) {
setTypeTreeData(data) setTypeTreeData(data)
return { data: data, success: true, total: data.length } return { data: data, success: true, total: data.length }

View File

@ -28,6 +28,7 @@ import defaultIcon from '../../../assets/brand/defaultIcon.png'
import classNames from 'classnames'; import classNames from 'classnames';
import session from '@/utils/session'; import session from '@/utils/session';
import ModalFooter from '../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../scenicSpotConfig/component/modalFooter';
import { handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -200,8 +201,10 @@ const MembershipLevelManage: React.FC<{ currentUser: CurrentUser | undefined }>
const result = await handeDeleteFIELDENUM(req) const result = await handeDeleteFIELDENUM(req)
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】成功`)
actionRef.current?.reload() actionRef.current?.reload()
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -228,6 +231,7 @@ const MembershipLevelManage: React.FC<{ currentUser: CurrentUser | undefined }>
const data = await handeSynchroFIELDENUM(req) const data = await handeSynchroFIELDENUM(req)
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
handleSetlogSave(`更新【${currentRow?.FIELDENUM_NAME}】成功`)
message.success("新增成功!") message.success("新增成功!")
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
@ -237,6 +241,7 @@ const MembershipLevelManage: React.FC<{ currentUser: CurrentUser | undefined }>
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.FIELDENUM_NAME}】失败`)
} }
} }
@ -266,6 +271,7 @@ const MembershipLevelManage: React.FC<{ currentUser: CurrentUser | undefined }>
SearchKey: "" SearchKey: ""
} }
const data = await handeGetNestingFIELDENUMList(req); const data = await handeGetNestingFIELDENUMList(req);
handleSetlogSave(`点击查询按钮`)
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
if (data && data.length > 0) { if (data && data.length > 0) {
setTypeTreeData(data) setTypeTreeData(data)

View File

@ -15,8 +15,9 @@ import moment from 'moment'
import session from "@/utils/session"; import session from "@/utils/session";
const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser }> = (props) => {
const { currentUser } = props const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser, isComponent?: boolean, parentDetail?: any }> = (props) => {
const { currentUser, isComponent, parentDetail } = props
const actionRef = useRef<ActionType>(); const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>(); const formRef = useRef<FormInstance>();
const [collapsible, setCollapsible] = useState<boolean>(false) const [collapsible, setCollapsible] = useState<boolean>(false)
@ -52,7 +53,7 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser }> = (props)
}; };
}, },
}, },
initialValue: [moment().format('YYYY-MM-DD'), moment().add(-1, 'M').format('YYYY-MM-DD')], initialValue: [moment().add(-1, 'M').format('YYYY-MM-DD'), moment().format('YYYY-MM-DD')],
}, },
{ {
title: "序号", title: "序号",
@ -139,9 +140,13 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser }> = (props)
return ( return (
<div> <div>
<div style={{ backgroundColor: '#fff', display: 'flex' }}> <div style={{ backgroundColor: '#fff', display: 'flex' }}>
{
isComponent ? '' :
<LeftSelectTree setSelectedId={setSelectedId} setCollapsible={setCollapsible} collapsible={collapsible} /> <LeftSelectTree setSelectedId={setSelectedId} setCollapsible={setCollapsible} collapsible={collapsible} />
}
<div style={{ <div style={{
width: !collapsible ? 'calc(100% - 300px)' : 'calc(100% - 60px)', width: isComponent ? '100%' : !collapsible ? 'calc(100% - 300px)' : 'calc(100% - 60px)',
paddingTop: 0, paddingTop: 0,
paddingBottom: 0, paddingBottom: 0,
paddingRight: 0 paddingRight: 0
@ -154,14 +159,29 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser }> = (props)
expandable={{ expandable={{
expandRowByClick: true expandRowByClick: true
}} }}
scroll={{ x: "100%", y: "calc(100vh - 410px)" }} scroll={{ x: "100%", y: isComponent ? '300px' : "calc(100vh - 410px)" }}
headerTitle={<PageTitleBox props={props} />} // 列表表头 headerTitle={<PageTitleBox props={props} />} // 列表表头
search={{ span: 6 }} search={isComponent ? false : { span: 6 }}
request={async (params) => { request={async (params) => {
if (!selectedId) { if (!selectedId && !isComponent) {
return return
} }
const req: any = { const req: any = isComponent ? {
SearchParameter: {
OWNERUNIT_ID: currentUser?.OwnerUnitId,
PROVINCE_CODE: currentUser?.ProvinceCode,
COMMENT_ISVALID: 1,
CREATE_DATE_Start: params?.CREATE_DATE_Start || "",
CREATE_DATE_End: params?.CREATE_DATE_End || "",
MEMBERSHIP_IDS: parentDetail?.MEMBERSHIP_ID,
},
PageIndex: 1,
PageSize: 999999,
keyWord: {
Key: "SELLER_NAME,MEMBERSHIP_NAME",
Value: params?.searchText || ""
},
} : {
SearchParameter: { SearchParameter: {
OWNERUNIT_ID: currentUser?.OwnerUnitId, OWNERUNIT_ID: currentUser?.OwnerUnitId,
PROVINCE_CODE: currentUser?.ProvinceCode, PROVINCE_CODE: currentUser?.ProvinceCode,
@ -177,7 +197,7 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser }> = (props)
}, },
} }
const data = await handeGetCOMMENTList(req) const data = await handeGetCOMMENTList(req)
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata222', data);
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -27,6 +27,7 @@ import { uploadPicture } from '@/services/picture';
import defaultIcon from '../../../assets/brand/defaultIcon.png' import defaultIcon from '../../../assets/brand/defaultIcon.png'
import classNames from 'classnames'; import classNames from 'classnames';
import ModalFooter from '../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../scenicSpotConfig/component/modalFooter';
import { handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -240,9 +241,11 @@ const OrderCategoryManage: React.FC<{ currentUser: CurrentUser | undefined }> =
const result = await handlDeleteUSERDEFINEDTYPE(req) const result = await handlDeleteUSERDEFINEDTYPE(req)
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.USERDEFINEDTYPE_NAME}】失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
actionRef.current?.reload() actionRef.current?.reload()
handleSetlogSave(`删除【${currentRow?.USERDEFINEDTYPE_NAME}】成功`)
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -285,6 +288,7 @@ const OrderCategoryManage: React.FC<{ currentUser: CurrentUser | undefined }> =
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
message.success("新增成功!") message.success("新增成功!")
handleSetlogSave(`更新【${currentRow?.USERDEFINEDTYPE_NAME}】成功`)
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
handleModalVisible(false) handleModalVisible(false)
@ -293,6 +297,7 @@ const OrderCategoryManage: React.FC<{ currentUser: CurrentUser | undefined }> =
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.USERDEFINEDTYPE_NAME}】失败`)
} }
} }
@ -322,6 +327,7 @@ const OrderCategoryManage: React.FC<{ currentUser: CurrentUser | undefined }> =
// SearchKey: "" // SearchKey: ""
} }
const data = await handlGetUSERDEFINEDTYPEList(req); const data = await handlGetUSERDEFINEDTYPEList(req);
handleSetlogSave(`点击查询按钮`)
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
if (data && data.length > 0) { if (data && data.length > 0) {
setTypeTreeData(data) setTypeTreeData(data)

View File

@ -30,6 +30,7 @@ import OrderCategoryManage from '../OrderCategoryManage';
import session from '@/utils/session'; import session from '@/utils/session';
import OrderCategoryTreeMultiple from './components/OrderCategoryTreeMultiple'; import OrderCategoryTreeMultiple from './components/OrderCategoryTreeMultiple';
import Item from 'antd/lib/list/Item'; import Item from 'antd/lib/list/Item';
import { handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -355,7 +356,7 @@ const OrderProductManage: React.FC<{ currentUser: CurrentUser | undefined }> = (
const data = await handeSyncSellerCommodityInfo({ list: [req] }) const data = await handeSyncSellerCommodityInfo({ list: [req] })
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
handleSetlogSave(`更新【${currentRow?.COMMODITY_NAME}】成功`)
message.success("同步成功!") message.success("同步成功!")
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
@ -365,6 +366,7 @@ const OrderProductManage: React.FC<{ currentUser: CurrentUser | undefined }> = (
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.COMMODITY_NAME}】失败`)
} }
}; };
@ -480,6 +482,7 @@ const OrderProductManage: React.FC<{ currentUser: CurrentUser | undefined }> = (
console.log('reqreqreqreq', req); console.log('reqreqreqreq', req);
const data = await handeGetSellerCommodityList(req); const data = await handeGetSellerCommodityList(req);
handleSetlogSave(`点击查询按钮`)
// const data = await handeGetCOMMODITYList(req); // const data = await handeGetCOMMODITYList(req);
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
@ -585,6 +588,7 @@ const OrderProductManage: React.FC<{ currentUser: CurrentUser | undefined }> = (
formRef={formRef} formRef={formRef}
autoFocusFirstInput autoFocusFirstInput
submitter={false} submitter={false}
labelCol={{ style: { width: 80 } }}
preserve={false} preserve={false}
request={async () => { request={async () => {
if (currentRow) { if (currentRow) {

View File

@ -17,10 +17,11 @@ import { handleGetCONSUMPTIONRECORDList, handleGetPOINTRECORDList } from "../ser
import PageTitleBox from "@/components/PageTitleBox"; import PageTitleBox from "@/components/PageTitleBox";
import moment from 'moment' import moment from 'moment'
import session from "@/utils/session"; import session from "@/utils/session";
import { handleSetlogSave } from "@/utils/format";
const PointsRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props) => { const PointsRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boolean, parentDetail?: any }> = (props) => {
const { currentUser } = props const { currentUser, isComponent, parentDetail } = props
const downloadBtnRef = useRef<any>() const downloadBtnRef = useRef<any>()
const actionRef = useRef<ActionType>(); const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>(); const formRef = useRef<FormInstance>();
@ -133,7 +134,7 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props) => {
align: 'center', align: 'center',
ellipsis: true, ellipsis: true,
render: (_, record) => { render: (_, record) => {
return record?.CREATE_DATE ? moment(record?.CREATE_DATE).format('YYYY-MM-DD') : "-" return record?.CREATE_DATE ? moment(record?.CREATE_DATE).format('YYYY-MM-DD HH:mm:ss') : "-"
} }
}, },
] ]
@ -163,9 +164,19 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props) => {
expandRowByClick: true expandRowByClick: true
}} }}
headerTitle={<PageTitleBox props={props} />} headerTitle={<PageTitleBox props={props} />}
search={{ span: 6 }} search={isComponent ? false : { span: 6 }}
scroll={{ x: '100%', y: isComponent ? '300px' : 'calc(100vh - 430px)' }}
request={async (params) => { request={async (params) => {
const req: any = { const req: any = isComponent ? {
SearchParameter: {
OWNERUNIT_ID: 911,
MEMBERSHIP_IDS: parentDetail?.MEMBERSHIP_ID,
},
PageIndex: params?.current,
PageSize: 20,
sortstr: "OPERATE_DATE desc",
} : {
SearchParameter: { SearchParameter: {
// PROVINCE_CODE: currentUser?.ProvinceCode || "", // PROVINCE_CODE: currentUser?.ProvinceCode || "",
OPERATE_DATE_Start: params?.OPERATE_DATE_Start || "", OPERATE_DATE_Start: params?.OPERATE_DATE_Start || "",
@ -179,6 +190,8 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser }> = (props) => {
sortstr: "OPERATE_DATE desc", sortstr: "OPERATE_DATE desc",
} }
const data = await handleGetPOINTRECORDList(req) const data = await handleGetPOINTRECORDList(req)
handleSetlogSave(`点击查询按钮`)
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -28,7 +28,7 @@ import classNames from 'classnames';
import session from '@/utils/session'; import session from '@/utils/session';
import { handeDeleteFIELDENUM, handeGetFIELDEXPLAINList, handeGetNestingFIELDENUMList, handeSynchroFIELDENUM } from '../service'; import { handeDeleteFIELDENUM, handeGetFIELDEXPLAINList, handeGetNestingFIELDENUMList, handeSynchroFIELDENUM } from '../service';
import ModalFooter from '../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../scenicSpotConfig/component/modalFooter';
import { convertTreeToLabelValue } from '@/utils/format'; import { convertTreeToLabelValue, handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -202,8 +202,10 @@ const PointConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
const result = await handeDeleteFIELDENUM(req) const result = await handeDeleteFIELDENUM(req)
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】类别失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】类别成功`)
actionRef.current?.reload() actionRef.current?.reload()
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -231,6 +233,7 @@ const PointConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
handleConfirmLoading(false) handleConfirmLoading(false)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
message.success("新增成功!") message.success("新增成功!")
handleSetlogSave(`更新【${currentRow?.FIELDENUM_NAME}】类别成功`)
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
handleModalVisible(false) handleModalVisible(false)
@ -239,6 +242,7 @@ const PointConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.FIELDENUM_NAME}】类别失败`)
} }
} }
@ -269,6 +273,7 @@ const PointConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props)
} }
const data = await handeGetNestingFIELDENUMList(req); const data = await handeGetNestingFIELDENUMList(req);
console.log('datadatadata', data); console.log('datadatadata', data);
handleSetlogSave(`查询成长值枚举配置`)
if (data && data.length > 0) { if (data && data.length > 0) {
setTypeTreeData(data) setTypeTreeData(data)

View File

@ -26,6 +26,7 @@ import session from '@/utils/session';
import PageTitleBox from '@/components/PageTitleBox'; import PageTitleBox from '@/components/PageTitleBox';
import ModalFooter from '../scenicSpotConfig/component/modalFooter'; import ModalFooter from '../scenicSpotConfig/component/modalFooter';
import PointConfig from './PointConfig'; import PointConfig from './PointConfig';
import { handleSetlogSave } from '@/utils/format';
@ -272,8 +273,10 @@ const PointsRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.SCORE_NAME}】类别失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除【${currentRow?.SCORE_NAME}】类别成功`)
actionRef.current?.reload() actionRef.current?.reload()
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
@ -310,6 +313,7 @@ const PointsRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
const data = await handleSynchroSCORESETTING(req) const data = await handleSynchroSCORESETTING(req)
if (data.Result_Code === 100) { if (data.Result_Code === 100) {
handleSetlogSave(`更新【${currentRow?.SCORE_NAME}】类别成功`)
message.success(data.Result_Desc) message.success(data.Result_Desc)
formRef?.current?.resetFields() formRef?.current?.resetFields()
setCurrentRow(undefined) setCurrentRow(undefined)
@ -317,6 +321,7 @@ const PointsRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
actionRef.current?.reload() actionRef.current?.reload()
} else { } else {
message.error(data.Result_Desc) message.error(data.Result_Desc)
handleSetlogSave(`更新【${currentRow?.SCORE_NAME}】类别失败`)
} }
} }
@ -353,6 +358,7 @@ const PointsRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
} }
setSearchParams(searchWholeParams) setSearchParams(searchWholeParams)
const data = await handleGetSCORESETTINGList(searchWholeParams); const data = await handleGetSCORESETTINGList(searchWholeParams);
handleSetlogSave(`点击查询按钮`)
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -1,4 +1,4 @@
// 注册留存分析 // 注册留存分析 用户行为记录分析
import { connect, Link } from "umi"; import { connect, Link } from "umi";
import type { CurrentUser } from "umi"; import type { CurrentUser } from "umi";
@ -18,8 +18,8 @@ import PageTitleBox from "@/components/PageTitleBox";
import { handleGetBEHAVIORRECORDList } from "@/pages/Setting/OperationLog/service"; import { handleGetBEHAVIORRECORDList } from "@/pages/Setting/OperationLog/service";
const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (props) => { const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComponent?: Boolean, parentDetail?: any }> = (props) => {
const { dispatch, children, currentUser } = props const { dispatch, children, currentUser, isComponent, parentDetail } = props
const downloadBtnRef = useRef<any>() const downloadBtnRef = useRef<any>()
const actionRef = useRef<ActionType>(); const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>(); const formRef = useRef<FormInstance>();
@ -115,6 +115,7 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
{ {
title: '操作人员', title: '操作人员',
hideInSearch: true, hideInSearch: true,
align: 'center',
dataIndex: 'USER_NAME', dataIndex: 'USER_NAME',
ellipsis: true, ellipsis: true,
width: 120, width: 120,
@ -128,12 +129,14 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
title: '操作地址', title: '操作地址',
hideInSearch: true, hideInSearch: true,
dataIndex: 'USER_LOGINIP', dataIndex: 'USER_LOGINIP',
align: 'center',
width: 150, width: 150,
}, },
{ {
title: '操作地点', title: '操作地点',
hideInSearch: true, hideInSearch: true,
dataIndex: 'USER_LOGINPLACE', dataIndex: 'USER_LOGINPLACE',
align: 'center',
width: 160, width: 160,
ellipsis: true, ellipsis: true,
}, },
@ -149,11 +152,11 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
// } // }
// }, // },
{ {
title: '操作内容', title: <div style={{ textAlign: 'center' }}></div>,
hideInSearch: true, hideInSearch: true,
dataIndex: 'BEHAVIORRECORD_EXPLAIN', dataIndex: 'BEHAVIORRECORD_EXPLAIN',
width: 250, width: 250,
align: 'center', align: 'left',
ellipsis: true, ellipsis: true,
}, },
// { // {
@ -169,6 +172,7 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
title: '操作日期', title: '操作日期',
width: 160, width: 160,
valueType: 'date', valueType: 'date',
align: 'center',
dataIndex: 'BEHAVIORRECORD_TIME', dataIndex: 'BEHAVIORRECORD_TIME',
initialValue: moment(), initialValue: moment(),
render: (_, record) => { render: (_, record) => {
@ -180,6 +184,7 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
width: 160, width: 160,
dataIndex: 'SOURCE_PLATFORM', dataIndex: 'SOURCE_PLATFORM',
valueType: 'select', valueType: 'select',
align: 'center',
valueEnum: { valueEnum: {
// "驿商云平台": "驿商云平台", // "驿商云平台": "驿商云平台",
// "数智化看板": "数智化看板", // "数智化看板": "数智化看板",
@ -203,13 +208,13 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
hideInSearch: true, hideInSearch: true,
dataIndex: 'BROWSER_VERSION', dataIndex: 'BROWSER_VERSION',
}, },
{ // {
title: '接口信息', // title: '接口信息',
width: 150, // width: 150,
hideInSearch: true, // hideInSearch: true,
dataIndex: 'REQUEST_INFO', // dataIndex: 'REQUEST_INFO',
ellipsis: true, // ellipsis: true,
}, // },
// { // {
// title: '调用入参', // title: '调用入参',
// width: 150, // width: 150,
@ -252,14 +257,24 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
const res: any = formRef.current?.getFieldsValue() const res: any = formRef.current?.getFieldsValue()
console.log('resresres', res); console.log('resresres', res);
let params: any = { let params: any = {
BEHAVIORRECORD_TIME: moment(res.BEHAVIORRECORD_TIME._d).format('YYYY-MM-DD'), BEHAVIORRECORD_TIME: res && res.BEHAVIORRECORD_TIME ? moment(res.BEHAVIORRECORD_TIME._d).format('YYYY-MM-DD') : "",
SOURCE_PLATFORM: res.SOURCE_PLATFORM, SOURCE_PLATFORM: res && res.SOURCE_PLATFORM ? res.SOURCE_PLATFORM : "",
BEHAVIORRECORD_TYPE: res.BEHAVIORRECORD_TYPE, BEHAVIORRECORD_TYPE: res && res.BEHAVIORRECORD_TYPE ? res.BEHAVIORRECORD_TYPE : "",
...res ...res
} }
setTableLoading(true) setTableLoading(true)
const req: any = { console.log('isComponentisComponent', isComponent);
const req: any = isComponent ? {
SearchParameter: {
SOURCE_PLATFORMS: '彩云驿出行',
USER_MOBILEPHONE: parentDetail?.MEMBERSHIP_MOBILEPHONE
},
SortStr: 'BEHAVIORRECORD_TIME desc',
PageIndex: 1,
PageSize: 999999
} : {
SearchParameter: { SearchParameter: {
BEHAVIORRECORD_TIME_Start: moment(params?.BEHAVIORRECORD_TIME).format('YYYY-MM-DD'), BEHAVIORRECORD_TIME_Start: moment(params?.BEHAVIORRECORD_TIME).format('YYYY-MM-DD'),
BEHAVIORRECORD_TIME_End: moment(params?.BEHAVIORRECORD_TIME).format('YYYY-MM-DD'), BEHAVIORRECORD_TIME_End: moment(params?.BEHAVIORRECORD_TIME).format('YYYY-MM-DD'),
@ -276,11 +291,13 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
} }
setSearchParams(params) setSearchParams(params)
const data = await handleGetBEHAVIORRECORDList(req) const data = await handleGetBEHAVIORRECORDList(req)
setReqDetailList(data)
setTableData(data) setTableData(data)
setTableLoading(false) setTableLoading(false)
if (isComponent) {
} else {
const allReq: any = { const allReq: any = {
SearchParameter: { SearchParameter: {
BEHAVIORRECORD_TIME_Start: moment(params?.BEHAVIORRECORD_TIME).format('YYYY-MM-DD'), BEHAVIORRECORD_TIME_Start: moment(params?.BEHAVIORRECORD_TIME).format('YYYY-MM-DD'),
@ -297,13 +314,17 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
PageSize: 999999 PageSize: 999999
} }
const allData = await handleGetBEHAVIORRECORDList(allReq) const allData = await handleGetBEHAVIORRECORDList(allReq)
setReqDetailList(data)
setTableData(allData) setTableData(allData)
setIsFirst(false) setIsFirst(false)
} }
useEffect(async () => {
handleGetTableData() }
}, [])
// useEffect(async () => {
// handleGetTableData()
// }, [])
return ( return (
<div ref={(el) => { <div ref={(el) => {
@ -371,16 +392,16 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser }> = (p
expandable={{ expandable={{
expandRowByClick: true expandRowByClick: true
}} }}
scroll={{ y: 'calc(100vh - 450px)' }} scroll={{ x: '100%', y: isComponent ? '300px' : 'calc(100vh - 430px)' }}
headerTitle={<PageTitleBox props={props} />} // 列表表头 search={isComponent ? false : { span: 6 }}
search={{ span: 6 }}
pagination={{ pageSize: 100 }} pagination={{ pageSize: 100 }}
dataSource={tableData} dataSource={tableData}
loading={tableLoading} loading={tableLoading}
request={async (params) => { request={async (params) => {
if (!isFirst) {
handleGetTableData() handleGetTableData()
} // if (!isFirst) {
// handleGetTableData()
// }
// console.log('data', data); // console.log('data', data);
// if (data && data.length > 0) { // if (data && data.length > 0) {

View File

@ -1,4 +1,4 @@
// 商城交易台账 // 商城交易台账 交易台账管理
import { connect } from "umi"; import { connect } from "umi";
import type { CurrentUser } from "umi"; import type { CurrentUser } from "umi";
import type { ConnectState } from "@/models/connect"; import type { ConnectState } from "@/models/connect";
@ -78,7 +78,7 @@ const TradingLedger: React.FC<{ currentUser: CurrentUser }> = (props) => {
{ {
dataIndex: 'SALEBILL_CODE', dataIndex: 'SALEBILL_CODE',
title: <div style={{ textAlign: 'center' }}></div>, title: <div style={{ textAlign: 'center' }}></div>,
align: 'left', align: 'center',
width: 220, width: 220,
ellipsis: true, ellipsis: true,
hideInSearch: true, hideInSearch: true,
@ -90,6 +90,14 @@ const TradingLedger: React.FC<{ currentUser: CurrentUser }> = (props) => {
}}>{record?.SALEBILL_CODE}</a> : "-" }}>{record?.SALEBILL_CODE}</a> : "-"
} }
}, },
{
dataIndex: 'PAYMENT_CODE',
title: <div style={{ textAlign: 'center' }}></div>,
align: 'center',
width: 220,
ellipsis: true,
hideInSearch: true,
},
{ {
dataIndex: 'COMMODITY_NAME', dataIndex: 'COMMODITY_NAME',
title: <div style={{ textAlign: 'center' }}></div>, title: <div style={{ textAlign: 'center' }}></div>,
@ -117,7 +125,6 @@ const TradingLedger: React.FC<{ currentUser: CurrentUser }> = (props) => {
title: "订单状态", title: "订单状态",
dataIndex: "SALEBILL_STATE", dataIndex: "SALEBILL_STATE",
width: 150, width: 150,
hideInSearch: true,
ellipsis: true, ellipsis: true,
valueType: "select", valueType: "select",
valueEnum: { valueEnum: {
@ -167,6 +174,14 @@ const TradingLedger: React.FC<{ currentUser: CurrentUser }> = (props) => {
align: "center", align: "center",
initialValue: '0', initialValue: '0',
}, },
{
dataIndex: 'ORDER_PERSON',
title: '收货人',
align: 'center',
width: 150,
ellipsis: true,
hideInSearch: true,
},
{ {
dataIndex: 'ORDER_DATE', dataIndex: 'ORDER_DATE',
title: '下单时间', title: '下单时间',
@ -281,7 +296,7 @@ const TradingLedger: React.FC<{ currentUser: CurrentUser }> = (props) => {
const req: any = { const req: any = {
SearchParameter: { SearchParameter: {
SALEBILL_IDS: "", SALEBILL_IDS: "",
SALEBILL_TYPES: params?.SALEBILL_TYPE === '0' ? '' : params?.SALEBILL_TYPE, SALEBILL_TYPES: params?.SALEBILL_TYPE === '0' ? '3000,3001,3002,3010' : params?.SALEBILL_TYPE,
MEMBERSHIP_IDS: "", MEMBERSHIP_IDS: "",
MERCHANTS_IDS: "", MERCHANTS_IDS: "",
// PROVINCE_CODE: currentUser?.ProvinceCode, // PROVINCE_CODE: currentUser?.ProvinceCode,

View File

@ -0,0 +1,159 @@
// 会员优惠券
import { connect } from "umi";
import type { ConnectState } from "@/models/connect";
import PageTitleBox from "@/components/PageTitleBox";
import ProTable, { ActionType } from "@ant-design/pro-table";
import { useRef, useState } from "react";
import { FormInstance, Image } from "antd";
import { handeGetCommodityCollectionList, handeGetCOUPON_SENDList, handeGetMemberShipLicenseList } from "../../service";
import moment from 'moment'
type DetailProps = {
parentDetail?: any
currentUser?: any
}
const CollectProducts = ({ parentDetail, currentUser }: DetailProps) => {
const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>();
// 文件列表
const [fileList, setFileList] = useState<any>([])
const [imagePreviewVisible, setImagePreviewVisible] = useState<boolean>(false) // 预览图片
const columns: any = [
{
title: "商品图片",
width: 150,
dataIndex: "list_img",
hideInSearch: true,
align: 'center',
ellipsis: true,
render: (_, record) => {
return record?.list_img ? <img style={{ width: '50px', height: '50px', cursor: 'pointer' }} src={record?.list_img} onClick={() => {
setFileList([{ url: record?.list_img }])
setImagePreviewVisible(true)
}} /> : "-"
}
},
{
title: "商品分类",
width: 150,
dataIndex: "USERDEFINEDTYPE_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "品牌名称",
width: 150,
dataIndex: "BRAND_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "商品名称",
width: 250,
dataIndex: "COMMODITY_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "商品单位",
width: 250,
dataIndex: "COMMODITY_UNIT",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "商品规格",
width: 250,
dataIndex: "COMMODITY_RULE",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "商品价格",
width: 250,
dataIndex: "COMMODITY_MEMBERPRICE",
hideInSearch: true,
align: 'center',
ellipsis: true,
}
]
const handleChangePreview = (val: any) => {
setImagePreviewVisible(val)
}
return (
<div>
<ProTable
actionRef={actionRef}
formRef={formRef}
columns={columns}
bordered
expandable={{
expandRowByClick: true
}}
search={false}
scroll={{ x: "100%", y: '300px' }}
// headerTitle={<PageTitleBox props={props} />} // 列表表头
request={async (params) => {
const req: any = {
ProvinceCode: currentUser?.ProvinceCode,
OwnerUnitId: currentUser?.OwnerUnitId,
MemberShipId: parentDetail?.MEMBERSHIP_ID,
AppGuid: "wxee018fb96955552a",
PageIndex: params?.current,
PageSize: params?.pageSize,
SortStr: 'COMMODITY_MEMBERPRICE desc',
}
const data = await handeGetCommodityCollectionList(req)
console.log('datadatadata', data);
if (data && data.length > 0) {
return { data, success: true }
}
return { data: [], success: true }
}}
pagination={{
defaultPageSize: 20,
showTotal: (total) => `${total} 条记录`
}}
// toolbar={{
// actions: [
// ]
// }}
/>
{/* 图片预览组件 */}
{
fileList && fileList.length > 0 && <div style={{ display: 'none' }}>
<Image.PreviewGroup
preview={{
visible: imagePreviewVisible,
onVisibleChange: vis => {
handleChangePreview(vis)
}
}}>
{
fileList.map((n) => <Image src={n.url} key={n.url} />)
}
</Image.PreviewGroup>
</div>
}
</div>
)
}
export default connect(({ user, }: ConnectState) => ({
currentUser: user.currentUser,
}))(CollectProducts);

View File

@ -0,0 +1,95 @@
// 车牌管理
import { connect } from "umi";
import type { ConnectState } from "@/models/connect";
import PageTitleBox from "@/components/PageTitleBox";
import ProTable, { ActionType } from "@ant-design/pro-table";
import { useRef } from "react";
import { FormInstance } from "antd";
import { handeGetMemberShipLicenseList } from "../../service";
type DetailProps = {
parentDetail?: any
}
const LicensePlateManage = ({ parentDetail }: DetailProps) => {
const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>();
const columns: any = [
{
title: "会员姓名",
width: 150,
dataIndex: "MEMBERSHIP_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "车辆类型",
width: 150,
dataIndex: "VEHICLE_TYPE",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "车牌号码",
width: 150,
dataIndex: "PLATE_NUMBER",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "手机号码",
width: 150,
dataIndex: "MEMBERSHIP_MOBILEPHONE",
hideInSearch: true,
align: 'center',
ellipsis: true,
}
]
return (
<div>
<ProTable
actionRef={actionRef}
formRef={formRef}
columns={columns}
bordered
expandable={{
expandRowByClick: true
}}
search={false}
scroll={{ x: "100%", y: '300px' }}
// headerTitle={<PageTitleBox props={props} />} // 列表表头
request={async (params) => {
const req: any = {
searchParameter: {
MEMBERSHIP_ID: parentDetail?.MEMBERSHIP_ID,
OWNERUNIT_ID: 911,
},
PageIndex: 1,
PageSize: 20,
}
const data = await handeGetMemberShipLicenseList(req)
console.log('datadatadata', data);
if (data && data.length > 0) {
return { data, success: true }
}
return { data: [], success: true }
}}
// toolbar={{
// actions: [
// ]
// }}
/>
</div>
)
}
export default connect(({ user, }: ConnectState) => ({
currentUser: user.currentUser,
}))(LicensePlateManage);

View File

@ -0,0 +1,128 @@
// 会员优惠券
import { connect } from "umi";
import type { ConnectState } from "@/models/connect";
import PageTitleBox from "@/components/PageTitleBox";
import ProTable, { ActionType } from "@ant-design/pro-table";
import { useRef } from "react";
import { FormInstance } from "antd";
import { handeGetCOUPON_SENDList, handeGetMemberShipLicenseList } from "../../service";
import moment from 'moment'
type DetailProps = {
parentDetail?: any
}
const MemberDiscounts = ({ parentDetail }: DetailProps) => {
const actionRef = useRef<ActionType>();
const formRef = useRef<FormInstance>();
const columns: any = [
{
title: "优惠券名称",
width: 150,
dataIndex: "COUPON_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "优惠券状态",
width: 150,
dataIndex: "COUPON_STATE",
hideInSearch: true,
align: 'center',
ellipsis: true,
valueType: 'select',
valueEnum: {
"0": { text: '未使用', status: 'processing' },
"1": { text: '已使用', status: 'success' },
"2": { text: '失效', status: 'error' }
}
},
{
title: "使用说明",
width: 250,
dataIndex: "COUPON_DESC",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "优惠形式",
width: 150,
dataIndex: "COUPON_TYPE",
hideInSearch: true,
align: 'center',
ellipsis: true,
valueType: 'select',
valueEnum: {
"1000": "满减券",
"2000": "折扣券",
"3000": "抵扣券",
"4000": "兑换券",
}
},
{
title: "有效期至",
width: 180,
dataIndex: "VALID_END_TIME",
hideInSearch: true,
align: 'center',
ellipsis: true,
render: (_, record) => {
return record?.VALID_END_TIME ? moment(record?.VALID_END_TIME).format('YYYY-MM-DD HH:mm:ss') : "-"
}
},
{
title: "适用门店",
width: 250,
dataIndex: "COOPSHOP_DESC",
hideInSearch: true,
align: 'center',
ellipsis: true,
}
]
return (
<div>
<ProTable
actionRef={actionRef}
formRef={formRef}
columns={columns}
bordered
expandable={{
expandRowByClick: true
}}
search={false}
scroll={{ x: "100%", y: '300px' }}
// headerTitle={<PageTitleBox props={props} />} // 列表表头
request={async (params) => {
const req: any = {
searchParameter: {
MEMBERSHIP_IDS: parentDetail?.MEMBERSHIP_ID,
// OWNERUNIT_ID: 911,
},
PageIndex: 1,
PageSize: 999999,
}
const data = await handeGetCOUPON_SENDList(req)
console.log('datadatadata', data);
if (data && data.length > 0) {
return { data, success: true }
}
return { data: [], success: true }
}}
// toolbar={{
// actions: [
// ]
// }}
/>
</div>
)
}
export default connect(({ user, }: ConnectState) => ({
currentUser: user.currentUser,
}))(MemberDiscounts);

View File

@ -0,0 +1,732 @@
// 会员详情组件
import { connect } from "umi";
import type { ConnectState } from "@/models/connect";
import { Col, FormInstance, Modal, Row } from "antd";
import { useEffect, useRef, useState } from "react";
import Draggable from "react-draggable";
import React from "react";
import ProForm, { ProFormSelect, ProFormText, ProFormTextArea } from "@ant-design/pro-form";
import moment from 'moment';
import memberInfoIcon from '@/assets/detail/memberInfoIcon.png'
import closeIcon from '@/assets/detail/closeIcon.png'
import session from "@/utils/session";
import memberDetailIcon from '@/assets/detail/memberDetailIcon.png'
import ProTable from "@ant-design/pro-table";
import { handleGetCONSUMPTIONRECORDList, handleGetMEMBERGROWTHList, handleGetPOINTRECORDList } from "../../service";
import AddressDetail from "../../MemberAddress/components/addressDetail";
import './style.less'
import ConsumptionRecordSearch from "../../ConsumptionRecordSearch";
import GrowthValueRecordSearch from "../../GrowthValueRecordSearch";
import PointsRecordSearch from "../../PointsRecordSearch";
import RegistrationRetentionAnalysis from "../../RegistrationRetentionAnalysis";
import LicensePlateManage from "./LicensePlateManage";
import MemberDiscounts from "./MemberDiscounts";
import CollectProducts from "./CollectProducts";
import MerchantEvaluationManage from "../../MerchantEvaluationManage";
import MallEvaluationManage from "../../MallEvaluationManage";
import { handleSetlogSave } from "@/utils/format";
type DetailProps = {
showDetailDrawer: boolean
currentRow: any
handleCloseModal: any
currentUser: any
}
const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentUser }: DetailProps) => {
const modalRef = useRef<FormInstance>();
const draggleRef = React.createRef<any>()
// 弹出框拖动效果
const [bounds, setBounds] = useState<{ left: number, right: number, top: number, bottom: number }>() // 移动的位置
const [disabled, setDraggleDisabled] = useState<boolean>() // 是否拖动
let MEMBERSHIPTYPEYNObj = session.get('MEMBERSHIPTYPEYNObj');
let MEMBERSHIPLEVELYNList = session.get('MEMBERSHIPLEVELYNList');
let COMPANY_STATEList = session.get('COMPANY_STATEList');
let SCORETYPETree = session.get('SCORETYPETree')
let CONSUMPTIONRECORDTYPEObj = session.get('CONSUMPTIONRECORDTYPEObj')
// 当前选中在详情里面要查看的内容
const [selectTab, setSelectTab] = useState<number>(1)
const onDraggaleStart = (event, uiData) => {
const { clientWidth, clientHeight } = window.document.documentElement;
const targetRect = draggleRef.current?.getBoundingClientRect();
if (!targetRect) {
return;
}
setBounds({
left: -targetRect.left + uiData.x,
right: clientWidth - (targetRect.right - uiData.x),
top: -targetRect.top + uiData.y,
bottom: clientHeight - (targetRect.bottom - uiData.y),
});
};
// 消费的列表
let consumptionColumns: any = [
{
title: "服务区名称",
width: 150,
dataIndex: "SERVERPART_NAME",
hideInSearch: true,
ellipsis: true,
align: 'center'
},
{
title: "门店名称",
width: 150,
dataIndex: "SHOPNAME",
hideInSearch: true,
ellipsis: true,
align: 'center'
},
{
title: "消费类型",
width: 120,
dataIndex: "CONSUMPTIONRECORD_TYPE",
hideInSearch: true,
ellipsis: true,
valueType: 'select',
valueEnum: CONSUMPTIONRECORDTYPEObj,
align: 'center'
},
{
title: "订单金额",
width: 120,
dataIndex: "CONSUME_AMOUNT",
hideInSearch: true,
valueType: 'digit',
ellipsis: true,
align: 'center'
},
{
title: "消费金额",
width: 120,
dataIndex: "CONSUME_PRICE",
hideInSearch: true,
valueType: 'digit',
ellipsis: true,
align: 'center'
},
{
title: "消费积分",
width: 120,
dataIndex: "CONSUME_SCORE",
hideInSearch: true,
valueType: 'digit',
ellipsis: true,
align: 'center'
},
{
title: "实付金额",
width: 120,
dataIndex: "PAY_AMOUNT",
hideInSearch: true,
valueType: 'digit',
ellipsis: true,
align: 'center'
},
{
title: "优惠金额",
width: 150,
dataIndex: "COUPON_AMOUNT",
hideInSearch: true,
ellipsis: true,
align: 'center'
},
{
title: "消费时间 ",
width: 150,
dataIndex: "CONSUMPTIONRECORD_DATE",
hideInSearch: true,
align: 'center',
render: (_, record) => {
return record?.CONSUMPTIONRECORD_DATE ? moment(record?.CONSUMPTIONRECORD_DATE).format('YYYY-MM-DD HH:mm:ss') : '-'
}
},
]
// 积分的列表
let PointColumns: any = [
{
title: "服务区名称",
width: 150,
dataIndex: "SERVERPART_NAME",
hideInSearch: true,
ellipsis: true,
align: 'center'
},
{
title: "门店名称",
width: 150,
dataIndex: "SHOPNAME",
hideInSearch: true,
ellipsis: true,
align: 'center'
},
{
title: "积分方式",
width: 120,
dataIndex: "POINT_TYPE",
hideInSearch: true,
ellipsis: true,
align: 'center',
valueType: 'select',
valueEnum: {
"1": "累计",
"-1": "消耗"
},
},
{
title: "积分来源",
width: 120,
dataIndex: "POINT_SOURCE",
hideInSearch: true,
ellipsis: true,
valueType: 'treeSelect',
align: 'center',
request: () => {
return SCORETYPETree
}
},
{
title: "本次积分",
width: 120,
dataIndex: "CURRENT_POINT",
hideInSearch: true,
ellipsis: true,
align: 'center',
valueType: "digit"
},
{
title: "累计积分",
width: 120,
dataIndex: "MEMBERSHIP_POINT",
hideInSearch: true,
ellipsis: true,
align: 'center',
valueType: "digit"
},
{
title: "获取时间",
width: 120,
dataIndex: "CREATE_DATE",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
]
// 成长值的列表
let GrowthValueColumns: any = [
{
title: "服务区名称",
width: 150,
dataIndex: "SERVERPART_NAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "门店名称",
width: 150,
dataIndex: "SHOPNAME",
hideInSearch: true,
align: 'center',
ellipsis: true,
},
{
title: "累计成长值",
width: 120,
dataIndex: "MEMBERSHIP_GROWTH",
hideInSearch: true,
ellipsis: true,
align: 'center',
valueType: 'digit'
},
{
title: "本次成长值",
width: 120,
dataIndex: "CURRENT_GROWTH",
hideInSearch: true,
ellipsis: true,
align: 'center',
valueType: 'digit'
},
{
title: "成长来源",
width: 120,
dataIndex: "GROWTH_SOURCE",
hideInSearch: true,
ellipsis: true,
valueType: 'treeSelect',
align: 'center',
request: () => {
return SCORETYPETree
}
},
{
title: "成长方式",
width: 120,
dataIndex: "GROWTH_TYPE",
hideInSearch: true,
align: 'center',
ellipsis: true,
valueType: 'select',
valueEnum: {
"1": "积累",
"-1": "消耗",
}
},
{
title: "操作时间",
width: 120,
dataIndex: "OPERATE_DATE",
align: 'center',
hideInSearch: true,
render: (_, record) => {
return record?.OPERATE_DATE ? moment(record?.OPERATE_DATE).format('YYYY-MM-DD') : "-"
}
},
]
useEffect(() => {
if (showDetailDrawer) {
setSelectTab(1)
}
}, [showDetailDrawer])
return (
<Modal
className="memberInfoDetailModal"
title={false}
closeIcon={<div></div>}
destroyOnClose={true}
width={1200}
visible={showDetailDrawer}
footer={false}
afterClose={() => {
modalRef.current?.resetFields();
// setCurrentRow(undefined);
}}
bodyStyle={{
maxHeight: '850px', // 你可以根据需要调整高度
overflowY: 'auto',
}}
onCancel={() => {
// setShowDetailDrawer(false)
// setCurrentRow(undefined);
}}
modalRender={(modal) => {
return <Draggable
disabled={disabled}
bounds={bounds}
onStart={(event, uiData) => onDraggaleStart(event, uiData)}
handle=".modalTop"
>
<div ref={draggleRef}>{modal}</div>
</Draggable>
}}
>
<ProForm
layout={'horizontal'}
formRef={modalRef}
submitter={false}
initialValues={currentRow ? {
...currentRow,
MEMBERSHIP_BIRTHDAY: currentRow?.MEMBERSHIP_BIRTHDAY ? moment(currentRow?.MEMBERSHIP_BIRTHDAY).format('YYYY-MM-DD') : '',
ADDTIME: currentRow?.ADDTIME ? moment(currentRow?.ADDTIME).format('YYYY-MM-DD') : '',
} : {}}
>
<div className="modalTop" style={{ position: 'fixed', background: '#fff', borderTopLeftRadius: "16px", borderTopRightRadius: "16px", zIndex: 999, borderBottom: '1px solid #D5D8DE' }}>
<div className="modalTopLeft">
<img className="memberIcon" src={memberInfoIcon} />
<span className="modalTitle"></span>
</div>
<div className="modalTopRight">
<img className="memberIcon" src={closeIcon} onClick={() => {
setSelectTab(0)
handleCloseModal()
}} />
</div>
</div>
<div className="topDetail" style={{ paddingTop: '90px' }}>
<div className="topDetailLeft">
<img className="headerImage" src={currentRow?.MEMBERSHIP_HEADIMAGEURL || "https://thirdwx.qlogo.cn/mmopen/vi_32/POgEwh4mIHO4nibH0KlMECNjjGxQUq24ZEaGT4poC6icRiccVGKSyXwibcPq4BWmiaIGuG1icwxaQX6grC9VemZoJ8rg/132"} />
</div>
<div className="topDetailRight">
<div className="topDetailRightTop">
<span className="detailName">{currentRow?.MEMBERSHIP_NAME || "-"}</span>
<span className="detailSex">{currentRow?.MEMBERSHIP_SEX === 1 ? '男' : currentRow?.MEMBERSHIP_SEX === 2 ? '女' : ''}</span>
{
currentRow?.MEMBERSHIP_TYPE && MEMBERSHIPTYPEYNObj && MEMBERSHIPTYPEYNObj[currentRow?.MEMBERSHIP_TYPE] ?
<span className="memberType">{MEMBERSHIPTYPEYNObj[currentRow?.MEMBERSHIP_TYPE]}</span> : ""
}
</div>
<div className="topDetailItem">
<Row gutter={8}>
<Col span={8} className="memberInfoDetailItem">
<ProFormSelect
name={"MEMBERSHIP_SEX"}
label={"性别"}
readonly
options={[{ label: "男", value: 1 }, { label: "女", value: 2 }, { label: "-", value: 0 }]}
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"CERTIFICATE_NUMBER"}
label={"身份证号"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_MOBILEPHONE"}
label={"联系电话"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"LICENSEPLATE_NUMBER"}
label={"车牌号"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_BIRTHDAY"}
label={"会员生日"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"ADDTIME"}
label={"注册时间"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
{/* <Col span={16} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_ADDRESS"}
label={"联系地址"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col> */}
</Row>
</div>
</div>
</div>
<div className="carNavBox">
<img className="carNavIcon" src={memberDetailIcon} />
<span className={selectTab === 1 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(1)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的详细信息`)
}}></span>
<span className={selectTab === 2 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(2)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的消费记录`)
}}></span>
<span className={selectTab === 3 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(3)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的成长值记录`)
}}></span>
<span className={selectTab === 4 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(4)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的积分记录`)
}}></span>
<span className={selectTab === 5 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(5)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的地址管理`)
}}></span>
<span className={selectTab === 6 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(6)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的活动轨迹`)
}}></span>
<span className={selectTab === 7 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(7)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的车牌管理`)
}}></span>
<span className={selectTab === 8 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(8)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的优惠券管理`)
}}></span>
<span className={selectTab === 9 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(9)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的收藏商品`)
}}></span>
<span className={selectTab === 10 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(10)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的商家评价`)
}}></span>
<span className={selectTab === 11 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(11)
handleSetlogSave(`查看了${currentRow?.MEMBERSHIP_NAME}的商城评价`)
}}></span>
</div>
<div className="bottomDetailBox" style={{ display: selectTab === 1 ? 'block' : "none" }}>
<Row gutter={8}>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_CARD"}
label={"会员卡号"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_CODE"}
label={"会员编码"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormSelect
name={"MEMBERSHIP_LEVEL"}
label={"会员等级"}
readonly
style={{ marginBottom: '16px' }}
options={[
...MEMBERSHIPLEVELYNList
]}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"ACCOUNT_BALANCE"}
label={"账户余额"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_POINT"}
label={"会员积分"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormSelect
name={"MEMBERSHIP_STATE"}
label={"会员状态"}
readonly
style={{ marginBottom: '16px' }}
options={COMPANY_STATEList}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormSelect
name={"ISPLUS"}
label={"付费会员"}
readonly
style={{ marginBottom: '16px' }}
options={[{ label: "是", value: 1 }, { label: "否", value: 0 }]}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"PLUS_EXPIRYDATE"}
label={"付费有效期"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"RECOMMEND_NAME"}
label={"推荐人"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
{/* <Col span={18} className="memberInfoDetailItem">
<ProFormText
name={"ADDTIME"}
label={"添加时间"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col> */}
<Col span={24} className="memberInfoDetailItem">
<ProFormTextArea
name={"MEMBERSHIP_DESC"}
label={"备注说明"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
</Row>
</div>
{/* 消费记录 */}
{
selectTab === 2 ? <ConsumptionRecordSearch isComponent={true} parentDetail={currentRow} /> : "-"
// selectTab === 2 ? <ProTable
// // headerTitle={<span style={{ color: "#1890ff", fontSize: 14, fontWeight: 600 }}>消费记录</span>}
// search={false}
// options={false}
// bordered
// columns={consumptionColumns}
// scroll={{ x: '100%', y: '350px' }}
// request={async (params: any) => {
// const req: any = {
// SearchParameter: {
// MEMBERSHIP_IDS: currentRow?.MEMBERSHIP_ID,
// PROVINCE_CODE: currentUser?.ProvinceCode || "",
// OWNERUNIT_ID: 911
// },
// PageIndex: params.current,
// PageSize: params?.pageSize,
// SortStr: "CONSUMPTIONRECORD_DATE desc"
// }
// const data = await handleGetCONSUMPTIONRECORDList(req)
// if (data.List && data.List.length > 0) {
// return { data: data.List, success: true, total: data.TotalCount }
// }
// return { data: [], success: true }
// }}
// pagination={{
// defaultPageSize: 20,
// showTotal: (total) => `共 ${total} 条记录`
// }}
// /> : ""
}
{/* 成长值记录 */}
{
selectTab === 3 ?
<GrowthValueRecordSearch isComponent={true} parentDetail={currentRow} /> : '-'
// <ProTable
// // headerTitle={<span style={{ color: "#1890ff", fontSize: 14, fontWeight: 600 }}>积分记录</span>}
// search={false}
// options={false}
// bordered
// scroll={{ x: '100%', y: '350px' }}
// columns={PointColumns}
// request={async (params: any) => {
// const req: any = {
// SearchParameter: {
// MEMBERSHIP_IDS: currentRow?.MEMBERSHIP_ID,
// PROVINCE_CODE: currentUser?.ProvinceCode || "",
// OWNERUNIT_ID: 911
// },
// PageIndex: params.current,
// PageSize: params?.pageSize,
// SortStr: "OPERATE_DATE desc"
// }
// const data = await handleGetPOINTRECORDList(req)
// console.log('22222', data);
// if (data.List && data.List.length > 0) {
// return { data: data.List, success: true, total: data.TotalCount }
// }
// return { data: [], success: true }
// }}
// pagination={{
// defaultPageSize: 20,
// showTotal: (total) => `共 ${total} 条记录`
// }}
// />
// : ""
}
{
selectTab === 4 ?
<PointsRecordSearch isComponent={true} parentDetail={currentRow} />
// <ProTable
// // headerTitle={<span style={{ color: "#1890ff", fontSize: 14, fontWeight: 600 }}>成长值记录</span>}
// search={false}
// options={false}
// bordered
// scroll={{ x: '100%', y: '350px' }}
// columns={GrowthValueColumns}
// request={async (params: any) => {
// const req: any = {
// SearchParameter: {
// MEMBERSHIP_IDS: currentRow?.MEMBERSHIP_ID,
// PROVINCE_CODE: currentUser?.ProvinceCode || "",
// OWNERUNIT_ID: 911
// },
// PageIndex: params.current,
// PageSize: params?.pageSize,
// SortStr: "OPERATE_DATE desc"
// }
// const data = await handleGetMEMBERGROWTHList(req)
// console.log('33333', data);
// if (data.List && data.List.length > 0) {
// return { data: data.List, success: true, total: data.TotalCount }
// }
// return { data: [], success: true }
// }}
// pagination={{
// defaultPageSize: 20,
// showTotal: (total) => `共 ${total} 条记录`
// }}
// />
: ''
}
{/* 地址管理 */}
{
selectTab === 5 ? <AddressDetail currentBigRow={currentRow} currentUser={currentUser} /> : ''
}
{/* 活动轨迹 */}
{
selectTab === 6 ? <RegistrationRetentionAnalysis isComponent={true} parentDetail={currentRow} /> : ""
}
{/* 车牌管理 */}
{
selectTab === 7 ? <LicensePlateManage parentDetail={currentRow} /> : ""
}
{/* 会员优惠券 */}
{
selectTab === 8 ? <MemberDiscounts parentDetail={currentRow} /> : ""
}
{/* 会员收藏 */}
{
selectTab === 9 ? <CollectProducts parentDetail={currentRow} /> : ""
}
{/* 商家评价 */}
{
selectTab === 10 ? <MerchantEvaluationManage isComponent={true} parentDetail={currentRow} /> : ""
}
{/* 商城评价 */}
{
selectTab === 11 ? <MallEvaluationManage isComponent={true} parentDetail={currentRow} /> : ""
}
</ProForm>
</Modal>
)
}
export default connect(({ user, }: ConnectState) => ({
currentUser: user.currentUser,
}))(MemberDetail);

View File

@ -0,0 +1,194 @@
.memberInfoDetailModal {
.react-draggable {
.ant-modal-content {
border-radius: 16px;
.ant-modal-body {
padding: 0;
height: 800px;
overflow-y: auto;
overflow: hidden;
.ant-form {
.modalTop {
width: 100%;
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1px solid #D5D8DE;
box-sizing: border-box;
padding-bottom: 10px;
box-sizing: border-box;
padding: 30px 20px;
.modalTopLeft {
display: flex;
align-items: center;
.memberIcon {
width: 18px;
height: 18px;
margin-right: 5px;
}
.modalTitle {
font-family: PingFangSC, PingFang SC;
font-weight: 600;
font-size: 18px;
color: rgba(0, 0, 0, 0.85);
line-height: 18px;
text-align: left;
font-style: normal;
}
}
.modalTopRight {
width: 18px;
height: 18px;
.memberIcon {
width: 18px;
height: 18px;
cursor: pointer;
}
}
}
.topDetail {
width: 100%;
display: flex;
box-sizing: border-box;
padding: 30px 28px;
.topDetailLeft {
width: 120px;
height: 120px;
margin-right: 28px;
.headerImage {
width: 120px;
height: 120px;
border-radius: 50%;
overflow: hidden;
}
}
.topDetailRight {
width: calc(100% - 148px);
height: 120px;
box-sizing: border-box;
padding: 8px 0;
.topDetailRightTop {
.detailName {
font-family: PingFangSC, PingFang SC;
font-weight: 600;
font-size: 20px;
color: #333333;
line-height: 14px;
text-align: left;
font-style: normal;
}
.detailSex {
font-family: PingFangSC, PingFang SC;
font-weight: 600;
font-size: 20px;
color: #333333;
line-height: 14px;
text-align: left;
font-style: normal;
margin-left: 8px;
}
.memberType {
font-family: PingFangSC, PingFang SC;
font-size: 14px;
color: #fff;
line-height: 14px;
text-align: left;
font-style: normal;
padding: 2px 8px;
background: linear-gradient(0deg, #A13B00 0%, #D7AB0E 100%);
border-radius: 4px;
}
}
.topDetailItem {
width: 100%;
margin-top: 16px;
.ant-row {
.memberInfoDetailItem {
.ant-form-item {
margin-bottom: 12px;
}
}
}
}
}
}
.carNavBox {
width: calc(100% - 42px);
background-color: #F3F4F8;
border-radius: 8px;
display: flex;
align-items: center;
margin-left: 21px;
box-sizing: border-box;
padding: 12px 16px;
margin-bottom: 12px;
.carNavIcon {
width: 30px;
height: 26px;
margin-right: 8px;
}
.carNavTitle {
font-family: PingFangSC, PingFang SC;
font-weight: 600;
font-size: 16px;
color: #333333;
line-height: 12px;
text-align: left;
font-style: normal;
padding: 0 10px;
cursor: pointer;
}
.selectCarNavTitle {
position: relative;
}
.selectCarNavTitle::after {
content: "";
position: absolute;
bottom: -10px;
left: 50%;
transform: translateX(-50%);
width: 2rem;
height: 2px;
background-color: #2B7CF0;
}
}
.bottomDetailBox {
width: calc(100% - 42px);
margin-left: 30px;
box-sizing: border-box;
margin-top: 26px;
}
}
}
.ant-modal-body::-webkit-scrollbar {
width: 0;
display: none;
}
}
}
}

View File

@ -19,11 +19,12 @@ import session from "@/utils/session";
import moment from 'moment' import moment from 'moment'
import Draggable from "react-draggable"; import Draggable from "react-draggable";
import ProForm, { ProFormSelect, ProFormText, ProFormTextArea } from "@ant-design/pro-form"; import ProForm, { ProFormSelect, ProFormText, ProFormTextArea } from "@ant-design/pro-form";
import './style.less'
import memberInfoIcon from '@/assets/detail/memberInfoIcon.png' import memberInfoIcon from '@/assets/detail/memberInfoIcon.png'
import closeIcon from '@/assets/detail/closeIcon.png' import closeIcon from '@/assets/detail/closeIcon.png'
import memberDetailIcon from '@/assets/detail/memberDetailIcon.png' import memberDetailIcon from '@/assets/detail/memberDetailIcon.png'
import AddressDetail from "../MemberAddress/components/addressDetail"; import AddressDetail from "../MemberAddress/components/addressDetail";
import { handleSetlogSave } from "@/utils/format";
import MemberDetail from "./component/memberDetail";
@ -41,7 +42,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
const [printIndex, setPrintIndex] = useState<number>(new Date().getTime()) const [printIndex, setPrintIndex] = useState<number>(new Date().getTime())
let MEMBERSHIP_TYPEObj = session.get('MEMBERSHIP_TYPEObj'); let MEMBERSHIPTYPEYNObj = session.get('MEMBERSHIPTYPEYNObj');
let MEMBERSHIP_LEVELList = session.get('MEMBERSHIP_LEVELList'); let MEMBERSHIP_LEVELList = session.get('MEMBERSHIP_LEVELList');
let COMPANY_STATEObj = session.get('COMPANY_STATEObj'); let COMPANY_STATEObj = session.get('COMPANY_STATEObj');
let COMPANY_STATEList = session.get('COMPANY_STATEList'); let COMPANY_STATEList = session.get('COMPANY_STATEList');
@ -106,6 +107,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
return <a onClick={() => { return <a onClick={() => {
setCurrentRow(record) setCurrentRow(record)
setShowDetailDrawer(true) setShowDetailDrawer(true)
handleSetlogSave(`查看了${record?.MEMBERSHIP_NAME}${record?.MEMBERSHIP_ID}】的会员信息`)
}}> }}>
{record?.MEMBERSHIP_NAME || ""} {record?.MEMBERSHIP_NAME || ""}
</a> </a>
@ -123,10 +125,9 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
align: 'center', align: 'center',
valueType: 'select', valueType: 'select',
valueEnum: { valueEnum: {
...MEMBERSHIP_TYPEObj, ...MEMBERSHIPTYPEYNObj,
0: '全部'
}, },
initialValue: "0" // initialValue: "0"
}, },
{ {
title: "会员类型", title: "会员类型",
@ -137,8 +138,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
align: 'center', align: 'center',
valueType: 'select', valueType: 'select',
valueEnum: { valueEnum: {
...MEMBERSHIP_TYPEObj, ...MEMBERSHIPTYPEYNObj,
0: '-'
}, },
}, },
{ {
@ -235,7 +235,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
align: 'center', align: 'center',
valueType: 'select', valueType: 'select',
valueEnum: MEMBERSHIPLEVELYNObj, valueEnum: MEMBERSHIPLEVELYNObj,
initialValue: "0" // initialValue: "0"
}, },
{ {
title: "会员积分", title: "会员积分",
@ -672,7 +672,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
SearchParameter: { SearchParameter: {
PROVINCE_CODE: currentUser?.ProvinceCode || "", PROVINCE_CODE: currentUser?.ProvinceCode || "",
OWNERUNIT_ID: 911, OWNERUNIT_ID: 911,
MEMBERSHIP_TYPE: params?.MEMBERSHIP_TYPE === "0" ? "" : params?.MEMBERSHIP_TYPE, MEMBERSHIP_TYPE: params?.MEMBERSHIP_TYPE === "0" ? "0" : params?.MEMBERSHIP_TYPE,
MEMBERSHIP_LEVEL: params?.MEMBERSHIP_LEVEL === "0" ? "" : params?.MEMBERSHIP_LEVEL, MEMBERSHIP_LEVEL: params?.MEMBERSHIP_LEVEL === "0" ? "" : params?.MEMBERSHIP_LEVEL,
MEMBERSHIP_STATE: params?.MEMBERSHIP_STATE MEMBERSHIP_STATE: params?.MEMBERSHIP_STATE
}, },
@ -685,6 +685,9 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
sortstr: sortstr.length ? sortstr.toString() : "", sortstr: sortstr.length ? sortstr.toString() : "",
} }
setSearchParams(params) setSearchParams(params)
handleSetlogSave(`查看了会员账户管理列表`)
const data = await handleGetMEMBERSHIPList(req) const data = await handleGetMEMBERSHIPList(req)
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
@ -717,390 +720,11 @@ const memberInfor: React.FC<{ currentUser: CurrentUser }> = (props) => {
</div> </div>
</div> </div>
<Modal {/* 会员详情 */}
className="memberInfoDetailModal" <MemberDetail showDetailDrawer={showDetailDrawer}
title={false} currentRow={currentRow}
// title={ handleCloseModal={handleCloseModal}
// <div currentUser={currentUser} />
// className="modal-drag-title"
// style={{
// width: '100%',
// cursor: 'move',
// }}
// onMouseOver={() => {
// if (disabled) {
// setDraggleDisabled(false)
// }
// }}
// onMouseOut={() => {
// setDraggleDisabled(true)
// }}
// onFocus={() => { }}
// onBlur={() => { }}
// >
// {'会员详情'}
// </div>
// }
closeIcon={<div></div>}
destroyOnClose={true}
width={1200}
visible={showDetailDrawer}
footer={false}
afterClose={() => {
modalRef.current?.resetFields();
setCurrentRow(undefined);
}}
bodyStyle={{
maxHeight: '700px', // 你可以根据需要调整高度
overflowY: 'auto',
}}
onCancel={() => {
setShowDetailDrawer(false)
setCurrentRow(undefined);
}}
modalRender={(modal) => {
return <Draggable
disabled={disabled}
bounds={bounds}
onStart={(event, uiData) => onDraggaleStart(event, uiData)}
handle=".modalTop"
>
<div ref={draggleRef}>{modal}</div>
</Draggable>
}}
>
<ProForm
layout={'horizontal'}
formRef={modalRef}
submitter={false}
initialValues={currentRow ? {
...currentRow,
MEMBERSHIP_BIRTHDAY: currentRow?.MEMBERSHIP_BIRTHDAY ? moment(currentRow?.MEMBERSHIP_BIRTHDAY).format('YYYY-MM-DD') : '',
ADDTIME: currentRow?.ADDTIME ? moment(currentRow?.ADDTIME).format('YYYY-MM-DD') : '',
} : {}}
>
<div className="modalTop" style={{ position: 'fixed', background: '#fff', borderTopLeftRadius: "16px", borderTopRightRadius: "16px", zIndex: 999, borderBottom: '1px solid #D5D8DE' }}>
<div className="modalTopLeft">
<img className="memberIcon" src={memberInfoIcon} />
<span className="modalTitle"></span>
</div>
<div className="modalTopRight">
<img className="memberIcon" src={closeIcon} onClick={() => {
handleCloseModal()
}} />
</div>
</div>
<div className="topDetail" style={{ paddingTop: '90px' }}>
<div className="topDetailLeft">
<img className="headerImage" src={currentRow?.MEMBERSHIP_HEADIMAGEURL || "https://thirdwx.qlogo.cn/mmopen/vi_32/POgEwh4mIHO4nibH0KlMECNjjGxQUq24ZEaGT4poC6icRiccVGKSyXwibcPq4BWmiaIGuG1icwxaQX6grC9VemZoJ8rg/132"} />
</div>
<div className="topDetailRight">
<div className="topDetailRightTop">
<span className="detailName">{currentRow?.MEMBERSHIP_NAME || "-"}</span>
<span className="detailSex">{currentRow?.MEMBERSHIP_SEX === 1 ? '男' : currentRow?.MEMBERSHIP_SEX === 2 ? '女' : ''}</span>
{
currentRow?.MEMBERSHIP_TYPE && MEMBERSHIP_TYPEObj && MEMBERSHIP_TYPEObj[currentRow?.MEMBERSHIP_TYPE] ?
<span className="memberType">{MEMBERSHIP_TYPEObj[currentRow?.MEMBERSHIP_TYPE]}</span> : ""
}
</div>
<div className="topDetailItem">
<Row gutter={8}>
<Col span={8} className="memberInfoDetailItem">
<ProFormSelect
name={"MEMBERSHIP_SEX"}
label={"性别"}
readonly
options={[{ label: "男", value: 1 }, { label: "女", value: 2 }, { label: "-", value: 0 }]}
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"CERTIFICATE_NUMBER"}
label={"身份证号"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_MOBILEPHONE"}
label={"联系电话"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"LICENSEPLATE_NUMBER"}
label={"车牌号"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_BIRTHDAY"}
label={"会员生日"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={8} className="memberInfoDetailItem">
<ProFormText
name={"ADDTIME"}
label={"注册时间"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
{/* <Col span={16} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_ADDRESS"}
label={"联系地址"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col> */}
</Row>
</div>
</div>
</div>
<div className="carNavBox">
<img className="carNavIcon" src={memberDetailIcon} />
<span className={selectTab === 1 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(1)
}}></span>
<span className={selectTab === 2 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(2)
}}></span>
<span className={selectTab === 3 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(3)
}}></span>
<span className={selectTab === 4 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(4)
}}></span>
<span className={selectTab === 5 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
setSelectTab(5)
}}></span>
</div>
<div className="bottomDetailBox" style={{ display: selectTab === 1 ? 'block' : "none" }}>
<Row gutter={8}>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_CARD"}
label={"会员卡号"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_CODE"}
label={"会员编码"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormSelect
name={"MEMBERSHIP_LEVEL"}
label={"会员等级"}
readonly
style={{ marginBottom: '16px' }}
options={[
...MEMBERSHIP_LEVELList,
{ label: "VIP会员", value: 9000 }
]}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"ACCOUNT_BALANCE"}
label={"账户余额"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"MEMBERSHIP_POINT"}
label={"会员积分"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormSelect
name={"MEMBERSHIP_STATE"}
label={"会员状态"}
readonly
style={{ marginBottom: '16px' }}
options={COMPANY_STATEList}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormSelect
name={"ISPLUS"}
label={"付费会员"}
readonly
style={{ marginBottom: '16px' }}
options={[{ label: "是", value: 1 }, { label: "否", value: 0 }]}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"PLUS_EXPIRYDATE"}
label={"付费有效期"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
<Col span={6} className="memberInfoDetailItem">
<ProFormText
name={"RECOMMEND_NAME"}
label={"推荐人"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
{/* <Col span={18} className="memberInfoDetailItem">
<ProFormText
name={"ADDTIME"}
label={"添加时间"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col> */}
<Col span={24} className="memberInfoDetailItem">
<ProFormTextArea
name={"MEMBERSHIP_DESC"}
label={"备注说明"}
readonly
style={{ marginBottom: '16px' }}
/>
</Col>
</Row>
</div>
{
selectTab === 2 ? <ProTable
// headerTitle={<span style={{ color: "#1890ff", fontSize: 14, fontWeight: 600 }}>消费记录</span>}
search={false}
options={false}
bordered
columns={consumptionColumns}
scroll={{ x: '100%', y: '350px' }}
request={async (params: any) => {
const req: any = {
SearchParameter: {
MEMBERSHIP_IDS: currentRow?.MEMBERSHIP_ID,
PROVINCE_CODE: currentUser?.ProvinceCode || "",
OWNERUNIT_ID: 911
},
PageIndex: params.current,
PageSize: params?.pageSize,
SortStr: "CONSUMPTIONRECORD_DATE desc"
}
const data = await handleGetCONSUMPTIONRECORDList(req)
if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount }
}
return { data: [], success: true }
}}
pagination={{
defaultPageSize: 20,
showTotal: (total) => `${total} 条记录`
}}
/> : ""
}
{
selectTab === 3 ?
<ProTable
// headerTitle={<span style={{ color: "#1890ff", fontSize: 14, fontWeight: 600 }}>积分记录</span>}
search={false}
options={false}
bordered
scroll={{ x: '100%', y: '350px' }}
columns={PointColumns}
request={async (params: any) => {
const req: any = {
SearchParameter: {
MEMBERSHIP_IDS: currentRow?.MEMBERSHIP_ID,
PROVINCE_CODE: currentUser?.ProvinceCode || "",
OWNERUNIT_ID: 911
},
PageIndex: params.current,
PageSize: params?.pageSize,
SortStr: "OPERATE_DATE desc"
}
const data = await handleGetPOINTRECORDList(req)
console.log('22222', data);
if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount }
}
return { data: [], success: true }
}}
pagination={{
defaultPageSize: 20,
showTotal: (total) => `${total} 条记录`
}}
/>
: ""
}
{
selectTab === 4 ?
<ProTable
// headerTitle={<span style={{ color: "#1890ff", fontSize: 14, fontWeight: 600 }}>成长值记录</span>}
search={false}
options={false}
bordered
scroll={{ x: '100%', y: '350px' }}
columns={GrowthValueColumns}
request={async (params: any) => {
const req: any = {
SearchParameter: {
MEMBERSHIP_IDS: currentRow?.MEMBERSHIP_ID,
PROVINCE_CODE: currentUser?.ProvinceCode || "",
OWNERUNIT_ID: 911
},
PageIndex: params.current,
PageSize: params?.pageSize,
SortStr: "OPERATE_DATE desc"
}
const data = await handleGetMEMBERGROWTHList(req)
console.log('33333', data);
if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount }
}
return { data: [], success: true }
}}
pagination={{
defaultPageSize: 20,
showTotal: (total) => `${total} 条记录`
}}
/>
: ''
}
{
selectTab === 5 ? <AddressDetail currentBigRow={currentRow} currentUser={currentUser} /> : ''
}
</ProForm>
</Modal>
{/* <Drawer {/* <Drawer
width={'80%'} width={'80%'}

View File

@ -26,6 +26,7 @@ import { handeDeleteSCENICAREA, handeGetSCENICAREAList, handeSynchroSCENICAREA }
import session from '@/utils/session'; import session from '@/utils/session';
import { deletePicture, uploadPicture } from '@/services/picture'; import { deletePicture, uploadPicture } from '@/services/picture';
import ModalFooter from './component/modalFooter'; import ModalFooter from './component/modalFooter';
import { handleSetlogSave } from '@/utils/format';
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
@ -291,8 +292,10 @@ const scenicSpotConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
if (result.Result_Code !== 100) { if (result.Result_Code !== 100) {
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`); message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
handleSetlogSave(`删除【${currentRow?.SCENICAREA_NAME}】信息失败`)
} else { } else {
message.success('删除成功!'); message.success('删除成功!');
handleSetlogSave(`删除【${currentRow?.SCENICAREA_NAME}】信息成功`)
handleConfirmLoading(false) handleConfirmLoading(false)
handleModalVisible(false) handleModalVisible(false)
setFileList([]) setFileList([])
@ -313,7 +316,7 @@ const scenicSpotConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
}) })
} }
if (currentRow?.USERDEFINEDTYPE_ID) { if (currentRow?.SCENICAREA_ID) {
req = { req = {
...currentRow, ...currentRow,
...res, ...res,
@ -350,7 +353,10 @@ const scenicSpotConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
console.log('formData', formData); console.log('formData', formData);
await uploadPicture(formData) await uploadPicture(formData)
} }
message.success("新增成功!")
handleSetlogSave(`${currentRow?.SCENICAREA_ID ? `更新${currentRow?.SCENICAREA_NAME}景区` : `新增${data.Result_Data.SCENICAREA_NAME}`}信息`)
message.success("更新成功!")
setCurrentRow(undefined) setCurrentRow(undefined)
formRef?.current?.resetFields() formRef?.current?.resetFields()
handleModalVisible(false) handleModalVisible(false)
@ -396,6 +402,9 @@ const scenicSpotConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
} }
const data = await handeGetSCENICAREAList(req); const data = await handeGetSCENICAREAList(req);
console.log('datadatadatadatadata', data); console.log('datadatadatadatadata', data);
handleSetlogSave(`查看了景区信息配置列表`)
if (data.List && data.List.length > 0) { if (data.List && data.List.length > 0) {
return { data: data.List, success: true, total: data.TotalCount } return { data: data.List, success: true, total: data.TotalCount }
} }

View File

@ -42,7 +42,7 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
// 片区的tab // 片区的tab
const [areaTabList, setAreaTabList] = useState<any>() const [areaTabList, setAreaTabList] = useState<any>()
// 选择的tab // 选择的tab
const [selectTab, setSelectTab] = useState<any>() const [selectTab, setSelectTab] = useState<any>('基础信息')
const shopregionObj: any = session.get('shopregionObj') const shopregionObj: any = session.get('shopregionObj')
const LOADBEARINGList = session.get('LOADBEARINGList') const LOADBEARINGList = session.get('LOADBEARINGList')
@ -87,20 +87,20 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
if (list && list.length > 0) { if (list && list.length > 0) {
const obj: any = session.get('shopregionObj') const obj: any = session.get('shopregionObj')
const res: any = [] const res: any = [{ label: "基础信息", key: '基础信息' }]
list.forEach((item: any, index: number) => { list.forEach((item: any, index: number) => {
if (item.SERVERPART_REGION) { if (item.SERVERPART_REGION) {
res.push({ label: obj[item.SERVERPART_REGION], value: item.SERVERPART_REGION.toString(), key: item.SERVERPART_REGION.toString() }) res.push({ label: obj[item.SERVERPART_REGION], value: item.SERVERPART_REGION.toString(), key: item.SERVERPART_REGION.toString() })
if (index === 0) { if (index === 0) {
setSelectTab(item.SERVERPART_REGION.toString()) // setSelectTab(item.SERVERPART_REGION.toString())
} }
} }
}) })
console.log('resresresres', res); console.log('resresresres', res);
setSelectTab('基础信息');
setAreaTabList(res) setAreaTabList(res)
} else { } else {
setAreaTabList([]) setAreaTabList([{ label: "基础信息", key: '基础信息' }])
setSelectTab(null) setSelectTab(null)
} }
} }
@ -113,7 +113,8 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
useEffect(() => { useEffect(() => {
// 确保 areaTabList 更新后selectTab 也正确设置 // 确保 areaTabList 更新后selectTab 也正确设置
if (areaTabList && areaTabList.length > 0 && !selectTab) { if (areaTabList && areaTabList.length > 0 && !selectTab) {
setSelectTab(areaTabList[0].key); // setSelectTab(areaTabList[0].key);
setSelectTab('基础信息');
} }
}, [areaTabList, selectTab]); }, [areaTabList, selectTab]);
@ -247,6 +248,7 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
</Row> </Row>
</div> </div>
<div style={{ display: selectTab === '基础信息' ? 'block' : 'none' }}>
<Divider orientation="left"></Divider> <Divider orientation="left"></Divider>
<Row> <Row>
<Col span={8}> <Col span={8}>
@ -383,8 +385,6 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
/> />
</Col> </Col>
</Row> </Row>
<Divider orientation="left"></Divider> <Divider orientation="left"></Divider>
<Row> <Row>
<Col span={8}> <Col span={8}>
@ -406,10 +406,11 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
/> />
</Col> </Col>
</Row> </Row>
</div>
<div style={{ width: '100%', boxSizing: 'border-box', padding: '0 48px', fontSize: '16px', fontWeight: 600 }}>{shopregionObj[selectTab] || ""}</div> <div style={{ width: '100%', boxSizing: 'border-box', padding: '0 48px', fontSize: '16px', fontWeight: 600 }}>{shopregionObj[selectTab] || ""}</div>
<div style={{ display: areaTabList && areaTabList.length > 0 && selectTab === areaTabList[0].key ? 'block' : 'none' }}> <div style={{ display: areaTabList && areaTabList.length > 0 && selectTab === areaTabList[1].key ? 'block' : 'none' }}>
<Divider orientation="left"></Divider> <Divider orientation="left"></Divider>
<Row> <Row>
<Col span={8}> <Col span={8}>
@ -665,7 +666,7 @@ const SERVERPARTTable = ({ currentRow, onShow, onRef, pageType }: DetailProps) =
</Row> </Row>
</div> </div>
<div style={{ display: areaTabList && areaTabList.length > 1 && selectTab === areaTabList[1].key ? 'block' : 'none' }}> <div style={{ display: areaTabList && areaTabList.length > 1 && selectTab === areaTabList[2].key ? 'block' : 'none' }}>
{/* <Divider orientation="left">对向信息</Divider> */} {/* <Divider orientation="left">对向信息</Divider> */}
<div style={{ display: 'none' }}> <div style={{ display: 'none' }}>
<Row> <Row>

View File

@ -22,6 +22,7 @@ import Draggable from "react-draggable";
import searchIcon from '@/assets/ai/searchIcon.png' import searchIcon from '@/assets/ai/searchIcon.png'
import close from '@/assets/ai/close.png' import close from '@/assets/ai/close.png'
import './style.less' import './style.less'
import { handleSetlogSave } from "@/utils/format";
const beforeUpload = (file: any) => { const beforeUpload = (file: any) => {
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png'; const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
@ -137,6 +138,11 @@ const serverpartInfo: React.FC<{ currentUser: CurrentUser }> = (props) => {
setSelectedId('') setSelectedId('')
setCurrenRegion('') setCurrenRegion('')
console.log('value', value);
let serverpartObj = session.get('serverpartObj')
handleSetlogSave(`${serverpartObj && value && serverpartObj[value] ? `查看了${serverpartObj[value]}基础信息` : ""}`)
// 只有修改服务区的时候 触发刷新 // 只有修改服务区的时候 触发刷新
setShowRightForm(false) setShowRightForm(false)
setTimeout(() => { setTimeout(() => {
@ -302,6 +308,8 @@ const serverpartInfo: React.FC<{ currentUser: CurrentUser }> = (props) => {
const data = await handleSynchroSERVERPART(req) const data = await handleSynchroSERVERPART(req)
let serverpartObj = session.get('serverpartObj')
handleSetlogSave(`${serverpartObj && currenMenu && serverpartObj[currenMenu] ? `保存${serverpartObj[currenMenu]}的基础信息` : ""}`)
if (res.carryingCapacity) { if (res.carryingCapacity) {
let carryReq: any = {} let carryReq: any = {}
@ -658,6 +666,7 @@ const serverpartInfo: React.FC<{ currentUser: CurrentUser }> = (props) => {
<Button type={'primary'} style={{ marginRight: '8px' }} onClick={() => { <Button type={'primary'} style={{ marginRight: '8px' }} onClick={() => {
setShowType(0) setShowType(0)
setShowUploadImgModal(true) setShowUploadImgModal(true)
handleSetlogSave(`点击服务区设施图片上传`)
}}></Button> }}></Button>
{/* <Button type={'primary'} style={{ marginRight: '8px' }} onClick={() => { {/* <Button type={'primary'} style={{ marginRight: '8px' }} onClick={() => {
@ -770,8 +779,10 @@ const serverpartInfo: React.FC<{ currentUser: CurrentUser }> = (props) => {
console.log('formData', formData); console.log('formData', formData);
let res = await uploadPicture(formData) let res = await uploadPicture(formData)
console.log('resresresres', res); console.log('resresresres', res);
let serverpartObj = session.get('serverpartObj')
if (res.Result_Code === 100) { if (res.Result_Code === 100) {
message.success("上传成功!") message.success("上传成功!")
handleSetlogSave(`更新【${serverpartObj && currenMenu && serverpartObj[currenMenu] ? `保存${serverpartObj[currenMenu]}的基础信息` : ""}${selectActiveKey === '1' ? '服务区图片' : selectActiveKey === '2' ? '母婴室图片' : selectActiveKey === '3' ? '司机之家图片' : selectActiveKey === '4' ? '住宿客房图片' : selectActiveKey === '5' ? '便利店图片' : ''}】成功`)
setConfirmLoading(false) setConfirmLoading(false)
setShowType(0) setShowType(0)
setShowUploadImgModal(false); setShowUploadImgModal(false);
@ -783,6 +794,7 @@ const serverpartInfo: React.FC<{ currentUser: CurrentUser }> = (props) => {
}, 1000) }, 1000)
} else { } else {
message.error(res.Result_Desc) message.error(res.Result_Desc)
handleSetlogSave(`更新【${serverpartObj && currenMenu && serverpartObj[currenMenu] ? `保存${serverpartObj[currenMenu]}的基础信息` : ""}${selectActiveKey === '1' ? '服务区图片' : selectActiveKey === '2' ? '母婴室图片' : selectActiveKey === '3' ? '司机之家图片' : selectActiveKey === '4' ? '住宿客房图片' : selectActiveKey === '5' ? '便利店图片' : ''}】失败`)
} }
} else { } else {
setConfirmLoading(false) setConfirmLoading(false)

View File

@ -824,3 +824,40 @@ export async function handeGetPointGrowthSummary(params: any) {
return data.Result_Data.List return data.Result_Data.List
} }
// 获取会员即车牌信息
export async function handeGetMemberShipLicenseList(params: any) {
const data = await requestEncryption(`/Member/GetMemberShipLicenseList`, {
method: 'POST',
data: { ...params, requestEncryption: true }
})
if (data.Result_Code !== 100) {
return data
}
return data.Result_Data.List
}
// 获取会员优惠券表列表
export async function handeGetCOUPON_SENDList(params: any) {
const data = await requestEncryption(`/Coupon/GetCOUPON_SENDList`, {
method: 'POST',
data: { ...params, requestEncryption: true }
})
if (data.Result_Code !== 100) {
return data
}
return data.Result_Data.List
}
// 用户收藏的商品
export async function handeGetCommodityCollectionList(params: any) {
const data = await requestEncryption(`/Member/GetCommodityCollectionList`, {
method: 'POST',
data: { ...params, requestEncryption: true }
})
if (data.Result_Code !== 100) {
return data
}
return data.Result_Data.List
}

View File

@ -510,17 +510,24 @@ export const secondsToHuman = (seconds: number) => {
// 封装一个只要传入操作事项的就可以记录日志 // 封装一个只要传入操作事项的就可以记录日志
export const handleSetlogSave = async (str: string) => { export const handleSetlogSave = async (str?: string) => {
const currentUser = session.get('currentUser') const currentUser = session.get('currentUser')
const basicInfo = session.get('basicInfo') const basicInfo = session.get('basicInfo')
const browserVersion = session.get('browserVersion') const browserVersion = session.get('browserVersion')
const systemBasin = session.get('systemBasin') const systemBasin = session.get('systemBasin')
let nowMenu = session.get("currentMenu")
synchroBehaviorRecord({ synchroBehaviorRecord({
USER_ID: currentUser?.ID, USER_ID: currentUser?.ID,
USER_NAME: currentUser?.Name, USER_NAME: currentUser?.Name,
BEHAVIORRECORD_TYPE: "2000", BEHAVIORRECORD_TYPE: "2000",
BEHAVIORRECORD_EXPLAIN: str, BEHAVIORRECORD_EXPLAIN: str || "",
BEHAVIORRECORD_ROUT: nowMenu.pathname,
BEHAVIORRECORD_ROUTNAME: nowMenu.name,
BEHAVIORRECORD_TIME: moment().format('YYYY-MM-DD HH:mm:ss'),
// REQUEST_INFO: str || "",
OWNERUNIT_ID: currentUser?.OwnerUnitId, OWNERUNIT_ID: currentUser?.OwnerUnitId,
OWNERUNIT_NAME: currentUser?.OwnerUnitName, OWNERUNIT_NAME: currentUser?.OwnerUnitName,
BUSINESSMAN_ID: currentUser?.BUSINESSMAN_ID, BUSINESSMAN_ID: currentUser?.BUSINESSMAN_ID,