Commit f011f37d authored by huangjie's avatar huangjie

Merge branch 'V20231129-中建一局二公司' of http://192.168.60.201/root/dsk-operate-sys...

Merge branch 'V20231129-中建一局二公司' of http://192.168.60.201/root/dsk-operate-sys into V20231129-中建一局二公司
parents 5abe9333 f91cdfe9
......@@ -16,6 +16,6 @@ public class EnterpriseBusinessSkyProjectDetailBody {
* id
*/
@NotNull(message = "id不能为空")
private Long sourceId;
private String sourceId;
}
......@@ -41,7 +41,7 @@
<router-link :to="`/biddetail/${scope.row.sourceId}`" tag="a" class="a-link" v-if="scope.row.sourceId" v-html="scope.row.projectName"></router-link>
<div v-else v-html="scope.row.projectName || '--'"></div>
</template>
<template>
<template v-else>
<span @click="linkTo1(scope.row.sourceId)" v-if="scope.row.projectName" style="color: #0081FF;cursor: pointer;" v-html="scope.row.projectName">{{scope.row.projectName}}</span>
<span v-else>-</span>
</template>
......
......@@ -41,7 +41,7 @@
<router-link :to="`/biddetail/${scope.row.sourceId}`" tag="a" class="a-link" v-if="scope.row.sourceId" v-html="scope.row.projectName"></router-link>
<div v-else v-html="scope.row.projectName || '--'"></div>
</template>
<template>
<template v-else>
<span @click="linkTo1(scope.row.sourceId)" v-if="scope.row.projectName" style="color: #0081FF;cursor: pointer;" v-html="scope.row.projectName">{{scope.row.projectName}}</span>
<span v-else>-</span>
</template>
......
......@@ -176,7 +176,7 @@ export default {
},
// 跳转项目详情
viewProjectDetail(row) {
this.$tab.openPage(row.projectName, `/consultingOrgManagement/projectDetail?advisoryBodyCid=${row.advisoryBody?.advisoryBodyCid ? row.advisoryBody?.advisoryBodyCid : ""}&projectKey=${row.projectKey}`);
},
viewEnterprise(row) {
......
......@@ -9,7 +9,7 @@
<div class="directCost-cont">
<div class="left">
<div class="left-side-menu">
<project-side-menu :menuTree="menuTreeList" :menuOptions="menuOptions" :unique-opened="false" :default-active="defaultActive" @select="handleSelect">
<project-side-menu :menuTree="menuTreeList" :menuOptions="menuOptions" :unique-opened="false" v-model="defaultActive" @select="handleSelect">
<template :slot="`${menuDetails.menuName}-${menuDetails.menuLevel}`">
<img src="@/assets/images/projectCostLedger/icon_cost_detail_1.svg" alt="">
<div class="project-sub-menu-title-text">{{menuDetails.menuName}}</div>
......@@ -17,14 +17,16 @@
</project-side-menu>
</div>
</div>
<div class="right-table">
<div class="right-table" ref="rightTable">
<skeleton v-if="isSkeleton" style="padding: 16px"></skeleton>
<div class="table-item">
<el-table
v-if="!isSkeleton"
element-loading-text="Loading"
:maxHeight="maxHeight"
:data="tableData"
:row-class-name="tableRowClassName"
row-key="id"
v-horizontal-scroll="'hover'"
default-expand-all
:tree-props="{children: 'childrenList', hasChildren: 'hasChildren'}"
border
......@@ -60,7 +62,6 @@
</el-table-column>
</el-table>
</div>
</div>
</div>
</div>
......@@ -101,6 +102,7 @@
<script>
import ProjectSideMenu from "@/views/projectCostLedger/detail/components/ProjectSideMenu";
import { getCbDirectExpenseMenuTreeApi,getCbDirectExpenseList,cbDirectExpenseAdd,cbDirectExpenseDelete } from "@/api/projectCostLedger";
import skeleton from '../../../../component/skeleton'
export default {
name: "directCost",
props: {
......@@ -116,10 +118,11 @@ export default {
default: () => ({})
}
},
components: {ProjectSideMenu},
components: {ProjectSideMenu,skeleton},
data() {
return {
date:'2023年11月',
isSkeleton: true,
datelist:[
{
dictValue:'2023年11月',
......@@ -162,7 +165,8 @@ export default {
children : "childrenList"
},
detailsId:'',
menuId:''
menuId:'',
maxHeight:''
};
},
watch: {
......@@ -184,7 +188,6 @@ export default {
immediate: true
}
},
//可访问data属性
created() {
},
......@@ -217,7 +220,6 @@ export default {
},
async getCbDirectExpenseList(params) {
try {
const result = await getCbDirectExpenseList(params);
if (result.code == 200) {
const _dataArray = result.data;
......@@ -226,6 +228,8 @@ export default {
this.tableData.forEach((item,index)=>{
item.index=index+1
})
this.maxHeightInit();
this.isSkeleton = false;
}
} catch (error) {
......@@ -295,6 +299,11 @@ export default {
}
}
},
async maxHeightInit() {
const divHeight = this.$refs.rightTable.clientHeight-32;
this.maxHeight=divHeight;
console.log('DIV的高度是:', divHeight);
}
},
}
</script>
......@@ -352,6 +361,35 @@ export default {
.color2{
background: #FFFFFF;
}
.el-table__fixed-right {
z-index: 9;
right: 16px !important;
bottom: 15px !important;
.el-table__fixed-header-wrapper {
position: absolute;
}
}
.el-table__fixed-right-patch {
width: 16px !important;
z-index: 9;
top: 0px;
background: #f0f3fa;
border: 1px solid #e6eaf1;
border-left: unset;
border-top: unset;
}
// 自动适配下 减去滚动条高度
.el-table__fixed {
height: calc(100% - 15px) !important;
}
.el-table__fixed-right {
height: calc(100% - 15px) !important;
}
.el-table__fixed-body-wrapper {
.el-table__body {
padding-bottom: 10px!important;
}
}
}
}
}
......
<template>
<el-dialog :title="comIsEntityMaterials ? '推送到物资用量' : '推送工程量'" :visible.sync="pushProjectUseDialog" width="480px" class="push-project-use-dialog"
@close="dialogClose">
<el-dialog :title="comIsEntityMaterials ? '推送到物资用量' : '推送工程量'" :visible.sync="comPushProjectUseDialog" width="480px"
class="push-project-use-dialog" @close="dialogClose">
<div class="dialog-body-content">
<el-form :model="pushForm" ref="pushForm" :rules="rules">
<el-form :model="pushForm" ref="pushForm" :rules="rules" class="push-form">
<el-form-item label="分包项目名称">
<el-input v-model="form.projectName"></el-input>
<el-input :value="pushForm.projectName" :disabled="true"></el-input>
</el-form-item>
<el-form-item label="本月实际工程量">
<el-input :value="pushForm.totalQuantities" :disabled="true"></el-input>
</el-form-item>
<el-form-item label="需推送工程量" prop="pushQuantities">
<el-input v-model="pushForm.pushQuantities" placeholder="请填写需推送工程量"></el-input>
</el-form-item>
</el-form>
</div>
</el-dialog>
</template>
<script>
import { subtract } from "@/utils/decimal";
import { cloneDeep } from 'lodash-es';
export default {
name: "pushProjectUseDialog",
model: {
......@@ -45,11 +53,17 @@ export default {
rowData: {
handler(newValue, oldValue) {
const _temp = newValue ? newValue : {};
this.pushForm = { ...this.pushForm, ..._temp };
this.pushForm = cloneDeep({ ...this.pushForm, ..._temp });
}
}
},
data() {
// 验证需推送工程量
const pushQuantitiesValidator = (rule, value, callback) => {
const reg = /^(?!0\d)(?!0+$)(?!0*\.0*$)\d+(\.\d+)?$/;
if (!reg.test(value)) return callback(new Error("请输入正确的工程量"));
callback();
};
return {
comIsEntityMaterials: this.isEntityMaterials,
comPushProjectUseDialog: this.pushProjectUseDialog,
......@@ -61,7 +75,9 @@ export default {
ipmBizCode: ""
},
rules: {
pushQuantities: [
{ trigger: ["blur", "change"], validator: pushQuantitiesValidator }
]
}
};
},
......@@ -76,6 +92,10 @@ export default {
//方法集
methods: {
dialogClose() {
const form = this.$refs["pushForm"];
if (form) form.clearValidate();
this.$emit("dialogClose");
this.pushForm = this.$options.data.call(this).pushForm;
this.$emit("close", false);
}
},
......@@ -120,6 +140,51 @@ export default {
.dialog-body-content {
padding: 24px 20px;
box-sizing: border-box;
.push-form {
.el-form-item {
margin-bottom: 16px;
display: flex;
align-items: center;
.el-form-item__label {
width: 98px;
min-width: 98px;
line-height: 20px;
color: rgba(35, 35, 35, 0.8);
font-weight: 350;
font-size: 14px;
text-align: right;
padding-right: 0px;
margin-right: 16px;
white-space: nowrap;
}
.el-form-item__content {
width: 100%;
line-height: 32px;
.el-input {
&.is-disabled {
.el-input__inner {
background: #fff;
color: rgba(35, 35, 35, 0.8);
}
}
}
.el-input__inner {
line-height: 32px;
height: 32px;
border-radius: 2px;
padding: 0px 7px;
::placeholder {
color: #c0c4cc !important;
}
}
}
}
}
}
}
}
......
......@@ -85,8 +85,8 @@
<add-actual-cost v-model="showAddActualCost" :project-create-time="projectDetailInfo.createTime" @timeSelect="timeSelect"></add-actual-cost>
<!-- 推送工程量 , 推送物资 -->
<push-project-use-dialog v-model="pushProjectUseDialog" :is-entity-materials="isEntityMaterials"
:row-data="pushProjectUseTemp"></push-project-use-dialog>
<push-project-use-dialog v-model="pushProjectUseDialog" :is-entity-materials="isEntityMaterials" :row-data="pushProjectUseTemp"
@dialogClose="dialogClose"></push-project-use-dialog>
<!-- 单位换算弹窗 -->
<unit-conversion v-if="showUnitConversion" :isVisible="showUnitConversion" :dataList="unitConversionList"
......@@ -646,6 +646,10 @@ export default {
this.pushProjectUseTemp = _temp;
this.pushProjectUseDialog = true;
},
// 推送工程用量弹窗关闭
dialogClose() {
this.pushProjectUseTemp = {};
},
differentCompare() {
const originData = this.originTableDataList;
/**
......
......@@ -3,7 +3,7 @@
<div class="otherProjects-cont">
<div class="left">
<div class="left-side-menu">
<project-side-menu :menuTree="menuTreeList" :menuOptions="menuOptions" :unique-opened="false" :default-active="defaultActive" @select="select">
<project-side-menu :menuTree="menuTreeList" :menuOptions="menuOptions" :unique-opened="false" v-model="defaultActive" @select="select">
<template slot="其他费-1">
<img src="@/assets/images/projectCostLedger/icon_cost_detail_5.svg" alt="">
<div class="project-sub-menu-title-text">其他费</div>
......@@ -12,7 +12,8 @@
</div>
</div>
<div class="right-table">
<div class="table-item" v-if="defaultActive ==='费用汇总'">
<skeleton v-if="isSkeleton" style="padding: 16px"></skeleton>
<div class="table-item" v-if="defaultActiveTitle ==='费用汇总'">
<tables
v-if="!isSkeleton"
:tableLoading="tableLoading"
......@@ -62,10 +63,11 @@
import Tables from "../../../../component/Tables"
import ProjectSideMenu from "@/views/projectCostLedger/detail/components/ProjectSideMenu";
import { getProjectOtherMenuTreeApi,getProjectOtherStatistics,getProjectOtherList } from "@/api/projectCostLedger";
import skeleton from '../../../../component/skeleton'
export default {
name: "directCost",
components: {
Tables,ProjectSideMenu
Tables,ProjectSideMenu,skeleton
},
props: {
// 项目ID
......@@ -83,8 +85,9 @@ export default {
data() {
return {
comProjectId:'',
isSkeleton:false,
tableLoading:false,
// 加载数据列表
isSkeleton: true,
tableLoading: false,
tableData:[],
tableDataTotal:0,
forData: [
......@@ -109,6 +112,7 @@ export default {
pageNum:1,
pageSize:10,
},
defaultActiveTitle: "费用汇总",
defaultActive: "",
menuTreeList: [
{
......@@ -145,11 +149,7 @@ export default {
immediate: true
}
},
//可访问data属性
created() {
},
//计算集
computed: {
......@@ -177,6 +177,7 @@ export default {
const _dataArray = result.data;
this.tableDataTotal=_dataArray.length;
this.tableData = _dataArray;
this.isSkeleton = false;
}
} catch (error) {
......@@ -184,14 +185,19 @@ export default {
},
select(menuPath, menuPathArray){
this.defaultActive=menuPath;
this.defaultActiveTitle=menuPathArray.nodeName;
let param = {
projectId:this.comProjectDetailInfo.projectId,
parentId:menuPathArray.originData.id
}
if(menuPathArray.nodeName === '费用汇总'){
this.getProjectOtherStatistics(this.comProjectDetailInfo.projectId)
}else {
getProjectOtherList(param).then(res=>{
this.tableData1 = res.data;
this.tableDataTotal1=res.data.length;
})
}
},
//分页
handleCurrentChange(e){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment