title: How can I write the code to append all of the items(XPages)?
body: <p>I have many documents in Notes, all of the  documents have a different form, like this picture : </p>
  
  <p>(possibly like pic 1,  pic 2, or pic 3)</p>
  
  <p><a href="https://i.stack.imgur.com/u7EJC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/u7EJC.png" alt="enter image description here"></a></p>
  
  <p><a href="https://i.stack.imgur.com/oLEVa.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/oLEVa.png" alt="enter image description here"></a></p>
  
  <p><a href="https://i.stack.imgur.com/17ndr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/17ndr.png" alt="enter image description here"></a></p>
  
  <p>How can I write the code in Xpages? </p>
  
  <p>use the "computed field"? Or use the "input text"? </p>
  
  <p>I used the "input text".But only for one item, not for all.</p>
  
  <pre><code>var doc = purchase.getDocument();
  var A0 = doc.getItemValueString("DAY_A0");
  if(A0 != 0){
      return "Division processing";
  }
  </code></pre>
  
  <p>If the form not only has one item, like the pics. How can I write the code to append all of the items?</p>