-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathSMSme.py
108 lines (87 loc) · 3.33 KB
/
SMSme.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
from Class.Output import *
from Class.Phones import *
import random
import json
YELLOW = '\033[93m'
GREEN = '\033[92m'
RED = '\033[31m'
WHITE = '\33[97m'
BOLD = '\033[1m'
BLUE = '\033[36m'
Output.logo()
Output.list()
file = open("Files/data.json", "r")
phones = json.load(file)["phones"]
countriesChoose = str(
input(f"\n\n {BOLD}{RED}[REQ] {YELLOW}Choose which Country Ex[3] : {WHITE}"))
def Sites(self, phoneNumber, country, id):
match self:
case "receiveSms":
print("this is receiveSms")
Phones.receiveSms(phoneNumber, country, id)
case "myTempSms":
print("this is myTempSms")
Phones.myTempSms(phoneNumber, country, id)
case "myTempSmsSecond":
print("this is myTempSmsSecond")
Phones.myTempSmsSecond(phoneNumber, country, id)
def find(self, choosePhonenumber):
if choosePhonenumber <= 40:
for phone in phones:
phoneNumber = phone["Number"]
country = phone["Country"]
Code = phone["Code"]
numberId = phone["id"]
id = phone["ID"]
Site = phone["Site"]
if Code == self and choosePhonenumber == numberId:
match Site:
case "receiveSms":
Phones.receiveSms(phoneNumber, country, id)
case "myTempSms":
Phones.myTempSms(phoneNumber, country, id)
case "myTempSmsSecond":
Phones.myTempSmsSecond(
phoneNumber, country, id)
elif choosePhonenumber == 99:
print(f"\t\n{BOLD}{RED}[EXIT]{WHITE} Happy to help you Bye!{WHITE}\n")
quit()
else:
print(f"\n{RED}[ERR] {WHITE}Please make sure use the number , Don't use [{YELLOW} {choosePhonenumber}{WHITE} ]!\n\n{RED}[ERR] {WHITE}Kindly use numbers from [{YELLOW} 1 to 40 {WHITE}]\n")
match countriesChoose:
case "1":
Output.USA()
chooseUSA = int(
input(f"\n {RED}[REQ] {YELLOW}Choose which number Ex[34] : {WHITE}"))
find("+1", chooseUSA)
case "2":
Output.UK()
chooseUK = int(
input(f"\n {RED}[REQ] {YELLOW}Choose which number Ex[2] : {WHITE}"))
find("+44", chooseUK)
case "3":
Output.Sweden()
chooseSweden = int(
input(f"\n {RED}[REQ] {YELLOW}Choose which number Ex[22] : {WHITE}"))
find("+46", chooseSweden)
case "4":
Output.France()
chooseFrance = int(
input(f"\n {RED}[REQ] {YELLOW}Choose which number Ex[34] : {WHITE}"))
find("+33", chooseFrance)
case "5":
print(
f"\t\n{BOLD}{RED}[EXIT]{WHITE} Happy to help you Bye!{WHITE}\n")
quit()
case "6":
CountryCode = {
1: "+1",
2: "+44",
3: "+46",
4: "+33"
}
randomCountry = random.choice(range(1, 4))
randomNumber = random.choice(range(0, 40))
find(CountryCode[randomCountry], randomNumber)
case _:
print(f"\n{RED}[ERR] {WHITE}Please make sure use the number , Don't use [{YELLOW} {countriesChoose}{WHITE} ]!\n\n{RED}[ERR] {WHITE}Kindly use numbers from [{YELLOW} 1 to 6 {WHITE}]\n")