简体   繁体   English

将自定义操作添加到账单和调整 (AP301000) 屏幕上操作菜单的特殊文件夹

[英]Adding custom action to Special Folders of action menu on Bills and Adjustments (AP301000) screen

I would like to add a custom action to the Bills and Adjustments (AP301000) screen which navigates to a report.我想向导航到报告的账单和调整 (AP301000) 屏幕添加自定义操作。 I want to add the action to the special folder in acumatica (action menu) as shown on screenshot 1 where the red line is.我想将操作添加到 acumatica(操作菜单)中的特殊文件夹,如屏幕截图 1 所示,红线所在的位置。

Screenshot 1: Action Menu截图 1:操作菜单

截图 1:操作菜单

Below code is used to add the action to the menu下面的代码用于将操作添加到菜单

  public class APInvoiceEntry_Extension : PXGraphExtension<PX.Objects.AP.APInvoiceEntry>
    {
 public override void Initialize()
         {
            base.Initialize();

            //this added the report to the reports menu

            Base.report.AddMenuAction(SupplierInvoice);



        }
            
        public PXAction<PX.Objects.AP.APInvoice> SupplierInvoice;

        [PXButton(CommitChanges = true)]
        [PXUIField(DisplayName = "Supplier Invoice")]
        protected void supplierInvoice()
        {
            if (Base.Document.Current.RefNbr != string.Empty)
            {
                //create parameters for report! Check report by editing it to see what reports are needed
                Dictionary<string, string> parameters = new Dictionary<string, string>();

                parameters["RefNbr"] = Base.Document.Current.RefNbr.ToString();
                parameters["DocType"] = Base.Document.Current.DocType;

                //the report number gets set below and parameters are sent with


                throw new PXReportRequiredException(parameters, "AP641500");


            }
        }

        }
}

The error which I get is shown in below screenshot我得到的错误显示在下面的屏幕截图中

Screenshot 2: Code error截图 2:代码错误

截图 2:代码错误

The issue I encountered is that the report folder for the Bills and Adjustments (AP301000) screen in the screen editor of the customization does not the Layout Properties as shown in the screenshot below:我遇到的问题是自定义的屏幕编辑器中的账单和调整(AP301000)屏幕的报告文件夹没有布局属性,如下面的屏幕截图所示:

Screenshot 3: Bill and Adjustments (AP301000) Screen Editor屏幕截图 3:账单和调整 (AP301000) 屏幕编辑器

屏幕截图 3:账单和调整 (AP301000) 屏幕编辑器

The Acumatica Version I am currently using is: 22.101.0085我目前使用的 Acumatica 版本是:22.101.0085

How could I possibly fix the error in order to add the action in the action menu of the screen?我怎么可能修复错误以便在屏幕的操作菜单中添加操作?

You can apply a Category to the action that should position it correctly in the category:您可以将类别应用到应该在类别中正确定位的操作:

public override void Initialize()
{
    base.Initialize();
    SupplierInvoice.SetCategory("Reports");   
}

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 帐单和调整屏幕 AP301000 在详细信息部分显示库存 ID,但在 BillDetail 类中没有 InventoryID 属性 - Bills and Adjustment Screen AP301000 shows Inventory ID in Detail Section, yet no InventoryID property in BillDetail class 如何参考我在AP301000中创建的客户字段 - How to reference customer field which I created in AP301000 从“账单和调整”屏幕上的按钮打开弹出的自定义Acumatica屏幕 - Open custom Acumatica screen as popup from button on Bills and Adjustments screen 使用图形对象将记录插入到AP帐单和调整中 - Using graph object to insert records into AP Bills and Adjustments 如果要在Acumatica的Bills and Adjustments屏幕上的Application选项卡Menu中自定义,使用哪种方法或事件处理程序 - In which method or event handler if I would to customize in Application tab Menu in screen Bills And Adjustments of Acumatica 向 Acumatica 客户表单添加自定义操作菜单 - Adding custom action menu to Acumatica Customer form 如何将 PO301000 上的 Add Email (NewMailActivity) 操作移动到操作菜单中? - How can I move the Add Email (NewMailActivity) action on PO301000 into the Actions menu? 无法使用报价屏幕 CR304500 中的操作打开 SO 屏幕 SO301000 - Unable to open SO screen SO301000 using Action from Quote screen CR304500 如何从审批屏幕链接回账单和调整以获取记录? - How can I link back to Bills and Adjustments for a record from the Approvals screen? 根据账单和调整中的自定义日期字段计算发票日期和折扣日期 - Calculate Invoice Date and Discount Date based on Custom Date field in Bills and Adjustments
相关标签
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM