Yansen 2 years ago
parent
commit
e98815cb33
2 changed files with 3 additions and 2 deletions
  1. 2
    1
      src/pages/check/edit/components/LocForm.jsx
  2. 1
    1
      src/pages/check/edit/index.jsx

+ 2
- 1
src/pages/check/edit/components/LocForm.jsx View File

68
             <Cell title="性别">
68
             <Cell title="性别">
69
               <View style={{textAlign: 'right'}}>
69
               <View style={{textAlign: 'right'}}>
70
                 <RadioGroup
70
                 <RadioGroup
71
+                  disabled={readonly}
71
                   direction="horizontal"
72
                   direction="horizontal"
72
                   value={answer?.sex}
73
                   value={answer?.sex}
73
                   style={{display: 'inline-flex'}}
74
                   style={{display: 'inline-flex'}}
82
               title="年龄"
83
               title="年龄"
83
               isLink
84
               isLink
84
               value={answer?.age}
85
               value={answer?.age}
85
-              onClick={() => setShowAgePicker(true)}
86
+              onClick={() => !readonly && setShowAgePicker(true)}
86
             />
87
             />
87
             <AgePicker
88
             <AgePicker
88
               show={showAgePicker}
89
               show={showAgePicker}

+ 1
- 1
src/pages/check/edit/index.jsx View File

18
 import Question from './components/Question';
18
 import Question from './components/Question';
19
 import Footer from './components/Footer/index';
19
 import Footer from './components/Footer/index';
20
 
20
 
21
-const isNotEmpty = str => str !== undefined && str !== null && str.replace(/\s/g, '') !== '';
21
+const isNotEmpty = str => str !== undefined && str !== null && `${str}`.replace(/\s/g, '') !== '';
22
 
22
 
23
 export default (props) => {
23
 export default (props) => {
24
 
24