瀏覽代碼

Merge branch 'master' of http://git.ycjcjy.com/zhiyuxing/estateagents-admin-manager

魏熙美 5 年之前
父節點
當前提交
eea01ab292

+ 1
- 1
config/routes.js 查看文件

@@ -206,7 +206,7 @@ export default [
206 206
               },
207 207
               {
208 208
                 path: '/channel/InviteClients',
209
-                name: '邀请客户',
209
+                name: '邀请经纪人',
210 210
                 hideInMenu: true,
211 211
                 component: './channel/InviteClients',
212 212
               },

+ 2
- 2
src/pages/activity/ActivityList.jsx 查看文件

@@ -106,11 +106,11 @@ const toEditGoods = (dynamicId) => () => {
106 106
             <span style={{ color: '#1990FF', cursor: 'pointer' }} onClick={sendOrPublicDynamic.bind(this,row)}>{ row.status === 1 ? '取消发布' : '发布' }<Icon type="close-circle" className={styles.edit} /></span>
107 107
           </AuthButton>
108 108
           <AuthButton name="admin.buildingDynamic.finish.put" noRight={null}>
109
-            <span style={{ color: '#1990FF', cursor: 'pointer' }} onClick={finishDynamic.bind(this,row)}>结束活动<Icon type="poweroff" className={styles.edit} /></span>
109
+            {row.isEnlist != 2 && <span style={{ color: '#1990FF', cursor: 'pointer' }} onClick={finishDynamic.bind(this,row)}>结束活动<Icon type="poweroff" className={styles.edit} /></span>}
110 110
           </AuthButton>
111 111
           <AuthButton name="admin.buildingDynamic.update.put" noRight={null}>
112 112
             <span style={{ color: '#1990FF', marginRight: '20px', cursor: 'pointer' }} onClick={topDynamic(row)}>{ row.weight === 1 ? '取消置顶' : '置顶' }<Icon type="vertical-align-top" className={styles.edit} /></span>
113
-            <span style={{ color: '#FF925C', cursor: 'pointer' }} onClick={toEditGoods(row.dynamicId)}>编辑<Icon type="form" className={styles.edit} /></span>
113
+            {row.isEnlist != 2 && <span style={{ color: '#FF925C', cursor: 'pointer' }} onClick={toEditGoods(row.dynamicId)}>编辑<Icon type="form" className={styles.edit} /></span>}
114 114
           </AuthButton>
115 115
         </>
116 116
       )

+ 4
- 3
src/pages/activity/editActivity.jsx 查看文件

@@ -133,7 +133,8 @@ const Edit = (props) => {
133 133
         label: '报名时间',
134 134
         name: 'signupTime',
135 135
         type: FieldTypes.RangePicker,
136
-        value: dynamicData.enlistStart != null ? [moment(dynamicData.enlistStart, 'YYYY-MM-DD'), moment(dynamicData.enlistEnd, 'YYYY-MM-DD')] : null,
136
+        value: dynamicData.enlistStart != null ? [moment(dynamicData.enlistStart, 'YYYY-MM-DD HH:mm'), moment(dynamicData.enlistEnd, 'YYYY-MM-DD HH:mm')] : null,
137
+        props: {showTime:{ format: 'HH:mm' }},
137 138
         rules: [
138 139
           { required: true, message: '请选择报名时间' },
139 140
         ]
@@ -146,8 +147,8 @@ const Edit = (props) => {
146 147
       submitValue.startDate = moment(startDate).format('YYYY-MM-DD HH:mm');
147 148
       submitValue.endDate = moment(endDate).format('YYYY-MM-DD HH:mm');
148 149
       const [enlistStart, enlistEnd] = signupTime
149
-      submitValue.enlistStart = moment(enlistStart).format('YYYY-MM-DD');
150
-      submitValue.enlistEnd = moment(enlistEnd).format('YYYY-MM-DD');
150
+      submitValue.enlistStart = moment(enlistStart).format('YYYY-MM-DD HH:mm');
151
+      submitValue.enlistEnd = moment(enlistEnd).format('YYYY-MM-DD HH:mm');
151 152
       console.log('submit data --->', submitValue)
152 153
       if (dynamicId) {
153 154
         submitValue.dynamicId = dynamicId

+ 1
- 1
src/pages/building/list/index.jsx 查看文件

@@ -135,7 +135,7 @@ function CartBody(props) {
135 135
       </p>
136 136
       <p className={Styles.cardItem}>
137 137
         <span className={Styles.title}>录入时间</span>
138
-        <span >:{data.createDate}</span>
138
+        <span >:{moment(data.createDate).format('YYYY-MM-DD HH:mm:ss')}</span>
139 139
       </p>
140 140
       <p style={{ margin: '15px 0', position: 'relative', fontSize: '0.106rem' }}>
141 141
       <AuthButton name="admin.building.update.status.put" noRight={null}>

+ 1
- 0
src/pages/channel/recommendClients.jsx 查看文件

@@ -84,6 +84,7 @@ const columns = [
84 84
     dataIndex: 'createDate',
85 85
     key: 'createDate',
86 86
     align: 'center',
87
+    render: (_, record) => <><span>{ record.createDate && moment(record.createDate).format('YYYY-MM-DD') }</span></>,
87 88
   },
88 89
   {
89 90
     title: '状态',

+ 1
- 0
src/pages/customer/independentList/index.jsx 查看文件

@@ -106,6 +106,7 @@ class ModalTable extends React.Component {
106 106
         title: '推荐时间',
107 107
         dataIndex: 'createDate',
108 108
         key: 'createDate',
109
+        render: (_, record) => <><span>{ record.createDate && moment(record.createDate).format('YYYY-MM-DD') }</span></>,
109 110
       },
110 111
       {
111 112
         title: '状态',

+ 17
- 1
src/pages/news/list/NewsList.jsx 查看文件

@@ -5,6 +5,7 @@ import router from 'umi/router';
5 5
 import request from '../../../utils/request';
6 6
 import apis from '../../../services/apis';
7 7
 import Styles from './style.less';
8
+import styles from '../../style/GoodsList.less';
8 9
 import NewsTypeSelect from '../../../components/SelectButton/NewTypeSelect'
9 10
 import BuildSelect from '../../../components/SelectButton/BuildSelect'
10 11
 import SelectCity from '../../../components/SelectButton/CitySelect'
@@ -118,6 +119,19 @@ function body(props) {
118 119
       });
119 120
     }
120 121
 
122
+    //   置顶
123
+    const topNews = (weightParam, newsId) => () => {
124
+      const weight = Math.abs(weightParam - 1)
125
+      request({ ...apis.news.weight, params: {newsId: newsId, weight} }).then((data) => {
126
+          console.log(data)
127
+          message.info('操作成功!')
128
+          getList({ pageNum: 1, pageSize: 10 })
129
+      }).catch((err) => {
130
+          console.log(err)
131
+          message.info(err.msg || err.message)
132
+      })
133
+    }
134
+
121 135
     function cancelRelease(newsId, newsStatus, buildingId, newsTypeId) {
122 136
       console.log("newsId" + newsId + "status" + newsStatus);
123 137
       if (newsStatus === 1) {
@@ -167,6 +181,8 @@ function body(props) {
167 181
         bodyStyle={{ padding: '10px 20px' }}
168 182
       >
169 183
         <AuthButton name="admin.taNews.id.put" noRight={null}>
184
+          <span style={{ position: 'absolute', right: '100px', top: '19px', fontSize: ' 0.106rem',zIndex:1, color: '#FF7E48', cursor: 'pointer' }} onClick={topNews(data.weight, data.newsId)}>{ data.weight === 1 ? '取消置顶' : '置顶' }</span>
185
+
170 186
           <span style={{ position: 'absolute', right: '20px', top: '20px', fontSize: ' 0.106rem',zIndex:1, color: '#FF7E48', cursor: 'pointer' }} onClick={toEditList(data.newsId)}>
171 187
             编辑
172 188
                   <Icon type="form" style={{ color: '#C0C4CC', marginLeft: '10px' }} />
@@ -210,7 +226,7 @@ function body(props) {
210 226
             <span>收藏数量:{data.saveNum}</span>
211 227
           </p>
212 228
 
213
-          <p style={{ fontSize: ' 0.106rem', color: '#999', marginBottom: '8px' }}>发布时间:{data.createDate}</p>
229
+          <p style={{ fontSize: ' 0.106rem', color: '#999', marginBottom: '8px' }}>发布时间:{moment(data.createDate).format('YYYY-MM-DD HH:mm:ss')}</p>
214 230
         </div>
215 231
       </Card>
216 232
     )

+ 1
- 0
src/pages/staff/list/editStaff.jsx 查看文件

@@ -121,6 +121,7 @@ const Edit = (props) => {
121 121
       type: FieldTypes.Text,
122 122
       placeholder: '请输入电话号码',
123 123
       value: userData.phone,
124
+      help: '默认密码:123456',
124 125
     },
125 126
     {
126 127
       label: '角色',

+ 5
- 0
src/services/apis.js 查看文件

@@ -156,6 +156,11 @@ export default {
156 156
       method: 'PUT',
157 157
       url: `${prefix}/taNews/:id`,
158 158
       action: 'admin.taNews.id.put',
159
+    },
160
+    weight: {
161
+      method: 'PUT',
162
+      url: `${prefix}/taNews/weight`,
163
+      action: 'admin.taNews.weight.put',
159 164
     }
160 165
   },
161 166
   newsType: {