donglu1913 2013-03-07 22:39
浏览 20
已采纳

我应该如何为我的Android应用程序构建/设计评级系统?

I am building a mobile Android application where users are able to find the nearest locations around them and then when viewing these places, they are allowed to see the details and also rate it. On top of this, they are allowed to add new places onto the map. I want to be able to lower the chance of people adding fake spots the best I can and so this is why I want to implement a ratings system, which is another layer security for fake spots.

I am not sure how I should design my database tables. Right now I only have:

Location: name, address, type, terrain, difficulty, lng, lat, rating.

The ratings column is only allowed values: 1, 2, 3, 4, 5.

What else would I need to keep the sum of the ratings?

After designing the tables. I want to know the most appropriate way to calculate the average ratings and then be able to delete them based on their ratings. The problem is, if a spot has 1 vote with a rating of 1 which is 100% negative then it will be considered bad when a a spot has a vote of 100 with 90 votes with 1 and 10 votes with 5. Surely, the first one should be considered worse and then deleted. How do I counter this?

  • 写回答

2条回答 默认 最新

  • douyu1656 2013-03-08 00:40
    关注

    I would say making a separate table containing foreign keys of the id of the location and id of the user submitting the review would be useful(as well as there rating of course). This way users could edit their review at a later time.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 matlab不知道怎么改,求解答!!
  • ¥15 永磁直线电机的电流环pi调不出来
  • ¥15 用stata实现聚类的代码
  • ¥15 请问paddlehub能支持移动端开发吗?在Android studio上该如何部署?
  • ¥20 docker里部署springboot项目,访问不到扬声器
  • ¥15 netty整合springboot之后自动重连失效
  • ¥15 悬赏!微信开发者工具报错,求帮改
  • ¥20 wireshark抓不到vlan
  • ¥20 关于#stm32#的问题:需要指导自动酸碱滴定仪的原理图程序代码及仿真
  • ¥20 设计一款异域新娘的视频相亲软件需要哪些技术支持