|
@@ -59,6 +59,7 @@
|
|
|
class="pageSubmitData"
|
|
|
:close-on-click-modal='false'
|
|
|
:close-on-press-escape="false"
|
|
|
+ :show-close="false"
|
|
|
>
|
|
|
<!-- <div class="addDialogLogo">LOGO</div> -->
|
|
|
<div class="" style="display: flex;align-items: center;justify-content: center;margin-top: 10px;">
|
|
@@ -129,24 +130,23 @@
|
|
|
|
|
|
projectApplicationApply1:{ //立项基础信息页面
|
|
|
amendMemberDialog:false, //修改人员对话框显示判断
|
|
|
- dialogImageUrl:"", //封面
|
|
|
telVerify:true, //判断基础信息里联系电话
|
|
|
telVerify2:true, //添加修改成员电话判断
|
|
|
- tableStudentData:[], //学生成员成员列表
|
|
|
- tableTeacherData:[], //老师成员成员列表
|
|
|
- textarea:'', //项目简介
|
|
|
- select:{ //提交后端的基本信息数据框
|
|
|
+
|
|
|
+ dialogImageUrl:"", //封面!!!!!!!!
|
|
|
+ tableStudentData:[], //学生成员成员列表!!!!!!!!
|
|
|
+ tableTeacherData:[], //老师成员成员列表!!!!!!!
|
|
|
+ textarea:'', //项目简介!!!!!!!
|
|
|
+ select:{ //要提交的数据!!!!!!!!!!!!!!!!!!!!!!!
|
|
|
projectName:'', //项目名称
|
|
|
- leader:'',
|
|
|
+ leader:'', //项目负责人
|
|
|
projectDate:'', //开始结束日期
|
|
|
department:"", //部门
|
|
|
fund:'', //资金
|
|
|
MultiSelectProjectNameS:[], //优先支持项目
|
|
|
schoolRemould:'', //校园改造项目
|
|
|
tel:'', //电话
|
|
|
- value1:"",
|
|
|
projectApplyPerson:'', //项目申请人
|
|
|
- sort:[] //["dawjiawdjaw",0]
|
|
|
},
|
|
|
|
|
|
|
|
@@ -156,7 +156,6 @@
|
|
|
phone:'',
|
|
|
score:'0'
|
|
|
},
|
|
|
-
|
|
|
MultiSelectProject:[ //优先支持项目下拉框数据
|
|
|
{
|
|
|
value: '1',
|
|
@@ -172,7 +171,6 @@
|
|
|
label: '产业命题项目'
|
|
|
}
|
|
|
],
|
|
|
-
|
|
|
schoolRemouldOptions:[ //美丽校园下拉框数据
|
|
|
{
|
|
|
value: '1',
|
|
@@ -197,7 +195,6 @@
|
|
|
label: '入驻学校孵化基地的初创企业法人'
|
|
|
}
|
|
|
],
|
|
|
-
|
|
|
departmentOptions: [], //部门下拉框
|
|
|
sortOptions: [ //选择分类下拉框数据
|
|
|
{
|
|
@@ -291,7 +288,7 @@
|
|
|
},
|
|
|
methods:{
|
|
|
|
|
|
- selectTypeButton(){
|
|
|
+ selectTypeButton(){ //分类选项 学生 学校
|
|
|
// this.$message.error('请选择分类')
|
|
|
console.log(this.pageType[0]==false);
|
|
|
if (!this.pageType[0]) return this.$message.error('请选择分类')
|
|
@@ -317,6 +314,7 @@
|
|
|
let a=this.projectApplicationApply1
|
|
|
a.options=p
|
|
|
this.MakerSpace.options = p;
|
|
|
+ this.projectApplicationApply1.departmentOptions=p;
|
|
|
},err=>{
|
|
|
console.log(err);
|
|
|
})
|
|
@@ -374,11 +372,83 @@
|
|
|
submitAll(){
|
|
|
if(this.pageType[0]=='5e21b204-c206-11ed-a4cd-509a4c5b67cf'){//学生创客项目
|
|
|
//在这里判断数据
|
|
|
+ this.submitData()
|
|
|
+
|
|
|
}else if(this.pageType[0]=='5f7a66d5-c206-11ed-a4cd-509a4c5b67cf'){//特色创客空间建设项目
|
|
|
//在这里判断项目
|
|
|
this.InsertProjectMakerSpace();
|
|
|
}
|
|
|
- // this.submitData()
|
|
|
+ },
|
|
|
+ submitData(){ //提交页面所有数据
|
|
|
+ let a=this.projectApplicationApply1;
|
|
|
+ let b=this.projectApplicationApply2;
|
|
|
+ let c=this.projectApplicationApply3
|
|
|
+ // if(a.select.projectName=='') return this.$message.error('请输入项目名称')
|
|
|
+ // if(a.select.person=='') return this.$message.error('请输入项目负责人')
|
|
|
+ // if(a.select.value1=='') return this.$message.error('请选择项目开始时间')
|
|
|
+ // if(a.select.value=='') return this.$message.error('请选择所在部门')
|
|
|
+ // if(a.select.fund=='') return this.$message.error('请输入预算总经费')
|
|
|
+ // if(a.select.tel=='') return this.$message.error('请输入联系电话')
|
|
|
+ // if(!a.telVerify) return this.$message.error('请输入正确联系电话格式')
|
|
|
+ // if(a.select.sort=='') return this.$message.error('请选择分类')
|
|
|
+
|
|
|
+ // let d=[] //按照后端格式传递数据,项目内容,要将经费支出,与项目明细放在一起,
|
|
|
+ // for(let key in b){
|
|
|
+ // d.push(b[key])
|
|
|
+ // }
|
|
|
+
|
|
|
+ // let newData1 = c.tableData[0]; //没有输入的月支出计划改为0,向后端传递
|
|
|
+ // for(let key in newData1){
|
|
|
+ // if (newData1[key]=='-') {
|
|
|
+ // newData1[key]=0
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ // console.log(a.select.sort);
|
|
|
+ // let typeId=a.select.sort[0]
|
|
|
+ // let typeName=a.select.sort[1]
|
|
|
+ // return console.log(typeId,typeName);
|
|
|
+
|
|
|
+ let param={
|
|
|
+ // title:a.select.projectName,
|
|
|
+ // brief:a.textarea,
|
|
|
+ // leader:a.select.person,
|
|
|
+ // phone:a.select.tel,
|
|
|
+ // cid:a.select.value,
|
|
|
+ // student:JSON.stringify(a.tableData),
|
|
|
+ // message:JSON.stringify([d,[newData1,c.tableData2]]),
|
|
|
+ // tid:typeId,
|
|
|
+ // tidName:typeName,
|
|
|
+ // mon:a.select.fund,
|
|
|
+ imgsrc:a.dialogImageUrl,
|
|
|
+ uid:this.$store.state.userInfo.userid,
|
|
|
+ tit:a.select.projectName,
|
|
|
+ con:a.textarea,
|
|
|
+ leader:a.select.leader,
|
|
|
+ tel:a.select.tel,
|
|
|
+ cid: this.pageType,
|
|
|
+ proDate:a.select.projectDate,
|
|
|
+ department:a.select.department,
|
|
|
+ fund:a.select.fund,
|
|
|
+ MultiSelectProjectNameS:JSON.stringify(a.select.MultiSelectProjectNameS),
|
|
|
+ schoolRemould:a.select.schoolRemould,
|
|
|
+ person:a.select.projectApplyPerson,
|
|
|
+ student:JSON.stringify(a.tableStudentData),
|
|
|
+ teacher:JSON.stringify(a.tableTeacherData)
|
|
|
+ }
|
|
|
+ return console.log(param);
|
|
|
+ this.ajax
|
|
|
+ .post(this.$store.state.api+'/CreateProject',param)
|
|
|
+ .then(res=>{
|
|
|
+ console.log(res)
|
|
|
+ if(res.data==1){
|
|
|
+ this.$message.success("创建成功")
|
|
|
+ this.$router.push('projectApplication')
|
|
|
+ }else{
|
|
|
+ this.$message.error("创建失败")
|
|
|
+ }
|
|
|
+ },err=>{
|
|
|
+ console.log(err);
|
|
|
+ })
|
|
|
},
|
|
|
// submitData(){ //提交页面所有数据
|
|
|
// //判断是那个分类
|