review

package
v1.4.5-alpha1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2019 License: MPL-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package review is a set of API functions to provide an ability to make reviews for a particular product

Index

Constants

View Source
const (
	ConstReviewCollectionName = "review"
	ConstRatingCollectionName = "rating"

	ConstErrorModule = "product/review"
	ConstErrorLevel  = env.ConstErrorLevelActor
)

Package global constants

Variables

This section is empty.

Functions

func APICreateProductReview

func APICreateProductReview(context api.InterfaceApplicationContext) (interface{}, error)

APICreateProductReview creates a new review for a specified product

  • product id should be specified in "productID" argument
  • if "stars" argument specified and is not blank rating mark will be also created

func APIDeleteProductReview

func APIDeleteProductReview(context api.InterfaceApplicationContext) (interface{}, error)

APIDeleteProductReview deletes existing review

  • review ID should be specified in "reviewID" argument

func APIGetProductRating

func APIGetProductRating(context api.InterfaceApplicationContext) (interface{}, error)

APIGetProductRating returns rating info for a specified product

  • product id should be specified in "productID" argument

func APIGetReview

func APIGetReview(context api.InterfaceApplicationContext) (interface{}, error)

APIGetReview returns an existing review for owner or admin

  • review ID should be specified in "reviewID" argument

func APIListReviews

func APIListReviews(context api.InterfaceApplicationContext) (interface{}, error)

APIListReviews returns a list of reviews for specified products

  • product id could be specified in "productID" parameter

func APIUpdateReview

func APIUpdateReview(context api.InterfaceApplicationContext) (interface{}, error)

APIUpdateReview updates an existing review

  • review ID should be specified in "reviewID" argument

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL