Solved

Getting Duplicate Column in Sales Quotes Screen (CR304500)

  • 2 October 2023
  • 6 replies
  • 68 views

Userlevel 4
Badge

I have two customizations. The main customization add fields for Margin and Margin % for the Quotes screen. 

This is the C# Code declaring them:

        #region UsrASGMarginPercent
[PXDBDecimal]
[PXUIField(DisplayName = "Margin %", Enabled = false)]
public virtual decimal? UsrASGMarginPercent { get; set; }
public abstract class usrASGMarginPercent : PX.Data.BQL.BqlDecimal.Field<usrASGMarginPercent> { }
#endregion

#region UsrASGMarginCury
[PXDBDecimal]
[PXUIField(DisplayName = "Margin", Enabled = false)]
public virtual decimal? UsrASGMarginCury { get; set; }
public abstract class usrASGMarginCury : PX.Data.BQL.BqlDecimal.Field<usrASGMarginCury> { }
#endregion

In the second Customization, I have added a field for Markup:


#region UsrASGMarkup
[PXDBDecimal]
[PXUIField(DisplayName = "Markup ", Enabled = false)]
public virtual decimal? UsrASGMarkup { get; set; }
public abstract class usrASGMarkup : PX.Data.BQL.BqlDecimal.Field<usrASGMarkup> { }
#endregion

Everything is fine, except when I publish the second project, I am getting a duplicate of the UsrASGMarginCury field.

I want to position the UsrASGMarginCury column next to the Margin % field, (using the column configurator) but it ignores me when I try, always putting them at the end:

 

In the past, when I have seen this behavior, it was because there were multiple customizations, all declaring the use of the column via the Acumatica App Customization screens. But, in this case, the second package never declares the margin field as part of its customization. It is unused in it:

Nor do I ever set it to visible within the C# code. It is also not part of any runtime code:

 

Where is this extra field coming from? If I unpublish the second package, it goes away, so I know it is coming from there somehow, but I can’t figure out from where?

Any ideas of where I can go to squash this cockroach?

icon

Best answer by mjgrice32 3 October 2023, 17:36

View original

6 replies

Userlevel 6
Badge +3

Hi @mjgrice32

Try to Unpublish all packages from the Customization projects screen and republish them.

You can also search for UsrASGMarginCury in Customization Project Editor - File menu - Edit Project XML.

If nothing helps, then please upload your both packages here and we can take a look at them.

 

Userlevel 7
Badge +17

Have you verified by clicking on the RESET TO DEFAULT ? @mjgrice32 

 

 

Userlevel 5
Badge +1

Hi everyone,

The column “Levels” is on Customization Project screen. It is level of customization during the publishing process. So you could enter level of each customization that you need then click “Publish” and Acumatica takes customizations then order them by level and publish to web site.

You need enter level ‘10’ for first customization and level ‘20’ from second customization. 

When Acumatica publishes customizations by level, the changes on UI (on aspx file of CR304500 screen) will be done depends from level.

Userlevel 6
Badge +3

@mjgrice32  Ideally, a screen should be added to just one customization project. you could try to add all changes to just one customization project and test if that fixes your issue.

Userlevel 4
Badge

Thanks for the suggestions.

First, one thing I forget to mention about this installation is that it is set up with an external file storage. So, the package information is actually coming from an Azure Blob file. IDK if that might be an issue. 

OK, so I went through all of the suggestions, and… no joy.

Here is a rundown on what I tried and what the results were:

  1. Publish and unplublish all.   YES. I’ve done this several times. No change
  2. RESET TO DEFAULT.         YES. No change
  3.  search for UsrASGMarginCury in Customization Project Editor -- It shows up one time only. (See below)
  4. Change  column “Levels” on Customization Project screen - I already did that. The project in question has the highest order.  (See below) 
  5.  “a screen should be added to just one customization project.” This has a couple of issues for me in this instance around how my company wishes to license things. Also, if this were true, then what do I do if, for example, my customer buys a 3rd party package that modifies a screen that I also need to modify? That isn’t allowed? Because our customers have packages from Biz-Tech as well as other integrators. I can’t make all of my changes in their packages (for obvious reasons).

XML Code: 

    <Page path="~/pages/cr/cr304500.aspx" ControlId="2" ">
<PXTabItem Text="Details" ParentId="phG_tab_Items#0" TypeFullName="PX.Web.UI.PXTabItem">
<Children Key="Template" />
</PXTabItem>
<PXGridLevel DataMember="Products" ParentId="phG_tab_Items#0_ProductsGrid_Levels#0" TypeFullName="PX.Web.UI.PXGridLevel">
<Children Key="Columns">
<AddItem>
<PXGridColumn TypeFullName="PX.Web.UI.PXGridColumn">
<Prop Key="DataField" Value="UsrASGMarkup" />
<Prop Key="Width" Value="100" />
<Prop Key="CommitChanges" Value="True" />
</PXGridColumn>
</AddItem>
<AddItem>
<PXGridColumn TypeFullName="PX.Web.UI.PXGridColumn">
<Prop Key="DataField" Value="UsrASGMarginCury" />
<Prop Key="Width" Value="100" />
<Prop Key="CommitChanges" Value="True" />
</PXGridColumn>
</AddItem>
<PXGridColumn DataField="IsConfigurable" OriginalIndex="0" />
</Children>
</PXGridLevel>
</Page>

Package level settings:

 

Userlevel 4
Badge

OK, actually. my previous reply is wrong. 

@Zoltan Febert suggestion was helpful. When he said: 

You can also search for UsrASGMarginCury in Customization Project Editor - File menu - Edit Project XML.

 

When I did that I saw that margin was found only once… however, I didn’t need it at all in this customization, so I deleted it in the XML source and saved it, and the issue went away.

So, that did work! Thanks.

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