lamphua 1 rok temu
rodzic
commit
81245f4c30

+ 5
- 5
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/domain/CmcBudgetSettle.java Wyświetl plik

@@ -27,7 +27,7 @@ public class CmcBudgetSettle extends BaseEntity
27 27
     @Excel(name = "结算单价id")
28 28
     private Integer priceId;
29 29
 
30
-    private CmcPrice price;
30
+    private CmcPrice cmcPrice;
31 31
 
32 32
     /** 工作量 */
33 33
     @Excel(name = "工作量")
@@ -68,14 +68,14 @@ public class CmcBudgetSettle extends BaseEntity
68 68
     {
69 69
         return priceId;
70 70
     }
71
-    public void setPrice(CmcPrice price)
71
+    public void setCmcPrice(CmcPrice cmcPrice)
72 72
     {
73
-        this.price = price;
73
+        this.cmcPrice = cmcPrice;
74 74
     }
75 75
 
76
-    public CmcPrice getPrice()
76
+    public CmcPrice getCmcPrice()
77 77
     {
78
-        return price;
78
+        return cmcPrice;
79 79
     }
80 80
     public void setWorkload(Double workload)
81 81
     {

+ 12
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/domain/CmcBudgetStaff.java Wyświetl plik

@@ -2,6 +2,7 @@ package com.ruoyi.oa.domain;
2 2
 
3 3
 import java.math.BigDecimal;
4 4
 
5
+import com.ruoyi.common.core.domain.entity.CmcPostSalary;
5 6
 import com.ruoyi.common.core.domain.entity.SysUser;
6 7
 import org.apache.commons.lang3.builder.ToStringBuilder;
7 8
 import org.apache.commons.lang3.builder.ToStringStyle;
@@ -35,6 +36,8 @@ public class CmcBudgetStaff extends BaseEntity
35 36
     @Excel(name = "天数")
36 37
     private Integer days;
37 38
 
39
+    private CmcPostSalary salary;
40
+
38 41
     /** 人员成本 */
39 42
     @Excel(name = "人员成本")
40 43
     private BigDecimal staffCost;
@@ -101,6 +104,15 @@ public class CmcBudgetStaff extends BaseEntity
101 104
     {
102 105
         return staffCost;
103 106
     }
107
+    public void setSalary(CmcPostSalary salary)
108
+    {
109
+        this.salary = salary;
110
+    }
111
+
112
+    public CmcPostSalary getSalary()
113
+    {
114
+        return salary;
115
+    }
104 116
     public void setInOutPrice(BigDecimal inOutPrice) 
105 117
     {
106 118
         this.inOutPrice = inOutPrice;

+ 2
- 1
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcBudgetCarMapper.xml Wyświetl plik

@@ -19,10 +19,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
19 19
     <resultMap type="CmcCar" id="CmcCarResult">
20 20
         <result property="carId"    column="car_id"    />
21 21
         <result property="licensePlate"    column="license_plate"    />
22
+        <result property="dayCost"    column="day_cost"    />
22 23
     </resultMap>
23 24
 
24 25
     <sql id="selectCmcBudgetCarVo">
25
-        select bc.budget_car_id, bc.budget_id, bc.car_id, c.license_plate, bc.days, bc.depreciation, bc.distance, bc.mileage, bc.expense from cmc_budget_car as bc
26
+        select bc.budget_car_id, bc.budget_id, bc.car_id, c.license_plate, c.day_cost, bc.days, bc.depreciation, bc.distance, bc.mileage, bc.expense from cmc_budget_car as bc
26 27
         left join cmc_car as c on c.car_id = bc.car_id
27 28
     </sql>
28 29
 

+ 2
- 1
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcBudgetDeviceMapper.xml Wyświetl plik

@@ -19,10 +19,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
19 19
         <result property="name"    column="name"    />
20 20
         <result property="series"    column="series"    />
21 21
         <result property="brand"    column="brand"    />
22
+        <result property="dayCost"    column="day_cost"    />
22 23
     </resultMap>
23 24
 
24 25
     <sql id="selectCmcBudgetDeviceVo">
25
-        select bd.budget_device_id, bd.budget_id, d.code, d.name, d.series, d.brand, bd.device_id, bd.days, bd.depreciation from cmc_budget_device as bd
26
+        select bd.budget_device_id, bd.budget_id, d.code, d.name, d.series, d.brand, d.day_cost, bd.device_id, bd.days, bd.depreciation from cmc_budget_device as bd
26 27
         left join cmc_device as d on d.device_id = bd.device_id
27 28
     </sql>
28 29
 

+ 4
- 2
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcBudgetSettleMapper.xml Wyświetl plik

@@ -11,7 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
11 11
         <result property="workload"    column="workload"    />
12 12
         <result property="coefficient"    column="coefficient"    />
13 13
         <result property="settle"    column="settle"    />
14
-        <association property="price"    javaType="CmcPrice"         resultMap="CmcPriceResult" />
14
+        <association property="cmcPrice"    javaType="CmcPrice"         resultMap="CmcPriceResult" />
15 15
     </resultMap>
16 16
 
17 17
     <resultMap type="CmcPrice" id="CmcPriceResult">
@@ -21,10 +21,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
21 21
         <result property="subItem"    column="sub_item"    />
22 22
         <result property="scaleGrade"    column="scale_grade"    />
23 23
         <result property="unit"    column="unit"    />
24
+        <result property="commonPrice"    column="common_price"    />
25
+        <result property="complexPrice"    column="complex_price"    />
24 26
     </resultMap>
25 27
 
26 28
     <sql id="selectCmcBudgetSettleVo">
27
-        select bs.budget_settle_id, bs.budget_id, bs.price_id, p.work_type, p.work_item, p.sub_item, p.scale_grade, p.unit, bs.workload, bs.coefficient, bs.settle from cmc_budget_settle as bs
29
+        select bs.budget_settle_id, bs.budget_id, bs.price_id, p.work_type, p.work_item, p.sub_item, p.scale_grade, p.unit, p.common_price, p.complex_price, bs.workload, bs.coefficient, bs.settle from cmc_budget_settle as bs
28 30
         left join cmc_price as p on p.id = bs.price_id
29 31
     </sql>
30 32
 

+ 12
- 1
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcBudgetStaffMapper.xml Wyświetl plik

@@ -13,16 +13,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
13 13
         <result property="inOutPrice"    column="in_out_price"    />
14 14
         <result property="inOutExpense"    column="in_out_expense"    />
15 15
         <association property="user"    javaType="SysUser"         resultMap="SysUserResult" />
16
+        <association property="salary"    javaType="CmcPostSalary"         resultMap="CmcPostSalaryResult" />
16 17
     </resultMap>
17 18
 
18 19
     <resultMap type="SysUser" id="SysUserResult">
19 20
         <result property="userId"    column="user_id"    />
20 21
         <result property="nickName"    column="nick_name"    />
22
+        <result property="postLevel"    column="post_level"    />
23
+        <result property="salaryLevel"    column="salary_level"    />
24
+    </resultMap>
25
+
26
+    <resultMap type="CmcPostSalary" id="CmcPostSalaryResult">
27
+        <result property="salaryId"    column="salary_id"    />
28
+        <result property="postLevel"    column="post_level"    />
29
+        <result property="salaryLevel"    column="salary_level"    />
30
+        <result property="salary"    column="salary"    />
21 31
     </resultMap>
22 32
 
23 33
     <sql id="selectCmcBudgetStaffVo">
24
-        select bs.budget_staff_id, bs.budget_id, bs.user_id, u.nick_name, bs.days, bs.staff_cost, bs.in_out_price, bs.in_out_expense from cmc_budget_staff as bs
34
+        select bs.budget_staff_id, bs.budget_id, bs.user_id, u.nick_name, bs.days, ps.salary, bs.staff_cost, bs.in_out_price, bs.in_out_expense from cmc_budget_staff as bs
25 35
         left join sys_user as u on u.user_id = bs.user_id
36
+        left join cmc_post_salary as ps on u.salary_level = ps.salary_level and u.post_level = ps.post_level
26 37
     </sql>
27 38
 
28 39
     <select id="selectCmcBudgetStaffList" parameterType="CmcBudgetStaff" resultMap="CmcBudgetStaffResult">

+ 2
- 138
oa-back/sql/sql.sql
Plik diff jest za duży
Wyświetl plik


+ 1
- 0
oa-ui/src/store/getters.js Wyświetl plik

@@ -15,6 +15,7 @@ const getters = {
15 15
   avatar: state => state.user.avatar,
16 16
   name: state => state.user.name,
17 17
   userId: state => state.user.id,
18
+  deptId: state => state.user.deptId,
18 19
   deptName: state => state.user.deptName,
19 20
   introduction: state => state.user.introduction,
20 21
   roles: state => state.user.roles,

+ 1
- 1
oa-ui/src/store/modules/user.js Wyświetl plik

@@ -72,7 +72,7 @@ const user = {
72 72
           }
73 73
           commit('SET_ID', user.userId)
74 74
           commit('SET_NAME', user.nickName)
75
-          commit('SET_DEPTID',user.dept.deptId)
75
+          commit('SET_DEPTID',user.deptId)
76 76
           commit('SET_DEPTNAME',user.dept.deptName)
77 77
           commit('SET_AVATAR', avatar)
78 78
           resolve(res)

Ładowanie…
Anuluj
Zapisz