我正在尝试在交易屏幕CA304000上的Acumatica中的Actions下添加一个选项。请参阅下面我要实现的目标:
using System;
using System.Collections;
using System.Collections.Generic;
using PX.Data;
using PX.Objects.Common;
using PX.Objects.AP;
using PX.Objects.CM;
using PX.Objects.CS;
using PX.Objects.GL;
using PX.Objects.IN;
using PX.Objects.TX;
using PX.Objects.EP;
using PX.Objects.CR;
using Avalara.AvaTax.Adapter;
using Avalara.AvaTax.Adapter.TaxService;
using AvaAddress = Avalara.AvaTax.Adapter.AddressService;
using AvaMessage = Avalara.AvaTax.Adapter.Message;
using CRLocation = PX.Objects.CR.Standalone.Location;
using PX.Objects;
using PX.Objects.CA;
namespace PX.Objects.CA
{
public class CATranEntry_Extension:PXGraphExtension<CATranEntry>
{
#region Event Handlers
public override void Initialize()
{
Base.action.AddMenuAction(ShowURL);
}
public PXAction<CAAdj> ShowURL;
[PXUIField(DisplayName = "Phieu Thu")]
[PXButton]
protected virtual void showURL()
{
CAAdj doc = Base.Document.Current;
if (doc.RefNbr != null)
{
throw new PXReportRequiredException(doc, "TNCA6401", null);
}
}
#endregion
}
}
然而,这告诉我('PX.Objects.CA.CATranEntry'不包含'Document'的定义,也没有扩展方法'Document'接受'PX.Objects.CA类型的第一个参数。可以找到CATranEntry两次。
此TNCA6401只有一个参数编号。请具体(图片是最好的)。我是Noob。谢谢。