李志伟 hace 3 años
padre
commit
08ecbc107f
Se han modificado 1 ficheros con 8 adiciones y 4 borrados
  1. 8
    4
      src/pages/org/org/Edit.jsx

+ 8
- 4
src/pages/org/org/Edit.jsx Ver fichero

@@ -63,13 +63,17 @@ export default (props) => {
63 63
               name="orgName"
64 64
               rules={[{ required: true, message: '请填写企业名称!' }]}
65 65
             >
66
-              <Input />
66
+              <Input readOnly={id} />
67 67
             </Form.Item>
68 68
 
69 69
             <Form.Item wrapperCol={{ offset: 8, span: 16 }}>
70
-              <Button type="primary" htmlType="submit" loading={loading}>
71
-                保存
72
-              </Button>
70
+              {
71
+                id ?
72
+                  <Button onClick={()=>history.go(-1)}>返回</Button> :
73
+                  <Button type="primary" htmlType="submit" loading={loading}>
74
+                    保存
75
+                  </Button>
76
+              }
73 77
             </Form.Item>
74 78
           </Form>
75 79
         </div>