QuickBooks에서 반환 된 totalRevenue 필드 온라인 API는 항상 null입니다.

StackOverflow https://stackoverflow.com//questions/20018849

  •  21-12-2019
  •  | 
  •  

문제

QuickBooks 온라인 v3 API의 PHP SDK를 사용하고 있습니다.나는 DataService 및 QueryMessage를 통해 전체 고객 별 레코드를 포함하는 객체 배열을 반환하는 QueryMessage를 통해 쿼리를 실행하고 있습니다.이름 / 주소 / 전화 번호 / 균형 기한 / 연체 균형 등

모든 것이 잘 작동하지만 키는 "totalRevenue"가 주어지며 그 값은 항상 "null"로 반환됩니다.온라인으로 QuickBooks에서 테스트 데이터를 사용하여 여러 개의 사전 판매 된 트랜잭션을 만들었습니다.그러나 저는 균형, 지난 균주 및 기타 회계 관련 분야를 조작 할 수 있습니다.TotalRevenue의 문제는 무엇입니까?QuickBooks가 꺼져있는 것에 대해 QuickBooks가 꺼지고 있습니다.하지만 확인을 원합니다 :)

편집 : QuickBooks의 온라인 API 탐색기를 확인하고 고객 테이블을 쿼리 할 때 "totalRevenue"를 반환하지 않습니다.

코드 :

    // Prep Data Services
    $dataService = new DataService($serviceContext);

    // Build a query
    $oneQuery = new QueryMessage();
    $oneQuery->sql = "SELECT";
    $oneQuery->entity = "Customer";
    $oneQuery->orderByClause = "FamilyName";
    $oneQuery->startposition = "1";
    $oneQuery->maxresults = "50";

    // Run a query
    $queryString = $oneQuery->getString();
    $entities = $dataService->Query($queryString);

    // Echo some formatted output
    var_dump($entities);
.

var_dump 출력 :

    [0]=>
  object(IPPCustomer)#29 (62) {
    ["Taxable"]=>
    string(4) "true"
    ["BillAddr"]=>
    object(IPPPhysicalAddress)#68 (16) {
      ["Id"]=>
      string(4) "55555"
      ["Line1"]=>
      string(22) "123 ABC St"
      }

      ...

    ["Notes"]=>
    string(20) "These are some notes"
    ["Job"]=>
    string(5) "false"
    ["BillWithParent"]=>
    string(5) "false"

    ... 

    ["Balance"]=>
    string(5) "40.00"
    ["OpenBalanceDate"]=>
    NULL
    ["BalanceWithJobs"]=>
    string(5) "40.00"
    ["CreditLimit"]=>
    NULL
    ["AcctNum"]=>
    NULL
    ["CurrencyRef"]=>
    NULL
    ["OverDueBalance"]=>
    NULL
    ["TotalRevenue"]=>
    NULL   //<-----Why is this always NULL if there are transactions (both expenses
           //      and revenue) made from and to the customers?

    ...

    ["GivenName"]=>
    string(4) "John"
    ["MiddleName"]=>
    string(6) "Middle"
    ["FamilyName"]=>
    string(10) "Doe"

    ...
.

도움이 되었습니까?

해결책

V3 PHP DevKit은 QBD 및 QBO API 상단의 래퍼입니다.

' totalRevenue '은 QBD 용입니다.QBD REST API가 뺍니다.미래의 PHP DevKit 릴리스에서는이 필드가 없을 것입니다.이 분야를 무시하십시오.

ref - https://developer.intuit.com/docs/docs/95_DEPRECATED / QBD_V3 / QBD_V3_reference / 030_entity_services_reference / customer

언급 했듯이이 필드는 QBO V3에 대해 없습니다.

ref - https://developer.intuit.com/docs/0025_quickbooksapi/0050_Data_Services / 030_entity_services_reference / 고객

감사합니다

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top