package com.ffii.fpsms.m18.model

/**
 * Result of scheduling job [com.ffii.fpsms.modules.master.service.BomM18ShopBulkPushService.pushAllBomsToM18ShopIfAllowed].
 */
data class M18BomShopBatchSyncSummary(
    /** BOM rows with deleted=false scanned. */
    val totalProcessed: Int,
    val synced: Int,
    /** Pushed attempted but [M18BomShopSyncTriggerResult.synced] is false (includes build/API failures). */
    val notSynced: Int,
    /** [SettingNames.M18_BOM_SHOP_SYNC_ENABLED] is off — no BOMs attempted. */
    val skippedBecauseFeatureDisabled: Boolean = false,
) {
    /** One-line summary for logs / scheduler_sync_log.query */
    fun toLogQuery(): String =
        "BOMShop batch: processed=$totalProcessed synced=$synced notSynced=$notSynced skippedFeatureDisabled=$skippedBecauseFeatureDisabled"
}
