(parent, title)
| 920 | |
| 921 | |
| 922 | def create_show_details_page2(parent, title): |
| 923 | page, main_layout = create_page_with_header(parent, title) |
| 924 | content_frame = create_styled_frame(page) |
| 925 | content_frame.setSizePolicy( |
| 926 | QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding |
| 927 | ) |
| 928 | content_layout = QtWidgets.QVBoxLayout(content_frame) |
| 929 | |
| 930 | form_frame = create_styled_frame( |
| 931 | content_frame, |
| 932 | min_size=(400, 200), |
| 933 | style="background-color: #ffffff; border-radius: 15px; padding: 10px;", |
| 934 | ) |
| 935 | form_layout = QtWidgets.QVBoxLayout(form_frame) |
| 936 | form_frame.setSizePolicy( |
| 937 | QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Expanding |
| 938 | ) |
| 939 | form_layout.setSpacing(3) |
| 940 | |
| 941 | # Define input fields |
| 942 | |
| 943 | labeles = [ |
| 944 | "Account No: ", |
| 945 | "Name: ", |
| 946 | "Age:", |
| 947 | "Address: ", |
| 948 | "Balance: ", |
| 949 | "Mobile Number: ", |
| 950 | "Account Type: ", |
| 951 | ] |
| 952 | for i in range(len(labeles)): |
| 953 | label_frame, input_field = create_input_field( |
| 954 | form_frame, labeles[i], min_label_size=(180, 30) |
| 955 | ) |
| 956 | form_layout.addWidget(label_frame) |
| 957 | input_field.setReadOnly(True) |
| 958 | input_field.setFont(QtGui.QFont("Arial", 12)) |
| 959 | if i == 0: |
| 960 | account_no_field = input_field |
| 961 | elif i == 1: |
| 962 | name_field = input_field |
| 963 | elif i == 2: |
| 964 | age_field = input_field |
| 965 | elif i == 3: |
| 966 | address_field = input_field |
| 967 | elif i == 4: |
| 968 | balance_field = input_field |
| 969 | elif i == 5: |
| 970 | mobile_number_field = input_field |
| 971 | elif i == 6: |
| 972 | account_type_field = input_field |
| 973 | |
| 974 | exite_btn = create_styled_button(form_frame, "Exit", min_size=(100, 50)) |
| 975 | exite_btn.setStyleSheet(""" |
| 976 | QPushButton { |
| 977 | background-color: #6c757d; |
| 978 | color: white; |
| 979 | border: none; |
no test coverage detected