(restaurant_id)
| 10 | this.getTags = this.getTags.bind(this); |
| 11 | } |
| 12 | async initData(restaurant_id){ |
| 13 | try{ |
| 14 | const status = await RatingModel.initData(restaurant_id); |
| 15 | if (status) { |
| 16 | console.log('初始化评论数据成功'); |
| 17 | } |
| 18 | }catch(err){ |
| 19 | console.log('初始化评论数据失败'); |
| 20 | throw new Error(err); |
| 21 | } |
| 22 | } |
| 23 | async getRatings(req, res, next){ |
| 24 | const restaurant_id = req.params.restaurant_id; |
| 25 | if (!restaurant_id || !Number(restaurant_id)) { |
no outgoing calls
no test coverage detected