Docusign Company Field Not Showing - PHP API



我正在尝试在文档中的文档上实现CompanyTab,但没有出现。它设置为TextTab时起作用,但我在其他地方使用此列表显示了邮政编码列表。

我尝试将信息放入多维阵列中,以与文本数据库一起使用,但这似乎会破坏页面。我似乎找不到任何指南。

请在下面找到一个代码示例:

$signHere = new DocuSigneSignModelSignHere();
$signHere->setXPosition("100");
$signHere->setYPosition("400");
$signHere->setDocumentId("1");
$signHere->setPageNumber("1");
$signHere->setRecipientId("1");
// add the signature tab to the envelope's list of tabs
$tabs = new DocuSigneSignModelTabs();
$tabs->setSignHereTabs(array($signHere));
// add name tab
$nameTab = new DocuSigneSignModelText();
$nameTab->setDocumentId("1");
$nameTab->setRecipientId("1");
$nameTab->setPageNumber("1");
$nameTab->setName("name");
$nameTab->setTabLabel("Name");
$nameTab->setValue($name[0]);
$nameTab->setLocked("true");
$nameTab->setXPosition("100");
$nameTab->setYPosition("150"); 
// add the name tab to the envelope's list of tabs
$tabs->setFirstNameTabs(array($nameTab));
// add email tab
$emailTab = new DocuSigneSignModelText();
$emailTab->setDocumentId("1");
$emailTab->setRecipientId("1");
$emailTab->setPageNumber("1");
$emailTab->setName("email");
$emailTab->setTabLabel("Email");
$emailTab->setValue($_SESSION['email']);
$emailTab->setLocked("true");
$emailTab->setXPosition("100");
$emailTab->setYPosition("200"); 
// add the email tab to the envelope's list of tabs
$tabs->setEmailAddressTabs(array($emailTab));
// add company tab
$firmTab = new DocuSigneSignModelText();
$firmTab->setDocumentId("1");
$firmTab->setRecipientId("1");
$firmTab->setPageNumber("1");
$firmTab->setName("company");
$firmTab->setTabLabel("Company");
$firmTab->setValue($_SESSION['company']);
$firmTab->setLocked("true");
$firmTab->setXPosition("100");
$firmTab->setYPosition("250"); 
// add the company tab to the envelope's list of tabs
$tabs->setCompanyTabs(array($firmTab));
// add phone tab
$phoneTab = new DocuSigneSignModelNumber();
$phoneTab->setDocumentId("1");
$phoneTab->setRecipientId("1");
$phoneTab->setPageNumber("1");
$phoneTab->setName("phone");
$phoneTab->setTabLabel("Phone");
$phoneTab->setValue($_SESSION['phone']);
$phoneTab->setLocked("true");
$phoneTab->setXPosition("100");
$phoneTab->setYPosition("300"); 
// add the phone tab to the envelope's list of tabs
$tabs->setNumberTabs(array($phoneTab));
// add postcode tab
$postcodeTab = new DocuSigneSignModelText();
$postcodeTab->setDocumentId("1");
$postcodeTab->setRecipientId("1");
$postcodeTab->setPageNumber("1");
$postcodeTab->setName("postcodes");
$postcodeTab->setTabLabel("Postcodes");
$postcodeTab->setValue($postcodes);
$postcodeTab->setLocked("true");
$postcodeTab->setXPosition("100");
$postcodeTab->setYPosition("350"); 
// add the postcodes tab to the envelope's list of tabs
$tabs->setTextTabs(array($postcodeTab));

谢谢。

如果您使用的是多个文本选项卡,请确保您仅调用setTextTabs()函数一次。

  // add company tab
  $firmTab = new DocuSigneSignModelText();
  $firmTab->setDocumentId("1");
  $firmTab->setRecipientId("1");
  $firmTab->setPageNumber("1");
  $firmTab->setName("company");
  $firmTab->setTabLabel("Company");
  $firmTab->setLocked("true");
  $firmTab->setXPosition("71");
  $firmTab->setYPosition("250"); 
  $firmTab->setWidth("80");
  $firmTab->setValue($_SESSION['company']); 
  // add postcode tab
  $postcodeTab = new DocuSigneSignModelText();
  $postcodeTab->setDocumentId("1");
  $postcodeTab->setRecipientId("1");
  $postcodeTab->setPageNumber("1");
  $postcodeTab->setName("postcodes");
  $postcodeTab->setTabLabel("Postcodes");
  $postcodeTab->setValue($postcodes);
  $postcodeTab->setLocked("true");
  $postcodeTab->setXPosition("66");
  $postcodeTab->setYPosition("312"); 
  $postcodeTab->setHeight("226");
  $postcodeTab->setWidth("500");
  // add the Company/postcodes tab to the envelope's list of tabs
  $tabs->setTextTabs(array($firmTab, $postcodeTab));

最新更新