コード例 #1
0
        public CreateInvoiceOperation(IIntacctSession session, IntacctInvoice invoice) : base(session, "create_invoice", "key")
        {
            if (invoice == null)
            {
                throw new ArgumentNullException(nameof(invoice));
            }

            _invoice = invoice;
        }
コード例 #2
0
        public GetEntityOperation(IIntacctSession session, string entityId, bool isExtenalKey = false) : base(session, "get", "data", mayHaveEmptyResult: true)
        {
            if (entityId == null)
            {
                throw new ArgumentNullException(nameof(entityId));
            }
            if (string.IsNullOrWhiteSpace(entityId))
            {
                throw new ArgumentException($"Argument {nameof(entityId)} may not be empty.", nameof(entityId));
            }

            _entityName   = GetObjectName <TEntity>();
            _entityId     = entityId;
            _isExtenalKey = isExtenalKey;
        }
コード例 #3
0
 protected IntacctOperationBase(IIntacctSession session, string functionName, string resultElementName, bool mayHaveEmptyResult) : this(functionName, resultElementName, mayHaveEmptyResult)
 {
     _session = session;
 }
コード例 #4
0
 private static XElement CreateAuthSessionElement(IIntacctSession session)
 {
     return(new XElement("sessionid", session.SessionId));
 }
コード例 #5
0
 public CreateCustomerOperation(IIntacctSession session, IntacctCustomer customer) : base(session, "create_customer", "key")
 {
     _customer = customer;
 }
コード例 #6
0
 protected IntacctAuthenticatedOperationBase(IIntacctSession session, string functionName, string responseElementName, bool mayHaveEmptyResult = false) : base(session, functionName, responseElementName, mayHaveEmptyResult)
 {
 }