All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.global.api.entities.payroll.LaborField Maven / Gradle / Ivy

There is a newer version: 14.2.3
Show newest version
package com.global.api.entities.payroll;

import com.global.api.utils.JsonDoc;

import java.util.ArrayList;

public class LaborField extends PayrollCollectionItem {
    private ArrayList lookup;

    public ArrayList getLookup() {
        return lookup;
    }

    public LaborField() {
        super("LaborFieldId", "LaborFieldValue");
    }

    void fromJson(JsonDoc doc, PayrollEncoder encoder) {
        super.fromJson(doc, encoder);

        if(description == null) {
            description = doc.getString("LaborFieldTitle");
        }

        if(doc.has("laborfieldLookups")) {
            lookup = new ArrayList();
            for(JsonDoc lookupData: doc.getEnumerator("laborfieldLookups")) {
                LaborFieldLookup lookups = new LaborFieldLookup();
                lookups.setDescription(lookupData.getString("laborFieldDescription"));
                lookups.setValue(lookupData.getString("laborFieldValue"));

                lookup.add(lookups);
            }
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy