Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ LOCATION_SUPPLIER_ALT=locationId
LOCATION_DEPOT=locationId
LOCATION_NO_PICK_AND_PUTAWAY_STOCK_DEPOT=locationId
LOCATION_INTERNAL=locationId
LOCATION_INTERNAL_TWO=locationId
LOCATION_WARD=locationId
PRODUCT_ONE=productId
PRODUCT_TWO=productId
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ jobs:
LOCATION_WARD: ${{ secrets.LOCATION_WARD }}
LOCATION_NO_PICK_AND_PUTAWAY_STOCK_DEPOT: ${{ secrets.LOCATION_NO_PICK_AND_PUTAWAY_STOCK_DEPOT }}
LOCATION_INTERNAL: ${{ secrets.LOCATION_INTERNAL }}
LOCATION_INTERNAL_TWO: ${{ secrets.LOCATION_INTERNAL_TWO }}
PRODUCT_ONE: ${{ secrets.PRODUCT_ONE }}
PRODUCT_TWO: ${{ secrets.PRODUCT_TWO }}
PRODUCT_THREE: ${{ secrets.PRODUCT_THREE }}
Expand Down
14 changes: 14 additions & 0 deletions src/config/AppConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export enum LOCATION_KEY {
WARD = 'ward',
NO_PICK_AND_PUTAWAY_STOCK = 'noPickAndPutawayStockDepot',
BIN_LOCATION = 'internalLocation',
BIN_LOCATION2 = 'internalLocation2',
}

export enum PRODUCT_KEY {
Expand Down Expand Up @@ -270,6 +271,19 @@ class AppConfig {
type: LocationTypeCode.BIN_LOCATION,
parentLocation: env.get('LOCATION_MAIN').required().asString(),
}),

internalLocation2: new LocationConfig({
id: env.get('LOCATION_INTERNAL_TWO').asString(),
key: LOCATION_KEY.BIN_LOCATION,
name: this.uniqueIdentifier.generateUniqueString('bin-location2'),
requiredActivityCodes: new Set([
ActivityCode.PICK_STOCK,
ActivityCode.PUTAWAY_STOCK,
]),
required: false,
type: LocationTypeCode.BIN_LOCATION,
parentLocation: env.get('LOCATION_MAIN').required().asString(),
}),
};

this.products = {
Expand Down
4 changes: 4 additions & 0 deletions src/fixtures/fixtures.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ type Fixtures = {
wardLocationService: LocationData;
noPickAndPutawayStockDepotService: LocationData;
internalLocationService: LocationData;
internalLocation2Service: LocationData;

// PRODUCT DATA
mainProductService: ProductData;
otherProductService: ProductData;
Expand Down Expand Up @@ -179,6 +181,8 @@ export const test = baseTest.extend<Fixtures>({
use(new LocationData(LOCATION_KEY.NO_PICK_AND_PUTAWAY_STOCK, page.request)),
internalLocationService: async ({ page }, use) =>
use(new LocationData(LOCATION_KEY.BIN_LOCATION, page.request)),
internalLocation2Service: async ({ page }, use) =>
use(new LocationData(LOCATION_KEY.BIN_LOCATION2, page.request)),
// PRODUCTS
mainProductService: async ({ page }, use) =>
use(new ProductData(PRODUCT_KEY.ONE, page.request)),
Expand Down
6 changes: 5 additions & 1 deletion src/pages/putaway/components/CompletePutawayTable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class CompletePutawayTable extends BasePageModel {
}

get rows() {
return this.table.getByRole('rowgroup');
return this.table.getByRole('row');
}

row(index: number) {
Expand All @@ -27,6 +27,10 @@ class Row extends BasePageModel {
super(page);
this.row = row;
}

getputawayBin(rowIndex: number) {
return this.row.getByTestId(`cell-${rowIndex}-undefined`).nth(9);
}
}

export default CompletePutawayTable;
8 changes: 8 additions & 0 deletions src/pages/putaway/components/SplitModalTable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,14 @@ class Row extends BasePageModel {
get quantityField() {
return this.row.getByRole('cell').getByTestId('quantity-input');
}

get clearBinSelect() {
return this.row.locator('.react-select__clear-indicator');
}

get putawayBinField() {
return this.row.getByTestId('bin-select').getByRole('textbox');
}
}

export default SplitModalTable;
4 changes: 4 additions & 0 deletions src/pages/putaway/components/StartPutawayTable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@ class Row extends BasePageModel {
get quantityField() {
return this.row.getByTestId('cell-0-quantity').getByRole('spinbutton');
}

get splitLineinPutawayBin() {
return this.row.getByTestId('cell-0-putawayBin');
}
}

export default StartPutawayTable;
Loading
Loading