2019-10-21 11:40:24 +00:00
|
|
|
import Api from "./Api";
|
|
|
|
|
import { ApiResponse } from "./ApiResponses";
|
|
|
|
|
import { PropertyConfig } from "../reducers/entityReducers/propertyPaneConfigReducer";
|
2019-10-29 12:02:58 +00:00
|
|
|
import { AxiosPromise } from "axios";
|
2019-10-21 11:40:24 +00:00
|
|
|
|
|
|
|
|
export interface PropertyPaneConfigsResponse extends ApiResponse {
|
|
|
|
|
data: {
|
|
|
|
|
config: PropertyConfig;
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export interface PropertyPaneConfigsRequest {
|
|
|
|
|
propertyPaneConfigsId: string;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class PropertyPaneConfigsApi extends Api {
|
|
|
|
|
static url = "v1/properties";
|
|
|
|
|
static fetch(
|
|
|
|
|
request: PropertyPaneConfigsRequest,
|
2019-10-29 12:02:58 +00:00
|
|
|
): AxiosPromise<PropertyPaneConfigsResponse> {
|
2019-10-21 11:40:24 +00:00
|
|
|
return Api.get(
|
|
|
|
|
PropertyPaneConfigsApi.url + "/" + request.propertyPaneConfigsId,
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default PropertyPaneConfigsApi;
|