hypersign-protocol / hyperfyre-frontend

A platform to automate the IDO whitelisting process using Hypersign SSI infrastructure.
https://fyre.hypersign.id
Apache License 2.0
3 stars 2 forks source link

Participants - Lottery and Export #1104

Open Pratap2018 opened 2 years ago

Pratap2018 commented 2 years ago

As an admin, I should be able to perform a lottery based on the event data .

  1. The lottery should be a button
  2. after clicking the button one pop should come
  3. The Pop will contain A title as a lottery
  4. The Pop will contain a description box with the following description Lottery is the process of selecting winners of an event. Upon clicking on "Execute button", the lottery process begins, which may take sometime and screen may freeze. Once done, you will get selected records in excel sheet. The winner selection is primarily based on their "score" unless checked "randomly".
  5. The Pop up will contain Total Records i.e the number of the participants on the selected event
  6. The pop up will contain a text box Number of the winners to choose default placeholder 0 this should be input type Number.
  7. The popup will contain a checkbox to choose randomly (optional) with default value unchecked

For Reference :

Screenshot from 2022-04-17 15-16-53

Note: The Pop-up design needs to be adopted based on the solawind theme.

Screenshot_2022-04-17_at_1 55 50_PM

Api end point for the lottery data: https://api.fyre.hypersign.id/api/v1/project/${eventId}/lottery?token=${authToken}&limitRecord=2&isRandom=false

Ref : The following two code snippets is reference for the export the participant data and lottery data

Handle Lottery https://github.com/hypersign-protocol/hyperfyre-frontend/blob/d7ce32c66f190e1a439d2df25a75476850748021/src/views/admin/Participants.vue#L467 Handle Export https://github.com/hypersign-protocol/hyperfyre-frontend/blob/d7ce32c66f190e1a439d2df25a75476850748021/src/views/admin/Participants.vue#L441 Response : (Raw Text)

EVENTID,DID,EMAIL,NAME,SCORE,HYPERSIGN AUTHENTICATION,JOIN HF TEST,PLEASE JOIN,JOIN RELEASE GROUP,JOIN FG TEST HYPER,JOIN HYPERSIGN ,CONNECT  YOUR POLYGON HID WALLET,FOLLOW TWEETER,FOLLOW TWEETER,HYPERSIGNCHAIN
61965cc5f46fdca2b7eb4b71,did:hs:22e9054f-69eb-400f-bb70-e128bd4f35e3,vishwasbhushan001@gmail.com,Vishwas Bhushan,100,Authorized,2131196338,2131196338,2131196338,2131196338
61965cc5f46fdca2b7eb4b71,did:hs:0c4e9895-dd6d-4de0-9dd4-a1119d09f9c9,pratapmridha@gmail.com,Pratap Mridha,100,Authorized,nowuceme,nowuceme,,nowuceme,nowuceme,0x54ceff083c2c71b8e23b7a98bac91cf65883e880,MridhaPratap,MridhaPratap,MridhaPratap 
lovelybhushan13 commented 2 years ago

@harshitha-kondadasu Click directly on the Execute button without selecting number of winners, the validation message displays but the loader keeps spinning. image

harshitha-kondadasu commented 2 years ago

@lovelybhushan13 Sure I'll fix this loader issue and push the code

harshitha-kondadasu commented 2 years ago

@lovelybhushan13 this is fixed, please do check