27d9a429
suweicheng
开发梳理;
|
1
2
|
package com.essa.pageObject;
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
3
|
import com.essa.pageObject.DocumentaryManage.BillingCenterPage;
|
492c1c63
huangyuanbo914@163.com
结构调整
|
4
|
import com.essa.pageObject.DocumentaryManage.ReceiptCorePage;
|
b2af39f8
zengjin
新增开发商品
|
5
|
import com.essa.pageObject.GoodsManage.*;
|
d688c3f8
hanlei
船务
|
6
|
import com.essa.pageObject.LogisticShipp.LogisticsShippPage;
|
0e4d02cb
toby5221
增加装柜任务形成现存尾货
|
7
|
import org.openqa.selenium.By;
|
a3ecf544
huangyuanbo914@163.com
调整结构
|
8
|
import com.essa.pageObject.SupplierManage.SupplierOperationsTrackPage;
|
b2af39f8
zengjin
新增开发商品
|
9
10
11
|
import com.essa.pageObject.productDev.AddMatterialPage;
import com.essa.pageObject.productDev.AddProjectPage;
import com.essa.pageObject.productDev.ProjectListPage;
|
06fc8ada
huangyuanbo914@163.com
123
|
12
|
import org.openqa.selenium.WebDriver;
|
27d9a429
suweicheng
开发梳理;
|
13
14
15
16
|
import org.openqa.selenium.WebElement;
import org.openqa.selenium.support.FindBy;
import com.essa.framework.BasePage;
import com.essa.framework.Model;
|
a294c18e
zengjin
修改设置装柜的返回值
|
17
|
import com.essa.pageObject.DocumentaryManage.PODocumentaryListPage;
|
27d9a429
suweicheng
开发梳理;
|
18
19
20
21
22
23
24
|
import com.essa.pageObject.StorageManage.GoodsReceiveTaskPage;
import com.essa.pageObject.StorageManage.NoticeReceivePage;
import com.essa.pageObject.buyPlaneManage.SkuCategoryManagerCongfigPage;
import com.essa.pageObject.buyerManage.InvateCodePage;
import com.essa.pageObject.inquiryManage.ProductInquiryTaskPage;
import com.essa.pageObject.marketingManage.GroupControlPage;
import com.essa.pageObject.marketingManage.GroupSettingPage;
|
71af73f2
78@qq.com
lana update
|
25
|
import com.essa.pageObject.needDealt.NeedDealtApplyPage;
|
81a4681f
zengjin
修改时间工具,还有船务相关
|
26
|
import com.essa.pageObject.StorageManage.CabineTaskManagemenPage;
|
71af73f2
78@qq.com
lana update
|
27
|
|
27d9a429
suweicheng
开发梳理;
|
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
/**
* @author Administrator
*bpms后台首页
*/
public class HomePage extends BasePage{
public HomePage(WebDriver driver) {
super(driver);
}
/*
* 元素定位
*/
//退出
@FindBy (xpath="//*[text()='退出']")
WebElement logout;
//左上角图标--用于回到首页
@FindBy (xpath="//*[@class='logo-text']")
WebElement essaIcon;
//供应商管理
@FindBy (xpath="//*[text()='供应商管理']")
WebElement supplier;
//平台运营跟进管理
@FindBy (xpath="//*/a[contains(text(),'平台运营跟进管理')]")
WebElement operationsTrack;
//供应商查询
@FindBy (xpath="//*[text()='供应商查询']")
WebElement searchSuppliers;
//商品管理
@FindBy (xpath="//*[text()='商品管理']")
WebElement goodsManage;
|
b2af39f8
zengjin
新增开发商品
|
64
65
66
|
@FindBy (xpath = "//*[text()='开发商品发布审核']")
WebElement DevGoodAudit;//开发商品发布审核
|
27d9a429
suweicheng
开发梳理;
|
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
|
//商品库
@FindBy (xpath="//*[text()='商品库']")
WebElement goodBank;
//原厂商品发布
@FindBy (xpath="//*[text()='原厂商品发布']")
WebElement addOriginalGoods;
//市场商品发布
@FindBy (xpath="//*[text()='市场商品发布']")
WebElement marketGoodsRelese;
//商品发布管理-子元素
@FindBy(xpath="//*[@name='child.text' and text()='商品发布管理']")
WebElement goodsPublish;
//原厂商品发布审核
@FindBy(xpath="//*[text()='原厂商品发布审核']")
WebElement auditOriginal;
//市场商品发布审核
@FindBy(xpath="//*[text()='市场商品发布审核']")
WebElement auditMarket;
//采购计划管理
@FindBy(xpath="//*[text()='采购计划管理']")
WebElement buyerPlaneManage;
//商品类目经理分配配置
@FindBy(xpath="//*[text()='商品类目经理分配配置']")
WebElement skuManagerConfig;
//营销管理
@FindBy (xpath="//*[text()='营销管理']")
WebElement marketingManage;
//团购设置
@FindBy (xpath="//*[text()='团购设置']/..")
WebElement groupSetting;
//团购控制
@FindBy (xpath="//*[text()='团购控制']/..")
WebElement groupControl;
//采购商管理
@FindBy (xpath="//*[text()='采购商管理']")
WebElement buyerManage;
//生成邀请码
@FindBy (xpath="//*[text()='生成邀请码']" )
WebElement inviteCode;
//询价管理
@FindBy (xpath ="//span[text()='询价管理']")
WebElement inquiryManage;
//成品询价任务列表
@FindBy (xpath = "//*[text()='成品询价任务列表']")
WebElement productInquiryTask;
//产品开发
@FindBy (xpath ="//*[text()='产品开发']")
WebElement productDev;
//项目立项书新增
@FindBy (xpath ="//*[text()='项目立项书新增']")
WebElement addProject;
//项目立项书查询
@FindBy (xpath ="//*[text()='项目立项书查询']")
WebElement quiryProject;
//待办中的"采购计划审核流程"
@FindBy (xpath = "//*[@title='采购计划审核流程']")
WebElement purchasePlaneProcess;
//待办中的“船务确认备选船期流程”
@FindBy (xpath = "//*[text()='船务确认备选船期流程']")
WebElement confirmDailingDate;
//第一条待办
@FindBy (xpath = "//*[@ng-table='tableParams']/tbody/tr[1]")
WebElement firstNeedDealt;
//待办搜索文本框
@FindBy (xpath ="//*[@name='searchForm']/div/input")
WebElement searchText;
//待办搜索按钮
@FindBy (xpath = "//*[@name='searchForm']/div/span/button")
WebElement search;
//跟单管理
@FindBy (xpath = "//*[text()='跟单管理']")
WebElement DocumentaryManage;
//PO跟单
@FindBy (xpath ="//*[text()='PO跟单']")
WebElement PODocumentary;
|
06fc8ada
huangyuanbo914@163.com
123
|
167
168
169
170
|
//前台发单中心
@FindBy (xpath ="//*[text()='前台发单中心']")
WebElement Receipt_core ;
|
27d9a429
suweicheng
开发梳理;
|
171
172
173
174
175
176
177
178
179
180
181
182
183
|
//仓储管理
@FindBy (xpath = "//span[contains(text(),'仓储管理')]")
WebElement StorageManage;
//收货通知
@FindBy (xpath = "//a[@name='child.text'][contains(text(),'收货通知')]")
WebElement NoticeReceive;
//收货任务管理
@FindBy (xpath = "//a[contains(text(),'收货任务管理')]")
WebElement goodsReceiveTask;
|
46c08699
zengjin
Merge branch 'dev...
|
184
|
|
b2af39f8
zengjin
新增开发商品
|
185
186
187
188
|
//物料新增
@FindBy (xpath = "//*[text()='物料新增']")
WebElement addMaterial;
|
0e4d02cb
toby5221
增加装柜任务形成现存尾货
|
189
190
191
192
|
//装柜任务管理
@FindBy (xpath = "//a[@name='child.text'][contains(text(),'装柜任务管理')]")
WebElement loadContainerTask;
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
193
194
195
196
|
//前台发单中心
@FindBy (xpath = "//*[text()='前台发单中心']")
WebElement billingCenter;
|
46c08699
zengjin
Merge branch 'dev...
|
197
|
|
d688c3f8
hanlei
船务
|
198
199
200
201
202
|
//物流船务
@FindBy (xpath = "//*[text()='物流船务']")
WebElement LogisticsskippBoard;
//船务看板
|
3f06ee1c
zengjin
修改时间工具,还有船务相关
|
203
|
@FindBy (xpath = "//*[text()='船务看板']")
|
d688c3f8
hanlei
船务
|
204
205
|
WebElement skippBoard;
|
71af73f2
78@qq.com
lana update
|
206
207
208
209
210
211
212
213
214
215
|
//装柜通知(lana)
@FindBy (xpath = "//a[@name='child.text'][contains(text(),'装柜通知')]")
WebElement CabinetsNotice;
//装柜务务管理(lana)
@FindBy (xpath = "//a[contains(text(),'装柜任务管理')]")
WebElement CabineTaskManagemen;
|
d688c3f8
hanlei
船务
|
216
|
|
27d9a429
suweicheng
开发梳理;
|
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
|
/*
* 方法
*/
/**
* 进入运营跟进管理页面
* @return SupplierOperationsTrackPage
*/
public SupplierOperationsTrackPage goToSupplierOperationsTrack() {
//点击 供应商管理
click(supplier);
//点击 平台运营跟进管理
click(operationsTrack);
//此时,系统会加载一个平台运营跟进管理页面,故在此初始化该页面并将driver传递过去
return new SupplierOperationsTrackPage(driver);
}
/**
* 进入原厂商品发布
* @return AddOriginalGoodsPage
*/
public AddOriginalGoodsPage tOriginalGoodsPage() {
click(goodsManage);
isElementExist(addOriginalGoods);
click(addOriginalGoods);
return new AddOriginalGoodsPage(driver);
}
/**
* 进入商品发布管理
* @return GoodsRelesePage
*/
public GoodsRelesePage tGoodsRelesePage() {
|
b2af39f8
zengjin
新增开发商品
|
254
|
getHome();
|
27d9a429
suweicheng
开发梳理;
|
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
|
click(goodsManage);
click(goodsPublish);
return new GoodsRelesePage(driver);
}
/**
* 进入原厂商品发布审核
* @return AuditOriginalGoodsPage
*/
public AuditOriginalGoodsPage toAuditOriginalGoodsPage() {
mywait(logout);
click(goodsManage);
click(auditOriginal);
return new AuditOriginalGoodsPage(driver);
}
/**
* 进入商品库
* @return GoodsBankPage
*/
public GoodsBankPage toGoodsBankPage() {
click(goodsManage);
click(goodBank);
return new GoodsBankPage(driver);
}
/**
* 进入市场商品发布
* @return MarketGoodsRelesePage
*/
public MarketGoodsRelesePage toMarketGoodsRelesePage() {
click(goodsManage);
click(marketGoodsRelese);
return new MarketGoodsRelesePage(driver);
}
/**
* 进入市场商品发布审核
* @return AuditMarketGoodsPage
*/
public AuditMarketGoodsPage toAuditMarketGoodsPage() {
click(goodsManage);
click(auditMarket);
return new AuditMarketGoodsPage(driver);
}
/**
* 进入商品类目经理分配配置
* @return SkuCategoryManagerCongfigPage
*/
public SkuCategoryManagerCongfigPage toSkuCategoryManagerCongfig() {
mywait(logout);
click(buyerPlaneManage);
click(skuManagerConfig);
return new SkuCategoryManagerCongfigPage(driver);
}
/**
* 进入团购设置
* @return GroupSettingPage
*/
public GroupSettingPage toGroupSettingPage() {
getHome();
click(marketingManage);
click(groupSetting);
return new GroupSettingPage(driver);
}
/**
* 进入团购控制
* @return GroupControlPage
*/
public GroupControlPage toGroupControlPage() {
// getHome();
jsExecutorClick(essaIcon);
click(marketingManage);
click(groupControl);
return new GroupControlPage(driver);
}
/**
* 进入生成邀请码
* @return InvateCodePage
*/
public InvateCodePage toInvateCodePage() {
click(buyerManage);
moveHeightScroll("100");
click(inviteCode);
return new InvateCodePage(driver);
}
/**
* 进入成品询价任务列表
* @return ProductInquiryTask
*/
public ProductInquiryTaskPage toProductInquiryTask() {
click(inquiryManage);
click(productInquiryTask);
return new ProductInquiryTaskPage(driver);
}
/**
* 判断是否进入后台首页
* @return boolean
*/
public boolean isSucceed() {
return isThisPage("退出", logout);
}
/**
* 判断是否选中“供应商管理”
* @return
*/
public boolean isSearchSuppliers() {
return isElementExist(searchSuppliers);
}
/**
*点击essa图标, 回到bpms后台首页
*/
public void getHome() {
forceWait(500);
jsExecutorClick(essaIcon);
forceWait(1000);
}
/**
* 退出登录
*/
public void logout() {
click(logout);
}
/**
* 点击退出,有弹框确认是否离开时,用这个
*/
public void sureLogout() {
click(logout);
alert(true);
forceWait(1000);
}
/**
* 团购活动达成,类目经理采购计划单申请
* @return 询价待办申请页面
*/
public NeedDealtApplyPage applyPurchasePlane() {
mywait(firstNeedDealt);
click(purchasePlaneProcess);
forceWait(500);
click(firstNeedDealt);
switchWindow();
return new NeedDealtApplyPage(driver);
}
/**
* 待办详情页
* @return 进入待办详情页
*/
public NeedDealtApplyPage toNeedDealtDetailPage() {
mywait(firstNeedDealt);
sendKeys(searchText, Model.getSerialNum());
click(search);
forceWait(1000);
mywait(firstNeedDealt);
click(firstNeedDealt);
// switchWindow();
switchMoreWindow();
return new NeedDealtApplyPage(driver);
}
/**
* 进入PO跟单列表页
* @return PO跟单列表页
*/
public PODocumentaryListPage toPoDocumentaryListPage() {
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
425
|
getHome();
|
27d9a429
suweicheng
开发梳理;
|
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
|
click(DocumentaryManage);
click(PODocumentary);
return new PODocumentaryListPage(driver);
}
/**
* 进入收货通知页面
* @return 收货通知页面
*/
public NoticeReceivePage toNoticeReceivePage() {
click(StorageManage);
click(NoticeReceive);
return new NoticeReceivePage(driver);
}
/**
* 进入收货任务管理
* @return 收货任务管理页面
*/
public GoodsReceiveTaskPage toGoodsReceiveTaskPage() {
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
446
|
getHome();
|
27d9a429
suweicheng
开发梳理;
|
447
448
449
450
451
452
453
454
455
456
|
click(StorageManage);
click(goodsReceiveTask);
return new GoodsReceiveTaskPage(driver);
}
/**
* 大跟单进入第一个需要确认备选船期的待办页面
* @return 确认船期页面
*/
public NeedDealtApplyPage toSailingDateConfirmPage() {
click(confirmDailingDate);
|
3f06ee1c
zengjin
修改时间工具,还有船务相关
|
457
|
forceWait(1000);
|
27d9a429
suweicheng
开发梳理;
|
458
459
460
461
462
463
|
click(firstNeedDealt);
switchMoreWindow();
return new NeedDealtApplyPage(driver);
}
/**
|
0e4d02cb
toby5221
增加装柜任务形成现存尾货
|
464
465
466
467
|
* 进入装柜任务处理管理页面
* @return 返回装柜任务处理管理页面
*/
public NeedDealtApplyPage toLoadContainer(){
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
468
|
getHome();
|
0e4d02cb
toby5221
增加装柜任务形成现存尾货
|
469
470
471
|
click(StorageManage);
click(loadContainerTask);
dynamicWait(By.xpath("//div[@class='loading ng-scope']"));
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
472
|
// forceWait(3000);
|
0e4d02cb
toby5221
增加装柜任务形成现存尾货
|
473
474
475
476
|
return new NeedDealtApplyPage(driver);
}
/**
|
27d9a429
suweicheng
开发梳理;
|
477
478
479
480
481
482
483
484
485
486
487
488
489
|
* 登记备选船期待办
* @return 进入登记船务船期待办详情页面
*/
public NeedDealtApplyPage toShippingMarkWait(){
mywait(firstNeedDealt);
sendKeys(searchText,Model.getSerialNum());
click(search);
forceWait(1000);
mywait(firstNeedDealt);
click(firstNeedDealt);
switchMoreWindow();
return new NeedDealtApplyPage(driver);
}
|
06fc8ada
huangyuanbo914@163.com
123
|
490
491
492
493
|
/*
* 进入前台发单中心页面
* */
|
492c1c63
huangyuanbo914@163.com
结构调整
|
494
|
public ReceiptCorePage toReceiptCore() {
|
06fc8ada
huangyuanbo914@163.com
123
|
495
496
|
click(DocumentaryManage);
click(Receipt_core);
|
492c1c63
huangyuanbo914@163.com
结构调整
|
497
|
return new ReceiptCorePage (driver);
|
06fc8ada
huangyuanbo914@163.com
123
|
498
|
}
|
b2af39f8
zengjin
新增开发商品
|
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
|
/**
*进入开发商品发布审核
* @param
* @return 开发商品发布审核
*/
public AuditDevGoodsPage toAuditDevgoodsPage(){
click(goodsManage);
click(DevGoodAudit);
return new AuditDevGoodsPage(driver);
}
/**
*进入项目立项书新增页面
* @param
* @return 项目立项书新增
*/
public AddProjectPage toAddProject(){
click(productDev);
click(addProject);
return new AddProjectPage(driver);
}
/**
*进入物料新增页面
* @param
* @return 物料新增页面
*/
public AddMatterialPage toMaterialPage(){
click(productDev);
click(addMaterial);
return new AddMatterialPage(driver);
}
/**
*进入项目立项书列表
* @param
* @return 项目立项书查询
*/
public ProjectListPage toProjectListPage(){
getHome();
click(productDev);
click(quiryProject);
return new ProjectListPage(driver);
}
|
d7f15c1c
zengjin
提交并且覆盖之前的
|
540
541
542
543
544
545
546
547
548
549
|
/**
*进入前台发单中心
* @param
* @return 前台发单中心页面
*/
public BillingCenterPage toBillingCenterPage() {
click(DocumentaryManage);
click(billingCenter);
return new BillingCenterPage(driver);
}
|
d688c3f8
hanlei
船务
|
550
551
552
553
554
|
/**
*进入船务看板界面
*/
public LogisticsShippPage toLogisticsShippPage(){
|
3f06ee1c
zengjin
修改时间工具,还有船务相关
|
555
|
// mywait(LogisticsskippBoard);
|
d688c3f8
hanlei
船务
|
556
|
click(LogisticsskippBoard);
|
3f06ee1c
zengjin
修改时间工具,还有船务相关
|
557
|
// forceWait(1000);
|
d688c3f8
hanlei
船务
|
558
|
click(skippBoard);
|
3f06ee1c
zengjin
修改时间工具,还有船务相关
|
559
|
// jsExecutorClick(skippBoard);
|
d688c3f8
hanlei
船务
|
560
561
|
return new LogisticsShippPage(driver);
}
|
3f06ee1c
zengjin
修改时间工具,还有船务相关
|
562
563
564
565
566
567
568
569
570
571
|
/**
*业务员进入待办详情页,填写船务资料
* @param
* @return
*/
public NeedDealtApplyPage toWriteShipping() {
click(firstNeedDealt);
switchMoreWindow();
return new NeedDealtApplyPage(driver);
}
|
d688c3f8
hanlei
船务
|
572
|
|
71af73f2
78@qq.com
lana update
|
573
574
575
576
577
578
579
580
581
|
/**
* 进入装柜任务管理
* @return装柜任务管理
*/
public CabineTaskManagemenPage toCabineTaskManagemenPage() {
click(StorageManage);
click(CabineTaskManagemen);
return new CabineTaskManagemenPage(driver);
}
|
81a4681f
zengjin
修改时间工具,还有船务相关
|
582
583
584
585
586
587
588
589
|
/**
*对浏览器弹框处理
* @param
* @return
*/
public void dealAlert(boolean isAccept){
alert(isAccept);
}
|
71af73f2
78@qq.com
lana update
|
590
|
|
27d9a429
suweicheng
开发梳理;
|
591
|
}
|