当前位置: 首页>>代码示例>>PHP>>正文


PHP Helper::hasNamedButton方法代码示例

本文整理汇总了PHP中Shopware\Tests\Mink\Helper::hasNamedButton方法的典型用法代码示例。如果您正苦于以下问题:PHP Helper::hasNamedButton方法的具体用法?PHP Helper::hasNamedButton怎么用?PHP Helper::hasNamedButton使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Shopware\Tests\Mink\Helper的用法示例。


在下文中一共展示了Helper::hasNamedButton方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: verifyPage

 /**
  * Verify if we're on an expected page. Throw an exception if not.
  * @throws \Exception
  */
 public function verifyPage()
 {
     $errors = [];
     if (!$this->hasField("sCaptcha")) {
         $errors[] = "- captcha input field not found!";
     }
     if (!Helper::hasNamedButton($this, 'submitButton')) {
         $errors[] = "- submit button not found!";
     }
     if (!$errors) {
         return;
     }
     $message = ['You are not on a form page:'];
     $message = array_merge($message, $errors);
     $message[] = 'Current URL: ' . $this->getSession()->getCurrentUrl();
     Helper::throwException($message);
 }
开发者ID:GerDner,项目名称:luck-docker,代码行数:21,代码来源:Form.php

示例2: verifyPageRegister

 /**
  * Helper function to check weather we are on the register page
  * @return bool
  */
 protected function verifyPageRegister()
 {
     return $this->hasSelect('register[personal][customer_type]') && $this->hasSelect('register[personal][salutation]') && $this->hasField('register[personal][firstname]') && $this->hasField('register[personal][lastname]') && $this->hasField('register[personal][email]') && $this->hasField('register[personal][password]') && $this->hasField('register[billing][company]') && $this->hasField('register[billing][department]') && $this->hasField('register[billing][ustid]') && $this->hasField('register[billing][street]') && $this->hasField('register[billing][zipcode]') && $this->hasField('register[billing][city]') && $this->hasSelect('register[billing][country]') && $this->hasField('register[billing][shippingAddress]') && $this->hasSelect('register[shipping][salutation]') && $this->hasField('register[shipping][company]') && $this->hasField('register[shipping][department]') && $this->hasField('register[shipping][firstname]') && $this->hasField('register[shipping][lastname]') && $this->hasField('register[shipping][street]') && $this->hasField('register[shipping][zipcode]') && $this->hasField('register[shipping][city]') && $this->hasSelect('register[shipping][country]') && Helper::hasNamedButton($this, 'sendButton');
 }
开发者ID:GerDner,项目名称:luck-docker,代码行数:8,代码来源:Account.php


注:本文中的Shopware\Tests\Mink\Helper::hasNamedButton方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。