Matteo Scandolo | d3b57a1 | 2017-04-20 14:33:04 -0700 | [diff] [blame^] | 1 | module.exports = new function(){ |
| 2 | |
| 3 | // list view |
| 4 | this.tableRows = element.all(by.repeater('item in vm.data')); |
| 5 | this.tableColumn = element(by.repeater('item in vm.data').row(0)) |
| 6 | .all(by.repeater('col in vm.columns')); |
| 7 | |
| 8 | this.actionsColumn = element(by.repeater('item in vm.data').row(0)) |
| 9 | .element(by.css('td:last-child')); |
| 10 | |
| 11 | this.deleteBtn = this.actionsColumn.all(by.tagName('a')); |
| 12 | |
| 13 | this.addBtn = element(by.linkText('Add')); |
| 14 | |
| 15 | // detail page |
| 16 | this.formInputs = element.all(by.repeater('field in vm.config.inputs')); |
| 17 | this.formBtn = element(by.buttonText('Save')); |
| 18 | |
| 19 | this.nameField = element(by.css('[name="name"]')); |
| 20 | this.successFeedback = element(by.css('.alert.alert-success')); |
| 21 | }; |