Module: JPSClient::API::SurveyCategory
- Defined in:
- lib/jpsclient/api/archived_outdated/survey_category.rb
Overview
SurveyCategory 相关 API 自动生成的模块,处理 survey_category 相关接口
Instance Method Summary collapse
-
#create_survey_categories(params: {}) ⇒ Hash
Create Survey Categories.
-
#create_survey_category(params: {}) ⇒ Hash
Create Survey Category.
-
#create_weights(params: {}) ⇒ Hash
Create Weights.
-
#update_survey_category(categoryId:, params: {}) ⇒ Hash
Update Survey Category.
Instance Method Details
#create_survey_categories(params: {}) ⇒ Hash
Create Survey Categories
51 52 53 54 55 56 57 58 |
# File 'lib/jpsclient/api/archived_outdated/survey_category.rb', line 51 def create_survey_categories(params: {}) config = @request_config && @request_config["survey_category_survey_categories"] raise JPSClient::ExceptionError, "Missing config for survey_category_survey_categories" unless config && config["url"] path = config["url"] return request_with_auth(:post, path, body: params) end |
#create_survey_category(params: {}) ⇒ Hash
Create Survey Category
25 26 27 28 29 30 31 32 |
# File 'lib/jpsclient/api/archived_outdated/survey_category.rb', line 25 def create_survey_category(params: {}) config = @request_config && @request_config["survey_category_survey_category"] raise JPSClient::ExceptionError, "Missing config for survey_category_survey_category" unless config && config["url"] path = config["url"] return request_with_auth(:post, path, body: params) end |
#create_weights(params: {}) ⇒ Hash
Create Weights
38 39 40 41 42 43 44 45 |
# File 'lib/jpsclient/api/archived_outdated/survey_category.rb', line 38 def create_weights(params: {}) config = @request_config && @request_config["survey_category_weights"] raise JPSClient::ExceptionError, "Missing config for survey_category_weights" unless config && config["url"] path = config["url"] return request_with_auth(:post, path, body: params) end |
#update_survey_category(categoryId:, params: {}) ⇒ Hash
Update Survey Category
11 12 13 14 15 16 17 18 19 |
# File 'lib/jpsclient/api/archived_outdated/survey_category.rb', line 11 def update_survey_category(categoryId:, params: {}) config = @request_config && @request_config["survey_category_survey_category"] raise JPSClient::ExceptionError, "Missing config for survey_category_survey_category" unless config && config["url"] path = config["url"] path = path.gsub("{categoryId}", categoryId.to_s) return request_with_auth(:put, path, body: params) end |