zhangyanpeng
2020-02-11 355d7d39a67bc1fc27ed1e391799ff7fcc3b2aa7
src/components/popup/newProject.vue
@@ -5,7 +5,7 @@
       <el-step title="方案设计" description="确立方案"></el-step>
       <el-step title="预览" description=""></el-step>
     </el-steps>
     <div style="height: 55vh; padding:0px; box-sizing:boder-box; overflow: auto;">
     <div style="height: 45vh; padding:0px; box-sizing:boder-box; overflow: auto;">
       <div v-if="add_Step == 0" style="width: 100%; height: 100%;" align="center">
        <div style="padding-top: 5%; box-sizing:boder-box">
               <el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
@@ -75,6 +75,8 @@
   },
  data () {
    return {
      userId: undefined,
      assign: undefined,
      add_Step: 0,
         loading_nextStep: false,
         nextStepName: "下一步",
@@ -136,6 +138,8 @@
      this.ruleForm = this.rowData;
      this.xmId = this.rowData.id;
   }
   this.userId = localStorage.getItem('userId');
   this.assign = localStorage.getItem('assign');
},
  methods:{
      Cancel() {
@@ -164,7 +168,6 @@
              if (valid) {
                is_null1 = true;
              } else {
                console.log('error submit!!');
                return false;
              }
            });
@@ -194,22 +197,22 @@
      //   let items2 = new Date(ruleForm_.items[1]).Format("yyyy-MM-dd").toLocaleString();
         
         let url = "/api/scheme/addOrUpdate";
         let me = this;
         this.$axios.get(url,{
           params: {
             reseachType: ruleForm_.objective,
             name: ruleForm_.name,
               startTime: items1,
               endTime: items2,
               id: this.xmId,
               desp:ruleForm_.desp
               id: me.xmId,
               desp:ruleForm_.desp,
               userId: me.userId
           }
         }).then(data_ => {
           console.log(data_);
            this.xmId = data_.data.data;
            me.xmId = data_.data.data;
            
            this.add_Step = 1;
            me.add_Step = 1;
         }).catch(error =>{
             console.log(error);
         })
      },
      
@@ -268,8 +271,8 @@
         }
      },
      saveStep3() {
         let url = "/api/scheme/working/" + this.ruleForm.id;
         this.$axios.get(url + datas).then(data_ => {
         let url = "/api/scheme/working/" + this.xmId;
         this.$axios.get(url).then(data_ => {
            if(data_.data.success) {
               this.$message('项目启动成功');
               this.Cancel();