顾绍勇 5 years ago
parent
commit
8c1151d4d6

+ 4
- 4
src/pages/contact/contact/add.jsx View File

@@ -45,8 +45,8 @@ const header = props => {
45 45
             type: FieldTypes.Text,
46 46
             value: data.contactName,
47 47
             rules: [
48
-                { required: true, message: '请输入通知标题' },
49
-                { max: 6, message: '通知标题名称不超过6个字符' }
48
+                { required: true, message: '请输入姓名' },
49
+                { max: 6, message: '姓名不能超过6个字符' }
50 50
             ]
51 51
         },
52 52
         {
@@ -74,7 +74,7 @@ const header = props => {
74 74
             rules: [
75 75
                 { required: false, message: '请选择头像' },
76 76
             ],
77
-            help: '建议尺寸:Npx*Npx,比例:1:1,格式:jpg,大小:不超过300KB,用于客户查看',
77
+            help: '建议尺寸:100px*100px,比例:1:1,格式:jpg,大小:不超过300KB,用于样例列表封面',
78 78
         },
79 79
         {
80 80
             label: '对外头衔',
@@ -133,7 +133,7 @@ const header = props => {
133 133
             value: data.address,
134 134
             rules: [
135 135
                 { required: false, message: '请输入联系地址' },
136
-                { max: 40, message: '邮箱不能超过40个字符' }
136
+                { max: 40, message: '联系地址不能超过40个字符' }
137 137
             ]
138 138
         },
139 139
         {

+ 5
- 5
src/pages/contact/contact/detail.jsx View File

@@ -62,15 +62,15 @@ const header = props => {
62 62
             type: FieldTypes.Text,
63 63
             value: data.contactName,
64 64
             rules: [
65
-                { required: true, message: '请输入通知标题' },
66
-                { max: 6, message: '通知标题名称不超过6个字符' }
65
+                { required: true, message: '请输入姓名' },
66
+                { max: 6, message: '姓名不能超过6个字符' }
67 67
             ]
68 68
         },
69 69
         {
70 70
             label: '性别',
71 71
             name: 'sex',
72 72
             type: FieldTypes.Select,
73
-            value: data.sex === 1 ? '男' : '女',
73
+            value: data.sex != null ? (data.sex === 1 ? '男' : '女') : "",
74 74
             dict: [{
75 75
                 name: '男',
76 76
                 value: '1',
@@ -91,7 +91,7 @@ const header = props => {
91 91
             rules: [
92 92
                 { required: false, message: '请选择头像' },
93 93
             ],
94
-            help: '建议尺寸:Npx*Npx,比例:1:1,格式:jpg,大小:不超过300KB,用于客户查看',
94
+            help: '建议尺寸:100*100px,比例:1:1,格式:jpg,大小:不超过300KB,用于样例列表封面',
95 95
         },
96 96
         {
97 97
             label: '对外头衔',
@@ -150,7 +150,7 @@ const header = props => {
150 150
             value: data.address,
151 151
             rules: [
152 152
                 { required: false, message: '请输入联系地址' },
153
-                { max: 40, message: '邮箱不能超过40个字符' }
153
+                { max: 50, message: '联系地址不能超过50个字符' }
154 154
             ]
155 155
         },
156 156
         {

+ 5
- 4
src/pages/contact/contact/list.jsx View File

@@ -64,7 +64,7 @@ function header(props) {
64 64
         }
65 65
 
66 66
         Modal.confirm({
67
-            title: '确定联系人信息吗',
67
+            title: '确定删除联系人信息吗',
68 68
             okText: '确定',
69 69
             cancelText: '取消',
70 70
             onOk() {
@@ -72,9 +72,10 @@ function header(props) {
72 72
                     message.info("操作成功")
73 73
                     getList({ pageNum: 1, pageSize: 10 });
74 74
                 }).catch((err) => {
75
-                    
75
+
76 76
                 })
77 77
             },
78
+            onCancel() { },
78 79
         });
79 80
     }
80 81
 
@@ -102,7 +103,7 @@ function header(props) {
102 103
             dataIndex: 'sex',
103 104
             key: 'sex',
104 105
             align: 'center',
105
-            render: (sex) => <span>{sex === 1 ? '男' : '女'}</span>,
106
+            render: (sex) => <span>{sex != null ? (sex === 1 ? '男' : '女') : ""}</span>,
106 107
         },
107 108
         {
108 109
             title: '头像',
@@ -205,7 +206,7 @@ function header(props) {
205 206
 
206 207
                 <Button type="primary" className={styles.addBtn} onClick={toDel()} style={{ marginLeft: '30px' }} >删除</Button>
207 208
 
208
-                <Table rowSelection={rowSelection} rowKey="goodsList" dataSource={data.records} columns={columns} pagination={false} />
209
+                <Table rowSelection={rowSelection} rowKey={r => r.contactId} dataSource={data.records} columns={columns} pagination={false} />
209 210
 
210 211
                 <div style={{ display: 'flex', justifyContent: 'flex-end', marginTop: '30px' }}>
211 212
                     {<Pagination showQuickJumper defaultCurrent={1} total={data.total} onChange={e => changePageNum(e)} current={data.current} />}