订单rpc
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
505 B

2 years ago
3 years ago
  1. package orderrpc
  2. import (
  3. "testing"
  4. )
  5. func Test_CreateByCart(t *testing.T) {
  6. products := []map[string]string{
  7. map[string]string{
  8. "product_id": "18",
  9. "sku_id": "6",
  10. "quantity": "3",
  11. },
  12. map[string]string{
  13. "product_id": "6",
  14. "sku_id": "7",
  15. "quantity": "2",
  16. },
  17. }
  18. data := map[string]interface{}{
  19. "product": products,
  20. "name": "5BC02AB31C",
  21. "mobile": "326598744",
  22. }
  23. ret, err := CreateByCart("test1_tetele_com", "100064", data)
  24. t.Log(ret)
  25. t.Log(err)
  26. }