zm
2020-05-18 a18bfacbf56b401f6e0fdae8710fbca4df8cff77
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package com.changhong.epc.parsing.service.bill.group;
 
import com.changhong.epc.bean.form.Fieldsets;
import com.changhong.epc.bean.tenant.bill.OCRBillEntity;
import com.changhong.epc.constter.parsing.bill.ConstBill;
import com.changhong.epc.parsing.service.util.IFromOperate;
import org.springframework.stereotype.Service;
 
import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;
 
/**
 * 将票据val转换为code
 * @author wangZX
 *
 */
@Service("billValToCode")
public class BillValToCode implements ConstBill {
 
    private static final Map<String, String> MAPPING_MD = new HashMap<>();
    
    @Resource
    private IFromOperate fromOperate;
    
    static {
        MAPPING_MD.put(FROM    , FROM_SIT);
        MAPPING_MD.put(TO    , TO_SIT);
    }
 
 
    public Fieldsets getFieldsets(OCRBillEntity bill) {
        return new Fieldsets(fromOperate.selectFromAll(bill));
    }
}