Commit 9fedd4b6 authored by Bill's avatar Bill

Merge branch 'dev' of 10.0.0.22:lingxi/lingxi-business-system into dev

parents 82577175 7848c41d
......@@ -139,6 +139,7 @@ const Details: React.FC<{}> = (props) => {
title: '序号',
key: 'inquiryListId',
dataIndex: 'inquiryListId',
render: (text: any, record: any, index: number) => <>{index + 1}</>
}, {
title: '操作角色',
key: 'roleName',
......@@ -323,4 +324,4 @@ const Details: React.FC<{}> = (props) => {
)
}
export default Details
\ No newline at end of file
export default Details
......@@ -112,6 +112,7 @@ const Details: React.FC<{}> = (props) => {
title: '序号',
key: 'inquiryListId',
dataIndex: 'inquiryListId',
render: (text: any, record: any, index: number) => <>{index + 1}</>
}, {
title: '操作角色',
key: 'roleName',
......@@ -236,7 +237,7 @@ const Details: React.FC<{}> = (props) => {
</div>
<div className={style.item_wrap}>
<div className={style.mainCol_title} style={view === 2 ? { paddingBottom: '0px' } : { paddingBottom: '24px' }}>报价商品</div>
<StandardTable
<StandardTable
currentRef={ref}
columns={inquiryGoods}
tableProps={{ rowKew: 'id' }}
......@@ -319,4 +320,4 @@ const Details: React.FC<{}> = (props) => {
)
}
export default Details
\ No newline at end of file
export default Details
......@@ -6,6 +6,7 @@ import SetUpModal from './setUpModal';
interface payWayTableParams {
name?: string,
way?: string,
payParametersList?: any,
payParametersListResponses?: any,
visible?: boolean,
......@@ -22,7 +23,7 @@ const PayWayTable: React.FC<payWayTableParams> = (props) => {
const [edit, setedit] = useState<any>({});
const [modifyIndex, setModifyIndex] = useState<any>(0)
const [modify, setmodify] = useState<boolean>(false);
const { name, payParametersListResponses, payParametersList, visible, onType, onGet, onDel, onEdit, id } = props;
const { name, payParametersListResponses, payParametersList, visible, onType, onGet, onDel, onEdit, id, way } = props;
const columns: ColumnType<any>[] = [
{
title: '参数代码',
......@@ -87,7 +88,7 @@ const PayWayTable: React.FC<payWayTableParams> = (props) => {
<Button style={{ marginBottom: 16, marginTop: 24 }} block icon={<PlusOutlined />} onClick={() => { setmodalvisible(true); setType(id); setmodify(false) }} type='dashed'>新增参数配置</Button>
{
id !== 2 &&
way !== '微信' &&
<>
<div style={{ borderLeft: '2px solid #00B37A', margin: '41px 0 8px', padding: '1px 5px' }}>{name}转账到银行卡参数配置</div>
<Table
......
......@@ -98,27 +98,33 @@ const PayWaySetTemplate: React.FC<{}> = () => {
const onHnadleSubmit = () => {
let conditions = false;
let wayName = '';
payItem.forEach(item => {
if (item.id === 2 && item.isPitchOn === 1) {
if(item.payParametersAddListRequests.length > 0) {
conditions = true
try {
payItem.forEach(item => {
if (item.way === '微信' && item.isPitchOn === 1) {
console.log(1)
if(item.payParametersAddListRequests.length > 0) {
conditions = true
} else {
conditions = false
wayName = item.way
throw new Error
}
} else if (item.way === '支付宝' && item.isPitchOn === 1) {
console.log(2)
if(item.payParametersAddListRequests.length > 0 && item.payParametersList.length > 0) {
conditions = true
} else {
conditions = false
wayName = item.way
throw new Error
}
} else {
conditions = false
wayName = item.way
return
}
} else if (item.id === 1 && item.isPitchOn === 1) {
if(item.payParametersAddListRequests.length > 0 && item.payParametersList.length > 0) {
conditions = true
} else {
conditions = false
wayName = item.way
return
}
} else {
conditions = true
}
})
})
} catch {
message.error(`${wayName}缺少支付参数配置`)
}
if (conditions) {
PublicApi.postPayCollectionParametersAdd({
platformPayWays: payItem
......@@ -127,8 +133,6 @@ const PayWaySetTemplate: React.FC<{}> = () => {
history.push('/ruleSettingManager/paySetting')
}
})
} else {
message.error(`请新增${wayName}的支付参数配置`)
}
}
......@@ -179,9 +183,10 @@ const PayWaySetTemplate: React.FC<{}> = () => {
selectId={payItem[idx].id}
onChange={(value) => onChangeRaido(value, idx)}
/>
{(payItem[idx].id === 1 || payItem[idx].id === 2) &&
{(payItem[idx].way === '微信' || payItem[idx].way === '支付宝') &&
<PayWayTable
id={payItem[idx].id}
way={payItem[idx].way}
onType={payItem[idx].payType}
name={payItem[idx].way}
payParametersList={payItem[idx].payParametersList}
......
......@@ -61,16 +61,16 @@ const PaySetting: React.FC<{}> = () => {
levelList: [],
roleList: []
})
const [memberRowSelection, memberRowCtl] = useRowSelectionTable({ customKey: 'memberId' })
const [memberRowSelection, memberRowCtl] = useRowSelectionTable({ customKey: 'id' })
const [optionType, setoptionType] = useState(0)
const { preview, pageStatus } = usePageStatus()
// const initValue = useInitValue(PublicApi.getPayPayMemberTacticsDetails)
const columnsSetMember: ColumnType<any>[] = [
{
title: 'ID',
dataIndex: 'memberId',
dataIndex: 'id',
align: 'center',
key: 'memberId',
key: 'id',
},
{
title: '会员名称',
......@@ -130,7 +130,7 @@ const PaySetting: React.FC<{}> = () => {
// 弹出会员
const handleAddMemberBtn = () => {
const checkBoxs = payActions.getFieldValue('applyMember')
memberRowCtl.setSelectedRowKeys(checkBoxs.map(v => v.memberId))
memberRowCtl.setSelectedRowKeys(checkBoxs.map(v => v.id))
memberRowCtl.setSelectRow(checkBoxs)
setvisible(true)
console.log(visibleChannelMember)
......@@ -191,7 +191,7 @@ const PaySetting: React.FC<{}> = () => {
}).then(res => {
if (res.code === 1000) {
let { data } = res.data
memberRowCtl.setSelectedRowKeys(data.map(v => v.memberId))
memberRowCtl.setSelectedRowKeys(data.map(v => v.id))
memberRowCtl.setSelectRow(data)
payActions.setFieldValue('applyMember', data)
}
......@@ -417,7 +417,6 @@ const PaySetting: React.FC<{}> = () => {
}
}
//新增
console.log(param, 10086)
if (param.memberIdRoleIds.length === 0 && values.isSelected === 0) {
message.error('请选择指定的会员');
return
......@@ -495,7 +494,7 @@ const PaySetting: React.FC<{}> = () => {
}
}
tableProps={{
rowKey: 'memberId'
rowKey: 'id'
}}
/>
</PageHeaderWrapper>
......
......@@ -55,7 +55,7 @@ export const strategyDetailTab = (props: any, usePageStatus: any) => {
"x-component": 'checkbox',
'x-component-props': {
},
required: false,
required: true,
}
}
}
......
......@@ -16,8 +16,8 @@ const SensitiveWords: React.FC<{}> = () => {
await PublicApi.getManageUnitUpdateUnitStatus({ id: id, status: _status })
ref.current.reload()
}
const confirmCancel = (id: number) => {
PublicApi.postManageSensitiveWordDelete({ ids: [id] }).then(res => {
const confirmCancel = (id: any) => {
PublicApi.getManageUnitDeleteUnit({ id }).then(res => {
if (res.code === 1000) {
message.success('删除成功')
ref.current.reload()
......@@ -132,7 +132,7 @@ const SensitiveWords: React.FC<{}> = () => {
name: {
type: 'string',
'x-component-props': {
placeholder: '属性名称',
placeholder: '单位名称',
},
'x-component': 'Search'
}
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment