收藏
回答

自定义交易组件,怎么更新售后单的退款类型?

调用更新售后单接口 https://api.weixin.qq.com/shop/ecaftersale/update ,报错 {"errcode":-2,"errmsg":" 参数错误, detail: can not change after-sale type, current type(3), new type(1) rid: 632ae6d4-2264bc97-2aca10a1"}

以下是请求的参数:

{
    "out_aftersale_id": "refund_34620",
    "openid": "oCMBM5Xg6AiUtE6cXAcwuu_69Za4",
    "type": 1,
    "orderamt": 1,
    "refund_reason": "xxx",
    "status": 7,
    "refund_reason_type": 3
}


然后我试了下,用户取消售后和商家拒绝售后,再去创建售后单(接口 https://api.weixin.qq.com/shop/ecaftersale/add),会报 “售后单已存在,请勿重复发起售后” 的错误。


# 这是重新创建售后单前的售后状态,是用户取消
{
    "errcode":0,
    "errmsg":"ok",
    "after_sales_order":{
        "out_aftersale_id":"refund_34618",
        "aftersale_id":4000000003623215,
        "out_order_id":"30855",
        "order_id":3306229098294937600,
        "type":1,
        "return_info":{
            "order_return_time":0,
            "delivery_id":"",
            "waybill_id":"",
            "delivery_name":""
        },
        "orderamt":1,
        "refund_reason_type":7,
        "refund_reason":"其他",
        "status":1,
        "create_time":"1663752281953",
        "update_time":"1663753625307",
        "openid":"oCMBM5Xg6AiUtE6cXAcwuu_69Za4"
    }
}

# 这是创新创建售后单的请求参数
{
    "openid": "oCMBM5Xg6AiUtE6cXAcwuu_69Za4",
    "order_id": 0,
    "out_order_id": "30856",
    "out_aftersale_id": "refund_34618",
    "type": 2,
    "orderamt": 1,
    "refund_reason": "其他",
    "refund_reason_type": 12,
    "media_list": null,
    "product_info": {
        "product_cnt": 1,
        "out_product_id": "20986",
        "out_sku_id": "60091"
    }
}
最后一次编辑于  2022-09-22
回答关注问题邀请回答
收藏

1 个回答

登录 后发表内容