# ApiOfElsaPanel.PlanPanelApi

All URIs are relative to *https://localhost*

Method | HTTP request | Description
------------- | ------------- | -------------
[**createPlan**](PlanPanelApi.md#createPlan) | **POST** /panel/v1/plan | 创建服务计划
[**listPlan**](PlanPanelApi.md#listPlan) | **GET** /panel/v1/plan | 服务计划列表
[**offPlan**](PlanPanelApi.md#offPlan) | **POST** /panel/v1/plan/{id}/off | 下架指定服务计划
[**onPlan**](PlanPanelApi.md#onPlan) | **POST** /panel/v1/plan/{id}/on | 下架指定服务计划
[**show**](PlanPanelApi.md#show) | **GET** /panel/v1/plan/{id} | 获取指定服务计划信息


<a name="createPlan"></a>
# **createPlan**
> RPlanVO createPlan(dto)

创建服务计划

### Example
```javascript
import ApiOfElsaPanel from 'api_of_elsa_panel';
let defaultClient = ApiOfElsaPanel.ApiClient.instance;

// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new ApiOfElsaPanel.PlanPanelApi();

let dto = new ApiOfElsaPanel.CreatePlanDTO(); // CreatePlanDTO | dto

apiInstance.createPlan(dto).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **dto** | [**CreatePlanDTO**](CreatePlanDTO.md)| dto | 

### Return type

[**RPlanVO**](RPlanVO.md)

### Authorization

[apiKey](../README.md#apiKey)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: */*

<a name="listPlan"></a>
# **listPlan**
> RPagePlanVO listPlan(opts)

服务计划列表

### Example
```javascript
import ApiOfElsaPanel from 'api_of_elsa_panel';
let defaultClient = ApiOfElsaPanel.ApiClient.instance;

// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new ApiOfElsaPanel.PlanPanelApi();

let opts = { 
  'page': 56, // Number | 
  'size': 56, // Number | 
  'sort': "sort_example" // String | 
};
apiInstance.listPlan(opts).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **page** | **Number**|  | [optional] 
 **size** | **Number**|  | [optional] 
 **sort** | **String**|  | [optional] 

### Return type

[**RPagePlanVO**](RPagePlanVO.md)

### Authorization

[apiKey](../README.md#apiKey)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: */*

<a name="offPlan"></a>
# **offPlan**
> RPlanVO offPlan(id)

下架指定服务计划

### Example
```javascript
import ApiOfElsaPanel from 'api_of_elsa_panel';
let defaultClient = ApiOfElsaPanel.ApiClient.instance;

// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new ApiOfElsaPanel.PlanPanelApi();

let id = 789; // Number | id

apiInstance.offPlan(id).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **id** | **Number**| id | 

### Return type

[**RPlanVO**](RPlanVO.md)

### Authorization

[apiKey](../README.md#apiKey)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: */*

<a name="onPlan"></a>
# **onPlan**
> RPlanVO onPlan(id)

下架指定服务计划

### Example
```javascript
import ApiOfElsaPanel from 'api_of_elsa_panel';
let defaultClient = ApiOfElsaPanel.ApiClient.instance;

// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new ApiOfElsaPanel.PlanPanelApi();

let id = 789; // Number | id

apiInstance.onPlan(id).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **id** | **Number**| id | 

### Return type

[**RPlanVO**](RPlanVO.md)

### Authorization

[apiKey](../README.md#apiKey)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: */*

<a name="show"></a>
# **show**
> RPlanVO show(id)

获取指定服务计划信息

### Example
```javascript
import ApiOfElsaPanel from 'api_of_elsa_panel';
let defaultClient = ApiOfElsaPanel.ApiClient.instance;

// Configure API key authorization: apiKey
let apiKey = defaultClient.authentications['apiKey'];
apiKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.apiKeyPrefix = 'Token';

let apiInstance = new ApiOfElsaPanel.PlanPanelApi();

let id = 789; // Number | id

apiInstance.show(id).then((data) => {
  console.log('API called successfully. Returned data: ' + data);
}, (error) => {
  console.error(error);
});

```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **id** | **Number**| id | 

### Return type

[**RPlanVO**](RPlanVO.md)

### Authorization

[apiKey](../README.md#apiKey)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: */*

