Item1095: EditTablePlugin: Hide ugly long CALC when editing replaced by static text CALC

pencil
Priority: Enhancement
Current State: Closed
Released In: 1.0.6
Target Release: patch
Applies To: Extension
Component: EditTablePlugin
Branches:
Reported By: ArthurClemens
Waiting For:
Last Change By: KennethLavrsen
Wouldn't it be nice to hide the CALC when editing a table. Of course only when it is in a label or header or footer.

-- ArthurClemens - 17 Feb 2009

Yes I have also seen this problem. I use looong CALC macros in footer rows or label columns and in edit mode this makes the columns very wide.

This problem occurs after we changed so that ETP does not change macros to the static value. This was a good and important change, but created this new issue.

It may not only be CALC but often is.

I have been thinking that maybe instead of showing the header and label fields as we do today, we show the value in a non-editable text field with same width as a non-header/footer field has, and maybe in gray to indicate that the content cannot be edited.

I do not know any way to truncate the visible text by CSS, but I believe it is possible to define a text field which is non-editable.

-- KennethLavrsen - 19 Feb 2009

Showing the value may be a problem when CALC copies another part of the table, for instance the selected values.

-- ArthurClemens - 19 Feb 2009

Putting the text inside a read-only textfield is a good idea.

This should only be done with label fields, otherwise the text is no longer editable.

Fix for 1.0.5

-- ArthurClemens - 06 Mar 2009

Reopening

Good you did not merge this over to Release01x00. And please do not before after 1.0.4 official release has been out for some days.

There are some side effects of this enhancement. Try testing a little more with multiple table on a topic. And try where the other tables also have CALC in them. They do not need to be tables with EDITTABLE tag. You will notice that this enhancement has the side effect that those CALCS are not rendered.

Another problem is that the non-edit field works for labels that are simple bold text. But not for a label column.

I will help with more testing when 1.0.4 is out. For now keep the changes to trunk and do not release the plugin to Extensions web until we have it stable.

I do look forward to having this enhancement stable. It will be very useful.

-- KennethLavrsen - 07 Mar 2009

Try testing a little more with multiple table on a topic. And try where the other tables also have CALC in them. They do not need to be tables with EDITTABLE tag. You will notice that this enhancement has the side effect that those CALCS are not rendered.

In fact I have tested this, and found no problem. Except for EDITROW, that does not render CALC when editing an edit table - but that is another plugin.

Another problem is that the non-edit field works for labels that are simple bold text. But not for a label column.

I don't know what that means. I have also tested this table, that contains a label column:

Item Description Qty Reason Unit Price Total Price
Hej Ho
4
Hello
50000
200000
Jah No
2
Hello
150000
300000
 
 
 
0
0
Total
 
 
 
500000

-- ArthurClemens - 07 Mar 2009

The first problem turned out to also be in Release01x00 branch and reported as Item1220

The 2nd problem happens on a table where I have two CALCs within a label

Item Cost (USD) Comments
Mechanics
600
All mechanical parts
Board A
400
Main board
Board B
350
Controller board
PSU
300
Power Supply
Filter
700
Noise filter
Package
200
Enclosure

Cost of Stations

Customer Pass Purpose Qty Mech Parts Main bd Control bd PSU Filter Package Cost (USD) When (Q)
Eng A
P1
Proto test
3
1
1
1
1
1
0
7050
Q309
Eng B
P1
Proto test
2
1
1
1
1
1
0
4700
Q309
SW Eng
P1
Proto test
3
1
1
1
1
1
0
7050
Q309
Controlbd
P1
Manuf test
2
1
1
1
1
1
0
4700
Q309
Eng A
P1
Main boards
10
0
1
0
0
0
0
4000
Q309
Eng B
P1
Main boards
20
0
1
0
0
0
0
8000
Q309
Eng B
P1
Control boards
10
0
0
1
0
0
0
3500
Q309
Eng A
P1
Control boards
5
0
0
1
0
0
0
1750
Q309
Eng A
P1
Mech samples
5
1
0
0
0
0
0
3000
Q209
Eng A
P1
Power supplies
3
0
0
0
1
0
1
1500
Q209
Eng A
P1
Filter samples
6
0
0
0
0
1
0
4200
Q209
Eng B
P2
Proto test
2
1
1
1
1
1
1
5100
Q409
SW Eng
P2
Proto test
6
1
1
1
1
1
0
14100
Q409
Eng A
P2
Product cert
8
1
1
1
1
1
1
20400
Q409
Rel Test
P2
Reliability
20
1
1
1
1
1
1
51000
Q409
Sys Test
P2
System Test Dept
8
1
1
1
1
1
0
18800
Q409
Controlbd
P2
Manuf
2
1
1
1
1
1
1
5100
Q409
Eng A
P2
Main boards
10
0
1
0
0
0
0
4000
Q409
Eng B
P2
Main boards
20
0
1
0
0
0
0
8000
Q409
Eng A
P2
Control boards
10
0
0
1
0
0
0
3500
Q409
Eng A
P2
Control boards
5
0
0
1
0
0
0
1750
Q309
Eng A
P2
Power supplies
3
0
0
0
1
0
0
900
Q409
Eng A
P2
Filter samples
20
0
0
0
0
1
0
14000
Q409
Eng A
A
Pilot validation
2
1
1
1
1
1
1
5100
Q210
SW Eng
A
Proto test
6
0
1
1
0
0
0
4500
Q210
Total
 
 
191
63
124
94
64
84
37
205700
 

-- KennethLavrsen - 08 Mar 2009

With the code refactoring with Item1406, the ugly raw CALCs have gone. Instead they are now replaced by faulty calculations. It looks better, but I can imagine this will lead to misinterpretations.

So I am still in favor of replacing the calculations by something like: FORMULA .

-- ArthurClemens - 14 Jun 2009

We actually got this fully fixed in Item1726. So setting this in WaitingForRelease as the 1726 also fixed a bug. This way both the fix and the enhancement goes in release notes

-- KennethLavrsen - 15 Jun 2009

ItemTemplate edit

Summary EditTablePlugin: Hide ugly long CALC when editing replaced by static text CALC
ReportedBy ArthurClemens
Codebase
SVN Range Foswiki-1.0.0, Thu, 08 Jan 2009, build 1878
AppliesTo Extension
Component EditTablePlugin
Priority Enhancement
CurrentState Closed
WaitingFor
Checkins distro:15f78f1a598a
TargetRelease patch
ReleasedIn 1.0.6
Topic revision: r13 - 22 Jun 2009, KennethLavrsen
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy