Commit 6907e659 authored by 前端-许佳敏's avatar 前端-许佳敏

fix:修复收货信息

parent 2c3e0ebd
export default {
'/api': {
'target': 'http://10.0.0.25:8100/',
'target': 'http://10.0.0.10:8100/',
'changeOrigin': true,
'pathRewrite': { '^/api': '' },
}
......
import React, { useState } from 'react'
import { Tag, Row } from 'antd'
import { useFormEffects, ISchemaFieldComponentProps } from '@formily/antd'
import { RiskCheck } from 'god'
const SliderValidate = (props: ISchemaFieldComponentProps) => {
const { value = [], mutators } = props
const xPoint = 80
const yPoint = 30
const imgUrl = 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1603280613858&di=b810f23b7c17affe6a2be8a28cecd857&imgtype=0&src=http%3A%2F%2Fa3.att.hudong.com%2F14%2F75%2F01300000164186121366756803686.jpg'
const componentProps = {
xPoint,
yPoint,
imgUrl
}
return (
<div>
<RiskCheck {...componentProps} imgWidth={300}/>
</div>
)
}
SliderValidate.defaultProps = {}
SliderValidate.isFieldComponent = true;
export default SliderValidate
\ No newline at end of file
......@@ -26,6 +26,7 @@ import { Checkbox, Radio } from '@formily/antd-components';
import DateSelect from './components/DateSelect';
import VirtualChildren from './components/VirtualChildren';
import SmilingFace from './components/SmilingFace';
import SliderValidate from './components/SliderValidate';
import { useLinkComponentProps } from './linkages/linkComponentProps';
import Loading from '../Loading';
......@@ -98,6 +99,7 @@ export const componentExport = {
DateSelect,
VirtualChildren,
SmilingFace,
SliderValidate,
RadioGroup: Radio.Group
}
const NiceForm: React.FC<NiceFormProps> = props => {
......
......@@ -12,12 +12,11 @@ export interface OrderHandReceivedModalProps {
const OrderHandReceivedModal:React.FC<OrderHandReceivedModalProps> = ({currentRef}) => {
const { formContext } = useContext(OrderDetailContext)
const { data } = useContext(OrderDetailContext)
const [confirmVisible, setConfirmVisible] = useState(false)
const formData = formContext.data || {}
const formData = data || {}
const { run, loading } = useHttpRequest(PublicApi.postOrderManualConfirmReceipt)
const handleConfirm = async () => {
console.log('确认收货')
const { code } = await run({
orderId: formData.id
})
......
......@@ -18,7 +18,7 @@ const ReadyReceiveOrderDetail: React.FC = () => {
const approvedRef = useRef<any>({})
// 是否是手工收货
const isHeadReceipt = formContext && formContext.data.interiorState === PurchaseOrderInsideWorkState.HAND_RECEIPT_ORDER
const isHeadReceipt = formContext.data && formContext.data.interiorState === PurchaseOrderInsideWorkState.HAND_RECEIPT_ORDER
const handleClick = useCallback(() => {
if (isHeadReceipt) {
......
......@@ -16,7 +16,7 @@ const ReadyConfirmDelevedOrderDetail: React.FC = () => {
const { formContext, id, detailList } = useOrderDetail({type: 'saleOrder'})
// 是否是手工发货
const isHandDeleved = formContext && formContext.data && formContext.data.purchaseOrderInteriorState === SaleOrderInsideWorkState.HAND_DELEVED_ORDER
const isHandDeleved = formContext.data && formContext.data.purchaseOrderInteriorState === SaleOrderInsideWorkState.HAND_DELEVED_ORDER
// 所有发货单都是否已经发货了
const isShowBtn = formContext.data?.orderDeliveryDetailsResponses?.some(v => v.interiorState === DeliverySideState.ADD_LOGISTICS_ORDER)
......
......@@ -202,6 +202,10 @@ export const forgetPwdSchema: ISchema = {
size: 'large'
}
},
SliderValidate: {
type: 'object',
"x-component": "SliderValidate"
},
smsCode: {
type: 'string',
"x-component": 'Phone',
......
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