package com.zfire.mall.manager.bean.k3;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Data
public class RequestExcuteOperationBean {

    @JsonProperty("CreateOrgId")
    private Integer createOrgId = 0;

    @JsonProperty("Numbers")
    private String[] numbers;

    @JsonProperty("Ids")
    private String ids = "";

    @JsonProperty("PkEntryIds")
    private List<Map<String, String>> pkEntryIds = new ArrayList<>();


    @JsonProperty("NetworkCtrl")
    private String networkCtrl;

    @JsonProperty("IgnoreInterationFlag")
    private String ignoreInterationFlag;

    public void setPkEntryIds(String id, String entryIds) {
        Map<String, String> pkMap = new HashMap<>();
        pkMap.put("Id", id);
        pkMap.put("EntryIds", entryIds);
        pkEntryIds.add(pkMap);
    }

    public void setNumbers(String... numbers) {
        this.numbers = numbers;
    }
}