1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- const { request } = require('../../../api/request')
- /**
- * 关注商户
- * @param id 商户ID
- * @returns {Promise<*>}
- */
- export const postFollowUser = (id, type) => request({
- url: '/api/user/follow/user',
- method: 'POST',
- data: {
- shop_id: id,
- type: type // 类型(1关注2取消关注)
- },
- showLoading: true
- })
- /**
- * 评论动态
- * @param postData
- * @returns {Promise<*>}
- */
- export const postAddComment = (postData) => request({
- url: '/api/user/track/add/comment',
- method: 'POST',
- data: {
- ...postData
- // 'track_comment': '', // 评论内容
- // 'track_id': '' // 动态ID
- },
- showLoading: true
- })
- /**
- * 动态点赞、取消点赞
- * @param postData
- * @returns {Promise<*>}
- */
- export const postGood = (postData) => request({
- url: '/api/user/track/good',
- method: 'POST',
- data: {
- ...postData
- // 'track_id': 1, // 动态ID
- // 'type': 1 // 类型(1点赞2取消点赞)
- },
- showLoading: true
- })
- /**
- * 删除动态
- * @param track_id
- * @returns {Promise<*>}
- */
- export const postDelComment = (track_id) => request({
- url: '/api/user/track/delete',
- method: 'POST',
- data: {
- 'track_id': track_id // 动态ID
- },
- showLoading: true
- })
|