# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'AdminWidget.ui'
#
# Created by: PyQt5 UI code generator 5.15.2
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again.  Do not edit this file unless you know what you are doing.


from PyQt5 import QtCore, QtGui, QtWidgets
import TicketAir


class Ui_ADMINPanel(object):
    def setupUi(self, ADMINPanel):
        ADMINPanel.setObjectName("ADMINPanel")
        ADMINPanel.resize(1328, 786)
        ADMINPanel.setMinimumSize(QtCore.QSize(500, 700))
        self.verticalLayout = QtWidgets.QVBoxLayout(ADMINPanel)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setSpacing(0)
        self.verticalLayout.setObjectName("verticalLayout")
        self.top = QtWidgets.QFrame(ADMINPanel)
        self.top.setMaximumSize(QtCore.QSize(16777215, 40))
        self.top.setBaseSize(QtCore.QSize(0, 0))
        self.top.setStyleSheet("background-color: rgb(255, 255, 127);")
        self.top.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.top.setFrameShadow(QtWidgets.QFrame.Raised)
        self.top.setObjectName("top")
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout(self.top)
        self.horizontalLayout_2.setContentsMargins(0, 0, 0, 0)
        self.horizontalLayout_2.setSpacing(0)
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.ERRORFrame = QtWidgets.QFrame(self.top)
        self.ERRORFrame.setMaximumSize(QtCore.QSize(450, 35))
        self.ERRORFrame.setStyleSheet("background-color: rgb(170, 255, 127);\n"
                                      "border-radius: 5px;")
        self.ERRORFrame.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.ERRORFrame.setFrameShadow(QtWidgets.QFrame.Raised)
        self.ERRORFrame.setObjectName("ERRORFrame")
        self.horizontalLayout_3 = QtWidgets.QHBoxLayout(self.ERRORFrame)
        self.horizontalLayout_3.setContentsMargins(6, 6, 6, 6)
        self.horizontalLayout_3.setSpacing(4)
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        self.ERRORLabel = QtWidgets.QLabel(self.ERRORFrame)
        font = QtGui.QFont()
        font.setPointSize(12)
        self.ERRORLabel.setFont(font)
        self.ERRORLabel.setLayoutDirection(QtCore.Qt.LeftToRight)
        self.ERRORLabel.setAlignment(QtCore.Qt.AlignCenter)
        self.ERRORLabel.setObjectName("ERRORLabel")
        self.horizontalLayout_3.addWidget(self.ERRORLabel)
        self.ERRORXButton = QtWidgets.QPushButton(self.ERRORFrame)
        self.ERRORXButton.setMaximumSize(QtCore.QSize(15, 15))
        self.ERRORXButton.setStyleSheet("QPushButton {\n"
                                        "    border-raadius: 5px;\n"
                                        "    background-position: centre;\n"
                                        "    border: 2px solid;\n"
                                        "}\n"
                                        "\n"
                                        "QPushButton:hover {\n"
                                        "    background-color: rgb(50, 50, 50);\n"
                                        "    color: rgb(255, 234, 70);\n"
                                        "}\n"
                                        "\n"
                                        "QPushButton:pressed {\n"
                                        "    background-color: rgb(35, 35, 35);\n"
                                        "    color: rgb(255, 234, 70);\n"
                                        "}")
        self.ERRORXButton.setObjectName("ERRORXButton")
        self.horizontalLayout_3.addWidget(self.ERRORXButton)
        self.horizontalLayout_2.addWidget(self.ERRORFrame)
        self.verticalLayout.addWidget(self.top)
        self.content = QtWidgets.QFrame(ADMINPanel)
        self.content.setStyleSheet("background-color: rgb(143, 143, 143);")
        self.content.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.content.setFrameShadow(QtWidgets.QFrame.Raised)
        self.content.setObjectName("content")
        self.horizontalLayout = QtWidgets.QHBoxLayout(self.content)
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.main = QtWidgets.QFrame(self.content)
        self.main.setMaximumSize(QtCore.QSize(1300, 700))
        self.main.setStyleSheet("background-color: rgb(35, 31, 32);\n"
                                "border-radius: 10px;")
        self.main.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.main.setFrameShadow(QtWidgets.QFrame.Raised)
        self.main.setObjectName("main")
        self.ADMINIcon = QtWidgets.QFrame(self.main)
        self.ADMINIcon.setGeometry(QtCore.QRect(520, 10, 231, 211))
        self.ADMINIcon.setStyleSheet("background-image: url(:/LOGO/img/admin.png);")
        self.ADMINIcon.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.ADMINIcon.setFrameShadow(QtWidgets.QFrame.Raised)
        self.ADMINIcon.setObjectName("ADMINIcon")
        self.FLIGHT = QtWidgets.QLabel(self.main)
        self.FLIGHT.setGeometry(QtCore.QRect(40, 250, 111, 41))
        font = QtGui.QFont()
        font.setPointSize(14)
        font.setBold(True)
        font.setWeight(75)
        self.FLIGHT.setFont(font)
        self.FLIGHT.setStyleSheet("color: rgb(255, 255, 255);")
        self.FLIGHT.setObjectName("FLIGHT")
        self.Line1 = QtWidgets.QLabel(self.main)
        self.Line1.setGeometry(QtCore.QRect(40, 280, 1051, 20))
        self.Line1.setStyleSheet("color: rgb(255, 255, 255);")
        self.Line1.setObjectName("Line1")
        self.FROMAddLabel = QtWidgets.QLineEdit(self.main)
        self.FROMAddLabel.setGeometry(QtCore.QRect(40, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.FROMAddLabel.setFont(font)
        self.FROMAddLabel.setStyleSheet("QLineEdit {\n"
                                        "    border: 2px solid rgb(45,45,45);\n"
                                        "    border-radius: 8px;    \n"
                                        "    padding: 15 px;\n"
                                        "    background-color: rgb(30,30,30);\n"
                                        "    color: rgb(100, 100, 100);\n"
                                        "    color: rgb(255, 255, 255);    \n"
                                        "}\n"
                                        "\n"
                                        "QLineEdit:hover {\n"
                                        "    border: 2px solid rgb(55,55,55);\n"
                                        "}\n"
                                        "\n"
                                        "QLineEdit:focus {\n"
                                        "    border: 2px solid  rgb(170, 255, 255);\n"
                                        "    color: rgb(200,200,200);\n"
                                        "}")
        self.FROMAddLabel.setText("")
        self.FROMAddLabel.setMaxLength(100)
        self.FROMAddLabel.setObjectName("FROMAddLabel")
        self.TOAddLabel = QtWidgets.QLineEdit(self.main)
        self.TOAddLabel.setGeometry(QtCore.QRect(190, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.TOAddLabel.setFont(font)
        self.TOAddLabel.setStyleSheet("QLineEdit {\n"
                                      "    border: 2px solid rgb(45,45,45);\n"
                                      "    border-radius: 8px;    \n"
                                      "    padding: 15 px;\n"
                                      "    background-color: rgb(30,30,30);\n"
                                      "    color: rgb(100, 100, 100);\n"
                                      "    color: rgb(255, 255, 255);    \n"
                                      "}\n"
                                      "\n"
                                      "QLineEdit:hover {\n"
                                      "    border: 2px solid rgb(55,55,55);\n"
                                      "}\n"
                                      "\n"
                                      "QLineEdit:focus {\n"
                                      "    border: 2px solid  rgb(170, 255, 255);\n"
                                      "    color: rgb(200,200,200);\n"
                                      "}")
        self.TOAddLabel.setText("")
        self.TOAddLabel.setMaxLength(100)
        self.TOAddLabel.setObjectName("TOAddLabel")
        self.DATEAddLabel = QtWidgets.QLineEdit(self.main)
        self.DATEAddLabel.setGeometry(QtCore.QRect(340, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.DATEAddLabel.setFont(font)
        self.DATEAddLabel.setStyleSheet("QLineEdit {\n"
                                        "    border: 2px solid rgb(45,45,45);\n"
                                        "    border-radius: 8px;    \n"
                                        "    padding: 15 px;\n"
                                        "    background-color: rgb(30,30,30);\n"
                                        "    color: rgb(100, 100, 100);\n"
                                        "    color: rgb(255, 255, 255);    \n"
                                        "}\n"
                                        "\n"
                                        "QLineEdit:hover {\n"
                                        "    border: 2px solid rgb(55,55,55);\n"
                                        "}\n"
                                        "\n"
                                        "QLineEdit:focus {\n"
                                        "    border: 2px solid  rgb(170, 255, 255);\n"
                                        "    color: rgb(200,200,200);\n"
                                        "}")
        self.DATEAddLabel.setText("")
        self.DATEAddLabel.setMaxLength(100)
        self.DATEAddLabel.setObjectName("DATEAddLabel")
        self.TIMEAddLabel = QtWidgets.QLineEdit(self.main)
        self.TIMEAddLabel.setGeometry(QtCore.QRect(490, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.TIMEAddLabel.setFont(font)
        self.TIMEAddLabel.setStyleSheet("QLineEdit {\n"
                                        "    border: 2px solid rgb(45,45,45);\n"
                                        "    border-radius: 8px;    \n"
                                        "    padding: 15 px;\n"
                                        "    background-color: rgb(30,30,30);\n"
                                        "    color: rgb(100, 100, 100);\n"
                                        "    color: rgb(255, 255, 255);    \n"
                                        "}\n"
                                        "\n"
                                        "QLineEdit:hover {\n"
                                        "    border: 2px solid rgb(55,55,55);\n"
                                        "}\n"
                                        "\n"
                                        "QLineEdit:focus {\n"
                                        "    border: 2px solid  rgb(170, 255, 255);\n"
                                        "    color: rgb(200,200,200);\n"
                                        "}")
        self.TIMEAddLabel.setText("")
        self.TIMEAddLabel.setMaxLength(100)
        self.TIMEAddLabel.setObjectName("TIMEAddLabel")
        self.FLIGHTNUMBERAddLabel = QtWidgets.QLineEdit(self.main)
        self.FLIGHTNUMBERAddLabel.setGeometry(QtCore.QRect(640, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.FLIGHTNUMBERAddLabel.setFont(font)
        self.FLIGHTNUMBERAddLabel.setStyleSheet("QLineEdit {\n"
                                                "    border: 2px solid rgb(45,45,45);\n"
                                                "    border-radius: 8px;    \n"
                                                "    padding: 15 px;\n"
                                                "    background-color: rgb(30,30,30);\n"
                                                "    color: rgb(100, 100, 100);\n"
                                                "    color: rgb(255, 255, 255);    \n"
                                                "}\n"
                                                "\n"
                                                "QLineEdit:hover {\n"
                                                "    border: 2px solid rgb(55,55,55);\n"
                                                "}\n"
                                                "\n"
                                                "QLineEdit:focus {\n"
                                                "    border: 2px solid  rgb(170, 255, 255);\n"
                                                "    color: rgb(200,200,200);\n"
                                                "}")
        self.FLIGHTNUMBERAddLabel.setText("")
        self.FLIGHTNUMBERAddLabel.setMaxLength(100)
        self.FLIGHTNUMBERAddLabel.setObjectName("FLIGHTNUMBERAddLabel")
        self.PLANENUMBERAddFlightLabel = QtWidgets.QLineEdit(self.main)
        self.PLANENUMBERAddFlightLabel.setGeometry(QtCore.QRect(790, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.PLANENUMBERAddFlightLabel.setFont(font)
        self.PLANENUMBERAddFlightLabel.setStyleSheet("QLineEdit {\n"
                                                     "    border: 2px solid rgb(45,45,45);\n"
                                                     "    border-radius: 8px;    \n"
                                                     "    padding: 15 px;\n"
                                                     "    background-color: rgb(30,30,30);\n"
                                                     "    color: rgb(100, 100, 100);\n"
                                                     "    color: rgb(255, 255, 255);    \n"
                                                     "}\n"
                                                     "\n"
                                                     "QLineEdit:hover {\n"
                                                     "    border: 2px solid rgb(55,55,55);\n"
                                                     "}\n"
                                                     "\n"
                                                     "QLineEdit:focus {\n"
                                                     "    border: 2px solid  rgb(170, 255, 255);\n"
                                                     "    color: rgb(200,200,200);\n"
                                                     "}")
        self.PLANENUMBERAddFlightLabel.setText("")
        self.PLANENUMBERAddFlightLabel.setMaxLength(100)
        self.PLANENUMBERAddFlightLabel.setObjectName("PLANENUMBERAddFlightLabel")
        self.PRICEAddLabel = QtWidgets.QLineEdit(self.main)
        self.PRICEAddLabel.setGeometry(QtCore.QRect(940, 310, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.PRICEAddLabel.setFont(font)
        self.PRICEAddLabel.setStyleSheet("QLineEdit {\n"
                                         "    border: 2px solid rgb(45,45,45);\n"
                                         "    border-radius: 8px;    \n"
                                         "    padding: 15 px;\n"
                                         "    background-color: rgb(30,30,30);\n"
                                         "    color: rgb(100, 100, 100);\n"
                                         "    color: rgb(255, 255, 255);    \n"
                                         "}\n"
                                         "\n"
                                         "QLineEdit:hover {\n"
                                         "    border: 2px solid rgb(55,55,55);\n"
                                         "}\n"
                                         "\n"
                                         "QLineEdit:focus {\n"
                                         "    border: 2px solid  rgb(170, 255, 255);\n"
                                         "    color: rgb(200,200,200);\n"
                                         "}")
        self.PRICEAddLabel.setText("")
        self.PRICEAddLabel.setMaxLength(100)
        self.PRICEAddLabel.setObjectName("PRICEAddLabel")
        self.ADDFLIGHTButton = QtWidgets.QPushButton(self.main)
        self.ADDFLIGHTButton.setGeometry(QtCore.QRect(1110, 310, 131, 51))
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setBold(True)
        font.setWeight(75)
        self.ADDFLIGHTButton.setFont(font)
        self.ADDFLIGHTButton.setStyleSheet("QPushButton {\n"
                                           "    background-color: rgb(170, 255, 255);\n"
                                           "    border: 2px solid rgb(60,60,60);\n"
                                           "    border-radius: 10px;\n"
                                           "}\n"
                                           "\n"
                                           "QPushButton:hover {\n"
                                           "    background-color: rgb(60, 60, 60);\n"
                                           "    border: 2px solid rgb(70,70,70);\n"
                                           "    border-radius: 10px;\n"
                                           "}\n"
                                           "\n"
                                           "QPushButton:pressed {\n"
                                           "    background-color:  rgb(170, 255, 255);\n"
                                           "    border: 2px solid rgb(0,0,0);\n"
                                           "    border-radius: 10px;\n"
                                           "    \n"
                                           "    color: rgb(35, 35, 35);\n"
                                           "}")
        self.ADDFLIGHTButton.setObjectName("ADDFLIGHTButton")
        self.FLIGHTNUMBERDeleteLabel = QtWidgets.QLineEdit(self.main)
        self.FLIGHTNUMBERDeleteLabel.setGeometry(QtCore.QRect(40, 390, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.FLIGHTNUMBERDeleteLabel.setFont(font)
        self.FLIGHTNUMBERDeleteLabel.setStyleSheet("QLineEdit {\n"
                                                   "    border: 2px solid rgb(45,45,45);\n"
                                                   "    border-radius: 8px;    \n"
                                                   "    padding: 15 px;\n"
                                                   "    background-color: rgb(30,30,30);\n"
                                                   "    color: rgb(100, 100, 100);\n"
                                                   "    color: rgb(255, 255, 255);    \n"
                                                   "}\n"
                                                   "\n"
                                                   "QLineEdit:hover {\n"
                                                   "    border: 2px solid rgb(55,55,55);\n"
                                                   "}\n"
                                                   "\n"
                                                   "QLineEdit:focus {\n"
                                                   "    border: 2px solid rgb(17, 217, 217);\n"
                                                   "    color: rgb(200,200,200);\n"
                                                   "}")
        self.FLIGHTNUMBERDeleteLabel.setText("")
        self.FLIGHTNUMBERDeleteLabel.setMaxLength(100)
        self.FLIGHTNUMBERDeleteLabel.setObjectName("FLIGHTNUMBERDeleteLabel")
        self.DELETEFLIGHTButton = QtWidgets.QPushButton(self.main)
        self.DELETEFLIGHTButton.setGeometry(QtCore.QRect(210, 390, 121, 51))
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setBold(True)
        font.setWeight(75)
        self.DELETEFLIGHTButton.setFont(font)
        self.DELETEFLIGHTButton.setStyleSheet("QPushButton {\n"
                                              "    background-color: rgb(17, 217, 217);\n"
                                              "    border: 2px solid rgb(60,60,60);\n"
                                              "    border-radius: 10px;\n"
                                              "}\n"
                                              "\n"
                                              "QPushButton:hover {\n"
                                              "    background-color: rgb(60, 60, 60);\n"
                                              "    border: 2px solid rgb(70,70,70);\n"
                                              "    border-radius: 10px;\n"
                                              "}\n"
                                              "\n"
                                              "QPushButton:pressed {\n"
                                              "    background-color:rgb(17, 217, 217);\n"
                                              "    border: 2px solid rgb(0,0,0);\n"
                                              "    border-radius: 10px;\n"
                                              "    \n"
                                              "    color: rgb(35, 35, 35);\n"
                                              "}")
        self.DELETEFLIGHTButton.setObjectName("DELETEFLIGHTButton")
        self.PLANE = QtWidgets.QLabel(self.main)
        self.PLANE.setGeometry(QtCore.QRect(50, 460, 111, 41))
        font = QtGui.QFont()
        font.setPointSize(14)
        font.setBold(True)
        font.setWeight(75)
        self.PLANE.setFont(font)
        self.PLANE.setStyleSheet("color: rgb(255, 255, 255);")
        self.PLANE.setObjectName("PLANE")
        self.Line2 = QtWidgets.QLabel(self.main)
        self.Line2.setGeometry(QtCore.QRect(50, 490, 631, 20))
        self.Line2.setStyleSheet("color: rgb(255, 255, 255);")
        self.Line2.setObjectName("Line2")
        self.PLANENUMBERAddPlaneLabel = QtWidgets.QLineEdit(self.main)
        self.PLANENUMBERAddPlaneLabel.setGeometry(QtCore.QRect(40, 520, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.PLANENUMBERAddPlaneLabel.setFont(font)
        self.PLANENUMBERAddPlaneLabel.setStyleSheet("QLineEdit {\n"
                                                    "    border: 2px solid rgb(45,45,45);\n"
                                                    "    border-radius: 8px;    \n"
                                                    "    padding: 15 px;\n"
                                                    "    background-color: rgb(30,30,30);\n"
                                                    "    color: rgb(100, 100, 100);\n"
                                                    "    color: rgb(255, 255, 255);    \n"
                                                    "}\n"
                                                    "\n"
                                                    "QLineEdit:hover {\n"
                                                    "    border: 2px solid rgb(55,55,55);\n"
                                                    "}\n"
                                                    "\n"
                                                    "QLineEdit:focus {\n"
                                                    "    border: 2px solid rgb(0, 146, 208);\n"
                                                    "    color: rgb(200,200,200);\n"
                                                    "}\n"
                                                    "")
        self.PLANENUMBERAddPlaneLabel.setText("")
        self.PLANENUMBERAddPlaneLabel.setMaxLength(100)
        self.PLANENUMBERAddPlaneLabel.setObjectName("PLANENUMBERAddPlaneLabel")
        self.YEAROFPRDAddLabel = QtWidgets.QLineEdit(self.main)
        self.YEAROFPRDAddLabel.setGeometry(QtCore.QRect(190, 520, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.YEAROFPRDAddLabel.setFont(font)
        self.YEAROFPRDAddLabel.setStyleSheet("QLineEdit {\n"
                                             "    border: 2px solid rgb(45,45,45);\n"
                                             "    border-radius: 8px;    \n"
                                             "    padding: 15 px;\n"
                                             "    background-color: rgb(30,30,30);\n"
                                             "    color: rgb(100, 100, 100);\n"
                                             "    color: rgb(255, 255, 255);    \n"
                                             "}\n"
                                             "\n"
                                             "QLineEdit:hover {\n"
                                             "    border: 2px solid rgb(55,55,55);\n"
                                             "}\n"
                                             "\n"
                                             "QLineEdit:focus {\n"
                                             "    border: 2px solid rgb(0, 146, 208);\n"
                                             "    color: rgb(200,200,200);\n"
                                             "}")
        self.YEAROFPRDAddLabel.setText("")
        self.YEAROFPRDAddLabel.setMaxLength(100)
        self.YEAROFPRDAddLabel.setObjectName("YEAROFPRDAddLabel")
        self.FLIGHTSMILESAddLabel = QtWidgets.QLineEdit(self.main)
        self.FLIGHTSMILESAddLabel.setGeometry(QtCore.QRect(340, 520, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.FLIGHTSMILESAddLabel.setFont(font)
        self.FLIGHTSMILESAddLabel.setStyleSheet("QLineEdit {\n"
                                                "    border: 2px solid rgb(45,45,45);\n"
                                                "    border-radius: 8px;    \n"
                                                "    padding: 15 px;\n"
                                                "    background-color: rgb(30,30,30);\n"
                                                "    color: rgb(100, 100, 100);\n"
                                                "    color: rgb(255, 255, 255);    \n"
                                                "}\n"
                                                "\n"
                                                "QLineEdit:hover {\n"
                                                "    border: 2px solid rgb(55,55,55);\n"
                                                "}\n"
                                                "\n"
                                                "QLineEdit:focus {\n"
                                                "    border: 2px solid rgb(0, 146, 208);\n"
                                                "    color: rgb(200,200,200);\n"
                                                "}")
        self.FLIGHTSMILESAddLabel.setText("")
        self.FLIGHTSMILESAddLabel.setMaxLength(100)
        self.FLIGHTSMILESAddLabel.setObjectName("FLIGHTSMILESAddLabel")
        self.CAPACITYAddLabel = QtWidgets.QLineEdit(self.main)
        self.CAPACITYAddLabel.setGeometry(QtCore.QRect(490, 520, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.CAPACITYAddLabel.setFont(font)
        self.CAPACITYAddLabel.setStyleSheet("QLineEdit {\n"
                                            "    border: 2px solid rgb(45,45,45);\n"
                                            "    border-radius: 8px;    \n"
                                            "    padding: 15 px;\n"
                                            "    background-color: rgb(30,30,30);\n"
                                            "    color: rgb(100, 100, 100);\n"
                                            "    color: rgb(255, 255, 255);    \n"
                                            "}\n"
                                            "\n"
                                            "QLineEdit:hover {\n"
                                            "    border: 2px solid rgb(55,55,55);\n"
                                            "}\n"
                                            "\n"
                                            "QLineEdit:focus {\n"
                                            "    border: 2px solid rgb(0, 146, 208);\n"
                                            "    color: rgb(200,200,200);\n"
                                            "}")
        self.CAPACITYAddLabel.setText("")
        self.CAPACITYAddLabel.setMaxLength(100)
        self.CAPACITYAddLabel.setObjectName("CAPACITYAddLabel")
        self.ADDPLANEButton = QtWidgets.QPushButton(self.main)
        self.ADDPLANEButton.setGeometry(QtCore.QRect(650, 520, 131, 51))
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setBold(True)
        font.setWeight(75)
        self.ADDPLANEButton.setFont(font)
        self.ADDPLANEButton.setStyleSheet("QPushButton {\n"
                                          "    background-color: rgb(0, 146, 208);\n"
                                          "    border: 2px solid rgb(60,60,60);\n"
                                          "    border-radius: 10px;\n"
                                          "}\n"
                                          "\n"
                                          "QPushButton:hover {\n"
                                          "    background-color: rgb(60, 60, 60);\n"
                                          "    border: 2px solid rgb(70,70,70);\n"
                                          "    border-radius: 10px;\n"
                                          "}\n"
                                          "\n"
                                          "QPushButton:pressed {\n"
                                          "    background-color: rgb(0, 146, 208);\n"
                                          "    border: 2px solid rgb(0,0,0);\n"
                                          "    border-radius: 10px;\n"
                                          "    \n"
                                          "    color: rgb(35, 35, 35);\n"
                                          "}\n"
                                          "")
        self.ADDPLANEButton.setObjectName("ADDPLANEButton")
        self.PLANENUMBERDeleteLabel = QtWidgets.QLineEdit(self.main)
        self.PLANENUMBERDeleteLabel.setGeometry(QtCore.QRect(40, 590, 141, 51))
        font = QtGui.QFont()
        font.setPointSize(9)
        self.PLANENUMBERDeleteLabel.setFont(font)
        self.PLANENUMBERDeleteLabel.setStyleSheet("QLineEdit {\n"
                                                  "    border: 2px solid rgb(45,45,45);\n"
                                                  "    border-radius: 8px;    \n"
                                                  "    padding: 15 px;\n"
                                                  "    background-color: rgb(30,30,30);\n"
                                                  "    color: rgb(100, 100, 100);\n"
                                                  "    color: rgb(255, 255, 255);    \n"
                                                  "}\n"
                                                  "\n"
                                                  "QLineEdit:hover {\n"
                                                  "    border: 2px solid rgb(55,55,55);\n"
                                                  "}\n"
                                                  "\n"
                                                  "QLineEdit:focus {\n"
                                                  "    border: 2px solid rgb(12, 143, 143);\n"
                                                  "    color: rgb(200,200,200);\n"
                                                  "}")
        self.PLANENUMBERDeleteLabel.setText("")
        self.PLANENUMBERDeleteLabel.setMaxLength(100)
        self.PLANENUMBERDeleteLabel.setObjectName("PLANENUMBERDeleteLabel")
        self.DELETEPLANEButton = QtWidgets.QPushButton(self.main)
        self.DELETEPLANEButton.setGeometry(QtCore.QRect(210, 590, 131, 51))
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setBold(True)
        font.setWeight(75)
        self.DELETEPLANEButton.setFont(font)
        self.DELETEPLANEButton.setStyleSheet("QPushButton {\n"
                                             "    background-color: rgb(12, 143, 143);\n"
                                             "    border: 2px solid rgb(60,60,60);\n"
                                             "    border-radius: 10px;\n"
                                             "}\n"
                                             "\n"
                                             "QPushButton:hover {\n"
                                             "    background-color: rgb(60, 60, 60);\n"
                                             "    border: 2px solid rgb(70,70,70);\n"
                                             "    border-radius: 10px;\n"
                                             "}\n"
                                             "\n"
                                             "QPushButton:pressed {\n"
                                             "    background-color: rgb(12, 143, 143);\n"
                                             "    border: 2px solid rgb(0,0,0);\n"
                                             "    border-radius: 10px;\n"
                                             "    \n"
                                             "    color: rgb(35, 35, 35);\n"
                                             "}\n"
                                             "")
        self.DELETEPLANEButton.setObjectName("DELETEPLANEButton")
        self.SETTINGSIcon = QtWidgets.QFrame(self.main)
        self.SETTINGSIcon.setGeometry(QtCore.QRect(980, 390, 291, 291))
        self.SETTINGSIcon.setStyleSheet("background-image: url(:/LOGO/img/setting.jpg);")
        self.SETTINGSIcon.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.SETTINGSIcon.setFrameShadow(QtWidgets.QFrame.Raised)
        self.SETTINGSIcon.setObjectName("SETTINGSIcon")
        self.horizontalLayout.addWidget(self.main)
        self.verticalLayout.addWidget(self.content)
        self.bottom = QtWidgets.QFrame(ADMINPanel)
        self.bottom.setMaximumSize(QtCore.QSize(16777215, 40))
        self.bottom.setBaseSize(QtCore.QSize(0, 0))
        self.bottom.setStyleSheet("background-color: rgb(255, 255, 127);")
        self.bottom.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.bottom.setFrameShadow(QtWidgets.QFrame.Raised)
        self.bottom.setObjectName("bottom")
        self.verticalLayout.addWidget(self.bottom)

        self.retranslateUi(ADMINPanel)
        QtCore.QMetaObject.connectSlotsByName(ADMINPanel)
        self.DELETEFLIGHTButton.clicked.connect(self.deleteFlight)
        self.DELETEPLANEButton.clicked.connect(self.deletePlane)
        self.ADDFLIGHTButton.clicked.connect(self.addFlight)
        self.ADDPLANEButton.clicked.connect(self.addPlane)
        self.ERRORXButton.clicked.connect(self.closeError)
        self.ERRORFrame.hide()

    def retranslateUi(self, ADMINPanel):
        _translate = QtCore.QCoreApplication.translate
        ADMINPanel.setWindowTitle(_translate("ADMINPanel", "ADMIN "))
        self.ERRORLabel.setText(_translate("ADMINPanel", "ERROR"))
        self.ERRORXButton.setText(_translate("ADMINPanel", "X"))
        self.FLIGHT.setText(_translate("ADMINPanel", "FLIGHT"))
        self.Line1.setText(_translate("ADMINPanel",
                                      "_____________________________________________________________________________________________________________________________________________________________________________________________________________________________________________"))
        self.FROMAddLabel.setPlaceholderText(_translate("ADMINPanel", "FROM"))
        self.TOAddLabel.setPlaceholderText(_translate("ADMINPanel", "TO"))
        self.DATEAddLabel.setPlaceholderText(_translate("ADMINPanel", "DATE"))
        self.TIMEAddLabel.setPlaceholderText(_translate("ADMINPanel", "TIME"))
        self.FLIGHTNUMBERAddLabel.setPlaceholderText(_translate("ADMINPanel", "FLIGHT NUMBER"))
        self.PLANENUMBERAddFlightLabel.setPlaceholderText(_translate("ADMINPanel", "PLANE NUMBER"))
        self.PRICEAddLabel.setPlaceholderText(_translate("ADMINPanel", "PRICE"))
        self.ADDFLIGHTButton.setText(_translate("ADMINPanel", "ADD FLIGHT"))
        self.FLIGHTNUMBERDeleteLabel.setPlaceholderText(_translate("ADMINPanel", "FLIGHT NUMBER"))
        self.DELETEFLIGHTButton.setText(_translate("ADMINPanel", "DELETE FLIGHT"))
        self.PLANE.setText(_translate("ADMINPanel", "PLANE"))
        self.Line2.setText(_translate("ADMINPanel",
                                      "____________________________________________________________________________________________________________________________________"))
        self.PLANENUMBERAddPlaneLabel.setPlaceholderText(_translate("ADMINPanel", "PLANE NUMBER"))
        self.YEAROFPRDAddLabel.setPlaceholderText(_translate("ADMINPanel", "YEAR OF PRODUCTION"))
        self.FLIGHTSMILESAddLabel.setPlaceholderText(_translate("ADMINPanel", "FLIGHTS MILES"))
        self.CAPACITYAddLabel.setPlaceholderText(_translate("ADMINPanel", "CAPACITY"))
        self.ADDPLANEButton.setText(_translate("ADMINPanel", "ADD PLANE"))
        self.PLANENUMBERDeleteLabel.setPlaceholderText(_translate("ADMINPanel", "PLANE NUMBER"))
        self.DELETEPLANEButton.setText(_translate("ADMINPanel", "DELETE PLANE"))

    def deleteFlight(self):
        self.db = TicketAir.DataBase()
        self.ERRORFrame.show()
        if self.db.cancelFlight(str(self.FLIGHTNUMBERDeleteLabel.text())):
            self.ERRORLabel.setText(f'Successfully deleted flight with number: {str(self.FLIGHTNUMBERDeleteLabel.text())}')
            self.home.setOrigins()
        else:
            self.ERRORLabel.setText('Could not delete this flight.')

    def deletePlane(self):
        self.db = TicketAir.DataBase()
        self.ERRORFrame.show()
        if self.db.removePlane(str(self.PLANENUMBERDeleteLabel.text())):
            self.ERRORLabel.setText(f'Successfully deleted plane with tail number: {str(self.PLANENUMBERDeleteLabel.text())}')
            self.home.setOrigins()
        else:
            self.ERRORLabel.setText('There is no plane with that tail number.')

    def addFlight(self):
        try:
            self.db = TicketAir.DataBase()
            flight = TicketAir.Flight((self.FROMAddLabel.text()), (self.TOAddLabel.text()), (self.FLIGHTNUMBERAddLabel.text()),
                       self.PLANENUMBERAddFlightLabel.text(), self.DATEAddLabel.text(),
                       int(self.PRICEAddLabel.text()),
                       float(self.TIMEAddLabel.text()))

            self.db.addFlight(flight)

            self.FROMAddLabel.setText('')
            self.TOAddLabel.setText('')
            self.DATEAddLabel.setText('')
            self.TIMEAddLabel.setText('')
            self.FLIGHTNUMBERAddLabel.setText('')
            self.PLANENUMBERAddFlightLabel.setText('')
            self.PRICEAddLabel.setText('')
            self.home.setOrigins()
        except:
            self.ERRORFrame.show()
            self.ERRORLabel.setText("Couldn't add this plane, check values")


    def addPlane(self):
        try:
            db = TicketAir.DataBase()
            db.addPlane(
                TicketAir.Plane(self.YEAROFPRDAddLabel.text(), self.FLIGHTSMILESAddLabel.text(), self.CAPACITYAddLabel.text(),
                                self.PLANENUMBERAddPlaneLabel.text()))

            self.PLANENUMBERAddPlaneLabel.setText('')
            self.YEAROFPRDAddLabel.setText('')
            self.FLIGHTSMILESAddLabel.setText('')
            self.CAPACITYAddLabel.setText('')
        except:
            pass

    def closeError(self):
        self.ERRORFrame.hide()

    def __init__(self, homePage):
        self.home = homePage

if __name__ == "__main__":
    import sys

    app = QtWidgets.QApplication(sys.argv)
    ADMINPanel = QtWidgets.QWidget()
    ui = Ui_ADMINPanel()
    ui.setupUi(ADMINPanel)
    ADMINPanel.show()
    sys.exit(app.exec_())
