New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TableRecordId relation types to support Prefix_AD_Table_ID and Prefix_Record_ID #3058

Closed
metas-rc opened this Issue Nov 23, 2017 · 1 comment

Comments

Projects
None yet
3 participants
@metas-rc
Member

metas-rc commented Nov 23, 2017

Is this a bug or feature request?

  • FR

What is the current behavior?

  • In the task #2340 I implemented the support for generic, sourceless relation types that point to tables with AD_Table_ID and Record_ID columns.

Which are the steps to reproduce?


What is the expected or desired behavior?

  • Implement support also for the Prefix_table_ID and Prefix_Record ID
  • Make sure the relation works for each pair, even if the referenced table has multiple such pairs!

See de.metas.dlm.partitioner.config.TableReferenceDescriptor

@metas-rc metas-rc self-assigned this Nov 23, 2017

metas-rc added a commit that referenced this issue Nov 29, 2017

#3058 TableRecordIdDescriptor
* rename it
* move it lower so it can be use dby other projects too, not only DLM
#3058

metas-rc added a commit that referenced this issue Nov 29, 2017

#3058 Move DAO methods for TableRecordIdReferences so they can be acc…
…essed from anywhere

* Note that they are no longer DLM specific
#3058

metas-rc added a commit that referenced this issue Nov 29, 2017

metas-rc added a commit that referenced this issue Nov 29, 2017

#3058 referencedRecordId deleted + refactoring
* Got rid of a parameter that was only used in tests
* Refactored TableRecordIdDescriptor  so it is easier to understand (
especially the fields)
* Refactoring that came with the above
#3058

metas-rc added a commit that referenced this issue Nov 29, 2017

metas-rc added a commit that referenced this issue Nov 29, 2017

metas-rc added a commit that referenced this issue Dec 4, 2017

metas-rc added a commit to metasfresh/metasfresh-webui-api that referenced this issue Dec 4, 2017

metas-rc added a commit that referenced this issue Dec 4, 2017

metas-rc added a commit that referenced this issue Dec 4, 2017

metas-ts added a commit that referenced this issue Dec 10, 2017

Update ReleaseNotpes.md
[#727](metasfresh/metasfresh-webui-api#727)
Allow search of Subproducer
[#3079](#3079) Warehouse
picking group
[#1421](metasfresh/metasfresh-webui-frontend#1421)
Drop down lists remain displayed when using tab several times
[#3150](#3150) Always
keep Terms & Conditions equal per Compensation Group
[#714](metasfresh/metasfresh-webui-api#714)
login authenticate: provide an unique key for each JSONLoginRole
[#1404](metasfresh/metasfresh-webui-frontend#1404)
login form selects 2 items from roles dropdown
[#3174](#3174) Material
Receipt Candidates not generates when using Purchase Order from Sales
Order action
[#1406](metasfresh/metasfresh-webui-frontend#1406)
Can not enter "-" into any text field
[#721](metasfresh/metasfresh-webui-api#721)
picking terminal: HUs to pick: scan/filter by Locator
[#722](metasfresh/metasfresh-webui-api#722)
picking terminal: picking slot rows shall NOT have duplicate IDs
[#3139](#3139) Cannot
edit System Administrator role (AD_Role_ID=0)
[#1396](metasfresh/metasfresh-webui-frontend#1396)
View field editor: Patch request isn't sent after hit enter
[#3171](#3171) Add view
to keep track of unprocessed async work packages
[#3149](#3149) Automatic
Discount for Group Products
[#1414](metasfresh/metasfresh-webui-frontend#1414)
view: don't allow user to sort by a given column if layout says so
[#1425](metasfresh/metasfresh-webui-frontend#1425)
eslint: increase line max-len from 80 to 120.
[#716](metasfresh/metasfresh-webui-api#716)
picking terminal: scan picking slot by barcode
[#723](metasfresh/metasfresh-webui-api#723)
picking terminal: HUs to pick: Pick CUs process
[#3137](#3137) Clean
C_PaySelection
[#3160](#3160)
C_Printing_Queue_ReEnqueue with IsSelected doesn't work
[#713](metasfresh/metasfresh-webui-api#713)
Error creating bean with name 'scopedTarget.internalUserSessionData'
[#1383](metasfresh/metasfresh-webui-frontend#1383)
cannot completely delete a numeric field in grid view
[#3138](#3138) Import
BPartner window: cannot see data
[#2340](#2340) Relation
Type: changelog
[#3151](#3151)
ZoomTo-Performance Issues
[#3147](#3147) Errors wrt
C_BPartner SQL columns
[#2338](#2338) Relation
Type: fact_accounts
[#3110](#3110) Request
All does not show records
[#1407](metasfresh/metasfresh-webui-frontend#1407)
process result: open included view: handle profileId property
[#3105](#3105) Improve
Product import process
[#711](metasfresh/metasfresh-webui-api#711)
picking terminal: additional shall support grouping lines by order
[#3058](#3058)
TableRecordId relation types to support Prefix_AD_Table_ID and
Prefix_Record_ID
[#3126](#3126) Solve
issues around standalone report / jasper service
[#1393](metasfresh/metasfresh-webui-frontend#1393)
View attributes: consider row's supportAttributes property before
querying for attributes
[#1361](metasfresh/metasfresh-webui-frontend#1361)
View field editor: make sure the field value is sent to backend before
the view is deleted

@metas-lc metas-lc self-assigned this Dec 12, 2017

@metas-rc

This comment has been minimized.

Show comment
Hide comment
@metas-rc

metas-rc Dec 12, 2017

Member

Docu about how we tested:

Part I - How to create the required tables and relation for testing

  • Create a table TargetTest, with the basic columns (copied from Table Template ), add it in the database
  • Create a window for the table above
  • Add the window in the menu
  • Create a table PrefixTest, with the basic columns (copied from Table Template ), add it in the database
  • Create a window for the table above
  • Add the window in the menu
  • Create a table OriginTest
  • Add the basic columns(copied from Table Template )
  • Add the column AD_Table_ID, Table Direct
  • Add the column Record_ID, numeric
  • Add the column Prefix_AD_Table_ID, search, reference to the table "AD_Table"
    NOTE: Pay attention to the case. The suffixes "AD_Table_ID" and "Record_ID" are hardcoded in the code and must look exactly like this: "AD_Table_ID" and "Record_ID"
  • Add the table and columns to the db
  • Create a window for the table above
  • Add the window in the menu
  • Create an AD_Reference, (ex. name OriginTest)
    ** Type: Tablevalidation
    • AD_Ref_Table OriginTest, key OriginTest_ID, Display OriginTestID, window OriginTest
  • Create a relation type:
    ** IsTableRecordIdTarget = Y
    ** AD_Reference_Target_ID = the reference above (OriginTest)

Part II - how to test

  1. Basic test case - with AD_Table_ID and Record_ID
  • Create an entry in the window TargetTest (copy its ID, let's say it's 1000000)
  • Create an entry in the window OriginTest
    ** AD_Table_ID = TargetTest
    ** Record_ID = the ID of the targetTest entry (e.g. 1000000)
  • Go to TargetTest, zoom
  • => OK: got the OriginTest entry as result

Note: For the first test case, we already have real cases: Fact_Acct and AD_ChangeLog (#2338 and #2340)

  1. Test case with Prefix
  • Create an entry in the window PrefixTest (copy its ID, let's say it's 1000000)
  • Create an entry in the window OriginTest
    ** PrefixTest_AD_Table_ID = PrefixTest
    ** PrefixTest_Record_ID = the ID of the prefixTest entry (e.g. 1000000)
  • Go to PrefixTest, zoom
  • => OK: got the OriginTest entry as result

Note: For this second test we don't have any relation, yet, but we need to support the case too, since the Prefix_AD_Table_ID and Prefix_Record_ID are eligible columns already.

Member

metas-rc commented Dec 12, 2017

Docu about how we tested:

Part I - How to create the required tables and relation for testing

  • Create a table TargetTest, with the basic columns (copied from Table Template ), add it in the database
  • Create a window for the table above
  • Add the window in the menu
  • Create a table PrefixTest, with the basic columns (copied from Table Template ), add it in the database
  • Create a window for the table above
  • Add the window in the menu
  • Create a table OriginTest
  • Add the basic columns(copied from Table Template )
  • Add the column AD_Table_ID, Table Direct
  • Add the column Record_ID, numeric
  • Add the column Prefix_AD_Table_ID, search, reference to the table "AD_Table"
    NOTE: Pay attention to the case. The suffixes "AD_Table_ID" and "Record_ID" are hardcoded in the code and must look exactly like this: "AD_Table_ID" and "Record_ID"
  • Add the table and columns to the db
  • Create a window for the table above
  • Add the window in the menu
  • Create an AD_Reference, (ex. name OriginTest)
    ** Type: Tablevalidation
    • AD_Ref_Table OriginTest, key OriginTest_ID, Display OriginTestID, window OriginTest
  • Create a relation type:
    ** IsTableRecordIdTarget = Y
    ** AD_Reference_Target_ID = the reference above (OriginTest)

Part II - how to test

  1. Basic test case - with AD_Table_ID and Record_ID
  • Create an entry in the window TargetTest (copy its ID, let's say it's 1000000)
  • Create an entry in the window OriginTest
    ** AD_Table_ID = TargetTest
    ** Record_ID = the ID of the targetTest entry (e.g. 1000000)
  • Go to TargetTest, zoom
  • => OK: got the OriginTest entry as result

Note: For the first test case, we already have real cases: Fact_Acct and AD_ChangeLog (#2338 and #2340)

  1. Test case with Prefix
  • Create an entry in the window PrefixTest (copy its ID, let's say it's 1000000)
  • Create an entry in the window OriginTest
    ** PrefixTest_AD_Table_ID = PrefixTest
    ** PrefixTest_Record_ID = the ID of the prefixTest entry (e.g. 1000000)
  • Go to PrefixTest, zoom
  • => OK: got the OriginTest entry as result

Note: For this second test we don't have any relation, yet, but we need to support the case too, since the Prefix_AD_Table_ID and Prefix_Record_ID are eligible columns already.

@metas-rc metas-rc closed this Dec 12, 2017

@metas-rc metas-rc reopened this Dec 12, 2017

@metas-lc metas-lc closed this Dec 13, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment