MCPcopy Create free account
hub / github.com/bailicangdu/node-elm / initData

Method initData

controller/ugc/rating.js:12–22  ·  view source on GitHub ↗
(restaurant_id)

Source from the content-addressed store, hash-verified

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)) {

Calls

no outgoing calls

Tested by

no test coverage detected