积分累积救赎 [英] Reward Points Accumulation & Redumption

查看:149
本文介绍了积分累积救赎的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的迷你项目

我正在从事奖励积分管理,在该积分管理中,我需要检查每个用户获得奖励的动作,例如花费一些钱,耳朵,几分等等...,如果消费了积分,则需要从会员卡中扣除特定用户.

我已经完成了为特定游戏提供积分的操作
请给我一些想法来跟踪这些动作

在此先感谢

This is My Mini Project

I am working on Reward points management where i need to check every users actions for which they are awarded points actions like spending some amount of money ears few points etc..., if points are consumed they need to be deducted from the card of the specific user.

I have done with Giving points to particular game
please give me some ideas to track these actions

Thanks In Advance

推荐答案

您将需要将它们存储在数据库中

对于他们针对特定工作所做的每个动作(我假设),将他们已经完成的动作以及与该动作相关的点记录到数据库中.
you will need to store these in a database

for each action they do on (I assume) a particular job, record the action they have completed and the points associated with that action into a database.


作为Simon,您需要存储所有在数据库中.
首先,您需要定义用户可以执行的所有操作,然后定义用户在每次操作中赚取/兑换的点数.

现在,每当用户执行一项操作时,首先要在数据库中输入一个条目,以根据您的要求在什么时间采取什么操作,获得/兑换多少积分以及其他信息.
还要从总点中添加/取消添加点.

现在,只要您想查看/跟踪用户操作,就可以根据需要从数据库中获取信息.

这是基本思想,您可以根据需要进行更改.

希望对您有所帮助.
As Simon, you need to store all in database.
first, of all you need to define what all action can be taken by a User and then define the no of points earn/redeem by user on every action.

Now whenever user takes a action, first of all make a entry in the database, that what action is taken,at what time, how many points earned/redeemed and other information according to your requirement.
Also add/substarct the points from the total point.

Now whenever you want to see/track the user actions, you can get from database according to your need.

This is the basic idea, you can change it according to your requirement.

Hope this help you.


如果您不想使用数据库,可以将数据存储在文本文件中.但是,如果预计用户数量很大,则不建议这样做.

存储在文件中只能是一个小解决方案(针对少量用户).
If you dont want to use a database, you can store your data in a text file. However, if the number of users are excpected to be large this is NOT a recommended idea.

Storing in a file can only be a mini-solution (for a small number of users).


这篇关于积分累积救赎的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆