Explorar o código

费用类别检索内容调整

梁世豪 hai 2 meses
pai
achega
9a0b0cf80d
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      src/main/resources/mapper/PrjAnnualbudgetdetailDao.xml

+ 4 - 1
src/main/resources/mapper/PrjAnnualbudgetdetailDao.xml

@@ -735,16 +735,19 @@
735 735
         FROM
736 736
         (
737 737
         SELECT
738
-        COALESCE(SUM(b.BZJE), 0.00) AS BZZE,
738
+        COALESCE(SUM(r.BZJE), 0.00) AS BZZE,
739 739
         b.XMMC,
740 740
         b.ID,
741 741
         a.FYMC
742 742
         FROM
743 743
         sta_BudgetApproval b
744
+        LEFT JOIN sta_Reimbursement r on r.FYSQ = b.ID
744 745
         LEFT JOIN prj_AnnualBudgetDetail a ON a.ID = b.FYLB
745 746
         WHERE
746 747
         b.SFBZ = 1
747 748
         AND b.SPZT = '审批结束'
749
+        AND (a.FYMC = '(1)外委研究支出费' OR a.FYMC = '(3)外协测试试验与加工费' OR a.FYMC = '(二)间接费')
750
+        AND r.SPZT = '审批结束'
748 751
         AND b.BH != ''
749 752
         <if test="nys != null and nys !=''">
750 753
             AND b.NYS = #{nys}