Skip to content

Commit bf50bfa

Browse files
committed
PWA-1576: GQL gaps for Admin configuration
- update schema types
1 parent f15faf9 commit bf50bfa

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

app/code/Magento/PaymentGraphQl/etc/schema.graphqls

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ type StoreConfig {
77
zero_subtotal_payment_action: String @doc(description: "When the new order status is 'Processing', this can be set to 'authorize_capture' to automatically invoice all items that have a zero balance")
88
zero_subtotal_payment_from_applicable_countries: String @doc(description: "States whether All Allowed Countries or Specific Countries can use the Zero Subtotal payment method")
99
zero_subtotal_payment_from_specific_countries: String @doc(description: "Comma-separated list of specific countries allowed to use the Zero Subtotal payment method")
10-
zero_subtotal_sort_order: String @doc(description: "A number indicating the position of the Zero Subtotal payment method in the list of available payment methods during checkout")
10+
zero_subtotal_sort_order: Int @doc(description: "A number indicating the position of the Zero Subtotal payment method in the list of available payment methods during checkout")
1111
check_money_order_enabled: Boolean @doc(description: "Check/Money Order payment method status: enabled/disabled")
1212
check_money_order_title: String @doc(description: "The title of the Check/Money Order payment method displayed on the storefront")
1313
check_money_order_new_order_status: String @doc(description: "Status of new orders placed using the Check/Money Order payment method")
@@ -17,5 +17,5 @@ type StoreConfig {
1717
check_money_order_send_check_to: String @doc(description: "The full street address or PO Box where the checks are mailed")
1818
check_money_order_min_order_total: String @doc(description: "Minimum order amount required to qualify for the Check/Money Order payment method")
1919
check_money_order_max_order_total: String @doc(description: "Maximum order amount required to qualify for the Check/Money Order payment method")
20-
check_money_order_sort_order: String @doc(description: "A number indicating the position of the Check/Money Order payment method in the list of available payment methods during checkout")
20+
check_money_order_sort_order: Int @doc(description: "A number indicating the position of the Check/Money Order payment method in the list of available payment methods during checkout")
2121
}

dev/tests/api-functional/testsuite/Magento/GraphQl/PaymentGraphQl/StoreConfigTest.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public function testStoreConfigZeroSubtotalCheckMoneyOrderDefaultValues()
7272
self::assertEquals('authorize_capture', $response['storeConfig']['zero_subtotal_payment_action']);
7373
self::assertEquals('0', $response['storeConfig']['zero_subtotal_payment_from_applicable_countries']);
7474
self::assertNull($response['storeConfig']['zero_subtotal_payment_from_specific_countries']);
75-
self::assertEquals('1', $response['storeConfig']['zero_subtotal_sort_order']);
75+
self::assertEquals(1, $response['storeConfig']['zero_subtotal_sort_order']);
7676
self::assertTrue($response['storeConfig']['check_money_order_enabled']);
7777
self::assertEquals('Check / Money order', $response['storeConfig']['check_money_order_title']);
7878
self::assertEquals('pending', $response['storeConfig']['check_money_order_new_order_status']);
@@ -120,7 +120,7 @@ public function testStoreConfigZeroSubtotalCheckMoneyOrderDisabled()
120120
self::assertEquals('authorize_capture', $response['storeConfig']['zero_subtotal_payment_action']);
121121
self::assertEquals('0', $response['storeConfig']['zero_subtotal_payment_from_applicable_countries']);
122122
self::assertNull($response['storeConfig']['zero_subtotal_payment_from_specific_countries']);
123-
self::assertEquals('1', $response['storeConfig']['zero_subtotal_sort_order']);
123+
self::assertEquals(1, $response['storeConfig']['zero_subtotal_sort_order']);
124124
self::assertFalse($response['storeConfig']['check_money_order_enabled']);
125125
self::assertEquals('Check / Money order', $response['storeConfig']['check_money_order_title']);
126126
self::assertEquals('pending', $response['storeConfig']['check_money_order_new_order_status']);
@@ -179,7 +179,7 @@ public function testStoreConfigZeroSubtotalCheckMoneyOrderCustom()
179179
self::assertEquals('authorize_capture', $response['storeConfig']['zero_subtotal_payment_action']);
180180
self::assertEquals('1', $response['storeConfig']['zero_subtotal_payment_from_applicable_countries']);
181181
self::assertEquals('DZ', $response['storeConfig']['zero_subtotal_payment_from_specific_countries']);
182-
self::assertEquals('5', $response['storeConfig']['zero_subtotal_sort_order']);
182+
self::assertEquals(5, $response['storeConfig']['zero_subtotal_sort_order']);
183183
self::assertTrue($response['storeConfig']['check_money_order_enabled']);
184184
self::assertEquals('Test Check / Money Order Title', $response['storeConfig']['check_money_order_title']);
185185
self::assertEquals('pending', $response['storeConfig']['check_money_order_new_order_status']);
@@ -189,6 +189,6 @@ public function testStoreConfigZeroSubtotalCheckMoneyOrderCustom()
189189
self::assertEquals('Test Address', $response['storeConfig']['check_money_order_send_check_to']);
190190
self::assertEquals('5.00', $response['storeConfig']['check_money_order_min_order_total']);
191191
self::assertEquals('5555.00', $response['storeConfig']['check_money_order_max_order_total']);
192-
self::assertEquals('7', $response['storeConfig']['check_money_order_sort_order']);
192+
self::assertEquals(7, $response['storeConfig']['check_money_order_sort_order']);
193193
}
194194
}

0 commit comments

Comments
 (0)