Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User story 14: As PawerPay Kiosk, I would like to check my balance #1

Open
2 of 3 tasks
stephane-segning opened this issue Mar 1, 2024 · 0 comments
Open
2 of 3 tasks

Comments

@stephane-segning
Copy link
Contributor

stephane-segning commented Mar 1, 2024

Description

Sequence Diagram

sequenceDiagram

participant kiosk as kiosk
participant ppa as power pay app
participant pps as power pay service
kiosk->>ppa : Check Balance ()
ppa->>pps : send request ()
pps-->>ppa : Requests for PIN(sends procedure ID)
ppa-->>kiosk : Display enter PIN
kiosk->>ppa : Send PIN (PIN)
ppa->>pps : send (PIN, procedure ID)
pps->>pps : validate PIN and check balance
pps-->>ppa : return balance info
ppa-->>kiosk : Display balance
Loading

Wireframe

Tickets and Explanations

  • Implement the check balance interface: The kiosk user should be able send the request in order to check his balance. This function will return the kiosk user's phone number in the backend.
  • Implement the validateDisplayBalanceWithPin(id,PIN) function (REST API): Confirm a user's pin for a procedure. It will call the function that will check the balance if the pin is correct.
  • Implement the checkBalance(PhoneN) function (REST API): check the balance of the Account having the phone number provided and display the balance.

Methodology:
To implement these, we'll need to include a procedure object with a status.

---
title: Class Diagramm
---
classDiagram
    Procedure -- Status
    Procedure -- Type
    Procedure <|-- Transaction
    Procedure <|-- CheckBalance
    Procedure <|-- UserRegistration
    
    class Status {
        <<enumeration>>
        DONE
        WAITING
        ERROR
    }
    class Type {
        <<enumeration>>
        Transaction
        CheckBalance
    }
    class Procedure {
        <<Abstract>>
        +String id
        -Status status = WAITING
        +String phoneNumber
        +void markAsDone()
        +void markAsError()
        +bool isDone()
        +bool isError()
        +bool isWaiting()
        +Type getType()
    }
    class Transaction {
        +String receiverPhoneNumber
        +Double amount
        +String currency = "XAF"
    }
    class CheckBalance {
    }
    class UserRegistration {
        +String opt
        +String userName
    }
    class User {
        +String pin (hashed)
        +String phoneNumber
        +String userName
    }
Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Ready
Development

No branches or pull requests

1 participant