Skip to content

Commit 3e845a0

Browse files
Merge branch 'trunk' into issue/WOOMOB-1126-app-passwords-network
# Conflicts: # WooCommerce/src/main/kotlin/com/woocommerce/android/AppPrefs.kt
2 parents 8ee5125 + c58946a commit 3e845a0

File tree

120 files changed

+20580
-1335
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

120 files changed

+20580
-1335
lines changed

.github/dependabot.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ updates:
1515
- "com.google.devtools.ksp*"
1616
exclude-patterns:
1717
- "org.jetbrains.kotlinx*"
18+
cooldown:
19+
semver-major-days: 30
20+
semver-minor-days: 30
1821
ignore:
1922
# Bumping 2.26.3 to 2.27.2 will break the mocks. For more details, see
2023
# https://github.com/wiremock/wiremock/issues/1345#issuecomment-656060968
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Auto-merge Dependabot PATCH updates
2+
3+
on:
4+
pull_request:
5+
types: [opened, reopened]
6+
7+
permissions:
8+
contents: write
9+
pull-requests: write
10+
11+
jobs:
12+
auto-merge:
13+
runs-on: ubuntu-latest
14+
if: github.event.pull_request.user.login == 'dependabot[bot]' && github.repository == 'woocommerce/woocommerce-android'
15+
env:
16+
PR_URL: ${{ github.event.pull_request.html_url }}
17+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
18+
steps:
19+
- uses: actions/checkout@v5
20+
21+
- name: Fetch Dependabot metadata
22+
id: metadata
23+
uses: dependabot/fetch-metadata@v2
24+
with:
25+
github-token: "${{ secrets.GITHUB_TOKEN }}"
26+
27+
- name: Assign closest open milestone to PR
28+
if: steps.metadata.outputs.update-type == 'version-update:semver-patch'
29+
run: |
30+
set -e
31+
title=$(gh api repos/$GITHUB_REPOSITORY/milestones \
32+
--jq '[.[]
33+
| select(.state=="open" and .due_on!=null and (.due_on | fromdateiso8601) >= now)
34+
]
35+
| sort_by(.due_on)
36+
| .[0].title')
37+
38+
if [ -n "$title" ]; then
39+
echo "Assigning milestone '$title' to PR #${{ github.event.pull_request.number }}"
40+
gh pr edit "${{ github.event.pull_request.number }}" --milestone "$title"
41+
else
42+
echo "No future open milestones found."
43+
fi
44+
45+
- name: Approve the PR
46+
if: steps.metadata.outputs.update-type == 'version-update:semver-patch'
47+
run: |
48+
set -e
49+
gh pr review --approve "$PR_URL"
50+
51+
- name: Enable auto-merge for Dependabot PRs
52+
if: steps.metadata.outputs.update-type == 'version-update:semver-patch'
53+
run: |
54+
set -e
55+
gh pr merge --auto --merge "$PR_URL"

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
<!--
22
Contains editorialized release notes. Raw release notes should go into `RELEASE-NOTES.txt`.
33
-->
4+
## 23.2
5+
We’ve improved your WooCommerce app with new POS customization settings, clearer shipping label updates, smarter order filters, and automatic shipment weight entry. You’ll also find better handling of in-progress labels, fractional stock display, and enhanced login reliability for a smoother store management experience.
6+
47
## 23.1
58
Enhanced your store management experience with exciting new features! Remove backgrounds from product images instantly with our new one-tap tool. Improved shipping labels with better address validation, cleaner layouts, and smarter split shipment handling. Fixed order selection issues and enhanced login error handling for smoother operations.
69

RELEASE-NOTES.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
*** PLEASE FOLLOW THIS FORMAT: [<priority indicator, more stars = higher priority>] <description> [<PR URL>]
22
*** Use [*****] to indicate smoke tests of all critical flows should be run on the final APK before release (e.g. major library or targetSdk updates).
33
*** For entries which are touching the Android Wear app's, start entry with `[WEAR]` too.
4+
23.3
5+
-----
6+
7+
48
23.2
59
-----
610
- [Internal] Propagate response headers to all Rest Clients [https://github.com/woocommerce/woocommerce-android/pull/14513]
@@ -12,7 +16,9 @@
1216
- [WEAR] Updated UserAgent of API requests to use `http.agent` System Property to fix performance issues related to WebView usage on app launch [https://github.com/woocommerce/woocommerce-android/pull/14431]
1317
- [***] POS: A new settings to customize the POS [https://github.com/woocommerce/woocommerce-android/pull/14527]
1418
- [*] [Login] Improved the detection of WooCommerce API version during login flow [https://github.com/woocommerce/woocommerce-android/pull/14524]
19+
- [*] Add more filter options to orders filters sales channel [https://github.com/woocommerce/woocommerce-android/pull/14546]
1520
- [*] Automatically populate the weight field in the create shipment flow [https://github.com/woocommerce/woocommerce-android/pull/14525]
21+
- [*] [Shipping Labels] Fixed displaying incorrect hazardous material option for purchased labels [https://github.com/woocommerce/woocommerce-android/pull/14571]
1622

1723
23.1
1824
-----

WooCommerce/build.gradle

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ fladle {
1919
variant = "vanillaDebug"
2020
serviceAccountCredentials = rootProject.file(".configure-files/firebase.secrets.json")
2121
testTargets = [
22-
"notPackage com.woocommerce.android.e2e.tests.screenshot"
22+
"notPackage com.woocommerce.android.e2e.tests.screenshot",
23+
"notClass com.woocommerce.android.e2e.tests.ui.OrdersRealAPI",
24+
"notClass com.woocommerce.android.e2e.tests.ui.ProductsRealAPI"
2325
]
2426
devices = [
2527
["model": "MediumPhone.arm", "version": "35"]

WooCommerce/src/main/kotlin/com/woocommerce/android/AppPrefs.kt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ object AppPrefs {
7878
LOGIN_SITE_ADDRESS,
7979
DATABASE_DOWNGRADED,
8080
ORDER_SUMMARY_MIGRATED,
81+
GATEWAY_MIGRATED,
8182
IS_PRODUCTS_FEATURE_ENABLED,
8283
IS_PRODUCT_ADDONS_ENABLED,
8384
LOGIN_USER_BYPASSED_JETPACK_REQUIRED,
@@ -297,6 +298,10 @@ object AppPrefs {
297298
get() = getBoolean(DeletablePrefKey.ORDER_SUMMARY_MIGRATED, false)
298299
set(value) = setBoolean(DeletablePrefKey.ORDER_SUMMARY_MIGRATED, value)
299300

301+
var gatewayMigrated: Boolean
302+
get() = getBoolean(DeletablePrefKey.GATEWAY_MIGRATED, false)
303+
set(value) = setBoolean(DeletablePrefKey.GATEWAY_MIGRATED, value)
304+
300305
var jetpackAppPasswordsEnabled: Boolean
301306
get() = getBoolean(DeletablePrefKey.JETPACK_APP_PASSWORDS_ENABLED, true)
302307
set(value) = setBoolean(DeletablePrefKey.JETPACK_APP_PASSWORDS_ENABLED, value)

WooCommerce/src/main/kotlin/com/woocommerce/android/AppPrefsWrapper.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ open class AppPrefsWrapper @Inject constructor() {
4040
var isSiteWPComSuspended by AppPrefs::isSiteWPComSuspended
4141

4242
open var orderSummaryMigrated by AppPrefs::orderSummaryMigrated
43+
open var gatewayMigrated by AppPrefs::gatewayMigrated
4344

4445
var jetpackAppPasswordsEnabled by AppPrefs::jetpackAppPasswordsEnabled
4546

WooCommerce/src/main/kotlin/com/woocommerce/android/model/ShippingLabel.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package com.woocommerce.android.model
22

33
import android.os.Parcelable
4+
import com.woocommerce.android.ui.orders.shippinglabels.creation.ShippingLabelHazmatCategory
45
import com.woocommerce.android.ui.orders.wooshippinglabels.models.ShippingLabelModel
56
import com.woocommerce.android.ui.orders.wooshippinglabels.models.ShippingLabelStatus
67
import kotlinx.parcelize.IgnoredOnParcel
@@ -25,6 +26,7 @@ data class ShippingLabel(
2526
val currency: String = "",
2627
val productNames: List<String> = emptyList(),
2728
val productIds: List<Long> = emptyList(),
29+
val hazmatCategory: ShippingLabelHazmatCategory? = null,
2830
val originAddress: Address? = null,
2931
val destinationAddress: Address? = null,
3032
val refund: Refund? = null,
@@ -96,6 +98,7 @@ fun ShippingLabel.toShippingLabelModel(): ShippingLabelModel {
9698
usedDate = null,
9799
refund = refund?.let { ShippingLabelModel.Refund(status = it.status, requestDate = it.refundDate) },
98100
products = products,
101+
hazmatCategory = hazmatCategory,
99102
originAddress = originAddress,
100103
destinationAddress = destinationAddress
101104
)

WooCommerce/src/main/kotlin/com/woocommerce/android/ui/orders/filters/OrderFilterCategoriesViewModel.kt

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ import com.woocommerce.android.ui.orders.filters.data.OrderListFilterCategory.DA
1616
import com.woocommerce.android.ui.orders.filters.data.OrderListFilterCategory.ORDER_STATUS
1717
import com.woocommerce.android.ui.orders.filters.data.OrderListFilterCategory.PRODUCT
1818
import com.woocommerce.android.ui.orders.filters.data.OrderListFilterCategory.SALES_CHANNEL
19+
import com.woocommerce.android.ui.orders.filters.data.SalesChannel
1920
import com.woocommerce.android.ui.orders.filters.domain.GetDateRangeFilterOptions
2021
import com.woocommerce.android.ui.orders.filters.domain.GetOrderStatusFilterOptions
2122
import com.woocommerce.android.ui.orders.filters.domain.GetTrackingForFilterSelection
@@ -390,9 +391,19 @@ class OrderFilterCategoriesViewModel @Inject constructor(
390391

391392
return mutableListOf(
392393
OrderFilterOptionUiModel(
393-
key = "pos",
394+
key = SalesChannel.POS.key,
394395
displayName = resourceProvider.getString(R.string.point_of_sale),
395-
isSelected = currentSelection.contains("pos")
396+
isSelected = currentSelection.contains(SalesChannel.POS.key)
397+
),
398+
OrderFilterOptionUiModel(
399+
key = SalesChannel.WEB_CHECKOUT.key,
400+
displayName = resourceProvider.getString(R.string.orderfilters_sales_channel_filter_web_checkout),
401+
isSelected = currentSelection.contains(SalesChannel.WEB_CHECKOUT.key)
402+
),
403+
OrderFilterOptionUiModel(
404+
key = SalesChannel.WP_ADMIN.key,
405+
displayName = resourceProvider.getString(R.string.orderfilters_sales_channel_filter_wp_admin),
406+
isSelected = currentSelection.contains(SalesChannel.WP_ADMIN.key)
396407
)
397408
).apply {
398409
addFilterOptionAll(resourceProvider)

WooCommerce/src/main/kotlin/com/woocommerce/android/ui/orders/filters/data/OrderFilterDataModels.kt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ enum class OrderListFilterCategory {
88
SALES_CHANNEL
99
}
1010

11+
enum class SalesChannel(val key: String, val apiValue: String) {
12+
POS("pos", "pos-rest-api"),
13+
WEB_CHECKOUT("checkout", "checkout"),
14+
WP_ADMIN("admin", "admin");
15+
16+
companion object {
17+
fun fromKey(key: String): SalesChannel? = entries.find { it.key == key }
18+
}
19+
}
20+
1121
enum class DateRange(val filterKey: String) {
1222
TODAY("Today"),
1323
LAST_2_DAYS("Last2Days"),

0 commit comments

Comments
 (0)