Solved

Want to create DAC extension for the existing field in acumatica table

  • 16 March 2023
  • 7 replies
  • 278 views

Userlevel 3
Badge

Hi,

I need to know, If I created a DAC extension table for the POline table and create a orderType field for the DAC extension.

Is it possible to get same orderType column data inside in the POLine table into my DAC extension orderType field.

ex: POline row 1 OrderType is ‘standard’ and My DAC extension orderType is same to with ‘standard’ type.?

 

icon

Best answer by aaghaei 16 March 2023, 07:00

View original

7 replies

Userlevel 7
Badge +9

Sure but what is the benefit of redundant field? Also, You can not have duplicate names in the same table as OrderType already exists in the POLine table. You will need to read/watch the basics of customizations including naming conventions before starting the customization. All custom fields should start with Usr otherwise on updates Acumatica will DROP those fields which are not an Acumatica standard field and do not start with Usr.

This is a sample of adding a custom field to PMProject (Contract Table)

using PX.Data;

namespace PX.Objects.PM
{
// PMProject DAC Extension
[PXNonInstantiatedExtension]
public sealed class USRPMProjectExt : PXCacheExtension<PX.Objects.PM.PMProject>
{
public static bool IsActive() => true;

#region UsrField
public abstract class usrField : PX.Data.BQL.BqlInt.Field<usrField> { }
protected int? _UsrField;
[ActiveProjectTask(
typeof(PMProject.contractID),
CheckMandatoryCondition = typeof(Where<PMProject.isActive.FromCurrent.NoDefault.IsEqual<True>>),
DisplayName = "My Field")]
public int? UsrField
{
get
{
return this._UsrField;
}
set
{
this._UsrField = value;
}
}
#endregion
}
}

 

 

Userlevel 7
Badge +17

@jeewanishalika20  Why do you need to create the same field in the Extended DAC? what is the business scenario, behind this?

You cannot create the same field in the Extended DAC, Acumatica will not accept

Userlevel 7
Badge +9

@Naveen Boga  At the same time we were writing the same thing. funny 😂

Userlevel 7
Badge +9

@Naveen Boga It's funny. At the same time, we were writing the same comments :)

Userlevel 3
Badge

Hi @Naveen Boga ,

This is the related with the below issue.

We got a suggestion to create DAC extensions for  POOrder and POLine tables that we used in our customization.Using DAC extensions makes the tables independent from the original POOrder and POLine tables that’s requiring the Orderdate cannot be empty.

That’s why asking in here.

Userlevel 7
Badge +17

@aaghaei "Wow, what a coincidence!" :) 

Userlevel 7
Badge

Hi @jeewanishalika20 were you able to find a solution? Thank you!

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved