update
This commit is contained in:
parent
16b1153c4c
commit
158052ef6e
@ -1,11 +1,11 @@
|
||||
{
|
||||
"name": "ant-design-pro",
|
||||
"version": "4.5.0",
|
||||
"version": "4.5.8",
|
||||
"private": true,
|
||||
"description": "An out-of-box UI solution for enterprise applications",
|
||||
"scripts": {
|
||||
"analyze": "cross-env ANALYZE=1 umi build",
|
||||
"build": "umi build",
|
||||
"build": "node script/writeVersion.js && umi build",
|
||||
"deploy": "npm run site && npm run gh-pages",
|
||||
"dev": "npm run start:dev",
|
||||
"fetch:blocks": "pro fetch-blocks && npm run prettier",
|
||||
|
||||
26
script/writeVersion.js
Normal file
26
script/writeVersion.js
Normal file
@ -0,0 +1,26 @@
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
const child_process = require('child_process');
|
||||
|
||||
const pkgPath = path.resolve(__dirname, '../package.json');
|
||||
const pkg = require(pkgPath);
|
||||
|
||||
// 自动递增版本号
|
||||
const [major, minor, patch] = pkg.version.split('.').map(Number);
|
||||
const newVersion = `${major}.${minor}.${patch + 1}`;
|
||||
pkg.version = newVersion;
|
||||
fs.writeFileSync(pkgPath, JSON.stringify(pkg, null, 2));
|
||||
|
||||
// 获取 Git hash 和构建时间
|
||||
const gitHash = child_process.execSync('git rev-parse --short HEAD').toString().trim();
|
||||
const buildTime = new Date().toISOString();
|
||||
|
||||
// 写入 src/versionEnv.ts
|
||||
const content = `// 由 scripts/writeVersion.js 自动生成
|
||||
export const VERSION = "${newVersion}";
|
||||
export const GIT_HASH = "${gitHash}";
|
||||
export const BUILD_TIME = "${buildTime}";
|
||||
`;
|
||||
|
||||
fs.writeFileSync(path.resolve(__dirname, '../src/versionEnv.ts'), content);
|
||||
console.log('✅ 自动写入 src/versionEnv.ts 完成');
|
||||
@ -13,10 +13,10 @@ import { DefaultFooter, getMenuData, getPageTitle } from '@ant-design/pro-layout
|
||||
import { Helmet, HelmetProvider } from 'react-helmet-async';
|
||||
import type { ConnectProps } from 'umi';
|
||||
import { Link, useIntl, connect } from 'umi';
|
||||
import React from 'react';
|
||||
import React, { useEffect } from 'react';
|
||||
import type { ConnectState } from '@/models/connect';
|
||||
import logo from '../assets/logo.png';
|
||||
|
||||
import { VERSION, BUILD_TIME, GIT_HASH } from '../versionEnv';
|
||||
import styles from './UserLayout.less';
|
||||
|
||||
export type UserLayoutProps = {
|
||||
@ -44,6 +44,7 @@ const UserLayout: React.FC<UserLayoutProps> = (props) => {
|
||||
breadcrumb,
|
||||
...props,
|
||||
});
|
||||
|
||||
return (
|
||||
<HelmetProvider>
|
||||
<Helmet>
|
||||
@ -63,7 +64,8 @@ const UserLayout: React.FC<UserLayoutProps> = (props) => {
|
||||
{children}
|
||||
</div>
|
||||
<DefaultFooter
|
||||
copyright={`Copyright © 2013-${new Date().getFullYear()} Eshang Cloud. All Rights Reserved. 驿商云 版权所有`}
|
||||
copyright={`Copyright © 2013-${new Date().getFullYear()} Eshang Cloud. All Rights Reserved. 驿商云 版权所有 V${VERSION || ''}`}
|
||||
// copyright={`Copyright © 2013-${new Date().getFullYear()} Eshang Cloud. All Rights Reserved. 驿商云 版权所有 V6.6.6`}
|
||||
links={[]}
|
||||
/>
|
||||
</div>
|
||||
|
||||
@ -22,6 +22,7 @@ import { handleSetlogSave } from "@/utils/format";
|
||||
import moment from 'moment'
|
||||
import { uploadPicture } from "@/services/picture";
|
||||
import ModalFooter from "@/pages/travelMember/scenicSpotConfig/component/modalFooter";
|
||||
import { handeGetWECHATAPPSIGNList } from "@/pages/travelMember/service";
|
||||
|
||||
const beforeUpload = (file: any) => {
|
||||
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
|
||||
@ -71,6 +72,9 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
|
||||
// 文件列表
|
||||
const [fileList, setFileList] = useState<any>([])
|
||||
const [imagePreviewVisible, setImagePreviewVisible] = useState<boolean>(false) // 预览图片
|
||||
// 小程序列表数据
|
||||
const [wxMinList, setWxMinList] = useState<any>([])
|
||||
|
||||
|
||||
// 预览上传后的图片
|
||||
const handlePreview = async () => {
|
||||
@ -214,6 +218,21 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
|
||||
// 同步的方法
|
||||
const handleSynchroCOUPON = async (res: any) => {
|
||||
let req: any = {}
|
||||
let minDetail: any = {}
|
||||
if (wxMinList && wxMinList.length > 0 && res.WECHATAPPSIGN_ID) {
|
||||
|
||||
let filterObj: any = wxMinList.filter((n: any) => n.WECHATAPPSIGN_ID === res.WECHATAPPSIGN_ID)
|
||||
|
||||
if (filterObj && filterObj.length > 0) {
|
||||
let obj = filterObj[0]
|
||||
minDetail = {
|
||||
WECHATAPPSIGN_ID: obj.WECHATAPPSIGN_ID,
|
||||
WECHATAPPSIGN_NAME: obj.WECHATAPPSIGN_NAME,
|
||||
WECHATAPP_APPID: obj.WECHATAPP_APPID
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (currentRow?.COUPON_ID) {
|
||||
req = {
|
||||
...currentRow,
|
||||
@ -226,6 +245,7 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
|
||||
UPDATE_STAFF_NAME: currentUser?.Name,
|
||||
UPDATE_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
COUPON_IMAGEURL: fileList && fileList.length > 0 ? fileList[0].url : "",
|
||||
...minDetail
|
||||
}
|
||||
} else {
|
||||
req = {
|
||||
@ -238,6 +258,7 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
|
||||
CREATE_STAFF_ID: currentUser?.ID,
|
||||
CREATE_STAFF_NAME: currentUser?.Name,
|
||||
CREATE_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
...minDetail
|
||||
}
|
||||
}
|
||||
|
||||
@ -708,10 +729,27 @@ const CardInformationManager: React.FC<{ currentUser: CurrentUser }> = (props) =
|
||||
<ProFormSelect
|
||||
label={"小程序"}
|
||||
name={"WECHATAPPSIGN_ID"}
|
||||
options={[
|
||||
{ label: "彩云驿", value: 37 },
|
||||
{ label: "彩云驿商城", value: 38 },
|
||||
]}
|
||||
request={async () => {
|
||||
const req: any = {
|
||||
SearchParameter: {
|
||||
OWNERUNIT_ID: 911,
|
||||
}
|
||||
}
|
||||
const data = await handeGetWECHATAPPSIGNList(req)
|
||||
console.log('datadatadatadata', data);
|
||||
setWxMinList(data || [])
|
||||
let list: any = []
|
||||
if (data && data.length > 0) {
|
||||
data.forEach((item: any) => {
|
||||
list.push({ label: item.WECHATAPPSIGN_NAME, value: item.WECHATAPPSIGN_ID })
|
||||
})
|
||||
}
|
||||
return list
|
||||
}}
|
||||
// options={[
|
||||
// { label: "彩云驿", value: 37 },
|
||||
// { label: "彩云驿出行", value: 38 },
|
||||
// ]}
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
|
||||
@ -10,5 +10,5 @@ export async function handleGetBEHAVIORRECORDList(params?: any){
|
||||
if (data.Result_Code !== 100) {
|
||||
return {}
|
||||
}
|
||||
return data.Result_Data.List
|
||||
return data.Result_Data
|
||||
}
|
||||
@ -119,11 +119,15 @@ const MerchantInformation: React.FC<{ currentUser: CurrentUser | undefined }> =
|
||||
};
|
||||
// 拖动结束
|
||||
const formatTreeData = (data: any) => {
|
||||
return data.map((item: any) => ({
|
||||
...item,
|
||||
value: String(item.value), // 数字转字符串
|
||||
children: item.children ? formatTreeData(item.children) : undefined,
|
||||
}));
|
||||
return data.map((item: any) => {
|
||||
const hasChildren = Array.isArray(item.children) && item.children.length > 0;
|
||||
return {
|
||||
...item,
|
||||
value: String(item.value), // 确保 value 是字符串
|
||||
disabled: hasChildren, // 有子节点的禁用选择
|
||||
children: hasChildren ? formatTreeData(item.children) : undefined,
|
||||
};
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -234,7 +234,7 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow, detailTy
|
||||
style={{ marginBottom: '16px' }}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={8} className="memberInfoDetailItem">
|
||||
<Col span={8} className="memberInfoDetailItem SALEBILLSTATE">
|
||||
<ProFormText
|
||||
name={"ORDER_AMOUNT"}
|
||||
label={"订单金额"}
|
||||
@ -266,7 +266,7 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow, detailTy
|
||||
style={{ marginBottom: '16px' }}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={8} className="memberInfoDetailItem">
|
||||
<Col span={8} className="memberInfoDetailItem SALEBILLSTATE">
|
||||
<ProFormText
|
||||
name={"PAY_AMOUNT"}
|
||||
label={"实付金额"}
|
||||
@ -282,7 +282,7 @@ const OrderDetailModal = ({ modalVisible, handleCloseModal, currentRow, detailTy
|
||||
style={{ marginBottom: '16px' }}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={8} className="memberInfoDetailItem">
|
||||
<Col span={8} className="memberInfoDetailItem SALEBILLSTATE">
|
||||
{
|
||||
detailType === 'food' ?
|
||||
<ProFormSelect
|
||||
|
||||
@ -100,6 +100,23 @@
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
}
|
||||
|
||||
.SALEBILLSTATE {
|
||||
.ant-form-item {
|
||||
margin-bottom: 12px;
|
||||
|
||||
.ant-form-item-row {
|
||||
.ant-form-item-control {
|
||||
.ant-form-item-control-input {
|
||||
.ant-form-item-control-input-content {
|
||||
color: #1890ff;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -113,22 +113,6 @@ const BookingMealOrder: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
|
||||
}}>{record?.SALEBILL_CODE}</a> : "-"
|
||||
}
|
||||
},
|
||||
{
|
||||
dataIndex: 'SERVERPART_NAME',
|
||||
title: '服务区',
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
width: 150,
|
||||
ellipsis: true,
|
||||
},
|
||||
{
|
||||
dataIndex: 'SHOPNAME',
|
||||
title: '门店名称',
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
width: 150,
|
||||
ellipsis: true,
|
||||
},
|
||||
{
|
||||
dataIndex: 'ORDER_PERSON',
|
||||
title: '下单人员',
|
||||
@ -137,6 +121,17 @@ const BookingMealOrder: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
|
||||
width: 150,
|
||||
ellipsis: true,
|
||||
},
|
||||
{
|
||||
dataIndex: 'ORDER_DATE',
|
||||
title: '订单时间',
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
width: 170,
|
||||
ellipsis: true,
|
||||
render: (_, record) => {
|
||||
return record?.ORDER_DATE ? moment(record?.ORDER_DATE).format('YYYY-MM-DD HH:mm:ss') : ''
|
||||
}
|
||||
},
|
||||
{
|
||||
dataIndex: 'SALEBILL_STATE',
|
||||
title: '订单状态',
|
||||
@ -197,6 +192,22 @@ const BookingMealOrder: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
|
||||
ellipsis: true,
|
||||
align: "center",
|
||||
},
|
||||
{
|
||||
dataIndex: 'SERVERPART_NAME',
|
||||
title: '服务区',
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
width: 150,
|
||||
ellipsis: true,
|
||||
},
|
||||
{
|
||||
dataIndex: 'SHOPNAME',
|
||||
title: '门店名称',
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
width: 150,
|
||||
ellipsis: true,
|
||||
},
|
||||
// {
|
||||
// dataIndex: 'COUPON_SEND_ID',
|
||||
// title: '优惠券名',
|
||||
@ -205,17 +216,7 @@ const BookingMealOrder: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
|
||||
// width: 120,
|
||||
// ellipsis: true,
|
||||
// },
|
||||
{
|
||||
dataIndex: 'ORDER_DATE',
|
||||
title: '订单时间',
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
width: 170,
|
||||
ellipsis: true,
|
||||
render: (_, record) => {
|
||||
return record?.ORDER_DATE ? moment(record?.ORDER_DATE).format('YYYY-MM-DD HH:mm:ss') : ''
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
]
|
||||
|
||||
|
||||
@ -19,6 +19,7 @@ import moment from 'moment'
|
||||
import session from "@/utils/session";
|
||||
import OrderDetailModal from "../BookingMealOrder/components/orderDetailModal";
|
||||
import { handleSetlogSave } from "@/utils/format";
|
||||
import MemberDetail from "../memberInfor/component/memberDetail";
|
||||
|
||||
|
||||
const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: boolean, parentDetail?: any }> = (props) => {
|
||||
@ -47,6 +48,8 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
const [showExportTable, setShowExportTable] = useState<boolean>(false)
|
||||
// 查询的条件
|
||||
const [searchParams, setSearchParams] = useState<any>()
|
||||
// 显示详情抽屉
|
||||
const [showDetailDrawer, setShowDetailDrawer] = useState<boolean>(false)
|
||||
|
||||
const columns: any = [
|
||||
{
|
||||
@ -97,6 +100,15 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
hideInSearch: true,
|
||||
align: 'center',
|
||||
ellipsis: true,
|
||||
render: (_, record) => {
|
||||
return isComponent ? record?.MEMBERSHIP_NAME || "" : record?.MEMBERSHIP_NAME ? <a onClick={() => {
|
||||
setCurrentRow(record)
|
||||
setShowDetailDrawer(true)
|
||||
handleSetlogSave(`查看${record?.MEMBERSHIP_NAME}【${record?.MEMBERSHIP_ID}】会员信息`)
|
||||
}}>
|
||||
{record?.MEMBERSHIP_NAME}
|
||||
</a> : "-"
|
||||
}
|
||||
},
|
||||
{
|
||||
title: "手机号码",
|
||||
@ -263,6 +275,8 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
]
|
||||
const handleCloseModal = () => {
|
||||
setShowOrderModal(false)
|
||||
setCurrentRow(null)
|
||||
setShowDetailDrawer(false)
|
||||
}
|
||||
|
||||
return (
|
||||
@ -361,6 +375,12 @@ const ConsumptionRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
|
||||
|
||||
<OrderDetailModal modalVisible={showOrderModal} handleCloseModal={handleCloseModal} currentRow={currentRow} />
|
||||
|
||||
{/* 会员详情 */}
|
||||
<MemberDetail showDetailDrawer={showDetailDrawer}
|
||||
currentRow={currentRow}
|
||||
handleCloseModal={handleCloseModal}
|
||||
currentUser={currentUser} />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@ -19,6 +19,7 @@ import moment from 'moment'
|
||||
import session from "@/utils/session";
|
||||
import { handleSetlogSave } from "@/utils/format";
|
||||
import OrderDetailModal from "../BookingMealOrder/components/orderDetailModal";
|
||||
import MemberDetail from "../memberInfor/component/memberDetail";
|
||||
|
||||
|
||||
const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boolean, parentDetail?: any }> = (props) => {
|
||||
@ -50,6 +51,9 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
const [showExportTable, setShowExportTable] = useState<boolean>(false)
|
||||
// 查询的条件
|
||||
const [searchParams, setSearchParams] = useState<any>()
|
||||
// 显示详情抽屉
|
||||
const [showDetailDrawer, setShowDetailDrawer] = useState<boolean>(false)
|
||||
|
||||
|
||||
const columns: any = [
|
||||
{
|
||||
@ -92,6 +96,15 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
hideInSearch: true,
|
||||
align: 'center',
|
||||
ellipsis: true,
|
||||
render: (_, record) => {
|
||||
return isComponent ? record?.MEMBERSHIP_NAME || "" : record?.MEMBERSHIP_NAME ? <a onClick={() => {
|
||||
setCurrentRow(record)
|
||||
setShowDetailDrawer(true)
|
||||
handleSetlogSave(`查看${record?.MEMBERSHIP_NAME}【${record?.MEMBERSHIP_ID}】会员信息`)
|
||||
}}>
|
||||
{record?.MEMBERSHIP_NAME}
|
||||
</a> : "-"
|
||||
}
|
||||
},
|
||||
{
|
||||
title: "会员等级",
|
||||
@ -224,6 +237,8 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
|
||||
const handleCloseModal = () => {
|
||||
setShowOrderModal(false)
|
||||
setCurrentRow(null)
|
||||
setShowDetailDrawer(false)
|
||||
}
|
||||
|
||||
|
||||
@ -306,6 +321,13 @@ const GrowthValueRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?
|
||||
|
||||
|
||||
<OrderDetailModal modalVisible={showOrderModal} handleCloseModal={handleCloseModal} currentRow={currentRow} />
|
||||
|
||||
{/* 会员详情 */}
|
||||
<MemberDetail showDetailDrawer={showDetailDrawer}
|
||||
currentRow={currentRow}
|
||||
handleCloseModal={handleCloseModal}
|
||||
currentUser={currentUser} />
|
||||
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@ -0,0 +1,540 @@
|
||||
// 成长值枚举规则配置页面
|
||||
import React, { useRef, useState, Suspense } from 'react';
|
||||
import moment from 'moment'; // 时间相关引用,没有使用可以删除
|
||||
import numeral from "numeral"; // 数字相关引用,没有使用可以删除
|
||||
import { connect } from 'umi';
|
||||
|
||||
import useRequest from '@ahooksjs/use-request'; // 请求数据的引用
|
||||
import Draggable from 'react-draggable';
|
||||
import SubMenu from "antd/lib/menu/SubMenu";
|
||||
import ProTable from '@ant-design/pro-table';
|
||||
import ProDescriptions from '@ant-design/pro-descriptions';
|
||||
import ProForm, { ProFormDatePicker, ProFormDateTimePicker, ProFormDateTimeRangePicker, ProFormDigit, ProFormMoney, ProFormSelect, ProFormText, ProFormTextArea, ProFormTreeSelect, ProFormUploadButton } from '@ant-design/pro-form';
|
||||
import { MenuFoldOutlined, PlusOutlined, ExclamationCircleOutlined } from '@ant-design/icons';
|
||||
import { PageContainer } from '@ant-design/pro-layout';
|
||||
import { Button, Col, Drawer, message, Row, Popconfirm, Space, Image, Modal, Form, Switch, Upload, Tooltip, Descriptions, TreeSelect } from 'antd';
|
||||
|
||||
import type { CurrentUser } from "umi";
|
||||
import type { ConnectState } from '@/models/connect';
|
||||
import type { ActionType, ProColumns } from '@ant-design/pro-table';
|
||||
import type { ProDescriptionsItemProps } from '@ant-design/pro-descriptions';
|
||||
import type { FormInstance } from 'antd';
|
||||
|
||||
import { getFieldEnumTree, getFieldEnumName } from "@/services/options"; // 枚举的引用,没有使用可以删除
|
||||
import PageTitleBox from '@/components/PageTitleBox';
|
||||
import { uploadPicture } from '@/services/picture';
|
||||
import defaultIcon from '../../../assets/brand/defaultIcon.png'
|
||||
import classNames from 'classnames';
|
||||
import session from '@/utils/session';
|
||||
import ModalFooter from '../../scenicSpotConfig/component/modalFooter';
|
||||
import { handeDeleteFIELDENUM, handeGetFIELDEXPLAINList, handeGetNestingFIELDENUMList, handeSynchroFIELDENUM } from '../../service';
|
||||
import { convertTreeToLabelValue, handleSetlogSave } from '@/utils/format';
|
||||
|
||||
|
||||
const beforeUpload = (file: any) => {
|
||||
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
|
||||
if (!isJpgOrPng) {
|
||||
message.error('请上传JPEG、jpg、png格式的图片文件!');
|
||||
}
|
||||
const isLt2M = file.size / 1024 / 1024 < 2;
|
||||
if (!isLt2M) {
|
||||
message.error('图片大小不超过 2MB!');
|
||||
}
|
||||
return isJpgOrPng && isLt2M;
|
||||
}
|
||||
|
||||
|
||||
const MEMBERSHIPTYPEConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (props) => {
|
||||
const { currentUser } = props
|
||||
const { confirm } = Modal;
|
||||
const actionRef = useRef<ActionType>();
|
||||
const formRef = useRef<FormInstance>();
|
||||
const [currentRow, setCurrentRow] = useState<any>();
|
||||
const [showDetail, setShowDetail] = useState<boolean>();
|
||||
const [modalVisible, handleModalVisible] = useState<boolean>();
|
||||
const [confirmLoading, handleConfirmLoading] = useState<boolean>(false) // 弹出框的内容表单是否在提交
|
||||
const [searchParams, setSearchParams] = useState<any>();
|
||||
// 分类的树形结构数据
|
||||
const [typeTreeData, setTypeTreeData] = useState<any>()
|
||||
// 表单里面的是否预售
|
||||
const [formPRESALE_TYPE, setFormPRESALE_TYPE] = useState<boolean>(false)
|
||||
|
||||
// 弹出框拖动效果
|
||||
const [bounds, setBounds] = useState<{ left: number, right: number, top: number, bottom: number }>() // 移动的位置
|
||||
const [disabled, setDraggleDisabled] = useState<boolean>() // 是否拖动
|
||||
const draggleRef = React.createRef<any>()
|
||||
|
||||
let AFTERSALETYPEObj = session.get('AFTERSALETYPEObj')
|
||||
const { data: FIELDEXPLAIN_ID } = useRequest(async () => {
|
||||
const req: any = {
|
||||
SearchParameter: {
|
||||
FIELDEXPLAIN_FIELD: "MEMBERSHIP_TYPE"
|
||||
}
|
||||
}
|
||||
const data = await handeGetFIELDEXPLAINList(req)
|
||||
if (data && data.length > 0) {
|
||||
let obj: any = data[0]
|
||||
return obj.FIELDEXPLAIN_ID
|
||||
}
|
||||
|
||||
})
|
||||
// 文件列表
|
||||
const [fileList, setFileList] = useState<any>([])
|
||||
const [imagePreviewVisible, setImagePreviewVisible] = useState<boolean>(false) // 预览图片
|
||||
|
||||
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),
|
||||
});
|
||||
};
|
||||
// 定义列表字段内容
|
||||
const columns: any = [
|
||||
{
|
||||
dataIndex: 'FIELDENUM_NAME',
|
||||
title: '类别名称',
|
||||
align: 'center',
|
||||
width: 300,
|
||||
ellipsis: true,
|
||||
hideInSearch: true,
|
||||
hideInDescriptions: true,
|
||||
render: (_, record) => {
|
||||
return <a
|
||||
onClick={() => {
|
||||
setCurrentRow({ ...record });
|
||||
handleModalVisible(true);
|
||||
}}
|
||||
>{record?.FIELDENUM_NAME || ""}</a>
|
||||
}
|
||||
},
|
||||
{
|
||||
dataIndex: 'FIELDENUM_VALUE',
|
||||
title: '售后枚举',
|
||||
align: 'center',
|
||||
width: 120,
|
||||
ellipsis: true,
|
||||
// valueType: 'treeSelect',
|
||||
// valueEnum: typeTreeData,
|
||||
hideInSearch: true,
|
||||
},
|
||||
{
|
||||
dataIndex: 'FIELDENUM_INDEX',
|
||||
title: '类别索引',
|
||||
align: 'center',
|
||||
width: 120,
|
||||
ellipsis: true,
|
||||
hideInSearch: true,
|
||||
},
|
||||
{
|
||||
dataIndex: 'FIELDENUM_STATUS',
|
||||
title: '有效状态',
|
||||
align: 'center',
|
||||
width: 120,
|
||||
ellipsis: true,
|
||||
valueType: "select",
|
||||
valueEnum: {
|
||||
"1": "有效",
|
||||
"0": "无效"
|
||||
},
|
||||
initialValue: "1"
|
||||
},
|
||||
{
|
||||
dataIndex: 'FIELDENUM_DESC',
|
||||
title: '备注说明',
|
||||
align: 'center',
|
||||
ellipsis: true,
|
||||
hideInSearch: true,
|
||||
},
|
||||
// {
|
||||
// dataIndex: 'option',
|
||||
// title: '操作',
|
||||
// width: 100,
|
||||
// ellipsis: true,
|
||||
// valueType: 'option',
|
||||
// align: 'center',
|
||||
// hideInSearch: true,
|
||||
// render: (_, record) => {
|
||||
// return (
|
||||
// <Space>
|
||||
// <a
|
||||
// onClick={() => {
|
||||
// setCurrentRow({ ...record });
|
||||
// handleModalVisible(true);
|
||||
// }}
|
||||
// >
|
||||
// 编辑
|
||||
// </a>
|
||||
// <Popconfirm
|
||||
// title="确认删除该点餐自定义类别列表信息吗?"
|
||||
// onConfirm={async () => {
|
||||
// handelDelete(record.FIELDENUM_ID);
|
||||
// }}
|
||||
// >
|
||||
// <a>删除</a>
|
||||
// </Popconfirm>
|
||||
// </Space>
|
||||
// );
|
||||
// },
|
||||
// },
|
||||
];
|
||||
|
||||
// 预览上传后的图片
|
||||
const handlePreview = async () => {
|
||||
setFileList(fileList)
|
||||
setImagePreviewVisible(true)
|
||||
};
|
||||
const handleChangePreview = (val: any) => {
|
||||
setImagePreviewVisible(val)
|
||||
}
|
||||
|
||||
// 删除点餐类别
|
||||
const handelDelete = async (id: any) => {
|
||||
const req: any = {
|
||||
FIELDENUMId: id
|
||||
}
|
||||
const result = await handeDeleteFIELDENUM(req)
|
||||
if (result.Result_Code !== 100) {
|
||||
message.error(`${result.Result_Desc}` || `${result.Result_Code}:删除失败`);
|
||||
} else {
|
||||
message.success('删除成功!');
|
||||
handleSetlogSave(`删除【${currentRow?.FIELDENUM_NAME}】成功`)
|
||||
actionRef.current?.reload()
|
||||
handleConfirmLoading(false)
|
||||
handleModalVisible(false)
|
||||
setFormPRESALE_TYPE(false)
|
||||
setFileList([])
|
||||
}
|
||||
}
|
||||
|
||||
// 同步点餐列表
|
||||
const handleAddUpdate = async (res: any) => {
|
||||
let req: any = {}
|
||||
if (currentRow?.FIELDENUM_ID) {
|
||||
req = {
|
||||
...currentRow,
|
||||
...res,
|
||||
}
|
||||
} else {
|
||||
req = {
|
||||
...res,
|
||||
FIELDEXPLAIN_ID: FIELDEXPLAIN_ID,
|
||||
FIELDENUM_PID: -1,
|
||||
}
|
||||
}
|
||||
const data = await handeSynchroFIELDENUM(req)
|
||||
handleConfirmLoading(false)
|
||||
if (data.Result_Code === 100) {
|
||||
message.success("新增成功!")
|
||||
handleSetlogSave(`${currentRow?.FIELDENUM_ID ? '更新' : '新增'}【${data.Result_Data.FIELDENUM_NAME}】`)
|
||||
setCurrentRow(undefined)
|
||||
formRef?.current?.resetFields()
|
||||
handleModalVisible(false)
|
||||
setFormPRESALE_TYPE(false)
|
||||
setFileList([])
|
||||
actionRef.current?.reload()
|
||||
} else {
|
||||
message.error(data.Result_Desc)
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<PageContainer header={{
|
||||
title: '',
|
||||
breadcrumb: {}
|
||||
}}>
|
||||
<ProTable
|
||||
style={{ height: 'calc(100vh - 135px)', background: '#fff' }}
|
||||
scroll={{ y: 'calc(100vh - 410px)' }}
|
||||
rowKey={(record) => {
|
||||
return `${record?.FIELDENUM_PID}-${record?.FIELDENUM_ID}`
|
||||
}}
|
||||
formRef={formRef}
|
||||
headerTitle={<PageTitleBox props={props} />} // 列表表头
|
||||
actionRef={actionRef}
|
||||
search={{ span: 6, labelWidth: 'auto' }}
|
||||
bordered
|
||||
// 请求数据
|
||||
request={async (params, sorter) => {
|
||||
const req = {
|
||||
FIELDEXPLAIN_FIELD: 'MEMBERSHIP_TYPE',
|
||||
FIELDEXPLAIN_ID: "",
|
||||
FIELDENUM_PID: "",
|
||||
FIELDENUM_STATUS: params?.FIELDENUM_STATUS,
|
||||
SearchKey: ""
|
||||
}
|
||||
const data = await handeGetNestingFIELDENUMList(req);
|
||||
console.log('dasjkdas', data);
|
||||
|
||||
handleSetlogSave(`查看了成长值枚举配置列表`)
|
||||
|
||||
if (data && data.length > 0) {
|
||||
setTypeTreeData(data)
|
||||
if (data && data.length > 0) {
|
||||
const obj: any = {}
|
||||
const list: any = []
|
||||
data.forEach((item: any) => {
|
||||
list.push({ label: item.FIELDENUM_NAME, value: item.FIELDENUM_VALUE })
|
||||
obj[item.FIELDENUM_VALUE] = item.FIELDENUM_NAME
|
||||
})
|
||||
session.set('MEMBERSHIPTYPEYNList', list);
|
||||
session.set('MEMBERSHIPTYPEYNObj', obj);
|
||||
session.set('MEMBERSHIPTYPEYNTree', convertTreeToLabelValue(data, 'FIELDENUM_NAME', 'FIELDENUM_VALUE'));
|
||||
}
|
||||
return { data: data, success: true, total: data.length }
|
||||
}
|
||||
return { data: [], success: true }
|
||||
}}
|
||||
columns={columns}
|
||||
toolbar={{
|
||||
actions: [
|
||||
// 新增按钮
|
||||
<Button
|
||||
key="new"
|
||||
icon={<PlusOutlined />}
|
||||
type="primary"
|
||||
onClick={() => {
|
||||
handleModalVisible(true);
|
||||
}}
|
||||
>
|
||||
会员类型类别
|
||||
</Button>,
|
||||
],
|
||||
}}
|
||||
/>
|
||||
|
||||
{/* 图片预览组件 */}
|
||||
{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>}
|
||||
|
||||
|
||||
<Modal
|
||||
title={
|
||||
<div
|
||||
className='orderCategoryModal'
|
||||
style={{
|
||||
width: '100%',
|
||||
cursor: 'move',
|
||||
}}
|
||||
onMouseOver={() => {
|
||||
if (disabled) {
|
||||
setDraggleDisabled(false)
|
||||
}
|
||||
}}
|
||||
onMouseOut={() => {
|
||||
setDraggleDisabled(true)
|
||||
}}
|
||||
|
||||
onFocus={() => { }}
|
||||
onBlur={() => { }}
|
||||
>
|
||||
{currentRow ? '更新售后类别' : '新建售后类别'}
|
||||
</div>
|
||||
}
|
||||
destroyOnClose={true}
|
||||
width={900}
|
||||
bodyStyle={{
|
||||
height: '700px', // 你可以根据需要调整高度
|
||||
overflowY: 'auto',
|
||||
}}
|
||||
visible={modalVisible}
|
||||
confirmLoading={confirmLoading}
|
||||
afterClose={() => {
|
||||
formRef.current?.resetFields();
|
||||
setCurrentRow(undefined);
|
||||
}}
|
||||
footer={<ModalFooter
|
||||
hideDelete={!currentRow?.FIELDENUM_ID}
|
||||
handleDelete={async () => {
|
||||
await handelDelete(currentRow?.FIELDENUM_ID)
|
||||
}}
|
||||
handleCancel={() => {
|
||||
handleConfirmLoading(false)
|
||||
handleModalVisible(false)
|
||||
setFormPRESALE_TYPE(false)
|
||||
setFileList([])
|
||||
}}
|
||||
handleOK={() => {
|
||||
formRef?.current?.validateFields().then(() => {
|
||||
handleConfirmLoading(true)
|
||||
formRef?.current?.submit()
|
||||
})
|
||||
}}
|
||||
|
||||
/>}
|
||||
onCancel={() => {
|
||||
handleConfirmLoading(false)
|
||||
handleModalVisible(false)
|
||||
setFormPRESALE_TYPE(false)
|
||||
setFileList([])
|
||||
}}
|
||||
|
||||
onOk={async () => { // 提交框内的数据
|
||||
formRef?.current?.validateFields().then(() => {
|
||||
handleConfirmLoading(true)
|
||||
formRef?.current?.submit()
|
||||
})
|
||||
}}
|
||||
modalRender={(modal) => {
|
||||
return <Draggable
|
||||
disabled={disabled}
|
||||
bounds={bounds}
|
||||
onStart={(event, uiData) => onDraggaleStart(event, uiData)}
|
||||
handle='.orderCategoryModal'
|
||||
>
|
||||
<div ref={draggleRef}>{modal}</div>
|
||||
</Draggable>
|
||||
}}
|
||||
>
|
||||
<ProForm
|
||||
layout={'horizontal'}
|
||||
formRef={formRef}
|
||||
autoFocusFirstInput
|
||||
labelCol={{ style: { width: 80 } }}
|
||||
submitter={false}
|
||||
preserve={false}
|
||||
initialValues={currentRow ? {
|
||||
...currentRow,
|
||||
} : {
|
||||
FIELDENUM_STATUS: 1,
|
||||
}}
|
||||
onFinish={async (values) => {
|
||||
let newValue = { ...values };
|
||||
if (currentRow) {
|
||||
// 编辑数据
|
||||
newValue = { ...values, FIELDENUM_ID: currentRow.FIELDENUM_ID };
|
||||
}
|
||||
// 如果有开关,要把开关的代码写进去
|
||||
await handleAddUpdate(newValue);
|
||||
|
||||
handleConfirmLoading(false)
|
||||
setFormPRESALE_TYPE(false)
|
||||
}}
|
||||
>
|
||||
<Row gutter={8}>
|
||||
{/* <Col span={12}>
|
||||
<ProFormTreeSelect
|
||||
name="FIELDENUM_PID"
|
||||
label="上级类别"
|
||||
request={async () => {
|
||||
if (typeTreeData && typeTreeData.length > 0) {
|
||||
let list: any = [{ FIELDENUM_NAME: "默认类别", FIELDENUM_ID: -1 }, ...typeTreeData]
|
||||
return list
|
||||
} else {
|
||||
const req = {
|
||||
FIELDEXPLAIN_FIELD: 'MEMBERSHIP_TYPE',
|
||||
FIELDEXPLAIN_ID: "",
|
||||
FIELDENUM_PID: "",
|
||||
FIELDENUM_STATUS: 1,
|
||||
SearchKey: ""
|
||||
}
|
||||
const data = await handeGetNestingFIELDENUMList(req);
|
||||
if (data && data.length > 0) {
|
||||
data.unshirft({ FIELDENUM_NAME: "默认类别", FIELDENUM_ID: -1 })
|
||||
setTypeTreeData(data)
|
||||
return data
|
||||
} else {
|
||||
return [{ FIELDENUM_NAME: "默认类别", FIELDENUM_ID: -1 }]
|
||||
}
|
||||
}
|
||||
}}
|
||||
fieldProps={{
|
||||
fieldNames: {
|
||||
label: 'FIELDENUM_NAME',
|
||||
value: 'FIELDENUM_ID',
|
||||
children: 'children'
|
||||
},
|
||||
showSearch: true,
|
||||
filterTreeNode: (input, node) =>
|
||||
(node.FIELDENUM_NAME || '').toLowerCase().includes(input.toLowerCase())
|
||||
}}
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
message: "请选择上级类别"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
</Col> */}
|
||||
<Col span={12}>
|
||||
<ProFormText
|
||||
name="FIELDENUM_NAME"
|
||||
label="类别名称"
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
message: "请输入类别名称"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={12}>
|
||||
<ProFormDigit
|
||||
name="FIELDENUM_INDEX"
|
||||
label="类别索引"
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
message: "请输入类别索引"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={12}>
|
||||
<ProFormDigit
|
||||
name="FIELDENUM_VALUE"
|
||||
label="售后枚举"
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
message: "请输入售后枚举"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={12}>
|
||||
<ProFormSelect
|
||||
name="FIELDENUM_STATUS"
|
||||
label="有效状态"
|
||||
options={[{ label: "有效", value: 1 }, { label: "无效", value: 0 }]}
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
message: "请选择有效状态"
|
||||
}
|
||||
]}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={24}>
|
||||
<ProFormTextArea
|
||||
name="FIELDENUM_DESC"
|
||||
label="备注"
|
||||
/>
|
||||
</Col>
|
||||
|
||||
</Row>
|
||||
</ProForm>
|
||||
</Modal>
|
||||
</PageContainer >
|
||||
);
|
||||
};
|
||||
export default connect(({ user }: ConnectState) => ({
|
||||
currentUser: user.currentUser
|
||||
}))(MEMBERSHIPTYPEConfig);
|
||||
@ -27,6 +27,7 @@ import PageTitleBox from '@/components/PageTitleBox';
|
||||
import ModalFooter from '../scenicSpotConfig/component/modalFooter';
|
||||
import GrowthConfig from './components/growthConfig';
|
||||
import { handleSetlogSave } from '@/utils/format';
|
||||
import MembershipTypeConfig from './components/MEMBERSHIPTYPEConfig';
|
||||
|
||||
|
||||
|
||||
@ -38,17 +39,17 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
|
||||
const [showDetail, setShowDetail] = useState<boolean>();
|
||||
const [modalVisible, handleModalVisible] = useState<boolean>();
|
||||
const [showConfig, setShowConfig] = useState<boolean>();
|
||||
const [showTypeConfig, setShowTypeConfig] = useState<boolean>();
|
||||
const [confirmLoading, handleConfirmLoading] = useState<boolean>(false) // 弹出框的内容表单是否在提交
|
||||
const [searchParams, setSearchParams] = useState<any>();
|
||||
|
||||
// 会员成长值枚举
|
||||
let GROWTHTYPEList = session.get('GROWTHTYPEList')
|
||||
let GROWTHTYPEObj = session.get('GROWTHTYPEObj')
|
||||
let MEMBERSHIP_TYPEList = session.get('MEMBERSHIP_TYPEList')
|
||||
let MEMBERSHIP_TYPEObj = session.get('MEMBERSHIP_TYPEObj')
|
||||
let MEMBERSHIPTYPEYNObj = session.get('MEMBERSHIPTYPEYNObj')
|
||||
let MEMBERSHIPLEVELYNList = session.get('MEMBERSHIPLEVELYNList')
|
||||
let MEMBERSHIPTYPEYNList = session.get('MEMBERSHIPTYPEYNList')
|
||||
let MEMBERSHIPLEVELYNObj = session.get('MEMBERSHIPLEVELYNObj')
|
||||
let MEMBERSHIPLEVELYNList = session.get('MEMBERSHIPLEVELYNList')
|
||||
|
||||
|
||||
// 弹出框拖动效果
|
||||
@ -111,7 +112,10 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
|
||||
width: 120,
|
||||
// hideInSearch: true,
|
||||
valueType: 'select',
|
||||
valueEnum: MEMBERSHIPTYPEYNObj
|
||||
// valueEnum: MEMBERSHIPTYPEYNObj
|
||||
request: async () => {
|
||||
return MEMBERSHIPTYPEYNList
|
||||
}
|
||||
},
|
||||
{
|
||||
dataIndex: 'MEMBERSHIP_LEVEL',
|
||||
@ -333,6 +337,16 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
|
||||
}}
|
||||
>
|
||||
成长值枚举配置
|
||||
</Button>,
|
||||
// 配置会员类型枚举
|
||||
<Button
|
||||
key="new"
|
||||
type="primary"
|
||||
onClick={() => {
|
||||
setShowTypeConfig(true);
|
||||
}}
|
||||
>
|
||||
会员类型枚举配置
|
||||
</Button>
|
||||
],
|
||||
}}
|
||||
@ -450,6 +464,7 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
|
||||
GROWTHSETTING_TYPE: currentRow?.GROWTHSETTING_TYPE ? currentRow?.GROWTHSETTING_TYPE.toString() : "",
|
||||
MEMBERSHIP_LEVEL: currentRow?.MEMBERSHIP_LEVEL ? currentRow?.MEMBERSHIP_LEVEL.toString() : "",
|
||||
PROMOTION_LEVEL: currentRow?.PROMOTION_LEVEL ? currentRow?.PROMOTION_LEVEL.toString() : "",
|
||||
MEMBERSHIP_TYPE: currentRow?.MEMBERSHIP_TYPE ? currentRow?.MEMBERSHIP_TYPE.toString() : "",
|
||||
}}
|
||||
onFinish={async (values) => {
|
||||
let newValue: any = { ...values };
|
||||
@ -525,7 +540,10 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
|
||||
<ProFormSelect
|
||||
name="MEMBERSHIP_TYPE"
|
||||
label="会员类型"
|
||||
options={MEMBERSHIP_TYPEList}
|
||||
// options={MEMBERSHIPTYPEYNList}
|
||||
request={async () => {
|
||||
return MEMBERSHIPTYPEYNList
|
||||
}}
|
||||
/>
|
||||
</Col>
|
||||
|
||||
@ -596,6 +614,24 @@ const GrowthValueRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }>
|
||||
>
|
||||
<GrowthConfig />
|
||||
</Modal>
|
||||
|
||||
|
||||
<Modal
|
||||
title={"会员类型枚举配置"}
|
||||
destroyOnClose={true}
|
||||
width={1200}
|
||||
bodyStyle={{
|
||||
height: '700px', // 你可以根据需要调整高度
|
||||
overflowY: 'auto',
|
||||
}}
|
||||
visible={showTypeConfig}
|
||||
footer={false}
|
||||
onCancel={() => {
|
||||
setShowTypeConfig(false)
|
||||
}}
|
||||
>
|
||||
<MembershipTypeConfig />
|
||||
</Modal>
|
||||
</PageContainer>
|
||||
);
|
||||
};
|
||||
|
||||
@ -43,7 +43,7 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser, isComponent
|
||||
const [deleteREPLYLoading, setDeleteREPLYLoading] = useState<boolean>(false)
|
||||
|
||||
|
||||
const MEMBERSHIPLEVELYNObj = session.get('MEMBERSHIPLEVELYNObj')
|
||||
const MEMBERSHIPTYPEYNObj = session.get('MEMBERSHIPTYPEYNObj')
|
||||
// 树相关的属性和方法
|
||||
const [selectedId, setSelectedId] = useState<string>()
|
||||
|
||||
@ -139,7 +139,7 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser, isComponent
|
||||
ellipsis: true,
|
||||
align: "center",
|
||||
valueType: "select",
|
||||
valueEnum: MEMBERSHIPLEVELYNObj
|
||||
valueEnum: MEMBERSHIPTYPEYNObj
|
||||
},
|
||||
{
|
||||
title: "消费评价",
|
||||
@ -272,7 +272,7 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser, isComponent
|
||||
options={false}
|
||||
scroll={{ x: "100%", y: isComponent ? '300px' : "calc(100vh - 410px)" }}
|
||||
headerTitle={<PageTitleBox props={props} />} // 列表表头
|
||||
search={isComponent ? false : { span: 6 }}
|
||||
search={isComponent ? false : { span: 8 }}
|
||||
request={async (params) => {
|
||||
if (!selectedId && !isComponent) {
|
||||
return
|
||||
@ -410,16 +410,18 @@ const MerchantEvaluationManage: React.FC<{ currentUser: CurrentUser, isComponent
|
||||
if (res.ReplyList && res.ReplyList.length > 0) {
|
||||
let list: any = []
|
||||
res.ReplyList.forEach((item: any) => {
|
||||
list.push({
|
||||
COMMENT_ID: currentRow?.COMMENT_ID || "",
|
||||
COMMENT_CONTENT: currentRow?.COMMENT_CONTENT || "",
|
||||
// COMMENT_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
STAFF_ID: currentUser?.ID,
|
||||
STAFF_NAME: currentUser?.Name,
|
||||
REPLY_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
REPLY_CONTENT: item.REPLY_CONTENT,
|
||||
REPLY_STATE: 1
|
||||
})
|
||||
if (!item.REPLY_ID) {
|
||||
list.push({
|
||||
COMMENT_ID: currentRow?.COMMENT_ID || "",
|
||||
COMMENT_CONTENT: currentRow?.COMMENT_CONTENT || "",
|
||||
// COMMENT_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
STAFF_ID: currentUser?.ID,
|
||||
STAFF_NAME: currentUser?.Name,
|
||||
REPLY_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
REPLY_CONTENT: item.REPLY_CONTENT,
|
||||
REPLY_STATE: 1
|
||||
})
|
||||
}
|
||||
})
|
||||
console.log('list', list);
|
||||
|
||||
|
||||
@ -19,6 +19,7 @@ import moment from 'moment'
|
||||
import session from "@/utils/session";
|
||||
import { handleSetlogSave } from "@/utils/format";
|
||||
import OrderDetailModal from "../BookingMealOrder/components/orderDetailModal";
|
||||
import MemberDetail from "../memberInfor/component/memberDetail";
|
||||
|
||||
|
||||
const PointsRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boolean, parentDetail?: any }> = (props) => {
|
||||
@ -49,6 +50,8 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boo
|
||||
// 显示订单详情的悬浮框
|
||||
const [showOrderModal, setShowOrderModal] = useState<boolean>(false)
|
||||
const [currentRow, setCurrentRow] = useState<any>()
|
||||
// 显示详情抽屉
|
||||
const [showDetailDrawer, setShowDetailDrawer] = useState<boolean>(false)
|
||||
|
||||
const columns: any = [
|
||||
{
|
||||
@ -84,12 +87,21 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boo
|
||||
initialValue: [moment().startOf('M'), moment()],
|
||||
},
|
||||
{
|
||||
title: "用户昵称",
|
||||
title: "会员昵称",
|
||||
width: 150,
|
||||
dataIndex: "MEMBERSHIP_NAME",
|
||||
hideInSearch: true,
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
ellipsis: true,
|
||||
render: (_, record) => {
|
||||
return isComponent ? record?.MEMBERSHIP_NAME || "" : record?.MEMBERSHIP_NAME ? <a onClick={() => {
|
||||
setCurrentRow(record)
|
||||
setShowDetailDrawer(true)
|
||||
handleSetlogSave(`查看${record?.MEMBERSHIP_NAME}【${record?.MEMBERSHIP_ID}】会员信息`)
|
||||
}}>
|
||||
{record?.MEMBERSHIP_NAME}
|
||||
</a> : "-"
|
||||
}
|
||||
},
|
||||
{
|
||||
title: "会员等级",
|
||||
@ -221,6 +233,8 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boo
|
||||
|
||||
const handleCloseModal = () => {
|
||||
setShowOrderModal(false)
|
||||
setCurrentRow(null)
|
||||
setShowDetailDrawer(false)
|
||||
}
|
||||
|
||||
return (
|
||||
@ -298,6 +312,13 @@ const PointsRecordSearch: React.FC<{ currentUser: CurrentUser, isComponent?: Boo
|
||||
</div>
|
||||
|
||||
<OrderDetailModal modalVisible={showOrderModal} handleCloseModal={handleCloseModal} currentRow={currentRow} />
|
||||
|
||||
{/* 会员详情 */}
|
||||
<MemberDetail showDetailDrawer={showDetailDrawer}
|
||||
currentRow={currentRow}
|
||||
handleCloseModal={handleCloseModal}
|
||||
currentUser={currentUser} />
|
||||
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@ -195,28 +195,28 @@ const PointsRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
|
||||
// align: 'center',
|
||||
// hideInSearch: true,
|
||||
// },
|
||||
{
|
||||
dataIndex: 'SCORESETTING_STATE',
|
||||
title: '有效状态',
|
||||
width: 120,
|
||||
align: 'center',
|
||||
valueType: 'select',
|
||||
valueEnum: {
|
||||
"1": "有效",
|
||||
"0": "无效"
|
||||
},
|
||||
initialValue: "1"
|
||||
},
|
||||
{
|
||||
dataIndex: 'OPERATE_DATE',
|
||||
title: '操作时间',
|
||||
width: 150,
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
render: (_, record) => {
|
||||
return record?.OPERATE_DATE ? moment(record?.OPERATE_DATE).format('YYYY-MM-DD HH:mm:ss') : ""
|
||||
}
|
||||
},
|
||||
// {
|
||||
// dataIndex: 'SCORESETTING_STATE',
|
||||
// title: '有效状态',
|
||||
// width: 120,
|
||||
// align: 'center',
|
||||
// valueType: 'select',
|
||||
// valueEnum: {
|
||||
// "1": "有效",
|
||||
// "0": "无效"
|
||||
// },
|
||||
// initialValue: "1"
|
||||
// },
|
||||
// {
|
||||
// dataIndex: 'OPERATE_DATE',
|
||||
// title: '操作时间',
|
||||
// width: 150,
|
||||
// align: 'center',
|
||||
// hideInSearch: true,
|
||||
// render: (_, record) => {
|
||||
// return record?.OPERATE_DATE ? moment(record?.OPERATE_DATE).format('YYYY-MM-DD HH:mm:ss') : ""
|
||||
// }
|
||||
// },
|
||||
// {
|
||||
// dataIndex: 'STAFF_NAME',
|
||||
// title: '操作员名称',
|
||||
@ -230,12 +230,14 @@ const PointsRuleConfig: React.FC<{ currentUser: CurrentUser | undefined }> = (pr
|
||||
// align: 'center',
|
||||
// hideInSearch: true,
|
||||
// },
|
||||
// {
|
||||
// dataIndex: 'SCORESETTING_DESC',
|
||||
// title: '备注',
|
||||
// align: 'center',
|
||||
// hideInSearch: true,
|
||||
// },
|
||||
{
|
||||
dataIndex: 'SCORESETTING_DESC',
|
||||
title: '备注说明',
|
||||
width: 270,
|
||||
align: 'center',
|
||||
hideInSearch: true,
|
||||
ellipsis: true,
|
||||
},
|
||||
// {
|
||||
// dataIndex: 'option',
|
||||
// title: '操作',
|
||||
|
||||
@ -35,6 +35,8 @@ const LeftSelectMallType = ({ setSelectedId, reload, actionRef, currentUser, wid
|
||||
const searchTreeRef = useRef<FormInstance>();
|
||||
// 默认的服务区树
|
||||
const [allTreeViews, setAllTreeViews] = useState<any>()
|
||||
// 判断是不是在搜索状态 搜索状态 可以展开全部的树形节点 如果不是 那就正常
|
||||
const [inSearch, setInSearch] = useState<boolean>(false)
|
||||
// 是否要显示全部
|
||||
// const [isShowAllInTree, setIsShowAllInTree] = useState<boolean>(false)
|
||||
// 加载服务区树
|
||||
@ -77,6 +79,7 @@ const LeftSelectMallType = ({ setSelectedId, reload, actionRef, currentUser, wid
|
||||
setSelectedId('')
|
||||
if (resList && resList.length > 0 && value) {
|
||||
setTreeView([])
|
||||
setInSearch(true)
|
||||
const list: any = []
|
||||
resList.forEach((item: any) => {
|
||||
if (item.USERDEFINEDTYPE_NAME.indexOf(value) !== -1) {
|
||||
@ -107,6 +110,7 @@ const LeftSelectMallType = ({ setSelectedId, reload, actionRef, currentUser, wid
|
||||
setTreeView(list)
|
||||
}, 100)
|
||||
} else {
|
||||
setInSearch(false)
|
||||
setTreeView([])
|
||||
setTreeShowRow([])
|
||||
setTreeView(allTreeViews)
|
||||
@ -206,6 +210,7 @@ const LeftSelectMallType = ({ setSelectedId, reload, actionRef, currentUser, wid
|
||||
}]}
|
||||
blockNode
|
||||
// defaultExpandAll={isShowAllInTree ? false : true}
|
||||
defaultExpandAll={inSearch}
|
||||
defaultExpandedKeys={['0-0']}
|
||||
onCheck={(checkedKeys: React.Key[] | any, info) => {
|
||||
console.log('checkedKeyscheckedKeyscheckedKeys', checkedKeys);
|
||||
|
||||
@ -26,10 +26,24 @@ import { handeDeleteCOMMODITY_MULTI, handeSynchroCOMMODITY_MULTI, handlDeleteUSE
|
||||
import { render } from 'react-dom';
|
||||
import ModalFooter from '../scenicSpotConfig/component/modalFooter';
|
||||
import { handleSetlogSave } from '@/utils/format';
|
||||
import { uploadPicture } from '@/services/picture';
|
||||
import defaultIcon from '../../../assets/brand/defaultIcon.png'
|
||||
|
||||
const beforeUpload = (file: any) => {
|
||||
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
|
||||
if (!isJpgOrPng) {
|
||||
message.error('请上传JPEG、jpg、png格式的图片文件!');
|
||||
}
|
||||
const isLt2M = file.size / 1024 / 1024 < 2;
|
||||
if (!isLt2M) {
|
||||
message.error('图片大小不超过 2MB!');
|
||||
}
|
||||
return isJpgOrPng && isLt2M;
|
||||
}
|
||||
|
||||
const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefined }> = (props) => {
|
||||
const { currentUser } = props
|
||||
const { confirm } = Modal;
|
||||
const actionRef = useRef<ActionType>();
|
||||
const formRef = useRef<FormInstance>();
|
||||
const [currentRow, setCurrentRow] = useState<any>();
|
||||
@ -46,6 +60,11 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
const [dataType, setDataType] = useState<number>(0)
|
||||
// 表格数据
|
||||
const [tableData, setTableData] = useState<any>()
|
||||
// 文件列表
|
||||
const [fileList, setFileList] = useState<any>([])
|
||||
|
||||
const [imagePreviewVisible, setImagePreviewVisible] = useState<boolean>(false) // 预览图片
|
||||
|
||||
|
||||
const onDraggaleStart = (event, uiData) => {
|
||||
const { clientWidth, clientHeight } = window.document.documentElement;
|
||||
@ -80,7 +99,7 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
width: 200,
|
||||
ellipsis: true,
|
||||
render: (_, record) => {
|
||||
return record?.COMMODITY_NAME || record?.USERDEFINEDTYPE_NAME ?
|
||||
return record?.COMMODITY_NAME ?
|
||||
<a onClick={() => {
|
||||
if (record?.COMMODITY_MULTI_ID) {
|
||||
setDataType(2)
|
||||
@ -91,8 +110,21 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
setCurrentRow({ ...record });
|
||||
handleModalVisible(true);
|
||||
}}>
|
||||
{record?.COMMODITY_NAME || record?.USERDEFINEDTYPE_NAME}
|
||||
</a> : "-"
|
||||
{record?.COMMODITY_NAME}
|
||||
</a> : record?.USERDEFINEDTYPE_NAME ?
|
||||
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'flex-start' }}>
|
||||
<img style={{ width: '30px', height: '30px', marginRight: '5px', borderRadius: '50%' }} src={record?.USERDEFINEDTYPE_ICO || defaultIcon} />
|
||||
<a style={{ width: '240px', display: "inline-block", whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis', textAlign: 'left' }} onClick={() => {
|
||||
if (record?.COMMODITY_MULTI_ID) {
|
||||
setDataType(2)
|
||||
} else {
|
||||
setDataType(1)
|
||||
}
|
||||
setCurrentRow({ ...record });
|
||||
handleModalVisible(true);
|
||||
}}>{record?.USERDEFINEDTYPE_NAME}</a>
|
||||
</div>
|
||||
: "-"
|
||||
}
|
||||
},
|
||||
{
|
||||
@ -249,7 +281,8 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
GOODSTYPE: 6000,
|
||||
OPERATE_TIME: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
STAFF_ID: currentUser?.ID,
|
||||
STAFF_NAME: currentUser?.Name
|
||||
STAFF_NAME: currentUser?.Name,
|
||||
USERDEFINEDTYPE_ICO: fileList && fileList.length > 0 ? fileList[0].url : "",
|
||||
}
|
||||
} else {
|
||||
req = {
|
||||
@ -260,7 +293,8 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
STAFF_NAME: currentUser?.Name,
|
||||
USERDEFINEDTYPE_DATE: moment().format('YYYY-MM-DD HH:mm:ss'),
|
||||
OWNERUNIT_ID: currentUser?.OwnerUnitId,
|
||||
PROVINCE_CODE: currentUser?.ProvinceCode
|
||||
PROVINCE_CODE: currentUser?.ProvinceCode,
|
||||
USERDEFINEDTYPE_ICO: fileList && fileList.length > 0 ? fileList[0].url : "",
|
||||
}
|
||||
}
|
||||
console.log('reqreqreqreq', req);
|
||||
@ -340,6 +374,16 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
});
|
||||
}
|
||||
|
||||
// 预览上传后的图片
|
||||
const handlePreview = async () => {
|
||||
setFileList(fileList)
|
||||
setImagePreviewVisible(true)
|
||||
};
|
||||
|
||||
const handleChangePreview = (val: any) => {
|
||||
setImagePreviewVisible(val)
|
||||
}
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div style={{ backgroundColor: '#fff', display: 'flex' }}>
|
||||
@ -405,6 +449,21 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
}}
|
||||
/>
|
||||
|
||||
{/* 图片预览组件 */}
|
||||
{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>}
|
||||
|
||||
<Modal
|
||||
title={
|
||||
<div
|
||||
@ -443,6 +502,7 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
handleConfirmLoading(false)
|
||||
handleModalVisible(false)
|
||||
setDataType(0)
|
||||
setFileList([])
|
||||
}}
|
||||
|
||||
onOk={async () => { // 提交框内的数据
|
||||
@ -476,6 +536,7 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
setDataType(0)
|
||||
formRef.current?.resetFields();
|
||||
setCurrentRow(undefined);
|
||||
setFileList([])
|
||||
}}
|
||||
handleOK={() => {
|
||||
formRef?.current?.validateFields().then(() => {
|
||||
@ -506,11 +567,16 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
}}
|
||||
onFinish={async (values) => {
|
||||
let newValue: any = { ...values };
|
||||
console.log('newValuenewValuenewValue', newValue);
|
||||
|
||||
if (currentRow) {
|
||||
// 编辑数据
|
||||
if (dataType === 1) {
|
||||
// 同步类别
|
||||
newValue = { ...values, USERDEFINEDTYPE_ID: currentRow?.USERDEFINEDTYPE_ID };
|
||||
newValue = {
|
||||
...values,
|
||||
USERDEFINEDTYPE_ID: currentRow?.USERDEFINEDTYPE_ID,
|
||||
};
|
||||
} else if (dataType === 2) {
|
||||
// 同步规格
|
||||
newValue = { ...values, COMMODITY_MULTI_ID: currentRow?.COMMODITY_MULTI_ID };
|
||||
@ -596,6 +662,52 @@ const ProductSpecificationManage: React.FC<{ currentUser: CurrentUser | undefine
|
||||
disabled
|
||||
/>
|
||||
</Col>
|
||||
<Col span={12}>
|
||||
<ProFormUploadButton
|
||||
name="USERDEFINEDTYPE_ICO"
|
||||
label="图标地址"
|
||||
fileList={fileList || []}
|
||||
listType="picture-card"
|
||||
accept="image/*"
|
||||
fieldProps={{
|
||||
beforeUpload,
|
||||
maxCount: 1,
|
||||
onPreview: handlePreview,
|
||||
customRequest: async (info) => {
|
||||
const formData = new FormData();
|
||||
formData.append('files', info.file);
|
||||
formData.append('TableType', '1215');
|
||||
formData.append('ImageName', typeof info.file !== 'string' ? info.file?.name : '');
|
||||
if (info.filename) {
|
||||
const success = await uploadPicture(formData)
|
||||
if (success) {
|
||||
const list = [{
|
||||
// uid: `${success.ImageId}`, // 注意,这个uid一定不能少,否则上传失败
|
||||
name: success.Result_Data.ImageName,
|
||||
// status: 'done',
|
||||
url: success.Result_Data.ImageUrl, // url 是展示在页面上的绝对链接
|
||||
// imgUrl: success.ImagePath // + success.ImageUrl,
|
||||
}]
|
||||
setFileList(list)
|
||||
}
|
||||
} else {
|
||||
message.error("您上传的图片不存在.")
|
||||
}
|
||||
},
|
||||
onChange: async (info: any) => {
|
||||
if (info.file.status === 'removed') {
|
||||
confirm({
|
||||
title: '确认删除该图片吗?',
|
||||
icon: <ExclamationCircleOutlined rev={undefined} />,
|
||||
async onOk() {
|
||||
setFileList([])
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}}
|
||||
/>
|
||||
</Col>
|
||||
<Col span={24}>
|
||||
<ProFormTextArea
|
||||
name="USERDEFINEDTYPE_DESC"
|
||||
|
||||
@ -16,6 +16,8 @@ import ReactHTMLTableToExcel from "react-html-table-to-excel";
|
||||
import moment from 'moment'
|
||||
import PageTitleBox from "@/components/PageTitleBox";
|
||||
import { handleGetBEHAVIORRECORDList } from "@/pages/Setting/OperationLog/service";
|
||||
import MemberDetail from "../memberInfor/component/memberDetail";
|
||||
import { handleSetlogSave } from "@/utils/format";
|
||||
|
||||
|
||||
const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComponent?: Boolean, parentDetail?: any }> = (props) => {
|
||||
@ -59,6 +61,10 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComp
|
||||
});
|
||||
}
|
||||
};
|
||||
// 显示详情抽屉
|
||||
const [showDetailDrawer, setShowDetailDrawer] = useState<boolean>(false)
|
||||
// 当前行数据
|
||||
const [currentRow, setCurrentRow] = useState<any>()
|
||||
|
||||
const columns: any = [
|
||||
{
|
||||
@ -145,11 +151,15 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComp
|
||||
dataIndex: 'USER_NAME',
|
||||
ellipsis: true,
|
||||
width: 120,
|
||||
// render: (_, record) => {
|
||||
// return <Tooltip title={record?.BEHAVIORRECORD_EXPLAIN || ''}>
|
||||
// {record?.USER_NAME || '-'}
|
||||
// </Tooltip>
|
||||
// }
|
||||
render: (_, record) => {
|
||||
return isComponent ? record?.USER_NAME : <a onClick={() => {
|
||||
setCurrentRow(record)
|
||||
setShowDetailDrawer(true)
|
||||
handleSetlogSave(`查看${record?.MEMBERSHIP_NAME}【${record?.MEMBERSHIP_ID}】会员信息`)
|
||||
}}>
|
||||
{record?.USER_NAME || '-'}
|
||||
</a>
|
||||
}
|
||||
},
|
||||
{
|
||||
title: '操作地址',
|
||||
@ -277,9 +287,9 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComp
|
||||
tempTable.remove() // 防止重复打印一个内容
|
||||
}
|
||||
|
||||
|
||||
|
||||
const handleGetTableData = async (paramsObj?: any) => {
|
||||
let result: any = {}
|
||||
|
||||
const res: any = formRef ? formRef?.current?.getFieldsValue() : {}
|
||||
console.log('resresres', res);
|
||||
let [start, end] = ['', '']
|
||||
@ -322,42 +332,49 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComp
|
||||
Key: 'BEHAVIORRECORD_ROUTNAME,USER_NAME,VISIT_CHANNELS,BEHAVIORRECORD_PREROUT',
|
||||
Value: params?.searchValue || ''
|
||||
},
|
||||
PageIndex: 1,
|
||||
PageSize: 100
|
||||
PageIndex: paramsObj.current || 1,
|
||||
PageSize: paramsObj?.pageSize || 999999
|
||||
}
|
||||
console.log('reqreqreqreq', req);
|
||||
|
||||
setSearchParams(params)
|
||||
const data = await handleGetBEHAVIORRECORDList(req)
|
||||
setReqDetailList(data)
|
||||
setTableData(data)
|
||||
console.log('dhsjdhasjdhs', data);
|
||||
|
||||
setReqDetailList(data.List)
|
||||
setTableData(data.List)
|
||||
setTableLoading(false)
|
||||
result = { data: data.List, success: true, total: data.TotalCount }
|
||||
|
||||
if (isComponent) {
|
||||
|
||||
} else {
|
||||
const allReq: any = {
|
||||
SearchParameter: {
|
||||
BEHAVIORRECORD_TIME_Start: moment(params?.start).format('YYYY-MM-DD'),
|
||||
BEHAVIORRECORD_TIME_End: moment(params?.end).format('YYYY-MM-DD'),
|
||||
SOURCE_PLATFORMS: params?.SOURCE_PLATFORM,
|
||||
// BEHAVIORRECORD_TYPE: params?.BEHAVIORRECORD_TYPE
|
||||
},
|
||||
SortStr: 'BEHAVIORRECORD_TIME desc',
|
||||
KeyWord: {
|
||||
Key: 'BEHAVIORRECORD_ROUTNAME,USER_NAME,VISIT_CHANNELS,BEHAVIORRECORD_PREROUT',
|
||||
Value: params?.searchValue || ''
|
||||
},
|
||||
PageIndex: 1,
|
||||
PageSize: 999999
|
||||
}
|
||||
const allData = await handleGetBEHAVIORRECORDList(allReq)
|
||||
setReqDetailList(data)
|
||||
setTableData(allData)
|
||||
setIsFirst(false)
|
||||
}
|
||||
// if (isComponent) {
|
||||
|
||||
// } else {
|
||||
// const allReq: any = {
|
||||
// SearchParameter: {
|
||||
// BEHAVIORRECORD_TIME_Start: moment(params?.start).format('YYYY-MM-DD'),
|
||||
// BEHAVIORRECORD_TIME_End: moment(params?.end).format('YYYY-MM-DD'),
|
||||
// SOURCE_PLATFORMS: params?.SOURCE_PLATFORM,
|
||||
// // BEHAVIORRECORD_TYPE: params?.BEHAVIORRECORD_TYPE
|
||||
// },
|
||||
// SortStr: 'BEHAVIORRECORD_TIME desc',
|
||||
// KeyWord: {
|
||||
// Key: 'BEHAVIORRECORD_ROUTNAME,USER_NAME,VISIT_CHANNELS,BEHAVIORRECORD_PREROUT',
|
||||
// Value: params?.searchValue || ''
|
||||
// },
|
||||
// PageIndex: 1,
|
||||
// PageSize: 999999
|
||||
// }
|
||||
// const allData = await handleGetBEHAVIORRECORDList(allReq)
|
||||
// setReqDetailList(data)
|
||||
// setTableData(allData)
|
||||
// setIsFirst(false)
|
||||
// }
|
||||
}
|
||||
|
||||
// 悬浮框的关闭方法
|
||||
const handleCloseModal = () => {
|
||||
setShowDetailDrawer(false)
|
||||
setCurrentRow(undefined);
|
||||
}
|
||||
|
||||
// useEffect(async () => {
|
||||
@ -432,16 +449,59 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComp
|
||||
}}
|
||||
scroll={{ x: '100%', y: isComponent ? '300px' : 'calc(100vh - 430px)' }}
|
||||
search={isComponent ? false : { span: 6 }}
|
||||
pagination={{ pageSize: 100 }}
|
||||
dataSource={tableData}
|
||||
loading={tableLoading}
|
||||
// dataSource={tableData}
|
||||
// loading={tableLoading}
|
||||
options={isComponent ? false : {
|
||||
density: true,
|
||||
reload: true,
|
||||
setting: true
|
||||
}}
|
||||
request={async (params) => {
|
||||
handleGetTableData(params)
|
||||
console.log('paramsparamsparamsparams', params);
|
||||
|
||||
const req: any = isComponent ? {
|
||||
SearchParameter: {
|
||||
SOURCE_PLATFORMS: '彩云驿出行',
|
||||
USER_MOBILEPHONE: parentDetail?.MEMBERSHIP_MOBILEPHONE,
|
||||
USER_ID: parentDetail?.MEMBERSHIP_ID
|
||||
},
|
||||
SortStr: 'BEHAVIORRECORD_TIME desc',
|
||||
PageIndex: params?.current || 1,
|
||||
PageSize: params?.pageSize || 999999
|
||||
} : {
|
||||
SearchParameter: {
|
||||
BEHAVIORRECORD_TIME_Start: moment(params?.BEHAVIORRECORD_TIME_Start).format('YYYY-MM-DD'),
|
||||
BEHAVIORRECORD_TIME_End: moment(params?.BEHAVIORRECORD_TIME_End).format('YYYY-MM-DD'),
|
||||
SOURCE_PLATFORMS: params?.SOURCE_PLATFORM,
|
||||
// BEHAVIORRECORD_TYPE: params?.BEHAVIORRECORD_TYPE
|
||||
},
|
||||
SortStr: 'BEHAVIORRECORD_TIME desc',
|
||||
KeyWord: {
|
||||
Key: 'BEHAVIORRECORD_ROUTNAME,USER_NAME,VISIT_CHANNELS,BEHAVIORRECORD_PREROUT',
|
||||
Value: params?.searchValue || ''
|
||||
},
|
||||
PageIndex: params?.current || 1,
|
||||
PageSize: params?.pageSize || 999999
|
||||
}
|
||||
console.log('reqreqreqreq', req);
|
||||
|
||||
setSearchParams(params)
|
||||
const data = await handleGetBEHAVIORRECORDList(req)
|
||||
console.log('dhsjdhasjdhs', data);
|
||||
|
||||
setReqDetailList(data.List)
|
||||
setTableData(data.List)
|
||||
setTableLoading(false)
|
||||
|
||||
|
||||
if (data.List && data.List.length > 0) {
|
||||
return { data: data.List, success: true, total: data.TotalCount }
|
||||
}
|
||||
return { data: [], success: true }
|
||||
// const data = await handleGetTableData(params)
|
||||
// return data
|
||||
|
||||
|
||||
// if (!isFirst) {
|
||||
// handleGetTableData()
|
||||
// }
|
||||
@ -497,6 +557,13 @@ const RegistrationRetentionAnalysis: React.FC<{ currentUser: CurrentUser, isComp
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{/* 会员详情 */}
|
||||
<MemberDetail showDetailDrawer={showDetailDrawer}
|
||||
currentRow={currentRow}
|
||||
handleCloseModal={handleCloseModal}
|
||||
currentUser={currentUser} />
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@ -243,7 +243,7 @@ const SummaryOfIntegralGrowthValue: React.FC<{ currentUser: CurrentUser | undefi
|
||||
setShowDetail(false)
|
||||
}}
|
||||
>
|
||||
<MemberInfor searchType={searchType} valueType={valueType} isComponent={true} />
|
||||
<MemberInfor searchType={searchType} valueType={valueType} isComponent={true} noMemberType={searchType === 1} noMemberLevel={searchType === 2} />
|
||||
</Drawer>
|
||||
</div>
|
||||
)
|
||||
|
||||
@ -12,7 +12,7 @@ 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 { handeDeleteMembershipRecord, handleGetCONSUMPTIONRECORDList, handleGetMEMBERGROWTHList, handleGetPOINTRECORDList } from "../../service";
|
||||
import { handeDeleteMembershipRecord, handeGetMEMBERSHIPDetail, handleGetCONSUMPTIONRECORDList, handleGetMEMBERGROWTHList, handleGetPOINTRECORDList } from "../../service";
|
||||
import AddressDetail from "../../MemberAddress/components/addressDetail";
|
||||
import './style.less'
|
||||
import ConsumptionRecordSearch from "../../ConsumptionRecordSearch";
|
||||
@ -48,6 +48,9 @@ const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentU
|
||||
let SCORETYPETree = session.get('SCORETYPETree')
|
||||
let CONSUMPTIONRECORDTYPEObj = session.get('CONSUMPTIONRECORDTYPEObj')
|
||||
|
||||
// 会员详情信息
|
||||
const [userDetailInfo, setUserDetailInfo] = useState<any>({})
|
||||
|
||||
// 当前选中在详情里面要查看的内容
|
||||
const [selectTab, setSelectTab] = useState<number>(1)
|
||||
|
||||
@ -335,11 +338,32 @@ const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentU
|
||||
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') : '',
|
||||
} : {}}
|
||||
// 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') : '',
|
||||
// } : {}}
|
||||
request={async () => {
|
||||
if (currentRow?.MEMBERSHIP_ID || currentRow?.USER_ID) {
|
||||
const req: any = {
|
||||
MEMBERSHIPId: currentRow?.MEMBERSHIP_ID || currentRow?.USER_ID
|
||||
}
|
||||
const data = await handeGetMEMBERSHIPDetail(req)
|
||||
console.log('userDetailData', data);
|
||||
let obj: any = {
|
||||
...data,
|
||||
OPERATE_DATE: data.OPERATE_DATE ? moment(data.OPERATE_DATE).format('YYYY-MM-DD HH:mm:ss') : '',
|
||||
ADDTIME: data.ADDTIME ? moment(data.ADDTIME).format('YYYY-MM-DD HH:mm:ss') : '',
|
||||
MEMBERSHIP_BIRTHDAY: currentRow?.MEMBERSHIP_BIRTHDAY ? moment(currentRow?.MEMBERSHIP_BIRTHDAY).format('YYYY-MM-DD') : '',
|
||||
}
|
||||
setUserDetailInfo(obj)
|
||||
return obj
|
||||
} else {
|
||||
return {}
|
||||
}
|
||||
}}
|
||||
|
||||
|
||||
>
|
||||
<div className="modalTop" style={{ position: 'fixed', background: '#fff', borderTopLeftRadius: "16px", borderTopRightRadius: "16px", zIndex: 999, borderBottom: '1px solid #D5D8DE' }}>
|
||||
<div className="modalTopLeft">
|
||||
@ -355,22 +379,22 @@ const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentU
|
||||
</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"} />
|
||||
<img className="headerImage" src={userDetailInfo?.MEMBERSHIP_HEADIMAGEURL || "https://thirdwx.qlogo.cn/mmopen/vi_32/POgEwh4mIHO4nibH0KlMECNjjGxQUq24ZEaGT4poC6icRiccVGKSyXwibcPq4BWmiaIGuG1icwxaQX6grC9VemZoJ8rg/132"} />
|
||||
</div>
|
||||
|
||||
<div className="topDetailRight">
|
||||
<div className="topDetailRightTop">
|
||||
<span className="detailName" style={{ marginRight: '8px' }}>{currentRow?.MEMBERSHIP_NAME || "-"}</span>
|
||||
<span className="detailSex" style={{ marginRight: '8px' }}>{currentRow?.MEMBERSHIP_SEX === 1 ? '男' : currentRow?.MEMBERSHIP_SEX === 2 ? '女' : ''}</span>
|
||||
<span className="detailName" style={{ marginRight: '8px' }}>{userDetailInfo?.MEMBERSHIP_NAME || "-"}</span>
|
||||
{/* <span className="detailSex" style={{ marginRight: '8px' }}>{userDetailInfo?.MEMBERSHIP_SEX === 0 ? '男' : userDetailInfo?.MEMBERSHIP_SEX === 1 ? '女' : ''}</span> */}
|
||||
{
|
||||
currentRow?.MEMBERSHIP_TYPE && MEMBERSHIPTYPEYNObj && MEMBERSHIPTYPEYNObj[currentRow?.MEMBERSHIP_TYPE] ?
|
||||
<span className="memberType">{MEMBERSHIPTYPEYNObj[currentRow?.MEMBERSHIP_TYPE]}</span> : ""
|
||||
userDetailInfo?.MEMBERSHIP_TYPE && MEMBERSHIPTYPEYNObj && MEMBERSHIPTYPEYNObj[userDetailInfo?.MEMBERSHIP_TYPE] ?
|
||||
<span className="memberType">{MEMBERSHIPTYPEYNObj[userDetailInfo?.MEMBERSHIP_TYPE]}</span> : ""
|
||||
}
|
||||
|
||||
|
||||
{
|
||||
currentRow?.MEMBERSHIP_LEVEL && MEMBERSHIPLEVELYNObj && MEMBERSHIPLEVELYNObj[currentRow?.MEMBERSHIP_LEVEL] ?
|
||||
<span className="memberType" style={{ marginLeft: '8px' }}>{MEMBERSHIPLEVELYNObj[currentRow?.MEMBERSHIP_LEVEL]}</span> : ""
|
||||
userDetailInfo?.MEMBERSHIP_LEVEL && MEMBERSHIPLEVELYNObj && MEMBERSHIPLEVELYNObj[userDetailInfo?.MEMBERSHIP_LEVEL] ?
|
||||
<span className="memberType" style={{ marginLeft: '8px' }}>{MEMBERSHIPLEVELYNObj[userDetailInfo?.MEMBERSHIP_LEVEL]}</span> : ""
|
||||
}
|
||||
|
||||
</div>
|
||||
@ -444,47 +468,47 @@ const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentU
|
||||
<img className="carNavIcon" src={memberDetailIcon} />
|
||||
<span className={selectTab === 1 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(1)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】详细信息`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】详细信息`)
|
||||
}}>详情信息</span>
|
||||
<span className={selectTab === 2 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(2)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】消费记录`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】消费记录`)
|
||||
}}>消费记录</span>
|
||||
<span className={selectTab === 3 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(3)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】成长值记录`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】成长值记录`)
|
||||
}}>成长值记录</span>
|
||||
<span className={selectTab === 4 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(4)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】积分记录`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】积分记录`)
|
||||
}}>积分记录</span>
|
||||
<span className={selectTab === 5 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(5)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】地址管理`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】地址管理`)
|
||||
}}>地址管理</span>
|
||||
<span className={selectTab === 6 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(6)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】活动轨迹`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】活动轨迹`)
|
||||
}}>活动轨迹</span>
|
||||
<span className={selectTab === 7 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(7)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】车牌管理`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】车牌管理`)
|
||||
}}>车牌管理</span>
|
||||
<span className={selectTab === 8 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(8)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】优惠券管理`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】优惠券管理`)
|
||||
}}>优惠券管理</span>
|
||||
<span className={selectTab === 9 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(9)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】收藏商品`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】收藏商品`)
|
||||
}}>收藏商品</span>
|
||||
<span className={selectTab === 10 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(10)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】商家评价`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】商家评价`)
|
||||
}}>商家评价</span>
|
||||
<span className={selectTab === 11 ? "carNavTitle selectCarNavTitle" : "carNavTitle"} onClick={() => {
|
||||
setSelectTab(11)
|
||||
handleSetlogSave(`查看【${currentRow?.MEMBERSHIP_NAME}】商城评价`)
|
||||
handleSetlogSave(`查看【${userDetailInfo?.MEMBERSHIP_NAME}】商城评价`)
|
||||
}}>商城评价</span>
|
||||
</div>
|
||||
|
||||
@ -589,61 +613,61 @@ const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentU
|
||||
</div>
|
||||
{/* 消费记录 */}
|
||||
{
|
||||
selectTab === 2 ? <ConsumptionRecordSearch isComponent={true} parentDetail={currentRow} /> : ""
|
||||
selectTab === 2 ? <ConsumptionRecordSearch isComponent={true} parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
|
||||
{/* 成长值记录 */}
|
||||
{
|
||||
selectTab === 3 ?
|
||||
<GrowthValueRecordSearch isComponent={true} parentDetail={currentRow} /> : ''
|
||||
<GrowthValueRecordSearch isComponent={true} parentDetail={userDetailInfo} /> : ''
|
||||
}
|
||||
{/* 积分记录 */}
|
||||
{
|
||||
selectTab === 4 ?
|
||||
<PointsRecordSearch isComponent={true} parentDetail={currentRow} />
|
||||
<PointsRecordSearch isComponent={true} parentDetail={userDetailInfo} />
|
||||
: ''
|
||||
}
|
||||
|
||||
{/* 地址管理 */}
|
||||
{
|
||||
selectTab === 5 ? <AddressDetail currentBigRow={currentRow} currentUser={currentUser} /> : ''
|
||||
selectTab === 5 ? <AddressDetail currentBigRow={userDetailInfo} currentUser={currentUser} /> : ''
|
||||
}
|
||||
|
||||
{/* 活动轨迹 */}
|
||||
{
|
||||
selectTab === 6 ? <RegistrationRetentionAnalysis isComponent={true} parentDetail={currentRow} /> : ""
|
||||
selectTab === 6 ? <RegistrationRetentionAnalysis isComponent={true} parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
|
||||
{/* 车牌管理 */}
|
||||
{
|
||||
selectTab === 7 ? <LicensePlateManage parentDetail={currentRow} /> : ""
|
||||
selectTab === 7 ? <LicensePlateManage parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
|
||||
{/* 会员优惠券 */}
|
||||
{
|
||||
selectTab === 8 ? <MemberDiscounts parentDetail={currentRow} /> : ""
|
||||
selectTab === 8 ? <MemberDiscounts parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
|
||||
{/* 会员收藏 */}
|
||||
{
|
||||
selectTab === 9 ? <CollectProducts parentDetail={currentRow} /> : ""
|
||||
selectTab === 9 ? <CollectProducts parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
|
||||
{/* 商家评价 */}
|
||||
{
|
||||
selectTab === 10 ? <MerchantEvaluationManage isComponent={true} parentDetail={currentRow} /> : ""
|
||||
selectTab === 10 ? <MerchantEvaluationManage isComponent={true} parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
|
||||
{/* 商城评价 */}
|
||||
{
|
||||
selectTab === 11 ? <MallEvaluationManage isComponent={true} parentDetail={currentRow} /> : ""
|
||||
selectTab === 11 ? <MallEvaluationManage isComponent={true} parentDetail={userDetailInfo} /> : ""
|
||||
}
|
||||
</div>
|
||||
|
||||
|
||||
<div style={{ width: '100%', boxSizing: 'border-box', padding: '0 24px' }}>
|
||||
{
|
||||
currentRow?.MEMBERSHIP_TYPE === 9999 ?
|
||||
userDetailInfo?.MEMBERSHIP_TYPE === 9999 ?
|
||||
<Button danger onClick={() => {
|
||||
confirm({
|
||||
width: 500,
|
||||
@ -651,9 +675,9 @@ const MemberDetail = ({ showDetailDrawer, currentRow, handleCloseModal, currentU
|
||||
{`删除该消费记录将清除用户的积分与成长值,且该操作无法恢复。是否确认删除?`}
|
||||
</div>,
|
||||
onOk: async () => {
|
||||
console.log('currentRowcurrentRowcurrentRowcurrentRow', currentRow);
|
||||
console.log('currentRowcurrentRowcurrentRowcurrentRow', userDetailInfo);
|
||||
const req: any = {
|
||||
MembershipId: currentRow?.MEMBERSHIP_ID
|
||||
MembershipId: userDetailInfo?.MEMBERSHIP_ID
|
||||
}
|
||||
const data = await handeDeleteMembershipRecord(req)
|
||||
if (data.Result_Code === 100) {
|
||||
|
||||
@ -30,9 +30,11 @@ import MemberDetail from "./component/memberDetail";
|
||||
// searchType 1 会员类型 2 会员等级
|
||||
// valueType 对应枚举值
|
||||
// isComponent 判断是不是以组件形式
|
||||
// noMemberType 判断是否隐藏 会员类型得筛选条件
|
||||
// noMemberLevel 判断是否隐藏 会员等级得筛选条件
|
||||
|
||||
const memberInfor: React.FC<{ currentUser: CurrentUser, searchType?: any, valueType?: any, isComponent?: boolean }> = (props) => {
|
||||
const { currentUser, searchType, valueType, isComponent } = props
|
||||
const memberInfor: React.FC<{ currentUser: CurrentUser, searchType?: any, valueType?: any, isComponent?: boolean, noMemberType?: boolean, noMemberLevel?: boolean }> = (props) => {
|
||||
const { currentUser, searchType, valueType, isComponent, noMemberType, noMemberLevel } = props
|
||||
const downloadBtnRef = useRef<any>()
|
||||
const draggleRef = React.createRef<any>()
|
||||
const actionRef = useRef<ActionType>();
|
||||
@ -125,6 +127,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser, searchType?: any, valueT
|
||||
dataIndex: "MEMBERSHIP_TYPE",
|
||||
ellipsis: true,
|
||||
hideInTable: true,
|
||||
hideInSearch: noMemberType,
|
||||
align: 'center',
|
||||
valueType: 'select',
|
||||
valueEnum: {
|
||||
@ -179,6 +182,7 @@ const memberInfor: React.FC<{ currentUser: CurrentUser, searchType?: any, valueT
|
||||
dataIndex: "MEMBERSHIP_LEVEL",
|
||||
ellipsis: true,
|
||||
align: 'center',
|
||||
hideInSearch: noMemberLevel,
|
||||
valueType: 'select',
|
||||
valueEnum: MEMBERSHIPLEVELYNObj,
|
||||
// initialValue: "0"
|
||||
|
||||
@ -1023,4 +1023,14 @@ export async function handeGetMarketingSummary(params: any) {
|
||||
return data.Result_Data
|
||||
}
|
||||
|
||||
|
||||
// 拿到会员详情
|
||||
export async function handeGetMEMBERSHIPDetail(params: any) {
|
||||
const data = await requestEncryption(`/Member/GetMEMBERSHIPDetail`, {
|
||||
method: 'POST',
|
||||
data: { ...params, requestEncryption: true }
|
||||
})
|
||||
if (data.Result_Code !== 100) {
|
||||
return data
|
||||
}
|
||||
return data.Result_Data
|
||||
}
|
||||
4
src/versionEnv.ts
Normal file
4
src/versionEnv.ts
Normal file
@ -0,0 +1,4 @@
|
||||
// 由 scripts/writeVersion.js 自动生成
|
||||
export const VERSION = "4.5.8";
|
||||
export const GIT_HASH = "16b1153";
|
||||
export const BUILD_TIME = "2025-07-28T11:27:27.820Z";
|
||||
Loading…
x
Reference in New Issue
Block a user