harmonia form: a boolean (checkbox) field is marked required with *, though unchecked is a valid answer
Maintainer thường phản hồi trong vòng 1 ngày
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 82/100
Hướng nghiên cứu
Bắt đầu với nhánh hộp kiểm trong ui/perspective/manage/form-view.html.template ở khoảng dòng 383, sau đó kiểm tra các nhánh tương ứng trong năm mẫu biểu mẫu và tài liệu khác được liệt kê trong issue. Chỉ xóa dấu hoa thị biểu thị trường bắt buộc đối với các trường hộp kiểm, đồng thời giữ lại dấu này cho các widget khác; xác nhận rằng biểu mẫu được tạo không hiển thị dấu hoa thị cho hộp kiểm và các trường bắt buộc khác vẫn hiển thị dấu này.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Problem
In a generated Harmonia form, a boolean field (CHECKBOX) is marked required with a red *, although an unchecked box is a valid answer (false). The user cannot "skip" a checkbox, so the asterisk only suggests that the box must be ticked.
Steps to reproduce
- Open Tax Rates (
tax-ratesmodule), e.g./services/web/tax-rates/gen/tax-rates/index.html#/TaxRate. - Press + New (or open an existing row for edit).
- The Base checkbox ("Базова" in Bulgarian) shows a red
*. - Leave it unticked, fill in the other fields, save → the record is saved with
Base = false.
Expected: no * on a checkbox.
Cause
The Base column is NOT NULL, so the model marks the property required (isRequiredProperty == "true"). The CHECKBOX branch of the form templates adds the asterisk exactly as the other widgets do, e.g. template-application-ui-harmonia-java/ui/perspective/manage/form-view.html.template:383:
<label x-h-label for="f_${property.name}">...#if($property.isRequiredProperty == "true") <span class="text-negative">*</span>#end</label>
A checkbox always submits a value (the form initialises it to false), so for a boolean the NOT NULL is always satisfied.
Suggested fix
Drop the asterisk from the CHECKBOX branch in every form template that has it:
ui/perspective/manage/form-view.html.template(383)ui/perspective/document/document-view.html.template(321)ui/my/my-form-view.html.template,ui/my/my-document-view.html.templateui/partner/partner-form-view.html.template,ui/partner/partner-document-view.html.template
The non-checkbox branches keep it.
- Ngôn ngữ chính
- Java
- Star
- 278
- Fork
- 97
- Merge trung bình
- 12 giờ 43 phút
- Pull request đã merge (30 ngày)
- 296
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của eclipse-dirigible/dirigible
-
harmonia list: the record sheet's title collapses to 0 height when the record's properties overflow the sheetCó thể đã có người làm @NicoleNG18 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
eclipse-dirigible/dirigible#8570 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
intent checks: a soft duplicate warning is asked again on every update, even when its fields did not changeCó thể đã có người làm @NicoleNG18 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
eclipse-dirigible/dirigible#8568 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
harmonia list: search ignores what relation columns show - matches the key, not the labelCó thể đã có người làm @NicoleNG18 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
eclipse-dirigible/dirigible#8561 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
eclipse-dirigible/dirigible#8548 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
eclipse-dirigible/dirigible#8354 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của eclipse-dirigible/dirigible
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
wultra/powerauth-tests#980 ·
-
account bug communication lecture
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
line/centraldogma#1397 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 78/100
cryptomator/hub#515 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
vert-x3/vertx-mail-client#268 ·