yujian
2020-05-09 7e7db2fa55a9a3af46d4fd8ede0dee147f101d64
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
package com.yeshi.fanli.service.inter.dynamic;
 
import java.util.Date;
import java.util.List;
 
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
 
import com.yeshi.fanli.dto.pdd.PDDGoodsDetail;
import com.yeshi.fanli.entity.bus.activity.ActivityUser;
import com.yeshi.fanli.entity.dynamic.CommentInfo;
import com.yeshi.fanli.entity.dynamic.GoodsEvaluate;
import com.yeshi.fanli.entity.dynamic.ImgInfo;
import com.yeshi.fanli.entity.jd.JDGoods;
import com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief;
import com.yeshi.fanli.exception.dynamic.GoodsEvaluateException;
 
public interface GoodsEvaluateService {
 
    public String saveHead(MultipartFile file, GoodsEvaluate record) throws GoodsEvaluateException;
    
    
    public GoodsEvaluate getById(String id);
 
    public void deleteBatchByPrimaryKey(List<String> list);
    
    
    /**
     * 查询有效并缓存
     * @param start
     * @param count
     * @return
     */
    public List<GoodsEvaluate> queryValidEvaluateCache(int start, int count);
 
    public long countValid();
 
    /**
     * 查询
     * @param start
     * @param count
     * @param key
     * @param state
     * @return
     */
    public List<GoodsEvaluate> query(int start, int count, String key, Integer state, int dynamicType, String typeEnum);
 
    public long count(String key, Integer state,int dynamicType, String typeEnum);
 
    
    /**
     * 添加分享次数
     * @param id
     */
    public void addShareNum(String id);
 
 
    /**
     * 保存评论
     * @param pid
     * @param commentInfo
     * @throws GoodsEvaluateException
     */
    public void saveComment(String pid, CommentInfo commentInfo) throws GoodsEvaluateException;
 
 
    public void deleteComment(String pid, List<String> list) throws GoodsEvaluateException;
 
 
    /**
     * 保存商品信息单个
     * @param pid
     * @param goodsId
     * @param goodsType
     * @param videoUrl
     * @param picNum
     * @param picUrls
     * @param fileRequest
     * @throws GoodsEvaluateException
     * @throws Exception
     */
    public String saveSingleGoods(String pid, Long goodsId, Integer goodsType, String videoUrl, Integer picNum, String picUrls,
            MultipartHttpServletRequest fileRequest) throws GoodsEvaluateException, Exception;
 
    /**
     * 单个商品券信息 
     * @param pid
     * @param commentInfo
     * @throws GoodsEvaluateException
     * @throws Exception
     */
    public void saveCurrencyCoupon(String pid, int kind, CommentInfo commentInfo) throws GoodsEvaluateException, Exception;
 
 
    public void saveActivityPic(String pid, ImgInfo imgInfo, String picUrls, MultipartHttpServletRequest fileRequest)
            throws GoodsEvaluateException, Exception;
 
 
    /**
     * 多个商品保存信息
     * @param pid
     * @param videoUrl
     * @param goodsList
     * @param fileRequest
     * @throws GoodsEvaluateException
     * @throws Exception
     */
    public void saveMultipleGoods(String pid, String videoUrl, String goodsList, MultipartHttpServletRequest fileRequest)
            throws GoodsEvaluateException, Exception;
 
 
    /**
     * 素材
     * @param pid
     * @param videoUrl
     * @param picUrls
     * @param fileRequest
     * @throws GoodsEvaluateException
     * @throws Exception
     */
    public void saveSuCai(String pid, String videoUrl, String picUrls, MultipartHttpServletRequest fileRequest)
            throws GoodsEvaluateException, Exception;
 
 
    /**
     * 查询素材
     * @param start
     * @param count
     * @return
     */
    public List<GoodsEvaluate> queryMaterialsCache(int start, int count,int type) throws Exception;
 
    public long countValidMaterials(int type);
 
 
 
    public void release(String id) throws GoodsEvaluateException;
 
 
    public void saveGoodsComment(String id, int kind, List<CommentInfo> comments) throws GoodsEvaluateException, Exception;
 
 
    /**
     * 自动生成数据
     */
    public void addGoodsEvaluateByDaTaoKe();
 
 
    public void updateTaoBaoGoods(TaoBaoGoodsBrief goods);
 
 
    public void updateJDGoods(JDGoods jdGoods);
 
 
    public void updatePDDGoods(PDDGoodsDetail pddGoods);
 
 
    public void addRanDomShareCount();
 
    /**
     *  添加发圈内容
     * @param goodsId 商品id  必传
     * @param cid 大淘客分类id  必传
     * @param title 标题    必传
     * @param comment
     */
    public void addGoodsEvaluate(Long goodsId,List<ImgInfo> imgList, ActivityUser user, String title,String comment,Date startTime) throws GoodsEvaluateException;
 
    
    /**
     * 下架商品
     * @param goodsId
     */
    public void offlineTaoBaoGoods(Long goodsId);
 
    /**
     * 状态切换
     * @param id
     * @throws GoodsEvaluateException
     */
    public void switchState(String id) throws GoodsEvaluateException;
 
}