Commit 4c2f499f authored by XieZhiXiong's avatar XieZhiXiong

fix: 伪造 label *

parent a34ef4b2
.label {
font-size: 12px;
color: #909399;
&::after {
margin-left: 4px;
font-size: 12px;
font-family: SimSun, sans-serif;
color: #ff4d4f;
content: '*';
}
}
\ No newline at end of file
......@@ -9,8 +9,8 @@ import NiceForm from '@/components/NiceForm';
import { warehouseDetailSchema } from './schema';
import { useLinkEnumEffect } from '@/components/NiceForm/linkages/linkEnum';
import { useAsyncSelect } from '@/formSchema/effects/useAsyncSelect';
import { usePageStatus, PageStatus } from '@/hooks/usePageStatus';
import { PublicApi } from '@/services/api';
import styles from './index.less';
const formActions = createFormActions();
const {
......@@ -117,6 +117,12 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
setUnsaved(false);
};
const AddressLabel = (
<div className={styles.label}>
仓库地址
</div>
);
return (
<Spin spinning={infoLoading}>
<PageHeaderWrapper
......@@ -152,6 +158,9 @@ const WarehouseForm: React.FC<WarehouseFormProps> = ({
<NiceForm
previewPlaceholder="' '"
editable={isEdit || !id}
expressionScope={{
AddressLabel,
}}
effects={($, { setFieldState }) => {
useLinkEnumEffect('areaResponses', result =>
result.map(v => ({
......
......@@ -35,7 +35,7 @@ export const warehouseDetailSchema: ISchema = {
type: 'object',
'x-component': 'mega-layout',
'x-component-props': {
label: '仓库地址',
label: '{{AddressLabel}}',
wrapperCol: 24,
},
required: true,
......
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