StockinRefundPush.cs 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using WdtSdk;
  7. namespace StockinRefundPush
  8. {
  9. class StockinRefundPush
  10. {
  11. static void Main(string[] args)
  12. {
  13. WdtClient client = new WdtClient();
  14. client.sid = "";
  15. client.appkey = "";
  16. client.appsecret = "";
  17. client.gatewayUrl = "http://121.41.177.115/openapi2/stockin_refund_push.php";
  18. var stockin_refund_info = new
  19. {
  20. refund_no = "TK1901090001",
  21. outer_no = "234567898765432",
  22. warehouse_no = "api_test",
  23. logistics_code = "SMWL001",
  24. logistics_no = "6787654321234",
  25. detail_list = new[]
  26. {
  27. new{
  28. spec_no = "6521478635",
  29. stockin_num = "1",
  30. stockin_price = "11.11",
  31. }
  32. }
  33. };
  34. string json = stockin_refund_info.ToJsonString();
  35. client.putParams("stockin_refund_info", json);
  36. string result = client.wdtOpenapi();
  37. Console.WriteLine(result);
  38. Console.ReadKey();
  39. }
  40. }
  41. }