datetime
os
random
sys
PyQt5
Support function :
Add information
Modify the information
Delete the information
Query information
File storage data , Each run will load the information before the display
# Create a font object , Used to set the text to be displayed
font = QtGui.QFont()
font.setFamily(" In black ")
font.setPointSize(12)
# full name
label_name = QLabel(self)
label_name.setGeometry(40, 30, 54, 16)
label_name.setText(" full name :")
label_name.setFont(font)
self.line_edit_name = QLineEdit(self)
self.line_edit_name.setGeometry(90, 30, 141, 20)
# Gender
label_gender = QLabel(self)
label_gender.setGeometry(270, 30, 54, 16)
label_gender.setFont(font)
label_gender.setText(" Gender :")
self.line_edit_gender = QComboBox(self)
self.line_edit_gender.setGeometry(340, 30, 201, 20)
self.line_edit_gender.addItems([' male ', ' Woman '])
# Id card
label_id = QLabel(self)
label_id.setGeometry(580, 30, 54, 16)
label_id.setFont(font)
label_id.setText(" Id card :")
self.line_edit_id = QLineEdit(self)
self.line_edit_id.setGeometry(660, 30, 221, 20)
# Address
label_addr = QLabel(self)
label_addr.setGeometry(40, 110, 54, 16)
label_addr.setFont(font)
label_addr.setText(" Address :")
self.line_edit_addr = QLineEdit(self)
self.line_edit_addr.setGeometry(92, 110, 141, 20)
# Telephone
label_phone = QLabel(self)
label_phone.setGeometry(270, 70, 54, 16)
label_phone.setFont(font)
label_phone.setText(" Telephone :")
self.line_edit_phone = QLineEdit(self)
self.line_edit_phone.setGeometry(340, 70, 201, 20)
More information 、 Source code 、 Courseware & Error reporting solutions can be obtained by scanning the bottom