Skip to content

fix: prefill template fields with meta default on new ticket page - #3675

Open
RitvikSardana wants to merge 2 commits into
frappe:developfrom
RitvikSardana:fix/template-field-default
Open

RitvikSardana wants to merge 2 commits into
frappe:developfrom
RitvikSardana:fix/template-field-default

Conversation

@RitvikSardana

Copy link
Copy Markdown
Member

Template fields on the new ticket page were always initialized empty, ignoring the field's default set in meta (DocField / Custom Field / Property Setter).

  • get_one API now returns default for each template field
  • New ticket page prefills the field value with it

Test: set a default on an HD Ticket field via Customize Form, add it to the ticket template, open the new ticket page. The field comes prefilled.

🤖 Generated with Claude Code

@codecov-commenter

codecov-commenter commented Aug 5, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 74.30%. Comparing base (c037dcf) to head (f5ed4d0).
⚠️ Report is 249 commits behind head on develop.

Files with missing lines Patch % Lines
...elpdesk/helpdesk/doctype/hd_ticket_template/api.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3675      +/-   ##
===========================================
+ Coverage    71.63%   74.30%   +2.66%     
===========================================
  Files          145      149       +4     
  Lines        10106    11082     +976     
===========================================
+ Hits          7239     8234     +995     
+ Misses        2867     2848      -19     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@RitvikSardana
RitvikSardana marked this pull request as ready for review August 6, 2026 07:46
@mergify

mergify Bot commented Aug 6, 2026

Copy link
Copy Markdown

Tick the box to add this pull request to the merge queue (same as @mergifyio queue).

  • Queue this pull request

@greptile-apps

greptile-apps Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains.

Reviews (2): Last reviewed commit: "fix: normalize Check field defaults on t..." | Re-trigger Greptile

Comment thread desk/src/pages/ticket/TicketNew.vue Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants