Browse Source

企业邮件邀请,需求列表

lyn7568 6 years ago
parent
commit
1ed9a251cc

+ 1 - 1
config/index.js

@ -66,7 +66,7 @@ module.exports = {
66 66
     * Source Maps
67 67
     */
68 68
69
    productionSourceMap: true,
69
    productionSourceMap: false,
70 70
    // https://webpack.js.org/configuration/devtool/#production
71 71
    devtool: '#source-map',
72 72

+ 3 - 0
src/api/companyCen.js

@ -32,3 +32,6 @@ export const pageProduct = '/ajax/product/pq'
32 32
export const queryProductOne = '/ajax/product/qo'
33 33
/* 查看产品关键词类型内容 */
34 34
export const queryProductKeyword = '/ajax/product/qo/keyword'
35
36
// 邀请
37
export const inviteMail = '/ajax/company/invite/mail'

+ 16 - 13
src/views/companyCen/noactive/invite.vue

@ -11,7 +11,7 @@
11 11
</template>
12 12
13 13
<script>
14
// import {  } from '@/api/companyCen'
14
import { inviteMail } from '@/api/companyCen'
15 15
16 16
export default {
17 17
  data() {
@ -26,24 +26,27 @@ export default {
26 26
      var that = this
27 27
      if (row) {
28 28
        that.infoRow = row
29
        that.companyId = row.id
29 30
        setTimeout(function() {
30 31
          that.inviteDialogVisible = true
31 32
        }, 0)
32 33
      }
33 34
    },
34 35
    publishInvite() {
35
      // var that = this
36
      // that.$http.post(blackUser, {
37
      //   id: that.companyId
38
      // }, function(res) {
39
      //   if (res.success) {
40
      //     if (res.data === 0) {
41
      //       that.$message('该用户已经被拉黑,不允许操作')
42
      //     } else {
43
      //     }
44
      //     that.inviteDialogVisible = false
45
      //   }
46
      // })
36
      var that = this
37
      that.$http.post(inviteMail, {
38
        id: that.companyId
39
      }, function(res) {
40
        if (res.success) {
41
          if (res.data === 0) {
42
            that.$message({
43
              message: '邮箱发送成功,请耐心等待',
44
              type: 'success'
45
            })
46
          }
47
          that.inviteDialogVisible = false
48
        }
49
      })
47 50
    }
48 51
  }
49 52
}

+ 4 - 1
src/views/companyCen/noactive/noactiveList.vue

@ -119,7 +119,7 @@ export default {
119 119
          tit: '邀请码'
120 120
        },
121 121
        {
122
          prop: 'inviteTime',
122
          prop: 'activeTime',
123 123
          tit: '最后邀请时间',
124 124
          width: '160'
125 125
        },
@ -154,6 +154,9 @@ export default {
154 154
              if (obj[i].createTime) {
155 155
                obj[i].createTime = parseTime(obj[i].createTime)
156 156
              }
157
              if (obj[i].activeTime) {
158
                obj[i].activeTime = parseTime(obj[i].activeTime)
159
              }
157 160
              (function(item, num) {
158 161
                item.industry = []
159 162
                item.inviteCode = ''

+ 0 - 2
src/views/companyCen/noactive/productInfo.vue

@ -81,7 +81,6 @@
81 81
  } from '@/utils/validator'
82 82
  import { urlParse } from '@/utils'
83 83
84
  import cityPicker from '@/components/CityPicker'
85 84
  import dynamicTags from '@/components/DynamicTags'
86 85
  import uploadFile from '@/components/uploadFile'
87 86
@ -127,7 +126,6 @@
127 126
    },
128 127
    components: {
129 128
      dynamicTags,
130
      cityPicker,
131 129
      uploadFile
132 130
    },
133 131
    created() {

+ 1 - 1
src/views/demandCen/closeOperate.vue

@ -24,7 +24,7 @@
24 24
      </el-form-item>
25 25
      <div class="el-btn-col">
26 26
        <div class="el-btn-col-box" align="center">
27
          <el-button type="primary" @click="submitReq">确定</el-button>
27
          <el-button type="primary" @click="submitReq">提交</el-button>
28 28
          <el-button type="info" @click="closedDiloag">关闭</el-button>
29 29
        </div>
30 30
      </div>

+ 8 - 2
src/views/demandCen/closedList.vue

@ -3,8 +3,8 @@
3 3
    <div class="box-container">
4 4
      <div class="contain-title">已关闭需求</div>
5 5
      <div class="contain-search">
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="pageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="pageQuery"></el-button>
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="searchPageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="searchPageQuery"></el-button>
8 8
        </el-input>
9 9
      </div>
10 10
    </div>
@ -118,6 +118,12 @@
118 118
      this.pageQuery()
119 119
    },
120 120
    methods: {
121
      searchPageQuery() {
122
        this.pageNo = 1
123
        this.total = 0
124
        this.tableData = []
125
        this.pageQuery()
126
      },
121 127
      pageQuery() {
122 128
        var that = this
123 129
        this.$http.get(pageDemandUrl, {

+ 79 - 8
src/views/demandCen/completedList.vue

@ -3,8 +3,8 @@
3 3
    <div class="box-container">
4 4
      <div class="contain-title">已完成需求</div>
5 5
      <div class="contain-search">
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="pageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="pageQuery"></el-button>
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="searchPageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="searchPageQuery"></el-button>
8 8
        </el-input>
9 9
      </div>
10 10
    </div>
@ -53,10 +53,12 @@
53 53
</template>
54 54
55 55
<script>
56
  import axios from 'axios'
57
  import qs from 'qs'
56 58
  import queryBase from '@/utils/queryBase'
57 59
  import comTable from '@/utils/comTable'
58
  import { pageDemandUrl, pqDemandNum } from '@/api/demand'
59
  import { TimeTr } from '@/utils/index'
60
  import { pageDemandUrl, pqDemandNum, pqDemandPro, feedbackReason } from '@/api/demand'
61
  import { TimeTr, kexiuUrl } from '@/utils/index'
60 62
61 63
  import closeOperate from './closeOperate'
62 64
@ -99,9 +101,8 @@
99 101
            tit: '回复者数量'
100 102
          },
101 103
          {
102
            prop: 'jy',
103
            tit: '意见建议',
104
            width: '200'
104
            prop: 'feedback',
105
            tit: '意见建议'
105 106
          },
106 107
          {
107 108
            prop: 'overTime',
@ -109,7 +110,7 @@
109 110
            width: '160'
110 111
          },
111 112
          {
112
            prop: 'expert',
113
            prop: 'proArr',
113 114
            tit: '专家合作者'
114 115
          },
115 116
          {
@ -126,6 +127,12 @@
126 127
      this.pageQuery()
127 128
    },
128 129
    methods: {
130
      searchPageQuery() {
131
        this.pageNo = 1
132
        this.total = 0
133
        this.tableData = []
134
        this.pageQuery()
135
      },
129 136
      pageQuery() {
130 137
        var that = this
131 138
        this.$http.get(pageDemandUrl, {
@ -152,8 +159,11 @@
152 159
                (function(item, num) {
153 160
                  item.countNum = ''
154 161
                  item.creatorName = ''
162
                  item.feedback = ''
163
                  item.proArr = ''
155 164
                  that.turnOutProCount(item, num)
156 165
                  that.turnOutUserName(item, num)
166
                  that.turnOutProNames(item, num)
157 167
                })(obj[i], hData.num)
158 168
              }
159 169
              hData.num--
@ -176,6 +186,16 @@
176 186
          if (sc) {
177 187
            num--
178 188
            lmt.creatorName = value.account
189
            that.$http.get(feedbackReason, {
190
              target: lmt.id,
191
              type: 1,
192
              creator: lmt.creator
193
            }, function(res) {
194
              if (res.success && res.data) {
195
                lmt.feedback = res.data.cnt
196
                that.$forceUpdate()
197
              }
198
            })
179 199
            that.$forceUpdate()
180 200
          }
181 201
        })
@ -193,6 +213,57 @@
193 213
          }
194 214
        })
195 215
      },
216
      turnOutProNames(lmt, num) {
217
        const proQmUrl = kexiuUrl + '/ajax/professor/qm'
218
        var that = this
219
        num++
220
        this.$http.get(pqDemandPro, {
221
          id: lmt.id,
222
          actived: 1,
223
          pageSize: 5,
224
          pageNo: 1
225
        }, function(res) {
226
          if (res.success) {
227
            const obj = res.data.data
228
            var arr = []
229
            if (obj.length > 0) {
230
              for (let i = 0; i < obj.length; ++i) {
231
                arr.push(obj[i].uid)
232
              }
233
              if (arr.length > 0) {
234
                axios({
235
                  method: 'get',
236
                  url: proQmUrl,
237
                  params: {
238
                    id: arr
239
                  },
240
                  paramsSerializer: params => {
241
                    return qs.stringify(params, { indices: false })
242
                  }
243
                }).then(data => {
244
                  if (data.data.success && data.data.data) {
245
                    num--
246
                    const $info = data.data.data
247
                    if ($info.length > 0) {
248
                      var names = []
249
                      for (let j = 0; j < $info.length; ++j) {
250
                        names.push($info[j].name)
251
                      }
252
                      if (names.length < 5) {
253
                        lmt.proArr = names.join(',')
254
                      } else {
255
                        names.splice(4, 1)
256
                        lmt.proArr = names.join(',') + ' ...'
257
                      }
258
                      that.$forceUpdate()
259
                    }
260
                  }
261
                })
262
              }
263
            }
264
          }
265
        })
266
      },
196 267
      handelView(id) {
197 268
        this.$router.push({
198 269
          name: 'preview',

+ 8 - 2
src/views/demandCen/expiredList.vue

@ -3,8 +3,8 @@
3 3
    <div class="box-container">
4 4
      <div class="contain-title">已过期需求</div>
5 5
      <div class="contain-search">
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="pageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="pageQuery"></el-button>
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="searchPageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="searchPageQuery"></el-button>
8 8
        </el-input>
9 9
      </div>
10 10
    </div>
@ -124,6 +124,12 @@
124 124
      this.pageQuery()
125 125
    },
126 126
    methods: {
127
      searchPageQuery() {
128
        this.pageNo = 1
129
        this.total = 0
130
        this.tableData = []
131
        this.pageQuery()
132
      },
127 133
      pageQuery() {
128 134
        var that = this
129 135
        this.$http.get(pageDemandExpired, {

+ 4 - 3
src/views/demandCen/preview.vue

@ -103,8 +103,8 @@
103 103
            </el-form-item>
104 104
          </el-col>
105 105
          <el-col :span="24" ><el-form-item style="height:20px"></el-form-item></el-col>
106
          <el-col :span="24" >
107
            <el-form-item align="center">
106
          <el-col :span="24">
107
            <el-form-item align="center" style="margin-left:-100px">
108 108
              <el-button type="primary" @click="submitForm('ruleFormDem')" style="padding: 12px 50px">确定</el-button><br/>
109 109
            </el-form-item>
110 110
          </el-col>
@ -404,7 +404,8 @@
404 404
<style>
405 405
  .form-main{
406 406
    max-width:1000px;
407
    padding: 10px 20px;
407
    margin: auto;
408
    padding: 10px 40px;
408 409
  }
409 410
  .content-tit{
410 411
    text-align: center;

+ 10 - 9
src/views/demandCen/previewExpert.vue

@ -23,7 +23,7 @@
23 23
        pageSize: 10,
24 24
        pageNo: 1,
25 25
        total: 0,
26
        actived: 0,
26
        actived: '',
27 27
        tableData: [],
28 28
        tableLoading: true,
29 29
        demandId: '',
@ -32,11 +32,13 @@
32 32
          {
33 33
            prop: 'name',
34 34
            tit: '真实姓名',
35
            active: 'active'
35
            active: 'active',
36
            width: '200'
36 37
          },
37 38
          {
38 39
            prop: 'title',
39
            tit: '职称'
40
            tit: '职称',
41
            width: '200'
40 42
          },
41 43
          {
42 44
            prop: 'orgName',
@ -54,8 +56,7 @@
54 56
          },
55 57
          {
56 58
            prop: 'descp',
57
            tit: '回复内容',
58
            width: '160'
59
            tit: '回复内容'
59 60
          }
60 61
        ]
61 62
      }
@ -102,11 +103,11 @@
102 103
                crossDomain.getUserInfo(obj[i].uid, data => {
103 104
                  h--
104 105
                  Object.assign(obj[i], data)
105
                  if (h === 0) {
106
                    that.tableData = obj
107
                    that.total = res.data.total
108
                  }
109 106
                })
107
                if (h === 0) {
108
                  that.tableData = obj
109
                  that.total = res.data.total
110
                }
110 111
              }
111 112
              comTable.gapFilling(that.tableData)
112 113
            }

+ 8 - 2
src/views/demandCen/publishedList.vue

@ -3,8 +3,8 @@
3 3
    <div class="box-container">
4 4
      <div class="contain-title">发布中需求</div>
5 5
      <div class="contain-search">
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="pageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="pageQuery"></el-button>
6
        <el-input placeholder="搜索需求主题/需求内容/需求方" v-model="searchText" class="input-with-select" @keyup.enter.native="searchPageQuery">
7
          <el-button slot="append" icon="el-icon-search" @click="searchPageQuery"></el-button>
8 8
        </el-input>
9 9
      </div>
10 10
    </div>
@ -121,6 +121,12 @@
121 121
      this.pageQuery()
122 122
    },
123 123
    methods: {
124
      searchPageQuery() {
125
        this.pageNo = 1
126
        this.total = 0
127
        this.tableData = []
128
        this.pageQuery()
129
      },
124 130
      pageQuery() {
125 131
        var that = this
126 132
        this.$http.get(pageDemandUrl, {

+ 4 - 4
src/views/sysSetting/adminUser.vue

@ -46,14 +46,14 @@
46 46
                  size="medium"
47 47
                  type="primary"
48 48
                  @click="handleResetpw(scope.row)">重置密码</el-button>
49
                <el-button
50
                  size="medium"
51
                  type="primary"
52
                  @click="handleRight(scope.row.id)">分配权限</el-button>
53 49
                <el-button
54 50
                  size="medium"
55 51
                  type="danger"
56 52
                  @click="handleBan(scope.row.id)">停用</el-button>
53
                <el-button
54
                  size="medium"
55
                  type="primary"
56
                  @click="handleRight(scope.row.id)">分配权限</el-button>
57 57
              </div>
58 58
              <div class="forbidden" v-else>
59 59
                <el-button

+ 1 - 1
src/views/sysSetting/editUser.vue

@ -17,7 +17,7 @@
17 17
            <span>{{userForm[item.prop]}}</span>
18 18
          </el-form-item>
19 19
          <el-form-item v-if="!readonlyShow && !item.right" :label="item.tit" :prop="item.prop">
20
            <el-input v-model="userForm[item.prop]" :placeholder="`请填写用户${item.tit}`" :maxlength="item.num||''"></el-input>
20
            <el-input v-model="userForm[item.prop]" :placeholder="`请填写${item.tit}`" :maxlength="item.num||''"></el-input>
21 21
          </el-form-item>
22 22
          <el-form-item v-if="item.right" :prop="item.prop" label-width="0">
23 23
            <template>