{
  "title": "导入订单数据",
  "process": "scripts.rules.ImportData",
  "columns": [
    {
      "label": "订单号",
      "name": "order_sn",
      "match": ["订单号", "订单", "order_sn", "id"],
      "rules": ["scripts.rules.order_sn"],
      "primary": true
    },
    {
      "label": "用户",
      "name": "user.name",
      "match": ["用户名称", "姓名", "user_id"],
      "rules": ["scripts.rules.FmtUser"],
      "nullable": true
    },
    {
      "label": "性别",
      "name": "user.sex",
      "match": ["性别", "gender", "sex"],
      "rules": [],
      "nullable": true
    },
    {
      "label": "年龄",
      "name": "user.age",
      "match": ["年龄", "age"],
      "rules": [],
      "nullable": true
    },
    {
      "label": "手机号",
      "name": "mobile",
      "match": ["手机号", "手机", "mobile"],
      "rules": ["scripts.rules.mobile"]
    },
    {
      "label": "商品",
      "name": "skus[*].name",
      "match": ["商品", "商品名称", "goods", "skus", "sku_id", "goods_id"],
      "rules": ["scripts.rules.FmtGoods"]
    },
    {
      "label": "数量",
      "name": "skus[*].amount",
      "match": ["数量", "amount"],
      "rules": ["scripts.rules.FmtGoods"]
    },
    {
      "label": "单价",
      "name": "skus[*].price",
      "match": ["单价", "price", "价格"],
      "rules": ["scripts.rules.FmtGoods"]
    },
    {
      "label": "总价",
      "name": "total",
      "match": ["总价", "total", "total_price"],
      "rules": ["scripts.rules.FmtGoods"]
    },
    {
      "label": "备注",
      "name": "remark",
      "match": []
    }
  ],
  "option": {
    "autoMatching": true,
    "chunkSize": 3,
    "logging": "error",
    "mappingPreview": "auto",
    "dataPreview": "auto",
    "templateLink": "/somelinke/download/xxx"
  },
  "rules": {
    "scripts.rules.order_sn": "订单号验证",
    "scripts.rules.mobile": "手机号验证",
    "scripts.rules.FmtUser": "用户数据匹配验证",
    "scripts.rules.FmtGoods": "商品数据匹配验证"
  }
}
