Commit 5b23fea3 authored by leimo's avatar leimo

Merge branch '20418order' into 'v2-220418'

小细节 添加placeholder See merge request linkseeks-design/pro-platform!542
parents 225cb5e4 8e86ceff
......@@ -44,7 +44,9 @@ function LogisticsCompanySelect(props: LogisticsCompanySelectProps) {
}
return (
<Select disabled={disabled} value={value} options={options} onChange={(v) => {
<Select
placeholder={`请选择物流公司`}
disabled={disabled} value={value} options={options} onChange={(v) => {
const option = options.find(o => {
return o.value == v
})
......
......@@ -99,7 +99,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
const handleAnchor = (len) => {
update([
ot === RoleTypeEnum.B2B ? {
ot == RoleTypeEnum.B2B ? {
...DeliveryGood,
name: `${DeliveryGood.name}(${len})`
} :
......@@ -112,7 +112,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
const handleDelAnchor = (len) => {
delUpdate([
ot === RoleTypeEnum.B2B ? {
ot == RoleTypeEnum.B2B ? {
...DeliveryGood,
name: `${DeliveryGood.name}(${len})`
} :
......@@ -160,7 +160,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
validatorByteObject(150)
]}
label={NoteLabel} name="remark">
<Input maxLength={150} placeholder="150个汉字" />
<Input maxLength={150} placeholder="最长150个汉字" />
</FormItem>
<FormItem
......@@ -279,7 +279,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
validatorByteObject(20)
]}
hidden={isLogistics} label={LogisticsCarNoLabel} name="executorVO.carNumbers">
<Input maxLength={20} />
<Input placeholder={`请选择${LogisticsCarNoLabel}`} maxLength={20} />
</FormItem>
<FormItem hidden={isLogistics} label={LogisticsCompanyLabel} name="logisticsCompanyInt">
......@@ -292,11 +292,11 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
]}
hidden={isLogistics}
label={LogisticsNoLabel} name="logisticsNo">
<Input maxLength={20} />
<Input placeholder={`请选择${LogisticsNoLabel}`} maxLength={20} />
</FormItem>
</ContentBox>
<ContentBox title={ot === 1 ? DeliveryGood.name : Material.name}
<ContentBox title={ot == 1 ? DeliveryGood.name : Material.name}
id={ot == 1 ? DeliveryGood.key : Material.key}
cols={1}>
......@@ -307,7 +307,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
rowKey={row => row.orderNo}
columns={
[
...(ot === 1 ? DeliveryNoticeTableColumn : DeliveryNoticeTableColumnSRM)
...(ot == 1 ? DeliveryNoticeTableColumn : DeliveryNoticeTableColumnSRM)
, {
...DeliveryNumColumn,
render: (t, rcode, index) => {
......
......@@ -26,6 +26,7 @@ import { PATTERN_MAPS } from '@/constants/regExp';
import { size } from 'lodash';
import usePrompt from '@/hooks/usePrompt';
import useLogistics from '../../assets/hooks/useLogistics';
import { validatorByteObject } from '@/utils/regExp';
const DeliveryNoticeManageSRMDetails: React.FC = () => {
......@@ -122,7 +123,11 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
<Input />
</FormItem>
<FormItem label={NoteLabel} name="remark">
<FormItem
rules={[
validatorByteObject(100)
]}
label={NoteLabel} name="remark">
<Input placeholder='最长100字符,50个汉字' maxLength={100} />
</FormItem>
......@@ -154,7 +159,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
<FormItem
label={DeliveryNameLabel} name="executorVO.consignee">
<Input />
<Input placeholder={`请输入${DeliveryNameLabel}`} />
</FormItem>
<FormItem
......@@ -171,7 +176,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
{ pattern: PATTERN_MAPS.phone, message: "手机号是否正确" }
]}
label={DeliveryPhoneLabel} name="executorVO.phone">
<Input />
<Input placeholder={`请输入${DeliveryPhoneLabel}`} />
</FormItem>
</ContentBox>
......@@ -225,7 +230,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
</FormItem>
<FormItem hidden={isLogistics} label={LogisticsCarNoLabel} name="executorVO.carNumbers">
<Input maxLength={20} />
<Input placeholder={`请输入${LogisticsCarNoLabel}`} maxLength={20} />
</FormItem>
<FormItem hidden={isLogistics} label={LogisticsCompanyLabel} name="logisticsCompanyInt">
<LogisticsCompanyMerchantsSelect />
......@@ -234,7 +239,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
hidden={isLogistics}
label={LogisticsNoLabel}
name="logisticsNo">
<Input maxLength={20} />
<Input placeholder={`请输入${LogisticsNoLabel}`} maxLength={20} />
</FormItem>
</ContentBox>
......
......@@ -28,6 +28,7 @@ import DeliveryGoodTableSelectSRM from '../../components/DeliveryGoodTableSelect
import { PATTERN_MAPS } from '@/constants/regExp';
import usePrompt from '@/hooks/usePrompt';
import useLogistics from '../../assets/hooks/useLogistics';
import { validatorByteObject } from '@/utils/regExp';
const ContentBoxItem = ContentBox.BaseInfoItem;
......@@ -110,9 +111,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
</FormItem>
<FormItem label={NoteLabel} rules={[
{
max: 100, message: '最长100字符,50个汉字'
}
validatorByteObject(100)
]} name="remark">
<Input.TextArea placeholder='最长100字符,50个汉字' maxLength={100} rows={1} />
</FormItem>
......@@ -147,7 +146,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
<FormItem
label={DeliveryNameLabel} name="executorVO.consignee">
<Input maxLength={16} />
<Input placeholder={`请输入${DeliveryNameLabel}`} maxLength={16} />
</FormItem>
<FormItem
......@@ -163,7 +162,7 @@ const DeliveryNoticeManageSRMDetails: React.FC = () => {
{ pattern: PATTERN_MAPS.phone, message: "手机号是否正确" }
]}
label={DeliveryPhoneLabel} name="executorVO.phone">
<Input maxLength={20} />
<Input placeholder={`请输入${DeliveryPhoneLabel}`} maxLength={20} />
</FormItem>
</ContentBox>
......
......@@ -144,9 +144,7 @@ function DeliveryNoteAddForm() {
</FormItem>
<FormItem label={NoteLabel} name="remark" rules={[
{
max: 100, message: '最长100字节,50个汉字'
}
validatorByteObject(100)
]}>
<Input placeholder="最长100字节,50个汉字" maxLength={100} />
</FormItem>
......@@ -166,12 +164,12 @@ function DeliveryNoteAddForm() {
<FormItem
label={ConsigneeLabel} name="executorVO.consignee">
<Input />
<Input placeholder={`请输入${ConsigneeLabel}`} />
</FormItem>
<FormItem
label={ConsigneePhoneLabel} name="executorVO.phone">
<Input />
<Input placeholder={`请输入${ConsigneePhoneLabel}`} />
</FormItem>
</div>
......@@ -224,7 +222,7 @@ function DeliveryNoteAddForm() {
{info?.executorVO?.carNumbers}
</FormItem>
<FormItem label={LogisticsCompanyLabel} >
{info?.logisticsCompany}
{info?.logisticsCompany ?? '暂无信息'}
</FormItem>
<FormItem
rules={[
......@@ -232,7 +230,7 @@ function DeliveryNoteAddForm() {
]}
label={LogisticsNoLabel} >
<Input hidden maxLength={20} disabled={true} />
{info?.logisticsNo}
{info?.logisticsNo ?? '暂无信息'}
</FormItem>
</ContentBox>
......
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