| | |
| | | pl.template_name, |
| | | pl.approve_user_ids, |
| | | sm.is_white, |
| | | sm.supplier_type, |
| | | pl.approval_status, |
| | | pl.payment_method |
| | | pl.payment_method, |
| | | pl.remarks |
| | | from purchase_ledger pl |
| | | left join sales_ledger_product slp on slp.sales_ledger_id = pl.id and slp.type=2 |
| | | left join product_record pr on pl.id = pr.purchase_ledger_id |
| | |
| | | <if test="c.entryDateEnd != null and c.entryDateEnd != '' "> |
| | | AND pl.entry_date <= DATE_FORMAT(#{c.entryDateEnd},'%Y-%m-%d') |
| | | </if> |
| | | <if test="c.supplierType != null and c.supplierType != '' "> |
| | | AND sm.supplier_type = #{c.supplierType} |
| | | </if> |
| | | </where> |
| | | group by pl.id, pl.purchase_contract_number, pl.sales_contract_no, pl.supplier_name, |
| | | pl.project_name,pl.entry_date, |