张延森 5 年 前
コミット
46bbc3d21c

+ 0
- 1
package.json ファイルの表示

@@ -54,7 +54,6 @@
54 54
     "omit.js": "^1.0.2",
55 55
     "path-to-regexp": "^3.0.0",
56 56
     "qrcode.react": "^0.9.3",
57
-    "qrcodejs2": "0.0.2",
58 57
     "qs": "^6.7.0",
59 58
     "react": "^16.8.6",
60 59
     "react-amap": "^1.2.8",

+ 18
- 0
src/components/Wangedit/Wangedit.jsx ファイルの表示

@@ -43,6 +43,24 @@ class Wangedit extends React.Component {
43 43
 
44 44
       fetch(apis.image.upload)({data}).then(insert)
45 45
     }
46
+    this.editor.customConfig.menus = [
47
+      'head',  // 标题
48
+      'bold',  // 粗体
49
+      'fontSize',  // 字号
50
+      'fontName',  // 字体
51
+      'italic',  // 斜体
52
+      'underline',  // 下划线
53
+      'strikeThrough',  // 删除线
54
+      'foreColor',  // 文字颜色
55
+      'backColor',  // 背景颜色
56
+      'list',  // 列表
57
+      'justify',  // 对齐方式
58
+      'quote',  // 引用
59
+      'image',  // 插入图片
60
+      'undo',  // 撤销
61
+      'redo'  // 重复
62
+    ]
63
+
46 64
     this.editor.create()
47 65
     this.editor.customConfig.uploadImgShowBase64 = true
48 66
     this.editor.txt.html(this.props.value)

+ 1
- 1
src/pages/activity/ActivityList.jsx ファイルの表示

@@ -3,7 +3,7 @@ import { Form, Input, Button, Icon, Select, message, Table, Divider, Tag, Pagina
3 3
 import { FormattedMessage } from 'umi-plugin-react/locale';
4 4
 import router from 'umi/router';
5 5
 import moment from 'moment';
6
-import QRCode from 'qrcodejs2'
6
+// import QRCode from 'qrcodejs2'
7 7
 import styles from '../style/GoodsList.less';
8 8
 import SelectCity from '../../components/SelectButton/CitySelect'
9 9
 import BuildSelect from '../../components/SelectButton/BuildSelect'

+ 2
- 2
src/pages/building/list/add/components/base.jsx ファイルの表示

@@ -171,11 +171,11 @@ function AddBuilding(props) {
171 171
               <ImageUpload />,
172 172
             )}
173 173
           </Form.Item>
174
-          <Form.Item label="海报底图" help="建议图片尺寸:640px*1136px" >
174
+          {/* <Form.Item label="海报底图" help="建议图片尺寸:640px*1136px" >
175 175
             {getFieldDecorator('poster')(
176 176
               <ImageUpload />,
177 177
             )}
178
-          </Form.Item>
178
+          </Form.Item> */}
179 179
           <Form.Item label="排序" >
180 180
             {getFieldDecorator('orderNo')(<Input />)}
181 181
           </Form.Item>

+ 6
- 1
src/pages/building/list/add/components/poster.jsx ファイルの表示

@@ -71,6 +71,11 @@ const Poster = props => {
71 71
 
72 72
   const submitPoster = () => {
73 73
     if (buildingId) {
74
+      if (!imgValue) {
75
+        message.error('请选择海报图片')
76
+        return
77
+      }
78
+
74 79
       if (posterId) {
75 80
         request({
76 81
           ...apis.activity.updatePoster,
@@ -136,7 +141,7 @@ const Poster = props => {
136 141
       </div>
137 142
       <div >
138 143
         <div style={{ display: 'flex', width: '100%', margin: '60px 0' }}>
139
-          <p style={{ minWidth: '200px', color: '#222', textAlign: 'right', margin: '0 30px 0 0' }}>海报图片</p>
144
+          <p style={{ minWidth: '200px', color: '#222', textAlign: 'right', margin: '0 30px 0 0' }}><span style={{ color: 'red' }}>*</span> 海报图片</p>
140 145
           <ImageUploader value={imgValue} onChange={e => changeImg(e)} />
141 146
         </div>
142 147
         <div style={{ display: 'flex', alignItems: 'center', width: '100%', marginBottom: '60px' }}>

+ 3
- 2
src/pages/building/list/index.jsx ファイルの表示

@@ -31,7 +31,6 @@ function openNotificationWithIcon(type, message) {
31 31
 function CartBody(props) {
32 32
   const { data } = props
33 33
 
34
-
35 34
   function toEdi(record) {
36 35
     router.push({
37 36
       pathname: '/building/list/add',
@@ -98,11 +97,13 @@ function CartBody(props) {
98 97
     });
99 98
   }
100 99
 
100
+  const { buildingImg = []} = data
101
+
101 102
   return (
102 103
     <Card
103 104
       hoverable
104 105
       style={{ minWidth: '330px', borderRadius: '12px', margin: '10px', boxShadow: '0px 0px 16px 2px rgba(0,0,0,0.12)' }}
105
-      cover={<img alt="example" src={data.poster} style={{ borderRadius: '12px 12px 0 0', width: '100%', height: '14vw' }}></img>}
106
+      cover={<img alt="example" src={(buildingImg[0] || {}).url} style={{ borderRadius: '12px 12px 0 0', width: '100%', height: '14vw' }}></img>}
106 107
       bodyStyle={{ padding: '10px 20px' }}
107 108
     >
108 109
       <p className={Styles.cardText}>

+ 1
- 1
src/pages/carouselFigure/carouselFigureList.jsx ファイルの表示

@@ -185,7 +185,7 @@ const handleSubmit = (e, props) => {
185 185
               <Option value="activity">活动</Option>
186 186
               <Option value="project">项目</Option>
187 187
               <Option value="news">资讯</Option>
188
-              <Option value="other">其他</Option>
188
+              {/* <Option value="other">其他</Option> */}
189 189
             </Select>,
190 190
           )}
191 191
         </Form.Item>

+ 4
- 4
src/pages/carouselFigure/editCarousel.jsx ファイルの表示

@@ -123,10 +123,10 @@ const { MonthPicker, RangePicker, WeekPicker } = DatePicker;
123 123
             label: '资讯',
124 124
             value: 'news',
125 125
           },
126
-          {
127
-            label: '其他',
128
-            value: 'other',
129
-          },
126
+          // {
127
+          //   label: '其他',
128
+          //   value: 'other',
129
+          // },
130 130
           {
131 131
             label: '拼团',
132 132
             value: 'group',