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


import base64
import datetime
from PyQt6 import QtCore
from PyQt6 import QtGui , QtWidgets
from PyQt6.QtCore import QThread , QObject , QByteArray
from PyQt6.QtGui import QIcon , QPixmap
from PyQt6.QtWidgets import QTableWidget , QAbstractItemView , QTableWidgetItem
from Functions.apiFunction import api_fc


class updateDragDrop(QObject):
    def __init__(self,name,ip,column,item,flightid,thread,displayMode,flighttype,selectedtime):
        super().__init__()
        self.funcName = name
        self.column =column
        self.ipinfo=ip
        self.getDragitemName=item
        self.flightid=flightid
        self.thread = thread
        self.displayMode=displayMode
        self.flighttype = flighttype
        self.selectedtime=selectedtime
        #print(name,ip,column,item,flightid,thread,displayMode,flighttype,selectedtime)

    def run(self):
        self.updateDragDropItemSever()
        self.thread.quit()
    def updateDragDropItemSever(self):
        #ip = "http://%s/static/updateDragDropItem/%s/%s/%s/%s/%s/%s" % (str(self.ipinfo), self.column, self.getDragitemName, self.flightid,self.displayMode,self.flighttype,self.selectedtime)
        #requests.get(url=ip, timeout=30)
        api_fc.request_post("/static/updateDragDropItem",column=self.column,text=self.getDragitemName,flightid=self.flightid,displayMode=self.displayMode,flighttype=self.flighttype,selectedtime=self.selectedtime)



class flightDragDrop(QTableWidget):
    dropitem=QtCore.pyqtSignal(int,int)
    def __init__(self):
        QTableWidget.__init__(self)
    def dragEnterEvent(self, event):
        event.accept()
    def dropEvent(self, event):
        self.cellEntered.connect(self.FlightDroped)
    def FlightDroped(self,row,column):
        self.dropitem.emit(row, column)
        self.cellEntered.disconnect(self.FlightDroped)
        #print(row, column)
class personDragDrop(QTableWidget):
    dragitem = QtCore.pyqtSignal(str,str)
    def __init__(self):
        QTableWidget.__init__(self)
        self.cellPressed.connect(self.personPressed)
    def personPressed(self, row, column):
        if column == 1:
            self.dragitem.emit(self.item(row, column).text(),self.item(row, column+1).text())
        else:
            self.dragitem.emit("", "")
        # print(row, column)
        # print(self.item(row,column).text())

class Ui_Form(object):
    def setupUi(self, Form):
        icon_base64 = """
        [encoded data, 360532 characters]

        """

        # 从Base64创建图标
        icon_data = base64.b64decode(icon_base64)
        pixmap = QPixmap()
        pixmap.loadFromData(QByteArray(icon_data))
        icon = QIcon(pixmap)

        Form.setWindowIcon(icon)
        Form.setObjectName("Form")
        Form.resize(1466, 1001)
        self.gridLayout = QtWidgets.QGridLayout(Form)
        self.gridLayout.setObjectName("gridLayout")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout()
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout()
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.horizontalLayout_4 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_4.setSizeConstraint(QtWidgets.QLayout.SizeConstraint.SetMaximumSize)
        self.horizontalLayout_4.setObjectName("horizontalLayout_4")
        self.label_3 = QtWidgets.QLabel(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_3.setFont(font)
        self.label_3.setObjectName("label_3")
        self.horizontalLayout_4.addWidget(self.label_3)
        self.label_8 = QtWidgets.QLabel(parent=Form)
        self.label_8.setMaximumSize(QtCore.QSize(40, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_8.setFont(font)
        self.label_8.setObjectName("label_8")
        self.horizontalLayout_4.addWidget(self.label_8)
        self.lineEdit_change = QtWidgets.QLineEdit(parent=Form)
        self.lineEdit_change.setMaximumSize(QtCore.QSize(70, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.lineEdit_change.setFont(font)
        self.lineEdit_change.setObjectName("lineEdit_change")
        self.horizontalLayout_4.addWidget(self.lineEdit_change)
        self.pushButton_searchchange = QtWidgets.QPushButton(parent=Form)
        self.pushButton_searchchange.setMaximumSize(QtCore.QSize(40, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.pushButton_searchchange.setFont(font)
        self.pushButton_searchchange.setObjectName("pushButton_searchchange")
        self.horizontalLayout_4.addWidget(self.pushButton_searchchange)
        self.pushButtonAddPG = QtWidgets.QPushButton(parent=Form)
        self.pushButtonAddPG.setMaximumSize(QtCore.QSize(55, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.pushButtonAddPG.setFont(font)
        self.pushButtonAddPG.setObjectName("pushButtonAddPG")
        self.horizontalLayout_4.addWidget(self.pushButtonAddPG)
        self.horizontalLayout_4.setStretch(0, 4)
        self.horizontalLayout_4.setStretch(4, 1)
        self.verticalLayout_4.addLayout(self.horizontalLayout_4)
        self.tableWidget = QtWidgets.QTableWidget(parent=Form)
        self.tableWidget.setMaximumSize(QtCore.QSize(16777215, 16777215))
        self.tableWidget.setObjectName("tableWidget")
        self.tableWidget.setColumnCount(0)
        self.tableWidget.setRowCount(0)
        self.tableWidget.setMouseTracking(True)
        self.tableWidget.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
        self.tableWidget.setSelectionMode(QAbstractItemView.SelectionMode.SingleSelection)
        self.tableWidget.setMouseTracking(True)
        self.tableWidget.setAlternatingRowColors(True)
        self.tableWidget.setColumnHidden(3, True)
        self.verticalLayout_4.addWidget(self.tableWidget)
        self.verticalLayout_5 = QtWidgets.QVBoxLayout()
        self.verticalLayout_5.setObjectName("verticalLayout_5")
        self.horizontalLayout_6 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_6.setSizeConstraint(QtWidgets.QLayout.SizeConstraint.SetFixedSize)
        self.horizontalLayout_6.setObjectName("horizontalLayout_6")
        self.label_4 = QtWidgets.QLabel(parent=Form)
        self.label_4.setMinimumSize(QtCore.QSize(0, 19))
        self.label_4.setMaximumSize(QtCore.QSize(16777215, 19))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_4.setFont(font)
        self.label_4.setObjectName("label_4")
        self.horizontalLayout_6.addWidget(self.label_4)
        self.label_9 = QtWidgets.QLabel(parent=Form)
        self.label_9.setMaximumSize(QtCore.QSize(40, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_9.setFont(font)
        self.label_9.setObjectName("label_9")
        self.horizontalLayout_6.addWidget(self.label_9)
        self.lineEdit_log = QtWidgets.QLineEdit(parent=Form)
        self.lineEdit_log.setMaximumSize(QtCore.QSize(70, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.lineEdit_log.setFont(font)
        self.lineEdit_log.setObjectName("lineEdit_log")
        self.horizontalLayout_6.addWidget(self.lineEdit_log)
        self.pushButton_searchlog = QtWidgets.QPushButton(parent=Form)
        self.pushButton_searchlog.setMaximumSize(QtCore.QSize(50, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.pushButton_searchlog.setFont(font)
        self.pushButton_searchlog.setObjectName("pushButton_searchlog")
        self.horizontalLayout_6.addWidget(self.pushButton_searchlog)
        self.verticalLayout_5.addLayout(self.horizontalLayout_6)
        self.tableWidgetLOG = QtWidgets.QTableWidget(parent=Form)
        self.tableWidgetLOG.setMaximumSize(QtCore.QSize(16777215, 16777215))
        self.tableWidgetLOG.setObjectName("tableWidgetLOG")
        self.tableWidgetLOG.setColumnCount(0)
        self.tableWidgetLOG.setRowCount(0)
        self.tableWidgetLOG.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
        self.tableWidgetLOG.setSelectionMode(QAbstractItemView.SelectionMode.SingleSelection)
        self.tableWidgetLOG.setAlternatingRowColors(True)

        self.verticalLayout_5.addWidget(self.tableWidgetLOG)
        self.verticalLayout_4.addLayout(self.verticalLayout_5)
        self.verticalLayout_3.addLayout(self.verticalLayout_4)
        self.verticalLayout_4.setStretch(1, 10)
        self.verticalLayout_4.setStretch(2, 3)
        self.gridLayout.addLayout(self.verticalLayout_3, 2, 3, 1, 1)
        self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_2.setSpacing(0)
        self.horizontalLayout_2.setObjectName("horizontalLayout_2")
        self.label_6 = QtWidgets.QLabel(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_6.setFont(font)
        self.label_6.setObjectName("label_6")
        self.horizontalLayout_2.addWidget(self.label_6)
        self.label_username = QtWidgets.QLabel(parent=Form)
        self.label_username.setMinimumSize(QtCore.QSize(100, 0))
        self.label_username.setMaximumSize(QtCore.QSize(100, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_username.setFont(font)
        self.label_username.setObjectName("label_username")
        self.horizontalLayout_2.addWidget(self.label_username)
        self.label_10 = QtWidgets.QLabel(parent=Form)
        self.label_10.setMinimumSize(QtCore.QSize(55, 0))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_10.setFont(font)
        self.label_10.setObjectName("label_10")
        self.horizontalLayout_2.addWidget(self.label_10)
        self.label_11 = QtWidgets.QLabel(parent=Form)
        self.label_11.setMinimumSize(QtCore.QSize(45, 0))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_11.setFont(font)
        self.label_11.setObjectName("label_11")
        self.horizontalLayout_2.addWidget(self.label_11)
        self.horizontalLayout_2.setStretch(0, 1)
        self.horizontalLayout_2.setStretch(1, 4)
        self.gridLayout.addLayout(self.horizontalLayout_2, 0, 2, 1, 1)
        self.verticalLayout = QtWidgets.QVBoxLayout()
        self.verticalLayout.setSizeConstraint(QtWidgets.QLayout.SizeConstraint.SetDefaultConstraint)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tableWidgetFlight = flightDragDrop()
        self.tableWidgetFlight.dropitem.connect(self.getDropitem)
        self.verticalLayout.addWidget(self.tableWidgetFlight)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Policy.Expanding, QtWidgets.QSizePolicy.Policy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.tableWidgetFlight.sizePolicy().hasHeightForWidth())
        self.tableWidgetFlight.setSizePolicy(sizePolicy)
        self.tableWidgetFlight.setObjectName("tableWidgetFlight")
        self.tableWidgetFlight.setColumnCount(0)
        self.tableWidgetFlight.setRowCount(0)
        self.tableWidgetFlight.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
        self.tableWidgetFlight.setSelectionMode(QAbstractItemView.SelectionMode.SingleSelection)
        self.tableWidgetFlight.setMouseTracking(True)
        self.tableWidgetFlight.setAcceptDrops(True)
        self.tableWidgetFlight.viewport().setAcceptDrops(True)
        self.tableWidgetFlight.setDragDropOverwriteMode(True)
        self.tableWidgetFlight.setDragDropMode(QtWidgets.QAbstractItemView.DragDropMode.DropOnly)
        self.gridLayout.addLayout(self.verticalLayout, 2, 1, 1, 1)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.dateEdit = QtWidgets.QDateEdit(parent=Form)
        self.dateEdit.setMinimumSize(QtCore.QSize(130, 0))
        self.dateEdit.setCalendarPopup(True)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.dateEdit.setFont(font)
        self.dateEdit.setObjectName("dateEdit")
        self.horizontalLayout.addWidget(self.dateEdit)
        self.pushButton = QtWidgets.QPushButton(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.pushButton.setFont(font)
        self.pushButton.setObjectName("pushButton")
        self.horizontalLayout.addWidget(self.pushButton)
        self.radioButtonDay = QtWidgets.QRadioButton(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.radioButtonDay.setFont(font)
        self.radioButtonDay.setObjectName("radioButtonDay")
        self.horizontalLayout.addWidget(self.radioButtonDay)
        self.radioButtonNight = QtWidgets.QRadioButton(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.radioButtonNight.setFont(font)
        self.radioButtonNight.setObjectName("radioButtonNight")
        self.horizontalLayout.addWidget(self.radioButtonNight)
        self.horizontalLayout.setStretch(0, 1)
        self.gridLayout.addLayout(self.horizontalLayout, 0, 3, 1, 1)
        self.verticalLayout_2 = QtWidgets.QVBoxLayout()
        self.verticalLayout_2.setSpacing(0)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.horizontalLayout_7 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_7.setSpacing(0)
        self.horizontalLayout_7.setObjectName("horizontalLayout_7")
        self.label_15 = QtWidgets.QLabel(parent=Form)
        self.label_15.setMaximumSize(QtCore.QSize(55, 50))
        font = QtGui.QFont()
        font.setFamily("黑体")
        font.setBold(True)
        font.setUnderline(False)
        font.setWeight(75)
        self.label_15.setFont(font)
        self.label_15.setStyleSheet("color: rgb(255, 0, 0);")
        self.label_15.setObjectName("label_15")
        self.horizontalLayout_7.addWidget(self.label_15)
        self.lineEdit_phonenum = QtWidgets.QLineEdit(parent=Form)
        self.lineEdit_phonenum.setMaximumSize(QtCore.QSize(104, 16777215))
        self.lineEdit_phonenum.setObjectName("lineEdit_phonenum")
        self.horizontalLayout_7.addWidget(self.lineEdit_phonenum)
        self.pushButton_2 = QtWidgets.QPushButton(parent=Form)
        self.pushButton_2.setMaximumSize(QtCore.QSize(30, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        font.setBold(True)
        font.setWeight(75)
        self.pushButton_2.setFont(font)
        self.pushButton_2.setStyleSheet("color: rgb(0, 170, 0); ")
        self.pushButton_2.setObjectName("pushButton_2")
        self.horizontalLayout_7.addWidget(self.pushButton_2)
        self.pushButton_3 = QtWidgets.QPushButton(parent=Form)
        self.pushButton_3.setMaximumSize(QtCore.QSize(30, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        font.setBold(True)
        font.setWeight(75)
        self.pushButton_3.setFont(font)
        self.pushButton_3.setStyleSheet("color: rgb(255, 0, 0);")
        self.pushButton_3.setObjectName("pushButton_3")
        self.horizontalLayout_7.addWidget(self.pushButton_3)
        self.pushButton_4 = QtWidgets.QPushButton(parent=Form)
        self.pushButton_4.setMaximumSize(QtCore.QSize(40, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        font.setBold(True)
        font.setWeight(75)
        self.pushButton_4.setFont(font)
        self.pushButton_4.setStyleSheet("color: rgb(0, 0, 255);")
        self.pushButton_4.setObjectName("pushButton_4")
        self.horizontalLayout_7.addWidget(self.pushButton_4)
        self.verticalLayout_2.addLayout(self.horizontalLayout_7)
        self.tableWidget_3 = QtWidgets.QTableWidget(parent=Form)
        self.tableWidget_3.setMaximumSize(QtCore.QSize(16777215, 110))
        self.tableWidget_3.setObjectName("tableWidget_3")
        self.tableWidget_3.setColumnCount(0)
        self.tableWidget_3.setRowCount(0)
        self.verticalLayout_2.addWidget(self.tableWidget_3)
        self.horizontalLayout_3 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        self.label_2 = QtWidgets.QLabel(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_2.setFont(font)
        self.label_2.setObjectName("label_2")
        self.horizontalLayout_3.addWidget(self.label_2)
        self.pushButton_searchpeople = QtWidgets.QPushButton(parent=Form)
        self.pushButton_searchpeople.setMaximumSize(QtCore.QSize(30, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        font.setBold(True)
        font.setWeight(75)
        self.pushButton_searchpeople.setFont(font)
        self.pushButton_searchpeople.setStyleSheet("color: rgb(0, 170, 0);")
        self.pushButton_searchpeople.setObjectName("pushButton_searchpeople")
        self.horizontalLayout_3.addWidget(self.pushButton_searchpeople)
        self.pushButton_5 = QtWidgets.QPushButton(parent=Form)
        self.pushButton_5.setMaximumSize(QtCore.QSize(55, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        font.setBold(True)
        font.setWeight(75)
        self.pushButton_5.setFont(font)
        self.pushButton_5.setStyleSheet("color: rgb(255, 0, 0);")
        self.pushButton_5.setObjectName("pushButton_5")
        self.horizontalLayout_3.addWidget(self.pushButton_5)
        self.label_7 = QtWidgets.QLabel(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_7.setFont(font)
        self.label_7.setObjectName("label_7")
        self.horizontalLayout_3.addWidget(self.label_7)
        self.lineEdit_people = QtWidgets.QLineEdit(parent=Form)
        self.lineEdit_people.setMaximumSize(QtCore.QSize(70, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.lineEdit_people.setFont(font)
        self.lineEdit_people.setObjectName("lineEdit_people")
        self.horizontalLayout_3.addWidget(self.lineEdit_people)
        self.horizontalLayout_3.setStretch(0, 4)
        self.verticalLayout_2.addLayout(self.horizontalLayout_3)
        self.tableWidgetPerson =personDragDrop()
        self.tableWidgetPerson.dragitem.connect(self.getDragitem)
        self.tableWidgetPerson.setObjectName("tableWidgetPerson")
        self.tableWidgetPerson.setColumnCount(0)
        self.tableWidgetPerson.setRowCount(0)
        self.tableWidgetPerson.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectItems)
        self.tableWidgetPerson.setSelectionMode(QAbstractItemView.SelectionMode.SingleSelection)
        self.tableWidgetPerson.setAlternatingRowColors(True)
        self.tableWidgetPerson.setDragEnabled(True)
        self.tableWidgetPerson.setDragDropMode(QtWidgets.QAbstractItemView.DragDropMode.DragOnly)
        self.verticalLayout_2.addWidget(self.tableWidgetPerson)
        self.gridLayout.addLayout(self.verticalLayout_2, 2, 2, 1, 1)
        self.horizontalLayout_5 = QtWidgets.QHBoxLayout()
        self.horizontalLayout_5.setSizeConstraint(QtWidgets.QLayout.SizeConstraint.SetDefaultConstraint)
        self.horizontalLayout_5.setContentsMargins(-1, 10, -1, -1)
        self.horizontalLayout_5.setObjectName("horizontalLayout_5")
        self.label = QtWidgets.QLabel(parent=Form)
        self.label.setMaximumSize(QtCore.QSize(150, 19))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label.setFont(font)
        self.label.setObjectName("label")
        self.horizontalLayout_5.addWidget(self.label)
        self.label_5 = QtWidgets.QLabel(parent=Form)
        self.label_5.setMaximumSize(QtCore.QSize(180, 16777215))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.label_5.setFont(font)
        self.label_5.setCursor(QtGui.QCursor(QtCore.Qt.CursorShape.UpArrowCursor))
        self.label_5.setLayoutDirection(QtCore.Qt.LayoutDirection.LeftToRight)
        self.label_5.setAlignment(QtCore.Qt.AlignmentFlag.AlignRight|QtCore.Qt.AlignmentFlag.AlignTrailing|QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.label_5.setObjectName("label_5")
        self.horizontalLayout_5.addWidget(self.label_5)
        self.lineEdit_flight = QtWidgets.QLineEdit(parent=Form)
        self.lineEdit_flight.setMaximumSize(QtCore.QSize(100, 19))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.lineEdit_flight.setFont(font)
        self.lineEdit_flight.setCursor(QtGui.QCursor(QtCore.Qt.CursorShape.IBeamCursor))
        self.lineEdit_flight.setObjectName("lineEdit_flight")
        self.horizontalLayout_5.addWidget(self.lineEdit_flight)
        self.pushbutton_searchflight = QtWidgets.QPushButton(parent=Form)
        self.pushbutton_searchflight.setMaximumSize(QtCore.QSize(65, 20))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.pushbutton_searchflight.setFont(font)
        self.pushbutton_searchflight.setCheckable(False)
        self.pushbutton_searchflight.setObjectName("pushbutton_searchflight")
        self.horizontalLayout_5.addWidget(self.pushbutton_searchflight)
        self.checkBox_3 = QtWidgets.QCheckBox(parent=Form)
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.checkBox_3.setFont(font)
        self.checkBox_3.setLayoutDirection(QtCore.Qt.LayoutDirection.RightToLeft)
        self.checkBox_3.setObjectName("checkBox_3")
        self.horizontalLayout_5.addWidget(self.checkBox_3)
        self.checkBox = QtWidgets.QCheckBox(parent=Form)
        self.checkBox.setMaximumSize(QtCore.QSize(120, 19))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.checkBox.setFont(font)
        self.checkBox.setLayoutDirection(QtCore.Qt.LayoutDirection.RightToLeft)
        self.checkBox.setAutoRepeatDelay(300)
        self.checkBox.setObjectName("checkBox")
        self.horizontalLayout_5.addWidget(self.checkBox)
        self.checkBox_2 = QtWidgets.QCheckBox(parent=Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Policy.Minimum, QtWidgets.QSizePolicy.Policy.Fixed)
        sizePolicy.setHorizontalStretch(7)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.checkBox_2.sizePolicy().hasHeightForWidth())
        self.checkBox_2.setSizePolicy(sizePolicy)
        self.checkBox_2.setMaximumSize(QtCore.QSize(120, 16777215))
        self.checkBox_2.setSizeIncrement(QtCore.QSize(0, 0))
        font = QtGui.QFont()
        font.setFamily("黑体")
        self.checkBox_2.setFont(font)
        self.checkBox_2.setLayoutDirection(QtCore.Qt.LayoutDirection.RightToLeft)
        self.checkBox_2.setObjectName("checkBox_2")
        self.horizontalLayout_5.addWidget(self.checkBox_2)
        self.gridLayout.addLayout(self.horizontalLayout_5, 0, 1, 1, 1)
        self.gridLayout.setColumnStretch(1, 40)

        self.retranslateUi(Form)
        QtCore.QMetaObject.connectSlotsByName(Form)


    def retranslateUi(self, Form):
        _translate = QtCore.QCoreApplication.translate
        Form.setWindowTitle(_translate("Form", "天府机务分部机务一队准备组综合办公平台"))
        self.label_3.setText(_translate("Form", "航班变化"))
        self.label_8.setText(_translate("Form", "关键词："))
        self.pushButton_searchchange.setText(_translate("Form", "查询"))
        self.pushButtonAddPG.setText(_translate("Form", "添加待办"))
        self.label_4.setText(_translate("Form", "日志信息"))
        self.label_9.setText(_translate("Form", "关键词："))
        self.pushButton_searchlog.setText(_translate("Form", "查询"))
        self.label_6.setText(_translate("Form", "当前用户："))
        self.label_username.setText(_translate("Form", "无"))
        self.label_10.setText(_translate("Form", "服务器状态："))
        self.label_11.setText(_translate("Form", "无"))
        self.pushButton.setText(_translate("Form", "选择"))
        self.radioButtonDay.setText(_translate("Form", "白"))
        self.radioButtonNight.setText(_translate("Form", "夜"))
        self.label_2.setText(_translate("Form", "人员信息"))
        self.label_7.setText(_translate("Form", "关键词："))
        self.label.setText(_translate("Form", "航班信息"))
        self.label_5.setText(_translate("Form", "查询："))
        self.pushbutton_searchflight.setText(_translate("Form", "刷新航班"))
        self.checkBox_3.setText(_translate("Form", "进港监控模式"))
        self.checkBox.setText(_translate("Form", "航班/记录显示切换"))
        self.checkBox_2.setText(_translate("Form", "隐藏保障结束航班"))
        self.label_15.setText(_translate("Form", "号码(加9)"))
        self.lineEdit_phonenum.setText(_translate("Form", "首次请配置IP电话"))
        self.pushButton_2.setText(_translate("Form", "拨号"))
        self.pushButton_3.setText(_translate("Form", "挂断"))
        self.pushButton_4.setText(_translate("Form", "再登陆"))
        self.label_2.setText(_translate("Form", "人员信息"))
        self.pushButton_searchpeople.setText(_translate("Form", "筛选"))
        self.pushButton_5.setText(_translate("Form", "清空筛选"))

    def getDragitem(self,name,js):
        self.getDragitemName = name
        #print("getDragitem%s%s%s"%(row,item,column))
        self.getDragitemJs=js
        print(name,js)


    def QthreadUpdate(self,ip,column,getDragitemName,flightid,displayMode,flighttype,selectedtime):
        th111 = QThread()
        self.updateDragDropThread111 = updateDragDrop("updateDragDropItem", ip, column, getDragitemName,flightid,th111,displayMode,flighttype,selectedtime)
        self.updateDragDropThread111.moveToThread(th111)
        th111.started.connect(self.updateDragDropThread111.run)
        th111.start()

    def getDropitem(self, row, column):
        if self.getDragitemName != "" and 9 < column < 16:
            olditem = self.tableWidgetFlight.item(row, column).text()
            print(column)
            if column==10 and self.getDragitemJs =="放行":
                self.tableWidgetFlight.setItem(row,column,QTableWidgetItem(self.getDragitemName))
                flightid=self.tableWidgetFlight.item(row, self.tableWidgetFlight.columnCount() - 5).text()
                flighttype = self.tableWidgetFlight.item(row, 9).text()
                self.QthreadUpdate(self.ipinfo, column, self.getDragitemName, flightid,self.displayMode,flighttype,self.selectedtime)
                #print(flightid)
                #print("放行栏")
            elif column !=10:
                self.tableWidgetFlight.setItem(row, column, QTableWidgetItem(self.getDragitemName))
                flightid = self.tableWidgetFlight.item(row, self.tableWidgetFlight.columnCount() - 5).text()
                flighttype= self.tableWidgetFlight.item(row, 9).text()
                self.QthreadUpdate(self.ipinfo, column, self.getDragitemName, flightid,self.displayMode,flighttype,self.selectedtime)
                #print(flightid)
                #print("其他栏")
            newitem = self.tableWidgetFlight.item(row, column).text()
            acno = self.tableWidgetFlight.item(row, 1).text()
            flightno = self.tableWidgetFlight.item(row, 4).text()
            bgtype = self.displayLabel[column]
            #ip = "http://" + str(self.ipinfo) + "/static/insertLogs2/" + "%s,%s%s由%s变更为%s/" % (acno, flightno, bgtype,olditem,newitem) + "%s/" % str(self.user) + "%s" % str(datetime.datetime.now())
            #requests.get(url=ip, timeout=30).json()
            api_fc.request_post("/static/insertLogs2",text="%s,%s%s由%s变更为%s/" % (acno, flightno, bgtype,olditem,newitem),name=str(self.user),time=str(datetime.datetime.now()))



