O
O
oyshomusic2020-07-20 14:04:45
Python
oyshomusic, 2020-07-20 14:04:45

How to implement this feature?

Greetings, dear readers!

I'm working on a web application, but the problem is that I don't know everything about it .
My application is a page with an input line to activate personalized cards.

I need to implement a function that will generate non-activated card numbers for managers and assign them to them for distribution (respectively, make them possible for the invited user / buyer to activate).

How it's done? Through what is it implemented? Are there examples of this/similar functionality being implemented?

Many thanks for every answer!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander, 2020-07-20
@aleks0010

Well, you can generate an identifier via uuid4(), then check if there is one in the database, if so, generate a new one until it is unique, if not, write it to the database and return it. Further, each identifier in the database must have an is_active field or something like that.
But the task itself is not entirely clear.
Can you describe in more detail what the input line is, what data it accepts, who should interact with it and who should not? What should happen next logically, how should card numbers get to managers?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question