package request

import (
	"topsdk/util"
)

type TmallExchangeRefusereasonGetRequest struct {
	/*
	   换货单号ID     */
	DisputeId *int64 `json:"dispute_id" required:"true" `
	/*
	   换货申请类型：0-任意类型；1-售中；2-售后     */
	DisputeType *int64 `json:"dispute_type,omitempty" required:"false" `
	/*
	   返回字段     */
	Fields *[]string `json:"fields" required:"true" `
}

func (s *TmallExchangeRefusereasonGetRequest) SetDisputeId(v int64) *TmallExchangeRefusereasonGetRequest {
	s.DisputeId = &v
	return s
}
func (s *TmallExchangeRefusereasonGetRequest) SetDisputeType(v int64) *TmallExchangeRefusereasonGetRequest {
	s.DisputeType = &v
	return s
}
func (s *TmallExchangeRefusereasonGetRequest) SetFields(v []string) *TmallExchangeRefusereasonGetRequest {
	s.Fields = &v
	return s
}

func (req *TmallExchangeRefusereasonGetRequest) ToMap() map[string]interface{} {
	paramMap := make(map[string]interface{})
	if req.DisputeId != nil {
		paramMap["dispute_id"] = *req.DisputeId
	}
	if req.DisputeType != nil {
		paramMap["dispute_type"] = *req.DisputeType
	}
	if req.Fields != nil {
		paramMap["fields"] = util.ConvertBasicList(*req.Fields)
	}
	return paramMap
}

func (req *TmallExchangeRefusereasonGetRequest) ToFileMap() map[string]interface{} {
	fileMap := make(map[string]interface{})
	return fileMap
}
