SOURCE

var arrlist = []


for (let i = 1; i < 301; i++) {
    var obj = {
        "schemaCode": "{{schemaCode}}",
        "variantCode": "{{productCode}}1",
        "properties": {
            "barcode": "bar_{{productCode}}1",
            "saleLocation": "",
            "platformCode": "pf_{{productCode}}1",
            "skuCode": "",
            "basecolor": "red",
            "skuTagPrice": 101,
            "customSize": i + "XL",
            "customColor": {
                "customColorID": "RED",
                "customColorName": "古树红"
            },
            "dimensions": {
                "length": 11,
                "width": 21,
                "height": 31
            }
        }
    }
    obj.variantCode = "{{productCode}}" + i
    obj.properties.barcode = "bar_{{productCode}}" + i
    obj.properties.platformCode = "pf_{{productCode}}" + i
    obj.properties.skuTagPrice = 100 + i
    arrlist.push(obj)
}

console.log(arrlist)
console 命令行工具 X clear

                    
>
console