Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void pay(int clientId, String status, int amount)
- {
- if ("success".Equals(status))
- {
- Korisnik user = db.Korisniks.Find(clientId);
- if (user.tokeni == null)
- {
- user.tokeni = amount;
- }
- else
- {
- user.tokeni += amount;
- }
- using (var dbc = new Model1())
- {
- dbc.Entry(user).State = System.Data.Entity.EntityState.Modified;
- dbc.SaveChanges();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement