Пример #1
0
 /**
  * Fill product form 'Tier price'.
  *
  * @param array $fields
  * @param SimpleElement|null $element
  * @return $this
  */
 public function fillOptions(array $fields, SimpleElement $element = null)
 {
     foreach ($fields['value'] as $key => $option) {
         $this->_rootElement->find($this->buttonFormLocator)->click();
         ++$key;
         parent::fillOptions($option, $element->find('tbody tr:nth-child(' . $key . ')'));
     }
     return $this;
 }
Пример #2
0
 /**
  * Fill the form.
  *
  * @param array $fields
  * @param SimpleElement $element
  * @return $this
  */
 public function fillOptions(array $fields, SimpleElement $element = null)
 {
     $this->_rootElement->find($this->addValueButton)->click();
     return parent::fillOptions($fields, $element);
 }