Loading...
 
Skip to main content

Item Link field creation doesn't work right

Status
Closed
Subject
Item Link field creation doesn't work right
Version
2.x
Category
  • Error
  • Usability
Feature
Trackers
Edit interface (UI)
Resolution status
Fixed or Solved
Submitted by
mrisch
Volunteered to solve
mrisch
Lastmod by
mrisch
Rating
(0)
Description

I am using the "Item List" field in one tracker with "Item Link" in the other. It works well, but when I click on "Insert new item" the new item should automatically select the proper field value that is tied to whatever tracker item generated the request. As it stands now, you have to drop the list down and manually select the correct linked item, but that can be a real pain when the tracker gets big.

I've tracked the problem - it appears that the issue is in tiki-view_tracker_item.tpl. The code to set up the link is here:

<div style="clear:both;text-align:right;"><a href="tiki-view_tracker.php?trackerId={$cur_field.options_array0}&vals%5B{$cur_field.options_array1}%5D=

{section name=ox loop=$ins_fields}
{if $ins_fieldsox.fieldId eq $cur_field.options_array2}
{$ins_fieldsox.value}
{/if}
{/section}
">Insert new item{/tr}

</div>


However, when you have a two item link (e.g. 8,37,31|32,38,1), then cur_field.options_array2 never matches any ins_fields{ox].value, and consequently that part of the vals parameter is always blank.

Solution

tracker view and tracker item view templates were both broken.

Importance
7
Priority
35
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
1479
Created
Thursday 10 January, 2008 16:14:43 UTC
by Unknown
LastModif
Sunday 01 June, 2008 16:40:42 UTC


Show PHP error messages