Blame view

src/main/java/com/essa/pageObject/StorageManage/CabineTaskManagemenPage.java 1.62 KB
81a4681f   zengjin   修改时间工具,还有船务相关
1
  package com.essa.pageObject.StorageManage;
71af73f2   78@qq.com   lana update
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
  
  import com.essa.framework.BasePage;
  import com.essa.framework.Model;
  import org.openqa.selenium.By;
  import org.openqa.selenium.WebDriver;
  import org.openqa.selenium.WebElement;
  import org.openqa.selenium.support.FindBy;
  
  /**
   * Created by lana on 2018/10/26 0026.
   * 装柜任务管理页
   */
  public class CabineTaskManagemenPage extends BasePage{
  
      public CabineTaskManagemenPage(WebDriver driver) {
          super(driver);
      }
  
      /*
  	 * 元素定位
  	 */
  
      @FindBy(xpath = "//input[@name='selectKey']")
      WebElement selectKey;//关键字查询
  
      @FindBy (xpath = "//button[contains(@ng-click,'search')]")
      WebElement search;//查询按钮
  
      @FindBy(xpath ="//button[contains(@ng-click,'goCompleteTask')]" )
      WebElement handle;//处理按钮
  
      @FindBy(xpath ="//tbody/tr[1]")
      WebElement firstTr;//定位第一行
  
      @FindBy (xpath = "//button[contains(text(),'处理')]")
      WebElement deal;//处理
  
      /*
      * 页面参数
       * */
81a4681f   zengjin   修改时间工具,还有船务相关
42
  //    String poNo="";
71af73f2   78@qq.com   lana update
43
44
45
46
47
48
49
50
51
52
  
      /*
  	 * 页面方法
  	 */
  
      /**
       * 设置装柜处理查询
       */
      public CabineTaskManagemenPage setWareHouse() {
          dynamicLoad(By.xpath("//div[@style='display: none;' and @id='mask']"));
81a4681f   zengjin   修改时间工具,还有船务相关
53
54
55
56
57
58
59
  //        if(Model.getPoNum()!=""|| Model.getPoNum()!=null){
  //            poNo="B180828T9165";
  //            sendKeys(selectKey, poNo);
  //        }else{
  //        sendKeys(selectKey, Model.getPoNum());
  //    }
          sendKeys(selectKey, Model.getPoNum());
71af73f2   78@qq.com   lana update
60
61
62
63
64
65
66
67
68
          click(search);
          forceWait(1000);
          click(firstTr);
          click(deal);
          return new CabineTaskManagemenPage(driver);
  
      }
  
  }