山水共长天一色 před 3 roky
rodič
revize
83fad3a82b

+ 22 - 4
fhKeeper/formulahousekeeper/timesheet/src/views/corpreport/list.vue

@@ -41,6 +41,14 @@
   <div class="contents">
     <div class="headine" ref="headine">
       <h3 ref="headHe" style="padding-left: 210px">{{shuz[ins]}}</h3>
+      <div class="headScreen" v-if="ins != 4 && ins != 6">
+        <el-select v-model="proJuctId" placeholder="请选择项目" clearable filterable size="small" @change="selcts()">
+          <el-option v-for="(item, index) in proListOvertime" :key="index" :label="item.projectName + item.projectCode" :value="item.id">
+            <span style="float: left;color: #8492a6;">{{ item.projectCode }}</span>
+            <span style="float: right;font-size: 13px;margin-left: 20px">{{ item.projectName }}</span>
+          </el-option>
+        </el-select>
+      </div>
       <p style="float: right;margin-right: 25px;" ><el-button type="primary" @click="exportExcel" size="mini">报表导出</el-button></p>
     </div>
     <div ref="staff" style="margin: 5px 0px 0px 200px; width: 84%">
@@ -815,6 +823,7 @@ export default {
       this.http.post('/project/getProjectInAndOut', {
                     pageIndex: this.page,
                     pageSize: this.size,
+                    projectId: this.proJuctId
                     },
         res => {
             if (res.code == "ok") {
@@ -872,6 +881,7 @@ export default {
       this.http.post('/project/getAllProjectCost', {
                     pageIndex: this.page,
                     pageSize: this.size,
+                    projectId: this.proJuctId
                     },
         res => {
             if (res.code == "ok") {
@@ -898,6 +908,7 @@ export default {
       this.http.post('/project/getProjectTask', {
                     pageIndex: this.page,
                     pageSize: this.size,
+                    projectId: this.proJuctId
                     },
         res => {
             if (res.code == "ok") {
@@ -924,6 +935,7 @@ export default {
       this.http.post('/project/getProjectStagesCost', {
                     pageIndex: this.page,
                     pageSize: this.size,
+                    projectId: this.proJuctId
                     },
         res => {
             if (res.code == "ok") {
@@ -950,7 +962,8 @@ export default {
       this.listLoading = true
       this.http.post('/project/getBaseCostAndRealCost',{
         pageIndex: this.page,
-        pageSize: this.size
+        pageSize: this.size,
+        projectId: this.proJuctId
       },res => {
         if(res.code == 'ok'){
           this.baseCostList = res.data.records
@@ -1006,6 +1019,7 @@ export default {
       this.http.post('/project/getProjectPage', {
                     pageIndex: this.page,
                     pageSize: this.size,
+                    projectId: this.proJuctId
                     },
         res => {
             if (res.code == "ok") {
@@ -1029,7 +1043,6 @@ export default {
     },
     // 加班情况获取项目
     getProjectListOvertime() {
-        this.listLoading = true;
         this.http.post('/project/getProjectPage', {
                     pageIndex: 1,
                     pageSize: 9999,
@@ -1037,7 +1050,6 @@ export default {
         res => {
             if (res.code == "ok") {
                 this.proListOvertime = res.data.records
-                this.listLoading = false; 
             } else {
                 this.$message({
                 message: res.msg,
@@ -1085,7 +1097,8 @@ export default {
        return  _this.gettime
     },
     selcts() {
-      this.overTime()
+      console.log(this.proJuctId);
+      this.getList()
     },
     // 成本查看明细
     costBtn(item) {
@@ -1139,6 +1152,11 @@ export default {
   display: inline-block;
   margin: 0;
 }
+/* 头部筛选 */
+.headScreen{
+  display: inline-block;
+  padding-left: 60px;
+}
 /* /费用报销标题 */
 .sidebars {
   height: 100%;

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet/src/views/project/cost.vue

@@ -112,7 +112,7 @@
                         </el-popover>
                     </div>
                 </el-form-item>
-                <el-form-item v-if="radio == '项目' || radio == '部门'">
+                <el-form-item v-if="(radio == '项目' || radio == '部门') && exportParam.type == '0'">
                     <el-checkbox v-model="exportParam.projectSum" >含单个项目数据汇总</el-checkbox>
                 </el-form-item>
             </el-form>