package com.ruoyi.api.constant.yz;

import org.springframework.http.HttpMethod;

public enum ApiEnum {
    // 获取TOKEN
    GET_TOKEN(HttpMethod.POST, "/app/application/getToken"),
    // 推送商品至中台
    PUSH_PRODUCT(HttpMethod.POST, "/app/product/cloud/pushProduct"),
    // 更新商品至中台
    UPDATE_CLOUD_PRODUCT(HttpMethod.POST, "/app/product/cloud/updateCloudProduct"),
    // 更新sku到中台
    UPDATE_CLOUD_SKU(HttpMethod.POST, "/app/product/cloud/updateCloudSku"),
    // 批量上下架商品
    DISPLAY_PRODUCT_BY_IDS(HttpMethod.POST, "/app/product/cloud/displayProductByIds"),
    // 通过id获取中台的商品详情
    FIND_PRODUCT(HttpMethod.POST, "/app/product/cloud/findProduct"),
    // 删除中台系统商品
    DELETE_PRODUCT(HttpMethod.DELETE, "/app/product/cloud/deleteProduct"),
    ;

    private HttpMethod method;
    private String url;

    ApiEnum(HttpMethod method, String url) {
        this.method = method;
        this.url = url;
    }

    public HttpMethod getMethod() {
        return method;
    }

    public void setMethod(HttpMethod method) {
        this.method = method;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }
}
