Bläddra i källkod

fix: update words

hi-cactus! 3 år sedan
förälder
incheckning
0a7f6589ad

+ 1 - 1
app/containers/DataGovernanceMarkRule/components/AuditClassificationFormModal.tsx

@@ -135,7 +135,7 @@ export const AuditClassificationFormModal = (
   const handleDeleteTheme = async (data: IRule) => {
     try {
       setTableLoading(true)
-      const result = await request(api.deleteDataSubject + data.id)
+      const result = await request(api.deleteDataSubject + data.id, { method: 'delete' })
       // @ts-ignore
       if (result?.header?.code === 200) {
         message.success({ content: '删除成功' })

+ 30 - 9
app/containers/DataGovernanceMarkRule/components/RuleFormModal.tsx

@@ -140,7 +140,13 @@ class RuleFormModal extends React.PureComponent<IRuleFormModalProps> {
         <Form>
           <FormItem label="规则编号" {...this.formItemStyle} required>
             {getFieldDecorator<IDataRule>('ruleCode', {
-              initialValue: fromView?.ruleCode
+              initialValue: fromView?.ruleCode,
+              rules: [
+                {
+                  required: true,
+                  message: '请输入'
+                }
+              ]
             })(<Input />)}
             {!fromView?.id && (
               <Button onClick={this.handleSetUUID}>自动生成编号</Button>
@@ -148,7 +154,13 @@ class RuleFormModal extends React.PureComponent<IRuleFormModalProps> {
           </FormItem>
           <FormItem label="规则名称" {...this.formItemStyle} required>
             {getFieldDecorator<IDataRule>('ruleName', {
-              initialValue: fromView?.ruleName
+              initialValue: fromView?.ruleName,
+              rules: [
+                {
+                  required: true,
+                  message: '请输入'
+                }
+              ]
             })(<Input />)}
           </FormItem>
           <FormItem label="规则描述" {...this.formItemStyle}>
@@ -156,9 +168,15 @@ class RuleFormModal extends React.PureComponent<IRuleFormModalProps> {
               initialValue: fromView?.ruleDesc
             })(<Input />)}
           </FormItem>
-          <FormItem label="规则类型" {...this.formItemStyle}>
+          <FormItem label="规则类型" {...this.formItemStyle} required>
             {getFieldDecorator<IDataRule>('ruleType', {
-              initialValue: fromView?.ruleType
+              initialValue: fromView?.ruleType,
+              rules: [
+                {
+                  required: true,
+                  message: '请输入'
+                }
+              ]
             })(
               <Radio.Group>
                 {inspectionType === 'integrity' && (
@@ -173,9 +191,9 @@ class RuleFormModal extends React.PureComponent<IRuleFormModalProps> {
                 {inspectionType === 'uniformity' && (
                   <Radio value="date_format">日期格式</Radio>
                 )}
-                {inspectionType === 'uniformity' && (
-                  <Radio value="">自定义</Radio>
-                )}
+                {/*{inspectionType === 'uniformity' && (*/}
+                {/*  <Radio value="">自定义</Radio>*/}
+                {/*)}*/}
                 {inspectionType === 'normative' && (
                   <Radio value="null_data">空值</Radio>
                 )}
@@ -186,10 +204,13 @@ class RuleFormModal extends React.PureComponent<IRuleFormModalProps> {
             )}
           </FormItem>
           {this.props.form.getFieldValue('ruleType') === 'range' && (
-            <FormItem label="值域" {...this.formItemStyle}>
+            <FormItem label="值域" {...this.formItemStyle} required>
               {getFieldDecorator<IDataRule>('ruleConfig', {
                 initialValue: fromView?.ruleConfig?.range,
-                rules: [{ validator: this.checkRange }]
+                rules: [
+                  { validator: this.checkRange },
+                  { required: true, message: '请输入' }
+                ]
               })(<NumberRange />)}
             </FormItem>
           )}

+ 1 - 1
app/containers/DataGovernanceMarkRule/index.tsx

@@ -71,7 +71,7 @@ function DataDictionary() {
               setDataSubjectForm(data)
             }}
           >
-            编辑
+            列表
           </a>
           <Divider type="vertical" />
           <a

+ 1 - 0
app/containers/DataManagerView/index.tsx

@@ -364,6 +364,7 @@ export class ViewList extends React.PureComponent<IViewListProps,
         copyModalVisible: false
       })
       message.info('数据资产 复制成功')
+      this.loadViews()
     })
   }