bid_update_api.yml 1.6 KB
name: 保存竞标任务
base_url: ${ENV(base_worth_url)}
verify: False
variables:
    name: 测试竞标任务名称${get_nowtime()}
    acceptanceCriteria: 测试竞标任务的验收标准${get_nowtime()}
    description: 测试竞标任务的任务描述${get_nowtime()}
    bidStartTime: ${get_today1()}
    bidEndTime: ${get_tomorrow()}
    id: ${get_resource_id()}
    serial: ${get_serialNo()}
    msg: ok
teardown_hooks:
    - ${teardown_hook_get_bid_task_id($response)}
request:
    headers:
        Content-Type: application/json; charset=UTF-8
        Authorization: Bearer ${get_task_Authorization()}
        Origin: https://value-test.fjmaimaimai.com
        Referer: https://value-test.fjmaimaimai.com/
        User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.88 Safari/537.36
        X-Requested-With: XMLHttpRequest
    json:
        bidStartTime: $bidStartTime
        bidEndTime:  $bidEndTime
        name: $name
        resourceType: 1
        resourceList:
            - id: ${convert_to_number($id)}
              title: ${get_resource_title()}
              content: ${get_resource_content()}
              serial: ${convert_to_number($serial)}
        customerValue:
            -  31
        taskCharactor: 12
        reward: 2000
        acceptanceCriteria: $acceptanceCriteria
        description: $description
        isImportant: true
        taskBelong: 13
        isRemind: true
        pictures:
    method: POST
    url: task/bid/update
validate:
    -   eq:
        - content.code
        - 0
    -   eq:
        - content.msg
        - $msg