Browse Source

修改资料刷新sessionuser

lyn7568 6 years ago
parent
commit
c1dc203417

+ 8 - 7
src/router/index.js

173
      component: Layout,
173
      component: Layout,
174
      name: 'specialExperts',
174
      name: 'specialExperts',
175
      redirect: 'noredirect',
175
      redirect: 'noredirect',
176
      alwaysShow: true,
176
      // alwaysShow: true,
177
      meta: { title: '特约专家' },
177
      meta: { title: '特约专家' },
178
      children: [
178
      children: [
179
        {
179
        {
180
          path: 'expertslist',
180
          path: 'expertslist',
181
          name: 'expertslist',
181
          name: 'expertslist',
182
          component: () => import('@/views/specialExperts/index'),
182
          component: () => import('@/views/specialExperts/index'),
183
          meta: { title: '特约专家列表' }
183
          meta: { title: '特约专家' }
184
        }
184
        }
185
      ]
185
      ]
186
    },
186
    },
189
      component: Layout,
189
      component: Layout,
190
      name: 'cooperationAgency',
190
      name: 'cooperationAgency',
191
      redirect: 'noredirect',
191
      redirect: 'noredirect',
192
      alwaysShow: true,
192
      // alwaysShow: true,
193
      meta: { title: '合作机构' },
193
      meta: { title: '合作机构' },
194
      children: [
194
      children: [
195
        {
195
        {
196
          path: 'agencylist',
196
          path: 'agencylist',
197
          component: () => import('@/views/cooperationAgency/index'),
197
          component: () => import('@/views/cooperationAgency/index'),
198
          name: 'agencylist',
198
          name: 'agencylist',
199
          meta: { title: '合作机构管理列表' }
199
          meta: { title: '合作机构' }
200
        }
200
        }
201
      ]
201
      ]
202
    },
202
    },
217
            {
217
            {
218
              path: 'noactiveList',
218
              path: 'noactiveList',
219
              name: 'noactiveList',
219
              name: 'noactiveList',
220
              meta: { title: '未激活企业列表' },
220
              meta: { title: '未激活企业' },
221
              component: () => import('@/views/companyCen/noactive/noactiveList')
221
              component: () => import('@/views/companyCen/noactive/noactiveList')
222
            },
222
            },
223
            {
223
            {
229
            },
229
            },
230
            {
230
            {
231
              path: 'compProduct',
231
              path: 'compProduct',
232
              hidden: true,
232
              component: () => import('@/views/companyCen/noactive/compProduct'),
233
              component: () => import('@/views/companyCen/noactive/compProduct'),
233
              name: 'compProduct',
234
              name: 'compProduct',
234
              meta: { title: '企业产品' }
235
              meta: { title: '企业产品' }
255
      component: Layout,
256
      component: Layout,
256
      name: 'platinfo',
257
      name: 'platinfo',
257
      redirect: 'noredirect',
258
      redirect: 'noredirect',
258
      alwaysShow: true,
259
      // alwaysShow: true,
259
      meta: { title: '平台信息' },
260
      meta: { title: '平台信息' },
260
      children: [
261
      children: [
261
        {
262
        {
262
          path: 'platUpdate',
263
          path: 'platUpdate',
263
          component: () => import('@/views/platInfo/platUpdate'),
264
          component: () => import('@/views/platInfo/platUpdate'),
264
          name: 'platUpdate',
265
          name: 'platUpdate',
265
          meta: { title: '修改平台信息' }
266
          meta: { title: '平台信息' }
266
        }
267
        }
267
      ]
268
      ]
268
    },
269
    },

+ 9 - 4
src/views/accountSettings/modifyAccountInformation.vue

125
    },
125
    },
126
    methods: {
126
    methods: {
127
      submitForm(formName) {
127
      submitForm(formName) {
128
        this.$refs[formName].validate((valid) => {
128
        var that = this
129
        that.$refs[formName].validate((valid) => {
129
          if (valid) {
130
          if (valid) {
130
            this.$http.put(modifyUrl, this.ruleForm2, (response) => {
131
            that.$http.put(modifyUrl, that.ruleForm2, (response) => {
131
              if (response.success) {
132
              if (response.success) {
132
                this.$message({
133
                that.$message({
133
                  message: '资料修改成功',
134
                  message: '资料修改成功',
134
                  type: 'success'
135
                  type: 'success'
135
                })
136
                })
137
                that.$http.get('/ajax/sys/refresh', {}, function(data) {
138
                  if (data.success) {
139
                    that.$store.dispatch('GetUserInfo')
140
                  }
141
                })
136
              }
142
              }
137
            })
143
            })
138
          } else {
144
          } else {
139
            console.log('error submit!!')
140
            return false
145
            return false
141
          }
146
          }
142
        })
147
        })

+ 3 - 4
src/views/companyCen/activeList.vue

82
          width: '240'
82
          width: '240'
83
        },
83
        },
84
        {
84
        {
85
          prop: 'job',
85
          prop: 'linkman',
86
          tit: '联系人'
86
          tit: '联系人'
87
        },
87
        },
88
        {
88
        {
89
          prop: 'linkPhone',
89
          prop: 'linkphone',
90
          tit: '联系电话',
90
          tit: '联系电话',
91
          width: '120'
91
          width: '120'
92
        },
92
        },
93
        {
93
        {
94
          prop: 'email',
94
          prop: 'linkemail',
95
          tit: '联系邮箱',
95
          tit: '联系邮箱',
96
          width: '160'
96
          width: '160'
97
        },
97
        },
141
            hData.num--
141
            hData.num--
142
            that.total = res.data.total
142
            that.total = res.data.total
143
            if (hData.num === 0) {
143
            if (hData.num === 0) {
144
              console.log(obj)
145
              that.tableData = obj
144
              that.tableData = obj
146
            }
145
            }
147
            comTable.gapFilling(that.tableData)
146
            comTable.gapFilling(that.tableData)

+ 19 - 33
src/views/demandCen/preview.vue

30
          </el-col>
30
          </el-col>
31
          <el-col :span="12">
31
          <el-col :span="12">
32
            <el-form-item label="所在城市" prop="city">
32
            <el-form-item label="所在城市" prop="city">
33
              <span v-if="readonlyShow">{{ruleFormDem.cityStr}}</span>
33
              <span v-if="readonlyShow">{{cityStr}}</span>
34
              <cityPicker v-else @paren="toshow" @parenStr="toshowStr" :addrCode="ruleFormDem.city"></cityPicker>
34
              <cityPicker v-else @paren="toshow" @parenStr="toshowStr" :addrCode="ruleFormDem.city"></cityPicker>
35
            </el-form-item>
35
            </el-form-item>
36
          </el-col>
36
          </el-col>
110
          </el-col>
110
          </el-col>
111
        </el-row>
111
        </el-row>
112
      </el-form>
112
      </el-form>
113
      <div class="inner-wrapper">
114
        <!-- <el-collapse v-model="collapseName" v-if="buttCount>0">
115
          <el-collapse-item class="content-title" :title="`已为您对接${buttCount}位专家`" name="1">
116
            <div class="con-item" v-for="item in demandButtExperts" :key="item.index">
117
              <baseExpert :itemSingle="item.owner"></baseExpert>
118
              <div class="dele">
119
                <contactChat :cantactOptions="{oid: item.uid}"></contactChat>
120
                <collectCo :watchOptions="{oid: item.uid, type: 1}"></collectCo>
121
              </div>
122
              <div class="leavemsg">
123
                <div>留言:{{item.descp}}</div>
124
                <span>{{item.assTime}}</span>
125
              </div>
126
            </div>
127
          </el-collapse-item>
128
        </el-collapse>
129
        <div v-else class="content-title">正在为您对接专家...</div> -->
130
      </div>
131
    </div>
113
    </div>
132
  </div>
114
  </div>
133
</template>
115
</template>
172
        demandCloseReason: '',
154
        demandCloseReason: '',
173
        ownerIn: {},
155
        ownerIn: {},
174
        feedback: '',
156
        feedback: '',
157
        cityStr: '',
175
        ruleFormDem: {
158
        ruleFormDem: {
176
          title: '',
159
          title: '',
177
          descp: '',
160
          descp: '',
181
          linkOrg: '',
164
          linkOrg: '',
182
          cost: '',
165
          cost: '',
183
          duration: '',
166
          duration: '',
184
          cityStr: '',
185
          costStr: '',
167
          costStr: '',
186
          durationStr: ''
168
          durationStr: ''
187
        },
169
        },
253
    methods: {
235
    methods: {
254
      getDictoryData() {
236
      getDictoryData() {
255
        const that = this
237
        const that = this
256
        queryDict.applyDict('XZQH', function(dictData) {
257
          dictData.map(item => {
258
            that.cityRange[item.code] = item.caption
259
          })
260
        }) // 城市
261
        queryDict.applyDict('FYYS', function(dictData) {
238
        queryDict.applyDict('FYYS', function(dictData) {
262
          dictData.map(item => {
239
          dictData.map(item => {
263
            that.costRange.push({ value: item.code, label: item.caption })
240
            that.costRange.push({ value: item.code, label: item.caption })
288
              })
265
              })
289
              obj.durationStr = durationMM.label
266
              obj.durationStr = durationMM.label
290
            }
267
            }
291
            if (obj.city) {
292
              obj.cityStr = that.cityRange[obj.city]
293
            }
294
            that.turnOutUserName(obj.creator)
268
            that.turnOutUserName(obj.creator)
269
            that.cityTurn(obj.city)
295
            that.formLoading = false
270
            that.formLoading = false
296
            that.ruleFormDem = obj
271
            that.ruleFormDem = obj
297
            if (obj.state === 2) {
272
            if (obj.state === 2) {
298
              that.getFeedBack()
273
              that.getFeedBack(obj.creator)
274
            }
275
          }
276
        })
277
      },
278
      cityTurn(code) {
279
        const that = this
280
        queryDict.applyDict('XZQH', function(dictData) {
281
          for (let i = 0; i < dictData.length; ++i) {
282
            if (dictData[i].code === code) {
283
              that.cityStr = dictData[i].caption
284
              break
299
            }
285
            }
300
          }
286
          }
301
        })
287
        })
308
          }
294
          }
309
        })
295
        })
310
      },
296
      },
311
      getFeedBack() {
297
      getFeedBack(id) {
312
        var that = this
298
        var that = this
313
        this.$http.get(feedbackReason, {
299
        this.$http.get(feedbackReason, {
314
          target: that.demandId,
300
          target: that.demandId,
315
          type: 1,
301
          type: 1,
316
          creator: that.ownerIn.id
302
          creator: id
317
        }, function(res) {
303
        }, function(res) {
318
          if (res.success && res.data) {
304
          if (res.success && res.data) {
319
            that.feedback = res.data.cnt
305
            that.feedback = res.data.cnt
353
              linkOrg: obj.linkOrg,
339
              linkOrg: obj.linkOrg,
354
              cost: obj.cost,
340
              cost: obj.cost,
355
              duration: obj.duration,
341
              duration: obj.duration,
356
              cityStr: obj.cityStr,
342
              cityStr: that.cityStr,
357
              costStr: obj.costStr,
343
              costStr: obj.costStr,
358
              durationStr: obj.durationStr
344
              durationStr: obj.durationStr
359
            }
345
            }
395
        this.ruleFormDem.city = value
381
        this.ruleFormDem.city = value
396
      },
382
      },
397
      toshowStr(value) {
383
      toshowStr(value) {
398
        this.ruleFormDem.cityStr = value
384
        this.cityStr = value
399
      }
385
      }
400
    }
386
    }
401
  }
387
  }

+ 18 - 22
src/views/userInfo/baseInfo.vue

34
            <el-form-item label="联系邮箱">{{infoRow.email}}</el-form-item>
34
            <el-form-item label="联系邮箱">{{infoRow.email}}</el-form-item>
35
          </el-col>
35
          </el-col>
36
          <el-col :span="24">
36
          <el-col :span="24">
37
            <el-form-item label="所在城市">{{AllCitys[infoRow.addr]}}</el-form-item>
37
            <el-form-item label="所在城市">{{cityCaption}}</el-form-item>
38
          </el-col>
38
          </el-col>
39
          <el-col :span="24" v-if="type">
39
          <el-col :span="24" v-if="type">
40
            <el-form-item label="拉黑理由" class="el-to-block">
40
            <el-form-item label="拉黑理由" class="el-to-block">
52
        </el-col>
52
        </el-col>
53
        <el-col :span="24">
53
        <el-col :span="24">
54
          <el-form-item align="right">
54
          <el-form-item align="right">
55
            <span v-if='!type'>创建时间: {{createTime}}</span>
56
            <span v-else>拉黑时间: {{invalidTime}}</span>
55
            <span v-if='!type'>创建时间: {{infoRow.createTime ? parseTime(infoRow.createTime) : ''}}</span>
56
            <span v-else>拉黑时间: {{infoRow.invalidTime ? parseTime(infoRow.invalidTime) : ''}}</span>
57
          </el-form-item>
57
          </el-form-item>
58
        </el-col>
58
        </el-col>
59
      </el-row>
59
      </el-row>
64
<script>
64
<script>
65
  import { queryBlackOne } from '@/api/userInfo'
65
  import { queryBlackOne } from '@/api/userInfo'
66
  import { defaultSet, parseTime } from '@/utils'
66
  import { defaultSet, parseTime } from '@/utils'
67
  import queryDict from '@/utils/queryDict'
68
  import queryBase from '@/utils/queryBase'
67
  import queryBase from '@/utils/queryBase'
68
  import queryDict from '@/utils/queryDict'
69
  export default {
69
  export default {
70
    props: ['type'],
70
    props: ['type'],
71
    data() {
71
    data() {
72
      return {
72
      return {
73
        userDialogVisible: false,
73
        userDialogVisible: false,
74
        AllCitys: [],
75
        infoRow: ''
74
        infoRow: '',
75
        parseTime: parseTime
76
      }
76
      }
77
    },
77
    },
78
    computed: {
78
    computed: {
82
      headUrl() {
82
      headUrl() {
83
        return this.infoRow.head || defaultSet.img.user
83
        return this.infoRow.head || defaultSet.img.user
84
      },
84
      },
85
      createTime() {
86
        return this.infoRow.createTime ? parseTime(this.infoRow.createTime) : ''
87
      },
88
      invalidTime() {
89
        return this.infoRow.invalidTime ? parseTime(this.infoRow.invalidTime) : ''
90
      }
91
    },
92
    created() {
93
      this.getDictoryData()
94
    },
95
    methods: {
96
      getDictoryData() {
85
      cityCaption() {
97
        const that = this
86
        const that = this
87
        var city = ''
98
        queryDict.applyDict('XZQH', function(dictData) {
88
        queryDict.applyDict('XZQH', function(dictData) {
99
          dictData.map(item => {
100
            that.AllCitys[item.code] = item.fullCaption
101
          })
89
          for (let i = 0; i < dictData.length; ++i) {
90
            if (dictData[i].code === that.infoRow.addr) {
91
              city = dictData[i].fullCaption
92
              break
93
            }
94
          }
102
        })
95
        })
103
      },
96
        return city
97
      }
98
    },
99
    methods: {
104
      queryNormalOne(id) {
100
      queryNormalOne(id) {
105
        var that = this
101
        var that = this
106
        if (id) {
102
        if (id) {

+ 1 - 0
src/views/userInfo/blackList.vue

68
export default {
68
export default {
69
  data() {
69
  data() {
70
    return {
70
    return {
71
      AllCitys: [],
71
      blackType: true,
72
      blackType: true,
72
      searchText: '',
73
      searchText: '',
73
      pageSize: 10,
74
      pageSize: 10,

+ 2 - 9
src/views/userInfo/usingList.vue

47
        </el-pagination>
47
        </el-pagination>
48
      </div>
48
      </div>
49
    </div>
49
    </div>
50
    <baseInfo ref="baseInfo"></baseInfo>
50
    <baseInfo ref="baseInfoView"></baseInfo>
51
    <pullBlack ref="pullBlack"></pullBlack>
51
    <pullBlack ref="pullBlack"></pullBlack>
52
  </div>
52
  </div>
53
</template>
53
</template>
114
      ]
114
      ]
115
    }
115
    }
116
  },
116
  },
117
  watch: {
118
    '$route'(to, from) {
119
      console.log(111)
120
      console.log(to)
121
      console.log(from)
122
    }
123
  },
124
  components: {
117
  components: {
125
    baseInfo,
118
    baseInfo,
126
    pullBlack
119
    pullBlack
161
      })
154
      })
162
    },
155
    },
163
    queryInfo(id) {
156
    queryInfo(id) {
164
      this.$refs.baseInfo.queryNormalOne(id)
157
      this.$refs.baseInfoView.queryNormalOne(id)
165
    },
158
    },
166
    pullBlackFun(id) {
159
    pullBlackFun(id) {
167
      this.$refs.pullBlack.queryNormalOne(id)
160
      this.$refs.pullBlack.queryNormalOne(id)