{
    "task": [
        {
            "name": "AutoResell",
            "label": "$task.AutoResell.label",
            "entry": "ResellMain",
            "description": "$task.AutoResell.description",
            "controller": [
                "Win32-Window",
                "Win32-Window-Background",
                "Win32-Front"
            ],
            "option": [
                "AutoBuyAndSell",
                "AutoChangeRegion"
            ],
            "group": ["daily"]
        }
    ],
    "option": {
        "AutoBuyAndSell": {
            "type": "switch",
            "label": "$option.AutoBuyAndSell.label",
            "description": "$option.AutoBuyAndSell.description",
            "default_case": "Yes",
            "cases": [
                {
                    "name": "Yes",
                    "option": [
                        "ImportMinimumProfit"
                    ]
                },
                {
                    "name": "No",
                    "pipeline_override": {
                        "ResellStart": {
                            "action": {
                                "param": {
                                    "custom_action_param": {
                                        "MinimumProfit": 999999
                                    }
                                }
                            }
                        }
                    }
                }
            ]
        },
        "ImportMinimumProfit": {
            "type": "input",
            "label": "$option.ImportMinimumProfit.label",
            "inputs": [
                {
                    "name": "ImportMinimumProfit",
                    "label": "$option.ImportMinimumProfit.inputs.ImportMinimumProfit.label",
                    "description": "$option.ImportMinimumProfit.inputs.ImportMinimumProfit.description",
                    "pipeline_type": "int",
                    "verify": "^\\d+$",
                    "default": "3000"
                }
            ],
            "pipeline_override": {
                "ResellStart": {
                    "action": {
                        "param": {
                            "custom_action_param": {
                                "MinimumProfit": "{ImportMinimumProfit}"
                            }
                        }
                    }
                }
            }
        },
        "AutoChangeRegion": {
            "type": "switch",
            "label": "$option.AutoChangeRegion.label",
            "default_case": "Yes",
            "cases": [
                {
                    "name": "Yes",
                    "pipeline_override": {
                        "ResellFristAreaInWuLing": {
                            "enabled": true
                        },
                        "ChangeNextRegion": {
                            "enabled": true
                        }
                    }
                },
                {
                    "name": "No",
                    "pipeline_override": {
                        "ResellFristAreaInWuLing": {
                            "enabled": false
                        },
                        "ChangeNextRegion": {
                            "enabled": false
                        }
                    }
                }
            ]
        }
    }
}
