12345678910111213141516171819202122 |
- import request from '../utils/request.js'
- class comments extends request {
- static async getCommentsByProduct(storeId, productId) {
- const res = await this.getRequest(`${this.BASE_URL}Discuss/index?productId=${productId}&storeId=${storeId}`, this._defaultHeader)
- return res.data;
- }
- static async getCommentsByStore(storeId) {
- const res = await this.getRequest(`${this.BASE_URL}Discuss/index?storeId=${storeId}`, this._defaultHeader)
- return res.data;
- }
- static async getPersonComments(myDiscuss=1) {
- const res = await this.getRequest(`${this.BASE_URL}Discuss/index?myDiscuss=${myDiscuss}`, this._defaultHeader)
- return res.data;
- }
- }
- export default comments;
|