Bug 370802 - Declare columns order in the tableConfiguration file
Summary: Declare columns order in the tableConfiguration file
Status: NEW
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EMF-Facet (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P2 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 380293 380298
Blocks:
  Show dependency tree
 
Reported: 2012-02-07 05:08 EST by Vincent Lorenzo CLA
Modified: 2020-05-01 11:26 EDT (History)
1 user (show)

See Also:
gdupe: juno+
gdupe: luna+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent Lorenzo CLA 2012-02-07 05:08:37 EST
When you have customized tables, often you restrict to 1 element the elements which can be presented in the table. So you know which columns will appears in your table, and all these columns will be created with the first drop in the table. In this case, it should be interesting to define the order of these columns in the tableConfiguration file. I propose to add the following field to this file : 

<eStructuralFeatures xsi:type="ecore:EReference" name="columnOrder" upperBound="-1"
        eType="ecore:EClass http://www.eclipse.org/emf/2002/Ecore#//EStructuralFeature"/>
        
This field will be used to define the column order, but only when the first element is added to the table.
We shouldn't reuse it for others elements for 2 main reasons : 
	1/ the user can have change the column order between the first and the 2nd dropped element
	2/ If many kind of elements can be dropped into the table, the 2nd element can add columns, I think that these columns should be added at the end of the table.
Comment 1 Gregoire Dupe CLA 2012-03-08 04:26:10 EST
Hello,

> This field will be used to define the column order, but only when the first element is added to the table.
>We shouldn't reuse it for others elements for 2 main reasons : 
>    1/ the user can have change the column order between the first and the 2nd dropped element
>    2/ If many kind of elements can be dropped into the table, the 2nd element can add columns, I think that these columns should be added at the end of the table.

This looks to complicate to be easily to understand by the users (without reading the documentation)
I think that it would be better to create all the columns declare by the user when no column exists in the table, even if the table contains no row.
The additional reference’s type must be ETypedElement otherwise we will not be able to managed the operations.

<eStructuralFeatures xsi:type="ecore:EReference" name="columnOrder"
  upperBound="-1" eType="ecore:EClass http://www.eclipse.org/emf/2002/Ecore#//ETypedElement"/>

Regards,
Grégoire
Comment 2 Gregoire Dupe CLA 2012-03-08 04:51:11 EST
To anticipate the API freeze I've updated the meta-model.

Committed revision 1769.