|
|
@@ -298,7 +298,8 @@ import {
|
|
|
getAllPlatformTypes,
|
|
|
getAllServiceTypes,
|
|
|
getProvinceCodeByProvinceName,
|
|
|
- getProvinceNameByProvinceCode
|
|
|
+ getProvinceNameByProvinceCode,
|
|
|
+ storageGet,
|
|
|
} from '@/js/index'
|
|
|
|
|
|
export default {
|
|
|
@@ -320,6 +321,7 @@ export default {
|
|
|
}
|
|
|
return {
|
|
|
projectId: 0,
|
|
|
+ user: {},
|
|
|
tabPosition: 'top',
|
|
|
institutionArray: [],
|
|
|
isModifyMode: false,
|
|
|
@@ -455,6 +457,7 @@ export default {
|
|
|
this.setServiceType()
|
|
|
this.setPlatformType()
|
|
|
this.setInstitutions()
|
|
|
+ this.setUserInfo()
|
|
|
this.loadData()
|
|
|
// this.project.platform.map(item => {
|
|
|
// this.platformType.push(PlatformType[item])
|
|
|
@@ -463,7 +466,7 @@ export default {
|
|
|
//提交修改
|
|
|
submitForm (formName) {
|
|
|
const newProject = {
|
|
|
- userId: 3,
|
|
|
+ userId: this.user.userVO.id,
|
|
|
name: this.project.name,
|
|
|
type: this.project.type,
|
|
|
platform: this.project.platform,
|
|
|
@@ -527,7 +530,7 @@ export default {
|
|
|
//接收项目
|
|
|
submitProjectRequest () {
|
|
|
const data = {
|
|
|
- userId: 3,
|
|
|
+ userId: this.user.userVO.id,
|
|
|
projectId: this.projectId
|
|
|
}
|
|
|
Http.post(Apis.USER.SUBMIT_PROJECT_REQUEST, data).then((res) => {
|
|
|
@@ -537,7 +540,7 @@ export default {
|
|
|
//申请项目
|
|
|
applyProject () {
|
|
|
const data = {
|
|
|
- userId: 3,
|
|
|
+ userId: this.user.userVO.id,
|
|
|
projectId: this.projectId
|
|
|
}
|
|
|
Http.post(Apis.USER.ACCEPT_PROJECT, data).then((res) => {
|
|
|
@@ -655,7 +658,7 @@ export default {
|
|
|
headers: {'Content-Type': 'multipart/form-data'},
|
|
|
}
|
|
|
formData.append('file', param.file)
|
|
|
- Http.upload(Apis.FILE.REQUIREMENT_FILE.replace('{userId}', 3), formData, config).then((res) => {
|
|
|
+ Http.upload(Apis.FILE.REQUIREMENT_FILE.replace('{userId}', this.user.userVO.id), formData, config).then((res) => {
|
|
|
console.log('上传成功')
|
|
|
this.project.requireDocUrl = res.data
|
|
|
console.log(res.data)
|
|
|
@@ -668,7 +671,7 @@ export default {
|
|
|
headers: {'Content-Type': 'multipart/form-data'},
|
|
|
}
|
|
|
formData.append('file', param.file)
|
|
|
- Http.upload(Apis.FILE.APK.replace('{userId}', 3), formData, config).then((res) => {
|
|
|
+ Http.upload(Apis.FILE.APK.replace('{userId}', this.user.userVO.id), formData, config).then((res) => {
|
|
|
console.log('上传成功')
|
|
|
this.project.fileUrl = res.data
|
|
|
console.log(res)
|
|
|
@@ -682,6 +685,9 @@ export default {
|
|
|
},
|
|
|
setInstitutions () {
|
|
|
this.institutionArray = getAllInstitutions()
|
|
|
+ },
|
|
|
+ setUserInfo () {
|
|
|
+ this.user = storageGet('user')
|
|
|
}
|
|
|
}
|
|
|
}
|