OpenConcerto

Dépôt officiel du code source de l'ERP OpenConcerto
sonarqube

svn://code.openconcerto.org/openconcerto

Rev

Rev 102 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
102 ilm 1
package org.openconcerto.modules.common.batchprocessing.product;
2
 
3
import java.math.BigDecimal;
4
 
181 ilm 5
import org.openconcerto.modules.common.batchprocessing.BatchField;
102 ilm 6
import org.openconcerto.modules.common.batchprocessing.NumberProcessor;
7
import org.openconcerto.sql.model.SQLRowAccessor;
8
import org.openconcerto.sql.model.SQLRowValues;
9
 
10
public class PurchaseProcessor extends NumberProcessor {
11
 
181 ilm 12
    public PurchaseProcessor(BatchField field) {
102 ilm 13
        super(field);
14
    }
15
 
16
    @Override
17
    public void processBeforeUpdate(SQLRowAccessor from, SQLRowValues to) {
18
        final BigDecimal ht = to.getBigDecimal("PA_HT");
19
        to.put("PRIX_METRIQUE_HA_1", ht);
20
    }
21
}