View Issue Details

IDProjectCategoryView StatusLast Update
0025372mantisbtcustom fieldspublic2019-09-26 16:42
Reportersmartmantis Assigned Todregad  
Status closedResolutionduplicate 
Product Version2.19.0 
Summary0025372: custom fields with default value unable to saved ot database if they are not on the report issue page

If i have a custom field with default value but the field is not shown on the report issue page, it's not saved to the database.

Steps To Reproduce

Something went wrong in the new bug_report.php somewhere here:

# Produce an error if the field is required but wasn't posted
if( gpc_isset_custom_field( $t_id, $t_def['type'] ) ) {
  $t_custom_fields[] = array('field' => array( 'id' => $t_id ),'value' => gpc_get_custom_field( 'custom_field_' . $t_id, $t_def['type'], null ));
  1. this is not generate errors anymore, maybe comment left there from the old bug_report.php where this if has one more parameter && $t_def['require_report'] and trigger an error, not build the $t_custom_fields array.
  2. gpc will never check any default value and never call the custom function of the custom field (#function_string_value).
TagsNo tags attached.


duplicate of 0026151 new Custom fields required but not displayed should be filled with the default value 




2019-08-22 11:01

reporter   ~0062627

I'm also experiencing this error.

Issue History

Date Modified Username Field Change
2019-01-23 10:00 smartmantis New Issue
2019-08-22 11:01 zeroion Note Added: 0062627
2019-08-23 03:48 dregad Steps to Reproduce Updated View Revisions
2019-09-17 08:06 dregad Assigned To => dregad
2019-09-17 08:06 dregad Status new => resolved
2019-09-17 08:06 dregad Resolution open => duplicate
2019-09-17 08:06 dregad Relationship added duplicate of 0026151
2019-09-26 16:42 atrol Status resolved => closed