package com.ruoyi.web.modules.industryservice.support;

import java.io.InputStream;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.DataFormatter;
import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Sheet;
import org.apache.poi.ss.usermodel.Workbook;
import org.apache.poi.ss.usermodel.WorkbookFactory;
import com.ruoyi.common.exception.ServiceException;
import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.web.modules.industryservice.domain.BizCooperativeDevelopment;

/**
 * 合作社发展 Excel 解析（对齐 cooperative_development_import_template.xlsx）
 * <p>表头约 1～7 行（多级），数据从「村/乡镇/合作社名称」所在表头行 +5 起。</p>
 */
public final class CooperativeDevelopmentExcelParser
{
    public static final String TEMPLATE_CLASSPATH = "templates/cooperative_development_import_template.xlsx";

    /** 表头识别后，向下跳过的子表头行数（含识别行之后的 4 行，共 +5 到数据行） */
    static final int HEADER_SPAN = 5;

    static final int COL_SEQ = 0;

    static final int COL_VILLAGE = 1;

    static final int COL_TOWN = 2;

    static final int COL_COOP_NAME = 3;

    static final int COL_LEGAL_REP = 4;

    static final int COL_ESTABLISH_DATE = 5;

    static final int COL_REGISTERED_CAPITAL = 6;

    static final int COL_YEAR_END_ASSETS = 7;

    static final int COL_MEMBER_HOUSEHOLD = 8;

    static final int COL_MEMBER_POPULATION = 9;

    static final int COL_POVERTY_MONITOR = 10;

    static final int COL_CATTLE_SHARE = 11;

    static final int COL_SHEEP_SHARE = 12;

    static final int COL_LIVESTOCK_SHARE_TOTAL = 13;

    static final int COL_GRASSLAND_SHARE = 14;

    static final int COL_LABOR_SHARE = 15;

    static final int COL_CASH_SHARE = 16;

    static final int COL_OTHER_SHARE = 17;

    static final int COL_TOTAL_INCOME = 18;

    static final int COL_NET_INCOME = 19;

    static final int COL_CASH_DIVIDEND = 20;

    static final int COL_IN_KIND_DIVIDEND = 21;

    static final int COL_REVOLVING_FUND = 22;

    static final int COL_LOSS = 23;

    static final int COL_COLLEGE_COUNT = 24;

    static final int COL_COLLEGE_WAGE = 25;

    static final int COL_FARMER_TRANSFER_COUNT = 26;

    static final int COL_FARMER_TRANSFER_WAGE = 27;

    static final int COL_CATTLE_INVENTORY = 28;

    static final int COL_CATTLE_OUTBOUND = 29;

    static final int COL_SHEEP_INVENTORY = 30;

    static final int COL_SHEEP_OUTBOUND = 31;

    static final int COL_TRADEMARK = 32;

    static final int COL_QUALITY_CERT = 33;

    static final int COL_TRAIN_MANAGE = 34;

    static final int COL_TRAIN_SKILL = 35;

    static final int COL_TRAIN_OTHER = 36;

    static final int COL_SCOPE_START = 37;

    static final int COL_SCOPE_END = 46;

    static final int COL_MODEL_START = 47;

    static final int COL_MODEL_END = 52;

    static final int COL_STATUS_START = 53;

    static final int COL_STATUS_END = 55;

    static final int COL_LAST = COL_STATUS_END;

    public static final String[] BUSINESS_SCOPE_LABELS = {
            "养殖业", "种养结合", "农产品加工", "农机服务", "劳务输出",
            "建筑工程", "旅游服务", "运输", "特色产品制作及销售", "其他"
    };

    public static final String[] BUSINESS_MODEL_LABELS = {
            "整村合作社", "股份合作社", "联合合作社", "多种经营合作社", "公司型合作社", "其它"
    };

    public static final String[] OPERATION_STATUS_LABELS = { "规范", "一般", "差" };

    private static final DataFormatter FORMATTER = new DataFormatter();

    private CooperativeDevelopmentExcelParser()
    {
    }

    public static List<ParsedRow> parse(InputStream inputStream)
    {
        try (Workbook workbook = WorkbookFactory.create(inputStream))
        {
            Sheet sheet = resolveSheet(workbook);
            int headerRowIndex = detectHeaderRow(sheet);
            if (headerRowIndex < 0)
            {
                throw new ServiceException("未识别到表头行（村/乡镇/合作社名称）");
            }
            int dataStartRow = headerRowIndex + HEADER_SPAN;
            List<ParsedRow> rows = new ArrayList<>();
            for (int i = dataStartRow; i <= sheet.getLastRowNum(); i++)
            {
                Row row = sheet.getRow(i);
                if (row == null)
                {
                    continue;
                }
                String seqText = cellString(row, COL_SEQ);
                String villageName = cellString(row, COL_VILLAGE);
                String townName = cellString(row, COL_TOWN);
                String coopName = cellString(row, COL_COOP_NAME);
                if (StringUtils.isNotEmpty(seqText) && seqText.contains("合计"))
                {
                    break;
                }
                if (StringUtils.isNotEmpty(villageName) && villageName.contains("合计"))
                {
                    break;
                }
                if (StringUtils.isNotEmpty(townName) && townName.contains("合计"))
                {
                    break;
                }
                if (StringUtils.isEmpty(coopName) && StringUtils.isEmpty(villageName) && StringUtils.isEmpty(townName))
                {
                    continue;
                }
                ParsedRow parsed = new ParsedRow();
                parsed.setExcelRowNum(i + 1);
                parsed.setVillageName(villageName);
                parsed.setTownName(townName);
                parsed.setCooperativeName(coopName);
                parsed.setLegalRepresentative(cellString(row, COL_LEGAL_REP));
                parsed.setEstablishDate(cellString(row, COL_ESTABLISH_DATE));
                parsed.setRegisteredCapital(cellDecimal(row, COL_REGISTERED_CAPITAL));
                parsed.setYearEndTotalAssets(cellDecimal(row, COL_YEAR_END_ASSETS));
                parsed.setMemberHouseholdCount(cellInteger(row, COL_MEMBER_HOUSEHOLD));
                parsed.setMemberPopulationCount(cellInteger(row, COL_MEMBER_POPULATION));
                parsed.setPovertyMonitorCount(cellInteger(row, COL_POVERTY_MONITOR));
                parsed.setCattleShareCount(cellInteger(row, COL_CATTLE_SHARE));
                parsed.setSheepShareCount(cellInteger(row, COL_SHEEP_SHARE));
                parsed.setLivestockShareTotal(cellInteger(row, COL_LIVESTOCK_SHARE_TOTAL));
                parsed.setGrasslandShareArea(cellDecimal(row, COL_GRASSLAND_SHARE));
                parsed.setLaborShareCount(cellInteger(row, COL_LABOR_SHARE));
                parsed.setCashShareAmount(cellDecimal(row, COL_CASH_SHARE));
                parsed.setOtherShareAmount(cellDecimal(row, COL_OTHER_SHARE));
                parsed.setTotalIncome(cellDecimal(row, COL_TOTAL_INCOME));
                parsed.setNetIncome(cellDecimal(row, COL_NET_INCOME));
                parsed.setCashDividend(cellDecimal(row, COL_CASH_DIVIDEND));
                parsed.setInKindDividend(cellDecimal(row, COL_IN_KIND_DIVIDEND));
                parsed.setRevolvingFund(cellDecimal(row, COL_REVOLVING_FUND));
                parsed.setLossAmount(cellDecimal(row, COL_LOSS));
                parsed.setCollegeGraduateCount(cellInteger(row, COL_COLLEGE_COUNT));
                parsed.setCollegeGraduateWage(cellDecimal(row, COL_COLLEGE_WAGE));
                parsed.setFarmerTransferEmploymentCount(cellInteger(row, COL_FARMER_TRANSFER_COUNT));
                parsed.setFarmerTransferWage(cellDecimal(row, COL_FARMER_TRANSFER_WAGE));
                parsed.setCattleInventoryCount(cellInteger(row, COL_CATTLE_INVENTORY));
                parsed.setCattleOutboundCount(cellInteger(row, COL_CATTLE_OUTBOUND));
                parsed.setSheepInventoryCount(cellInteger(row, COL_SHEEP_INVENTORY));
                parsed.setSheepOutboundCount(cellInteger(row, COL_SHEEP_OUTBOUND));
                parsed.setTrademarkProductCount(cellInteger(row, COL_TRADEMARK));
                parsed.setQualityCertProductCount(cellInteger(row, COL_QUALITY_CERT));
                parsed.setTrainingManageCount(cellInteger(row, COL_TRAIN_MANAGE));
                parsed.setTrainingSkillCount(cellInteger(row, COL_TRAIN_SKILL));
                parsed.setTrainingOtherCount(cellInteger(row, COL_TRAIN_OTHER));
                parsed.setBusinessScope(parseMultiSelect(row, COL_SCOPE_START, BUSINESS_SCOPE_LABELS));
                parsed.setBusinessModel(parseSingleSelect(row, COL_MODEL_START, BUSINESS_MODEL_LABELS));
                parsed.setOperationStatus(parseSingleSelect(row, COL_STATUS_START, OPERATION_STATUS_LABELS));
                rows.add(parsed);
            }
            return rows;
        }
        catch (ServiceException ex)
        {
            throw ex;
        }
        catch (Exception ex)
        {
            throw new ServiceException("Excel 解析失败：" + ex.getMessage());
        }
    }

    static Sheet resolveSheet(Workbook workbook)
    {
        for (int i = 0; i < workbook.getNumberOfSheets(); i++)
        {
            Sheet sheet = workbook.getSheetAt(i);
            String name = sheet.getSheetName();
            if (name != null && name.contains("合作社"))
            {
                return sheet;
            }
        }
        return workbook.getSheetAt(0);
    }

    static int detectHeaderRow(Sheet sheet)
    {
        int last = Math.min(sheet.getLastRowNum(), 30);
        for (int i = 0; i <= last; i++)
        {
            Row row = sheet.getRow(i);
            if (row == null)
            {
                continue;
            }
            String villageHeader = cellString(row, COL_VILLAGE);
            String townHeader = cellString(row, COL_TOWN);
            String coopHeader = cellString(row, COL_COOP_NAME);
            if (StringUtils.isNotEmpty(villageHeader) && villageHeader.contains("村")
                    && StringUtils.isNotEmpty(townHeader) && townHeader.contains("乡镇")
                    && StringUtils.isNotEmpty(coopHeader) && coopHeader.contains("合作社"))
            {
                return i;
            }
        }
        return -1;
    }

    static String parseMultiSelect(Row row, int startCol, String[] labels)
    {
        List<String> selected = new ArrayList<>();
        for (int i = 0; i < labels.length; i++)
        {
            if (isMarkedOne(cellString(row, startCol + i)))
            {
                selected.add(labels[i]);
            }
        }
        return selected.isEmpty() ? null : String.join(",", selected);
    }

    static String parseSingleSelect(Row row, int startCol, String[] labels)
    {
        String found = null;
        for (int i = 0; i < labels.length; i++)
        {
            if (isMarkedOne(cellString(row, startCol + i)))
            {
                if (found != null)
                {
                    throw new ServiceException("第" + (row.getRowNum() + 1) + "行「" + labels[0] + "…」只能单选一项");
                }
                found = labels[i];
            }
        }
        return found;
    }

    static boolean isMarkedOne(String text)
    {
        if (StringUtils.isEmpty(text))
        {
            return false;
        }
        String t = text.trim();
        return "1".equals(t) || "１".equals(t);
    }

    static String cellString(Row row, int colIndex)
    {
        Cell cell = row.getCell(colIndex);
        if (cell == null)
        {
            return null;
        }
        String text = FORMATTER.formatCellValue(cell);
        return StringUtils.isEmpty(text) ? null : text.trim();
    }

    static Integer cellInteger(Row row, int colIndex)
    {
        String text = cellString(row, colIndex);
        if (StringUtils.isEmpty(text))
        {
            return null;
        }
        try
        {
            return (int) Math.round(Double.parseDouble(text.replace(",", "")));
        }
        catch (NumberFormatException ex)
        {
            throw new ServiceException("第" + (row.getRowNum() + 1) + "行数字格式错误");
        }
    }

    static BigDecimal cellDecimal(Row row, int colIndex)
    {
        String text = cellString(row, colIndex);
        if (StringUtils.isEmpty(text))
        {
            return null;
        }
        try
        {
            return new BigDecimal(text.replace(",", ""));
        }
        catch (NumberFormatException ex)
        {
            throw new ServiceException("第" + (row.getRowNum() + 1) + "行数字格式错误");
        }
    }

    public static BizCooperativeDevelopment toEntity(ParsedRow parsed, Integer statYear, Integer statMonth,
            Long townDeptId, String townName, Long villageDeptId, String villageName)
    {
        BizCooperativeDevelopment row = new BizCooperativeDevelopment();
        row.setStatYear(statYear);
        row.setStatMonth(statMonth);
        row.setTownDeptId(townDeptId);
        row.setTownName(townName);
        row.setVillageDeptId(villageDeptId);
        row.setVillageName(villageName);
        row.setCooperativeName(parsed.getCooperativeName());
        row.setLegalRepresentative(parsed.getLegalRepresentative());
        row.setEstablishDate(parsed.getEstablishDate());
        row.setRegisteredCapital(parsed.getRegisteredCapital());
        row.setYearEndTotalAssets(parsed.getYearEndTotalAssets());
        row.setMemberHouseholdCount(parsed.getMemberHouseholdCount());
        row.setMemberPopulationCount(parsed.getMemberPopulationCount());
        row.setPovertyMonitorCount(parsed.getPovertyMonitorCount());
        row.setCattleShareCount(parsed.getCattleShareCount());
        row.setSheepShareCount(parsed.getSheepShareCount());
        row.setLivestockShareTotal(parsed.getLivestockShareTotal());
        row.setGrasslandShareArea(parsed.getGrasslandShareArea());
        row.setLaborShareCount(parsed.getLaborShareCount());
        row.setCashShareAmount(parsed.getCashShareAmount());
        row.setOtherShareAmount(parsed.getOtherShareAmount());
        row.setTotalIncome(parsed.getTotalIncome());
        row.setNetIncome(parsed.getNetIncome());
        row.setCashDividend(parsed.getCashDividend());
        row.setInKindDividend(parsed.getInKindDividend());
        row.setRevolvingFund(parsed.getRevolvingFund());
        row.setLossAmount(parsed.getLossAmount());
        row.setCollegeGraduateCount(parsed.getCollegeGraduateCount());
        row.setCollegeGraduateWage(parsed.getCollegeGraduateWage());
        row.setFarmerTransferEmploymentCount(parsed.getFarmerTransferEmploymentCount());
        row.setFarmerTransferWage(parsed.getFarmerTransferWage());
        row.setCattleInventoryCount(parsed.getCattleInventoryCount());
        row.setCattleOutboundCount(parsed.getCattleOutboundCount());
        row.setSheepInventoryCount(parsed.getSheepInventoryCount());
        row.setSheepOutboundCount(parsed.getSheepOutboundCount());
        row.setTrademarkProductCount(parsed.getTrademarkProductCount());
        row.setQualityCertProductCount(parsed.getQualityCertProductCount());
        row.setTrainingManageCount(parsed.getTrainingManageCount());
        row.setTrainingSkillCount(parsed.getTrainingSkillCount());
        row.setTrainingOtherCount(parsed.getTrainingOtherCount());
        row.setBusinessScope(parsed.getBusinessScope());
        row.setBusinessModel(parsed.getBusinessModel());
        row.setOperationStatus(parsed.getOperationStatus());
        return row;
    }

    public static class ParsedRow
    {
        private int excelRowNum;

        private String villageName;

        private String townName;

        private String cooperativeName;

        private String legalRepresentative;

        private String establishDate;

        private BigDecimal registeredCapital;

        private BigDecimal yearEndTotalAssets;

        private Integer memberHouseholdCount;

        private Integer memberPopulationCount;

        private Integer povertyMonitorCount;

        private Integer cattleShareCount;

        private Integer sheepShareCount;

        private Integer livestockShareTotal;

        private BigDecimal grasslandShareArea;

        private Integer laborShareCount;

        private BigDecimal cashShareAmount;

        private BigDecimal otherShareAmount;

        private BigDecimal totalIncome;

        private BigDecimal netIncome;

        private BigDecimal cashDividend;

        private BigDecimal inKindDividend;

        private BigDecimal revolvingFund;

        private BigDecimal lossAmount;

        private Integer collegeGraduateCount;

        private BigDecimal collegeGraduateWage;

        private Integer farmerTransferEmploymentCount;

        private BigDecimal farmerTransferWage;

        private Integer cattleInventoryCount;

        private Integer cattleOutboundCount;

        private Integer sheepInventoryCount;

        private Integer sheepOutboundCount;

        private Integer trademarkProductCount;

        private Integer qualityCertProductCount;

        private Integer trainingManageCount;

        private Integer trainingSkillCount;

        private Integer trainingOtherCount;

        private String businessScope;

        private String businessModel;

        private String operationStatus;

        public int getExcelRowNum()
        {
            return excelRowNum;
        }

        public void setExcelRowNum(int excelRowNum)
        {
            this.excelRowNum = excelRowNum;
        }

        public String getVillageName()
        {
            return villageName;
        }

        public void setVillageName(String villageName)
        {
            this.villageName = villageName;
        }

        public String getTownName()
        {
            return townName;
        }

        public void setTownName(String townName)
        {
            this.townName = townName;
        }

        public String getCooperativeName()
        {
            return cooperativeName;
        }

        public void setCooperativeName(String cooperativeName)
        {
            this.cooperativeName = cooperativeName;
        }

        public String getLegalRepresentative()
        {
            return legalRepresentative;
        }

        public void setLegalRepresentative(String legalRepresentative)
        {
            this.legalRepresentative = legalRepresentative;
        }

        public String getEstablishDate()
        {
            return establishDate;
        }

        public void setEstablishDate(String establishDate)
        {
            this.establishDate = establishDate;
        }

        public BigDecimal getRegisteredCapital()
        {
            return registeredCapital;
        }

        public void setRegisteredCapital(BigDecimal registeredCapital)
        {
            this.registeredCapital = registeredCapital;
        }

        public BigDecimal getYearEndTotalAssets()
        {
            return yearEndTotalAssets;
        }

        public void setYearEndTotalAssets(BigDecimal yearEndTotalAssets)
        {
            this.yearEndTotalAssets = yearEndTotalAssets;
        }

        public Integer getMemberHouseholdCount()
        {
            return memberHouseholdCount;
        }

        public void setMemberHouseholdCount(Integer memberHouseholdCount)
        {
            this.memberHouseholdCount = memberHouseholdCount;
        }

        public Integer getMemberPopulationCount()
        {
            return memberPopulationCount;
        }

        public void setMemberPopulationCount(Integer memberPopulationCount)
        {
            this.memberPopulationCount = memberPopulationCount;
        }

        public Integer getPovertyMonitorCount()
        {
            return povertyMonitorCount;
        }

        public void setPovertyMonitorCount(Integer povertyMonitorCount)
        {
            this.povertyMonitorCount = povertyMonitorCount;
        }

        public Integer getCattleShareCount()
        {
            return cattleShareCount;
        }

        public void setCattleShareCount(Integer cattleShareCount)
        {
            this.cattleShareCount = cattleShareCount;
        }

        public Integer getSheepShareCount()
        {
            return sheepShareCount;
        }

        public void setSheepShareCount(Integer sheepShareCount)
        {
            this.sheepShareCount = sheepShareCount;
        }

        public Integer getLivestockShareTotal()
        {
            return livestockShareTotal;
        }

        public void setLivestockShareTotal(Integer livestockShareTotal)
        {
            this.livestockShareTotal = livestockShareTotal;
        }

        public BigDecimal getGrasslandShareArea()
        {
            return grasslandShareArea;
        }

        public void setGrasslandShareArea(BigDecimal grasslandShareArea)
        {
            this.grasslandShareArea = grasslandShareArea;
        }

        public Integer getLaborShareCount()
        {
            return laborShareCount;
        }

        public void setLaborShareCount(Integer laborShareCount)
        {
            this.laborShareCount = laborShareCount;
        }

        public BigDecimal getCashShareAmount()
        {
            return cashShareAmount;
        }

        public void setCashShareAmount(BigDecimal cashShareAmount)
        {
            this.cashShareAmount = cashShareAmount;
        }

        public BigDecimal getOtherShareAmount()
        {
            return otherShareAmount;
        }

        public void setOtherShareAmount(BigDecimal otherShareAmount)
        {
            this.otherShareAmount = otherShareAmount;
        }

        public BigDecimal getTotalIncome()
        {
            return totalIncome;
        }

        public void setTotalIncome(BigDecimal totalIncome)
        {
            this.totalIncome = totalIncome;
        }

        public BigDecimal getNetIncome()
        {
            return netIncome;
        }

        public void setNetIncome(BigDecimal netIncome)
        {
            this.netIncome = netIncome;
        }

        public BigDecimal getCashDividend()
        {
            return cashDividend;
        }

        public void setCashDividend(BigDecimal cashDividend)
        {
            this.cashDividend = cashDividend;
        }

        public BigDecimal getInKindDividend()
        {
            return inKindDividend;
        }

        public void setInKindDividend(BigDecimal inKindDividend)
        {
            this.inKindDividend = inKindDividend;
        }

        public BigDecimal getRevolvingFund()
        {
            return revolvingFund;
        }

        public void setRevolvingFund(BigDecimal revolvingFund)
        {
            this.revolvingFund = revolvingFund;
        }

        public BigDecimal getLossAmount()
        {
            return lossAmount;
        }

        public void setLossAmount(BigDecimal lossAmount)
        {
            this.lossAmount = lossAmount;
        }

        public Integer getCollegeGraduateCount()
        {
            return collegeGraduateCount;
        }

        public void setCollegeGraduateCount(Integer collegeGraduateCount)
        {
            this.collegeGraduateCount = collegeGraduateCount;
        }

        public BigDecimal getCollegeGraduateWage()
        {
            return collegeGraduateWage;
        }

        public void setCollegeGraduateWage(BigDecimal collegeGraduateWage)
        {
            this.collegeGraduateWage = collegeGraduateWage;
        }

        public Integer getFarmerTransferEmploymentCount()
        {
            return farmerTransferEmploymentCount;
        }

        public void setFarmerTransferEmploymentCount(Integer farmerTransferEmploymentCount)
        {
            this.farmerTransferEmploymentCount = farmerTransferEmploymentCount;
        }

        public BigDecimal getFarmerTransferWage()
        {
            return farmerTransferWage;
        }

        public void setFarmerTransferWage(BigDecimal farmerTransferWage)
        {
            this.farmerTransferWage = farmerTransferWage;
        }

        public Integer getCattleInventoryCount()
        {
            return cattleInventoryCount;
        }

        public void setCattleInventoryCount(Integer cattleInventoryCount)
        {
            this.cattleInventoryCount = cattleInventoryCount;
        }

        public Integer getCattleOutboundCount()
        {
            return cattleOutboundCount;
        }

        public void setCattleOutboundCount(Integer cattleOutboundCount)
        {
            this.cattleOutboundCount = cattleOutboundCount;
        }

        public Integer getSheepInventoryCount()
        {
            return sheepInventoryCount;
        }

        public void setSheepInventoryCount(Integer sheepInventoryCount)
        {
            this.sheepInventoryCount = sheepInventoryCount;
        }

        public Integer getSheepOutboundCount()
        {
            return sheepOutboundCount;
        }

        public void setSheepOutboundCount(Integer sheepOutboundCount)
        {
            this.sheepOutboundCount = sheepOutboundCount;
        }

        public Integer getTrademarkProductCount()
        {
            return trademarkProductCount;
        }

        public void setTrademarkProductCount(Integer trademarkProductCount)
        {
            this.trademarkProductCount = trademarkProductCount;
        }

        public Integer getQualityCertProductCount()
        {
            return qualityCertProductCount;
        }

        public void setQualityCertProductCount(Integer qualityCertProductCount)
        {
            this.qualityCertProductCount = qualityCertProductCount;
        }

        public Integer getTrainingManageCount()
        {
            return trainingManageCount;
        }

        public void setTrainingManageCount(Integer trainingManageCount)
        {
            this.trainingManageCount = trainingManageCount;
        }

        public Integer getTrainingSkillCount()
        {
            return trainingSkillCount;
        }

        public void setTrainingSkillCount(Integer trainingSkillCount)
        {
            this.trainingSkillCount = trainingSkillCount;
        }

        public Integer getTrainingOtherCount()
        {
            return trainingOtherCount;
        }

        public void setTrainingOtherCount(Integer trainingOtherCount)
        {
            this.trainingOtherCount = trainingOtherCount;
        }

        public String getBusinessScope()
        {
            return businessScope;
        }

        public void setBusinessScope(String businessScope)
        {
            this.businessScope = businessScope;
        }

        public String getBusinessModel()
        {
            return businessModel;
        }

        public void setBusinessModel(String businessModel)
        {
            this.businessModel = businessModel;
        }

        public String getOperationStatus()
        {
            return operationStatus;
        }

        public void setOperationStatus(String operationStatus)
        {
            this.operationStatus = operationStatus;
        }
    }
}
