yuanyiming 2 years ago
parent
commit
fd1709ef3f

+ 1 - 1
src/config/config.js

@@ -25,7 +25,7 @@ const store = new Vuex.Store({
         // socket: "http://localhost:1473",
         // api: 'http://10.3.16.226:7003/api',
         api: 'http://127.0.0.1:7003/api',
-        // api: 'http://localhost:5005',
+        // api: 'http://10.3.13.84:7003/api',
 
     },
 

+ 4 - 25
src/views/activityManage/makerActvityDetails.vue

@@ -167,44 +167,23 @@
             <div class="tabTit">
                  <div><p>活动计划</p></div>
             </div>
-              <!-- <el-input
-                type="textarea"
-                :rows="6"
-                placeholder="请输入内容"
-                v-model="tableData.chapters[0]">
-              </el-input> -->
+             
               <vue-editor  :editorToolbar="customToolbar" v-model="tableData.chapters[0]"></vue-editor>
             <div class="tabTit">
                  <div><p>预期目标</p></div>
             </div>
-              <!-- <el-input
-                type="textarea"
-                :rows="6"
-                placeholder="请输入内容"
-                v-model="tableData.chapters[1]">
-              </el-input> -->
+            
                 <vue-editor  :editorToolbar="customToolbar" v-model="tableData.chapters[1]"></vue-editor>
               
             <div class="tabTit">
                  <div><p>活动受面</p></div>
             </div>
-              <!-- <el-input
-                type="textarea"
-                :rows="6"
-                placeholder="请输入内容"
-                v-model="tableData.chapters[2]">
-              </el-input> -->
+            
               <vue-editor  :editorToolbar="customToolbar" v-model="tableData.chapters[2]"></vue-editor>
             <div class="tabTit">
                  <div><p>经费支出计划</p></div>
             </div>
-              <!-- <el-input
-                type="textarea"
-                :rows="6"
-                class="textArea"
-                placeholder="请输入内容"
-                v-model="tableData.chapters[3]">
-              </el-input> -->
+             
               <vue-editor  :editorToolbar="customToolbar" v-model="tableData.chapters[3]"></vue-editor>
             <!-- 多行文本框部分结束 -->
 

+ 2 - 4
src/views/projectManage/ProjectManagement1.vue

@@ -121,17 +121,15 @@
           >
         </el-table-column>
         
-        <el-table-column
+        <!-- <el-table-column
           prop="operation"
           align="center"
           label="操作"
           >
-          <!-- <template #default="scope"> -->
               <div class="operations">
                       <el-button type="primary" class="bt1" size="mini" style="background: #477edd">查看详情</el-button>
               </div>
-          <!-- </template> -->
-        </el-table-column>
+        </el-table-column> -->
       </el-table>
     <!-- 项目成员区域结束 -->
 

+ 312 - 150
src/views/projectManage/ProjectManagement3_1.vue

@@ -76,53 +76,57 @@
 
 
 
-      <!-- 指导老师开始 -->
-      <div class="tabTit">
-          <div><p>活动指导老师</p></div>
-          <el-button type="primary" @click="addMember" size="mini">添加教师</el-button>
-      </div>
-      <hr>
-      <el-table
-        :data="tableData"
-        tooltip-effect="dark"
-        stripe
-        class="fontSize"
-        :header-cell-style="{ background: '#f2f2f2',color:'#000' }"
-        >
-
-        <el-table-column
-          prop="Name"
-          label="姓名"
-          align="center"
-         >
-        </el-table-column>
-        <el-table-column
-          prop="work"
-          label="工作单位"
-          align="center"
-          >
-        </el-table-column>
-
-        <el-table-column
-          prop="takeCharge"
-          label="活动分工"
-          align="center"
-          >
-        </el-table-column>
-
-        <el-table-column
-          prop="operation"
-          align="center"
-          label="操作"
-          >
-          <!-- <template #default="scope"> -->
-              <div class="operations">
-                      <el-button type="primary" class="bt1" size="mini" style="background: #477edd">查看详情</el-button>
+   <!-- 活动指导老师开始 -->
+   <div class="tabTit">
+                <div>
+                  <p>活动指导老师</p>
+                </div>
+                <el-button type="primary" @click="addTeacher" size="mini">添加教师</el-button>
               </div>
-          <!-- </template> -->
-        </el-table-column>
-      </el-table>
-      <!-- 指导老师结束 -->
+              <hr>
+              <el-table
+                :data="tableData"
+                tooltip-effect="dark"
+                stripe
+                class="fontSize"
+                :header-cell-style="{ background: '#f2f2f2',color:'#000' }"
+                >
+                <!-- 数据根据prop进行遍历填充 -->
+                <el-table-column
+                  prop="Name"
+                  label="姓名"
+                  align="center"
+                  >
+                </el-table-column>
+                <el-table-column
+                  prop="work"
+                  label="工作单位"
+                  align="center"
+                  >
+                </el-table-column>
+  
+                <el-table-column
+                  prop="takeCharge"
+                  label="活动分工"
+                  align="center"
+                  >
+                </el-table-column>
+                
+                <el-table-column
+                  prop="operation"
+                  align="center"
+                  label="操作"
+                  >
+                  <template #default="scope">
+                      <div class="operations">
+                              <el-button type="primary" size="mini" @click="updateTeacher(scope.row.Id)" style="font-size: 14px;">修改</el-button>
+                              <el-button type="primary" size="mini" style="font-size: 14px;" @click="deleteRow(scope.row.Id)">删除</el-button>
+                      </div>
+                  </template>
+                </el-table-column>
+              </el-table>
+            <!-- 活动指导老师结束 -->
+
 
     <!-- 多行文本框区域开始 -->
       
@@ -152,44 +156,63 @@
       </div>
       <div class="textArea">
         <vue-editor  :editorToolbar="customToolbar" v-model="textareaS[3]"></vue-editor>
-
       </div>
     <!-- 多行文本框区域结束 -->
-
+    <div class="baseBtn">
+            <div class="blockWidth">
+              <el-button type="primary" class="backBtn"  @click="updateActivityDialog" >提交</el-button>
+            </div>
+          </div>
 
      <!--添加成员dialog对话框开始 -->
-      <el-dialog
-          title="添加成员"
-          :visible.sync="addMemberDialog"
-          class="AddMember"
-          :before-close="handleClose">
+     <el-dialog
+            :title="Member.Id==''?'添加指导老师':'修改指导老师'"
+            :visible.sync="addMemberDialog"
+            class="AddMember"
+            :before-close="handleClose">
 
-            <div class="littleBlock">
-              <div class="dialogLabel">姓名</div>
-              <div>
-                <el-input v-model="Member.name"></el-input>
+              <div class="littleBlock">
+                <div class="dialogLabel">姓名</div>
+                <div>
+                  <el-input v-model="Member.Name"></el-input>
+                </div>
               </div>
-            </div>
 
-            <div class="littleBlock">
-              <div class="dialogLabel">班级</div>
-              <div>
-                <el-input v-model="Member.className"></el-input>
+              <div class="littleBlock">
+                <div class="dialogLabel">工作单位</div>
+                <div>
+                  <el-input v-model="Member.work"></el-input>
+                </div>
               </div>
-            </div>
 
-            <div class="littleBlock">
-              <div class="dialogLabel">电话</div>
-              <div>
-                <el-input v-model="Member.Division"></el-input>
+              <div class="littleBlock">
+                <div class="dialogLabel">活动分工</div>
+                <div>
+                  <el-input v-model="Member.takeCharge"></el-input>
+                </div>
               </div>
-            </div>
-            <div slot="footer" class="footer">
-              <el-button type="primary" @click="commit" class="diaBtn" >确认提交</el-button>
-              <el-button @click="handleClose" class="diaBtn" >取消</el-button>
-            </div>
-      </el-dialog>
+              <div slot="footer" class="footer">
+                <el-button v-if="Member.Id==''" type="primary" @click="commit" class="diaBtn" size="small">确认提交</el-button>
+                <el-button v-if="!Member.Id==''"  type="primary" @click="change" class="diaBtn" size="small">确认修改</el-button>
+                <el-button @click="handleClose" class="diaBtn" size="small">取消</el-button>
+              </div>
+        </el-dialog>
       <!--添加成员dialog对话框结束 -->
+      <!-- 修改对话框框开始 -->
+      <el-dialog
+          title="提示"
+          :visible.sync="updateActivity"
+          width="600px"
+          class="projectApplicationfundAddDialog"
+          :before-close="handleClose">
+          <div class="addDialogLogo">LOGO</div>
+          <div class="deleteContent">确定修改?</div>
+          <span slot="footer" class="dialog-footer">
+            <el-button type="primary" @click="submitAll" class="btn5">确认提交</el-button>
+            <el-button @click="handleClose" class="btn5" style="background:#cccccc" size="small">取消</el-button>
+          </span>
+        </el-dialog>
+      <!-- 提交对话框结束 -->
     </div>
 </template>
 
@@ -202,6 +225,7 @@
         },
         data() {
           return {
+            updateActivity:false,
             customToolbar: [
               ["bold", "italic", "underline"], [{ list: "ordered" }, { list: "bullet" }],
               [{ align: "" }, { align: "center" }, { align: "right"}, { align: "justify"}],
@@ -221,98 +245,236 @@
 
           textareaS:[],
           selectInput: [], //部门下拉框
-            Member:{
-              name:'袁一鸣',
-              className:'21通信',
-              Division:'ui'
+          Member:{
+              Id:"",
+              Name:'',
+              work:'',
+              takeCharge:''
           },
-            value: '中德学院',
-            input:'',
           }
         },
         methods:{
-       
-        getData(){       //获取基础信息
-          this.ajax.get(this.$store.state.api+"/GetActivityDetail",{
-            uid:this.$store.state.userInfo.userid,
-            // aId:this.$route.query["Id"]
-            aId:this.$route.query["Id"]
+        
+              getData(){       //获取基础信息
+                this.ajax.get(this.$store.state.api+"/GetActivityDetail",{
+                  uid:this.$store.state.userInfo.userid,
+                  // aId:this.$route.query["Id"]
+                  aId:this.$route.query["Id"]
+                }).then(res=>{
+                  if(!res.data[0][0])return this.$message.error("错误")
+                  let data = res.data[0][0];
+                  // console.log(data);
+                  this.selects.projectName=data.title;
+                  this.selects.fund=data.money;
+                  this.selects.leader=data.pro_leader;
+                  this.selects.tel=data.phone;
+                  this.selects.beginDate=data.create_at;
+                  this.selects.studentNum=data.students;
+                  this.selects.department=data.classid;
+                  this.tableData=JSON.parse(data.course_teacher)
+                  this.textareaS=JSON.parse(data.chapters)
+                }).catch(err=>{
+                  this.$message.error(err.message)
+                })
+              },
+              getAllClass(){
+                    this.ajax.get(this.$store.state.api+"/SelectAllDepartment",{
+                        uid:this.$store.state.userInfo.userid,
+                    }).then(res=>{
+                        this.selectInput = res.data[0];
+                    }).catch(err=>{
+                        this.$message.error(err.message)
+                    })
+                },
+                handleClose(){
+                    this.addMemberDialog=false
+                    this.updateActivity=false
+                    for(let i in this.Member)this.Member[i]='';
+                },
+                addTeacher(){    //添加老师对话框
+                  this.addMemberDialog=true;
+                },
+                commit(){  //确定添加老师
+                    if(this.Member.Name=='')return this.$message.error('请输入姓名')
+                    if(this.Member.work=='')return this.$message.error('请输入工作单位')
+                    if(this.Member.takeCharge=='')return this.$message.error('请输入活动分工')
+                    let k={}
+                    this.addMemberDialog=false;
+                    this.Member.Id=uuid.v1()
+                    Object.assign(k,this.Member)
+                    this.tableData.push(k);
+                    this.$message.success('添加成功')
+                    for(let i in this.Member)this.Member[i]='';
+              },
 
-          }).then(res=>{
-            if(!res.data[0][0])return this.$message.error("错误")
-            let data = res.data[0][0];
-            console.log(data);
-            this.selects.projectName=data.title;
-            this.selects.fund=data.money;
-            this.selects.leader=data.pro_leader;
-            this.selects.tel=data.phone;
-            this.selects.beginDate=data.create_at;
-            this.selects.studentNum=data.students;
-            this.selects.department=data.classid;
-            this.tableData=JSON.parse(data.course_teacher)
-            this.textareaS=JSON.parse(data.chapters)
-          }).catch(err=>{
-            this.$message.error(err.message)
-          })
-        },
-        getAllClass(){
-          this.ajax.get(this.$store.state.api+"/SelectAllDepartment",{
-              uid:this.$store.state.userInfo.userid,
-          }).then(res=>{
-              this.selectInput = res.data[0];
-          }).catch(err=>{
-              this.$message.error(err.message)
-          })
-      },
-        handleClose(){
-          this.addMemberDialog=false
-        },
-        addMember(){
-          this.addMemberDialog=true
-        },
-          commit(){
-          this.addMemberDialog=false;
-          let { name: Name, className: className, Division:division } = this.Member;
-          let data={Name,className,division};
-          this.tableData.push(data);
-        },
-          content(){
-            this.$router.push('/ProjectManagement1')
-          },
-          remark(){
-            this.$router.push('/ProjectManagement2')
-          },
-          remark2(){
-            this.$router.push('/ProjectManagement3')
-          },
-          remark4(){
-            this.$router.push('/ProjectManagement4')
-          },
-          remark5(){
-            this.$router.push('/ProjectManagement5')
-          },
-          edit(){
-  
-          },
-          backBtn2(){
-            this.$router.push('/ProjectManagement1')
-          },
-          handleSelectionChange(val) {
-            this.multipleSelection = val;
-          },
+              updateTeacher(Id){    //修改对话框出现
+                Object.assign(this.Member,this.tableData.filter(item=>item.Id==Id)[0])
+                this.addMemberDialog = true;
+              },
+              change(){    //确定修改老师
+                if(this.Member.Id=='')return this.$message.error("错误");
+                if(this.Member.Name=='')return this.$message.error('请输入姓名')
+                if(this.Member.work=='')return this.$message.error('请输入工作单位')
+                if(this.Member.takeCharge=='')return this.$message.error('请输入活动分工')
+                // for(let a in this.Member)if(/^\s*$/g.test(this.Member[a]))return this.$message.error("请不要留空")
+                Object.assign(this.tableData.filter(item=>item.Id==this.Member.Id)[0],this.Member)
+                for(let i in this.Member)this.Member[i]='';
+                this.addMemberDialog = true;
+                this.$message({message:"修改成功",type:"success"})
+                this.addMemberDialog = false;
+              },
+              deleteRow(Id){   //删除老师
+                this.tableData = this.tableData.filter(item=>item.Id!=Id);
+                this.$message({message:"删除成功",type:"success"})
+              },
+              updateActivityDialog(){   //显示修改提交对话框
+                this.updateActivity=true
+              },
+              submitAll(){      //确定提交修改
+                  //保存修改
+                    const data = this.tableData;
+
+                    const param = {
+                      uid:this.$store.state.userInfo.userid,
+                      aid:data.acId,
+                      tit:data.title,
+                      con:data.brief,
+                      leader:data.pro_leader,
+                      mon:data.money,
+                      stu:data.students,
+                      teacher:JSON.stringify(data.course_teacher),
+                      chap:JSON.stringify(data.chapters),
+                      pid:data.pid,
+                      cid:data.classid,
+                      ph:data.phone,
+                      beginTime:JSON.stringify(data.begin_at)
+                    }
+                    // console.log(param)
+                    // return;
+                    this.ajax.post(this.$store.state.api+"/UpdateActivity",param).then(res=>{
+                      if(res.data==1){
+                        this.$message.success("修改成功");
+                        this.dialogVisible1=false
+                        this.getData();
+                      }else{
+                        this.$message.error("修改失败"+res.data);
+                      }
+                    }).catch(err=>{
+                      this.$message.error(err.message)
+                    })
+                    console.log(this.tableData)
+              },
+              content(){
+                this.$router.push('/ProjectManagement1')
+              },
+              remark(){
+                this.$router.push('/ProjectManagement2')
+              },
+              remark2(){
+                this.$router.push('/ProjectManagement3')
+              },
+              remark4(){
+                this.$router.push('/ProjectManagement4')
+              },
+              remark5(){
+                this.$router.push('/ProjectManagement5')
+              },
+              edit(){
+      
+              },
+              backBtn2(){
+                this.$router.push('/ProjectManagement1')
+              },
+              // handleSelectionChange(val) {
+              //   this.multipleSelection = val;
+              // },
          
         },
         mounted(){
-          // this.value=(this.options[0].value)
           this.getData();
           this. getAllClass();
-          console.log(this.$route.query["Id"]);
+          // console.log(this.$route.query["Id"]);
         }
       }
   </script>
 
   <style lang="less">
-
+   //提交对话框开始
+   .projectApplicationfundAddDialog{  
+ 
+      .el-dialog__header{
+        border-radius: 10px 10px 0 0;
+      }
+      .el-dialog{
+        border-radius:10px ;
+        top: 10%;
+      }
+      
+      .deleteContent{
+        width: 100%;
+        text-align: center;
+        font-size: 22px;
+        color: #000;
+      }
+      .addDialogLogo{
+        width: 60px;
+        height: 30px;
+        line-height: 30px;
+        background: #f2f2f2;
+        position: absolute;
+        left: 10px;
+        top: 10px;
+        text-align: center;
+      }
+      .el-dialog__header{
+        background: #32455b;
+      }
+      .el-dialog__title{
+        // text-align: center;
+        position: relative;
+        top: -5px;
+        margin-left:250px;
+        font-size: 22px;
+        color:rgb(246, 247, 246);
+      }
+      .addDialogMid{
+        box-sizing: border-box;
+        padding:0 60px 0 10px;
+        .addDialogTit{
+          display: flex;
+          span{
+            width: 80px;
+            line-height: 40px;
+            text-align: left;
+          }
+        }
+      .addDialogTit1{
+        display: flex;
+        justify-content: space-between;
+        margin-bottom: 15px;
+      }
+      .addDialogTit2{
+        margin-top: 10px;
+        font-size: 18px;
+        color: #000;
+        text-indent: 2em;
+      }
+      .addDialogCon{
+        margin-top: 20px;
+      }
+      }
+      .dialog-footer{
+      display: flex;
+      justify-content: center;
+      .btn5{
+        height: 40px;
+        font-size: 16px;
+        background: #0e72e6;
+        width: 200px;
+      }
+      }
+      }
+//提交对话框结束
   </style>
 
   

+ 41 - 14
src/views/projectManage/ProjectManagement4.vue

@@ -18,7 +18,9 @@
       </div>
       <!-- 跳转导航结束 -->
       <div class="pmInp">
-          <el-button type="primary" class="btn"  size="mini">上传文件</el-button>
+          <!-- <el-button type="primary" class="btn"  size="mini">上传文件</el-button> -->
+          <beUpload @getFile="getFile"  :navName="'上传文件'" :accept="accept"></beUpload>
+
         </div>
         <!-- 表格开始 -->
         <el-table
@@ -31,12 +33,12 @@
         >
        
 
-        <el-table-column
+        <!-- <el-table-column
           prop="title"
           label="活动名称"
           align="center"
           >
-        </el-table-column>
+        </el-table-column> -->
 
         <el-table-column
           prop="fileName"
@@ -89,9 +91,13 @@
   </template>
   
   <script>
+  import beUpload from '../../components/tool/beUpload'
+
       export default {
+        components:{beUpload},
         data() {
           return {
+          accept:".doc,.docx,application/msword,application/vnd.openxmlformats-officedocument.wordprocessingml.document",
             table:{         // 分页数据
               total:0,
               packageSize:8,
@@ -101,6 +107,32 @@
           }
         },
         methods:{
+          getFile(val) {    //上传文件
+            this.file = val;
+            let oldData = [];
+            this.tableData.forEach(item=>oldData.push(item))
+            oldData.push(val)
+          
+            let param={
+                uid:this.$store.state.userInfo.userid,
+                cid:JSON.parse(localStorage.getItem('pid')),
+                projectFile:JSON.stringify(oldData)
+            }
+            this.ajax
+                  .post(this.$store.state.api+'/AddProjectFile',param)
+                  .then(res=>{
+                    // console.log(res);
+                    if (res.data==1) {
+                      this.$message.success('上传成功')
+                      this.getData()
+                    }else{
+                      this.$message.error('上传失败')
+                    }
+                    
+                  },err=>{
+                    console.log(err);
+                  })
+          },
           handleCurrentChange(val) {   //当页数发生改变的时候调用获取列表数据请求
           // console.log(`当前页: ${val}`);
           this.table.currentPage=val
@@ -115,23 +147,18 @@
               }
               // console.log(param);
               this.ajax
-                    .get(this.$store.state.api+'/GetActivityFileByProjectId',param)
+                    .get(this.$store.state.api+'/SelectProjectFile',param)
                     .then(res=>{
                       // console.log(res.data);
                       let k=[]
                       res.data[0].forEach((e,i) => {
-                        let { title: f, reportFile: l } = e;
-                        k.push(Object.assign({title:f},JSON.parse(l)))
+                        console.log(e);
+                        let { projectFile: l } = e;
+                        console.log(l);
+                        k=JSON.parse(l)
                       });
+                      console.log(k);
                       this.tableData=k
-                      // console.log(k);
-                      // if (res.data[0][0] != undefined) {
-                      //   let { title: f, reportFile: l } = res.data[0][0];
-                      //   let k= Object.assign({title:f},JSON.parse(l))
-                      //   this.tableData=[k]
-                      // }
-                      
-                      // console.log(this.tableData);
                     },err=>{
                       console.log(err);
                     })

+ 29 - 19
src/views/projectManage/ProjectManagement5.vue

@@ -32,12 +32,15 @@
         class="fontSize"
         :header-cell-style="{ background: '#f2f2f2',color:'#000' }"
         >
-        <el-table-column
+        <!-- <el-table-column
           prop="projectTitle"
           label="项目名称"
           align="center"
          >
-        </el-table-column>
+          <template>
+            <span>{{ title }}</span>
+          </template>
+        </el-table-column> -->
 
         <el-table-column
           prop="fileName"
@@ -102,6 +105,7 @@
               packageSize:8,
               currentPage:1
             }, 
+            title:"",
             tableData:[],  //附件列表
             file:''
           }
@@ -109,15 +113,32 @@
         methods:{
           getFile(val) {    //上传文件
             this.file = val;
+            let oldData = [];
+            this.tableData.forEach(item=>oldData.push(item))
+            oldData.push(val)
+            // console.log(oldData)
+            // oldData.push(val)
+            // Object.assign(oldData,this.tableData)
+            // oldData.push(val)
+            // console.log(oldData)
+            // this.tableData.push(val)
+            // console.log(this.tableData);
             let param={
                 uid:this.$store.state.userInfo.userid,
                 cid:JSON.parse(localStorage.getItem('pid')),
-                projectFile:val
+                projectFile:JSON.stringify(oldData)
             }
             this.ajax
-                  .post(this.$store.state.api+'',param)
+                  .post(this.$store.state.api+'/AddProjectManageFile',param)
                   .then(res=>{
                     console.log(res);
+                    if (res.data==1) {
+                      this.getData()
+                      this.$message.success('上传成功')
+                    }else{
+                      this.$message.error('上传失败')
+                    }
+                   
                   },err=>{
                     console.log(err);
                   })
@@ -139,22 +160,11 @@
                     .get(this.$store.state.api+'/SelectProjectManageFile',param)
                     .then(res=>{
                       let file = JSON.parse(res.data[0][0]['endFile']);
-                      file.forEach(item=>item.projectTitle = res.data[0][0]['title'])
-                      console.log(file)
-                      // res.data[0].forEach((e,i) => {
-                        // let { title: f, } = JSON.parse(e.endFile);
-                        // console.log(e.title);
-
-                        // console.log(JSON.parse(e.endFile));
-                        // JSON.parse(e.endFile).title=e.title
-                        // JSON.parse(e.endFile).forEach((o,i)=>{
-                        //     k.title=o.title
-                        // })
-                        // console.log(JSON.parse(e.endFile));
-                        // k.push(Object.assign({title:f},JSON.parse(l)))
-                      // });
+                      // this.title = res.data[0][0]['title']
+                      // file.forEach(item=>item.projectTitle = res.data[0][0]['title'])
+                      // console.log(file)
+                     
                       this.tableData=file
-                      // console.log(this.tableData);
                     },err=>{
                       console.log(err);
                     })

+ 8 - 8
src/views/projectManage/ProjectManagementFund1.vue

@@ -126,7 +126,7 @@
           <!-- 经费明细开始 -->
             <div class="tabTit">
               <div><p>经费明细</p></div>
-              <el-button type="primary" @click="addBtn" >设置</el-button>
+              <!-- <el-button type="primary" @click="addBtn" >设置</el-button> -->
             </div>
 
             <el-table
@@ -134,7 +134,7 @@
               tooltip-effect="dark"
               stripe
               class="fontSize"
-              style="height: 320px;"
+              style="height: 360px;"
               :header-cell-style="{ background: '#f2f2f2',color:'#000' }"
               >
               <el-table-column
@@ -155,20 +155,20 @@
                 align="center"
                 >
               </el-table-column>
-              
+<!--               
               <el-table-column
                 prop="state"
                 label="状态"
                 align="center"
                 >
-              </el-table-column>
+              </el-table-column> -->
               <el-table-column
                 prop="textarea"
                 label="备注"
                 align="center"
                >
               </el-table-column>
-              <el-table-column
+              <!-- <el-table-column
                 prop="operation"
                 align="center"
                 label="操作"
@@ -178,17 +178,17 @@
                             <el-button type="primary" @click="lookDetail(scope)" size="mini">明细查看</el-button>
                     </div>
                 </template>
-                </el-table-column>
+                </el-table-column> -->
             </el-table>
           <!-- 经费明细结束 -->
             
-          <div class="pmFund1Footer">
+          <!-- <div class="pmFund1Footer">
             <el-pagination
             background
             layout="prev, pager, next"
             :total="1">
             </el-pagination>
-          </div>
+          </div> -->
 </div>
 </template>
 

+ 22 - 20
src/views/projectManage/ProjectManagementFund2.vue

@@ -68,21 +68,19 @@
           label="申请时间"
          >
         </el-table-column>
-        <el-table-column
+        <!-- <el-table-column
           prop="operation"
           label="操作"
           align="center"
           width="250px"
           >
           <template #default="scope">
-              <div class="operations">
-                  <!-- <el-button type="primary" > -->
-                        <el-button type="primary" class="bt1" @click="MADetails(scope)" size="mini" >查看详情</el-button>
-                        <el-button type="primary" class="bt1" size="mini">表单查看</el-button>
-                  <!-- </el-button> -->
-              </div>
+              <div class="operations"> -->
+                        <!-- <el-button type="primary" class="bt1" @click="MADetails(scope)" size="mini" >查看详情</el-button>
+                        <el-button type="primary" class="bt1" size="mini">表单查看</el-button> -->
+              <!-- </div>
           </template>
-        </el-table-column>
+        </el-table-column> -->
       </el-table>
       <!-- 表格结束 -->
 
@@ -101,7 +99,7 @@
 
 
       <!-- 查看详情对话框开始 -->
-      <el-dialog
+      <!-- <el-dialog
         title="创客资金申请"
         :visible.sync="fundDetail"
         width="900px"
@@ -133,13 +131,13 @@
               </el-select>
           </div>
         </div>
-        
-        <div class="dagRemark">
-          经费支出支出类别(单位:元)
-        </div>
+         -->
+        <!-- <div class="dagRemark"> -->
+          <!-- 经费支出支出类别(单位:元) -->
+        <!-- </div> -->
 
         <!-- 支出类别(单位:元)第一部分开始 -->
-        <div class="dagInpS">
+        <!-- <div class="dagInpS">
           <div class="dagInpS1">
             <div class="dagSpan">直接经费</div>
             <el-select v-model="values.fund"
@@ -175,11 +173,11 @@
                 placeholder="请输入内容"
                 v-model="datas.reason1">
               </el-input>
-        </div>
+        </div> -->
         <!-- 支出类别(单位:元)第一部分结束-->
 
  <!-- 支出类别(单位:元)第二部分开始 -->
- <div class="dagInpS">
+ <!-- <div class="dagInpS">
           <div class="dagInpS1">
             <div class="dagSpan" style="width: 70px;">其他</div>
             <el-input v-model="datas.rests" style="width: 200px;" placeholder="请输入内容"></el-input>
@@ -207,16 +205,16 @@
                 placeholder="请输入内容"
                 v-model="datas.reason2">
               </el-input>
-        </div>
+        </div> -->
         <!-- 支出类别(单位:元)第二部分结束-->
 
 
 
-        <span slot="footer" class="dialog-footer">
+        <!-- <span slot="footer" class="dialog-footer">
           <el-button type="primary" @click="init" style="font-size:16px" size="small">生成表单</el-button>
           <el-button type="primary" @click="init" style="font-size:16px" size="small">返回</el-button>
         </span>
-      </el-dialog>
+      </el-dialog> -->
       <!-- 查看详情对话框结束 -->
 
   </div>
@@ -262,7 +260,11 @@
                 projectType:'',
                 fund:''
               },
-              tableData:[],  //列表展示数据
+              tableData:[
+                {
+
+                }
+              ],  //列表展示数据
               datas:{
                 budget1:'',   //预算
                 budget2:'',

+ 117 - 39
src/views/projectSettlement/projectSettlement.vue

@@ -9,57 +9,64 @@
     <div class="selects">
       <div class="selectsBlock">
         <span class="selectLabel">项目筛选</span>
-        <el-select v-model="pavalues.value" placeholder="我的项目">
+        <el-select v-model="selectInp.filter" placeholder="我的项目">
+          <el-option label="所有项目" :value="0"></el-option>
           <el-option
-            v-for="item in options"
-            :key="item.value"
-            :label="item.label"
-            :value="item.value">
+            v-for="item in options.projectFilter"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id">
           </el-option>
         </el-select>
       </div>
 
       <div class="selectsBlock">
         <span class="selectLabel">部门</span>
-        <el-select v-model="pavalues.value1" placeholder="请选择">
+        <el-select v-model="selectInp.department" placeholder="请选择">
+          <el-option label="所有部门" :value="0"></el-option>
+
           <el-option
-            v-for="item in options1"
-            :key="item.value"
-            :label="item.label"
-            :value="item.value">
+            v-for="item in options.department"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id">
           </el-option>
         </el-select>
       </div>
 
       <div class="selectsBlock">
         <span class="selectLabel">分类</span>
-        <el-select v-model="pavalues.value2" placeholder="请选择">
+        <el-select v-model="selectInp.sort" placeholder="请选择">
+          <el-option label="所有分类" :value="0"></el-option>
+
           <el-option
-            v-for="item in options2"
-            :key="item.value"
-            :label="item.label"
-            :value="item.value">
+            v-for="item in options.sort"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id">
           </el-option>
         </el-select>
       </div>
 
       <div class="selectsBlock">
         <span class="selectLabel">负责人</span>
-        <el-select v-model="pavalues.value3" placeholder="请选择">
+        <el-select v-model="selectInp.person" placeholder="请选择">
+          <el-option label="所有负责人" :value="''"></el-option>
+
           <el-option
-            v-for="item in options3"
-            :key="item.value"
-            :label="item.label"
-            :value="item.value">
+            v-for="item in options.person"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id">
           </el-option>
         </el-select>
       </div>
 
       <div class="selectsBlock">
         <span class="selectLabel">状态</span>
-        <el-select v-model="pavalues.value4" placeholder="请选择">
+        <el-select v-model="selectInp.state" placeholder="请选择">
           <el-option
-            v-for="item in options4"
+            v-for="item in options.state"
             :key="item.value"
             :label="item.label"
             :value="item.value">
@@ -76,12 +83,13 @@
         :data="tableData"
         tooltip-effect="dark"
         class="fontSize"
+        style="height: 500px;"
         :header-cell-style="{ background: '#f2f2f2',color:'#000' }"
         @selection-change="handleSelectionChange">
-        <el-table-column
+        <!-- <el-table-column
           type="selection"
           >
-        </el-table-column>
+        </el-table-column> -->
         <el-table-column
           prop="projectName"
           label="项目名称"
@@ -133,7 +141,7 @@
           <template #default="scope">
               <div class="operations">
                         <el-button type="primary" class="bt1" size="mini" @click="details">查看详情</el-button>
-                        <!-- <el-button type="primary" class="bt1" size="mini">审核</el-button> -->
+                        <el-button type="primary" class="bt1" size="mini">审核</el-button>
                         <el-button type="primary" class="bt1" size="mini" @click="edit(scope.row.id,scope.row.status)"  >成果查看</el-button>
               </div>
           </template>
@@ -141,6 +149,17 @@
       </el-table>
     </div>
     <!-- 表格结束 -->
+    <!-- 分页 -->
+    <el-pagination
+            @current-change="handleCurrentChange"
+            :current-page="table.currentPage"
+            :page-size="table.packageSize"
+            layout=" prev, pager, next"
+            background
+            class="pagination"
+            :total="table.total">
+          </el-pagination>
+        <!-- 分页结束 -->
   </div>
 </template>
 
@@ -148,11 +167,32 @@
     export default {
       data() {
         return {
-          options:[],
-          options1:[],
-          options2:[],
-          options3:[],
-          options4:[],
+          options:{    //头部搜索框下拉框数据
+            projectFilter:[],//项目筛选
+            department:[],//部门
+            sort:[],//分类
+            person:[],//负责人
+            state:[//状态
+              {
+                value:99,
+                label:'全部'
+              },
+              {
+                value:0,
+                label:'未审核'
+              },
+              {
+                value:2,
+                label:"已审核"
+              },
+            ],
+          },
+           // 分页数据
+           table:{
+            total:0,
+            packageSize:6,
+            currentPage:1
+          },   
           tableData:[{
             projectName:'陆地游泳辅助器',
             projectPerson:'王多鱼',
@@ -160,7 +200,7 @@
             budget:'200万',
             date:'2022年-11月-12日',
             tel:'16625153432',
-            state:'已结项',
+            state:'未审核',
           },
           {
             projectName:'北极运冰',
@@ -169,20 +209,54 @@
             budget:'500万',
             date:'2022年-11月-12日',
             tel:'16625153432',
-            state:'已结项',
+            state:'已审核',
           }
           ],
-          pavalues:{
-            value:'',
-            value1:'',
-            value2:'',
-            value3:'',
-            value4:'',
-
+          selectInp:{
+            filter:0,
+            department:0,
+            sort:0,
+            person:'',
+            state:99,
           }
         }
       },
       methods:{
+        handleCurrentChange(val) {   //当页数发生改变的时候调用获取列表数据请求
+          // console.log(`当前页: ${val}`);
+          this.table.currentPage=val
+          this.getData()
+        },
+        getData(){    //获取表格数据
+          let param={
+            uid:this.$store.state.userInfo.userid,
+            pid:this.selectInp.filter,  //筛选
+            did:this.selectInp.department,  //部门
+            tid:this.selectInp.sort,    //分类
+            leader:this.selectInp.person,  //负责人
+            st:this.selectInp.state,  //审核状态
+            textInp:'',
+            page:this.table.currentPage,  //当前页
+            lim:this.table.packageSize  //限制获取几条数据
+          }
+          // return console.log(param);
+          // console.log(param)
+          this.ajax    
+            .get(this.$store.state.api+'/SelectSettlement',param)
+              .then(res=>{
+                console.log(res.data);
+                let data=res.data;
+                let a=this.options;
+                this.tableData=data[0];
+                a.projectFilter=data[1];
+                a.department=data[2];
+                a.sort=data[3];
+                a.person=data[4];
+                this.table.total=data[5][0].total
+              },err=>{
+                console.log(err);
+              })  
+        },
         edit(){
 
         },
@@ -199,6 +273,10 @@
 <style lang="less">
 .projectSettlement{
 
+  .pagination{   //分页
+    float: right;
+    margin: 20px 35px 10px;
+  }
 
   .selects{
     width: 100%;

+ 1 - 1
src/views/resultShow/resultsShow.vue

@@ -95,7 +95,7 @@
               <div>项目编号{{ item.num }}</div>
             </div>
         </div>
-        <div >
+        <div style="">
               <el-button type="primary" class="bt1" size="mini" @click="rsBtn">项目成果展示</el-button>
         </div>
       </div>