weightBizBill_doRefund.py 1.2 KB
#!/usr/bin/python
# -*- coding: UTF-8 -*-
import urllib3
from commons import common as com
from commons.MySession import my,sy1
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)


class weightBizBill_doRefund():
    "称重服务单列表-退款"
    url = "http://test.jmsf.diligrp.com:8385/weightBizBill/doRefund.action"
    header = {
          "Connection": "keep-alive",
          "Accept": "application/json, text/javascript, */*; q=0.01",
          "X-Requested-With": "XMLHttpRequest",
          "User-Agent": "Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.105 Safari/537.36",
          "Content-Type": "application/x-www-form-urlencoded; charset=UTF-8",
          "Accept-Language": "zh-CN,zh;q=0.9",
          "Accept-Encoding": "gzip, deflate"}
    body = "id=206&reason=退款原因_test_123"

    def __init__(self):
        self.url = weightBizBill_doRefund.url.replace("http://test.", com.get_global_config("global_data", "environment", "en"))
        self.header = weightBizBill_doRefund.header
        self.body = weightBizBill_doRefund.body



# tt=weightBizBill_doRefund()
# re=sy1.post(url=tt.url,headers=tt.header,json=tt.body)
# print(re.json())