Skip to content

Commit

Permalink
Merge branch 'release/3.12.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
shohag121 committed Aug 29, 2024
2 parents 7106305 + 8a58500 commit 9143147
Show file tree
Hide file tree
Showing 200 changed files with 10,699 additions and 9,573 deletions.
35 changes: 12 additions & 23 deletions .github/workflows/e2e_api_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,10 @@ env:
DB_HOST_NAME: localhost
DB_USER_NAME: root
DB_USER_PASSWORD: password
DB_PORT: 9998
DATABASE: tests-wordpress
DB_PREFIX: wp

PR_NUMBER: ${{ github.event.number }}
SHA: ${{ github.event.pull_request.head.sha }}
SYSTEM_INFO: ./tests/pw/playwright/systemInfo.json
Expand Down Expand Up @@ -112,19 +114,6 @@ jobs:
cd tests/pw
npm run start:env
# Grab test db port
- name: Get Test DB PORT
id: db-port
working-directory: tests/pw
run: |
echo "DB_PORT=$(docker ps -f ancestor='mariadb:lts' -f name='tests-mysql' --format='{{.Ports}}' | sed -E 's/.*:(.*)->.*/\1/')" >> $GITHUB_ENV
# db port
- name: DB PORT
working-directory: tests/pw
run: |
echo "The value of test DB_PORT is ${{ env.DB_PORT }}"
# Set permalink structure
- name: Set Permalink structure
working-directory: tests/pw
Expand Down Expand Up @@ -171,29 +160,29 @@ jobs:
# npm run pw:deps-only

# Run e2e tests
- name: 🧪 Running the e2e tests
- name: 🧪 Run e2e tests
id: e2e-test
if: success() && (github.event_name != 'workflow_dispatch' || ( github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'E2E' || github.event.inputs.testsuite == 'All')))
timeout-minutes: 40
working-directory: tests/pw
run: |
npm run test:e2e:lite
npm run test:e2e
# Run e2e coverage
- name: 🧪 Running e2e coverage
- name: 🧪 Run e2e coverage
if: always() && (steps.e2e-test.outcome == 'success' || steps.e2e-test.outcome == 'failure')
working-directory: tests/pw
run: |
npm run e2e_coverage
npm run test:e2e:coverage
# Run API tests
- name: 🧪 Running the api tests
# Run api tests
- name: 🧪 Run api tests
id: api-test
if: always() && steps.db-port.outcome == 'success' && ( github.event_name != 'workflow_dispatch' || ( github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'API' || github.event.inputs.testsuite == 'All')))
if: always() && steps.wp-env.outcome == 'success' && ( github.event_name != 'workflow_dispatch' || ( github.event_name == 'workflow_dispatch' && (github.event.inputs.testsuite == 'API' || github.event.inputs.testsuite == 'All')))
timeout-minutes: 5
working-directory: tests/pw
run: |
npm run test:api:lite
npm run test:api
# Prepare test summary
- name: Prepare test summary
Expand Down Expand Up @@ -229,9 +218,9 @@ jobs:

# Backup Database
- name: Backup Database
if: always() && steps.db-port.outcome == 'success'
if: always() && steps.wp-env.outcome == 'success'
working-directory: tests/pw
run: |
cd tests/pw
npm run wp-env run tests-cli wp db export wp-data/db.sql
# Upload artifacts
Expand Down
10 changes: 8 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
**Requires at least:** 6.4
**Tested up to:** 6.6.1
**WC requires at least:** 8.0.0
**WC tested up to:** 9.1.4
**WC tested up to:** 9.2.3
**Requires PHP:** 7.4
**Stable tag:** 3.11.5
**Stable tag:** 3.12.0
**License:** GPLv2 or later
**License URI:** http://www.gnu.org/licenses/gpl-2.0.html

Expand Down Expand Up @@ -347,6 +347,12 @@ A. Just install and activate the PRO version without deleting the free plugin. A

## Changelog ##

### v3.12.0 ( Aug 29, 2024 ) ###

- **fix:** Displaying incorrect withdrawal amount when using decimal separator as thousand.
- **fix:** Removed multiple invoice button for dokan sub-orders.
- **fix:** Ensure accurate stock updates when vendors edit products while sales occur. Thanks @brunomendespereira

### v3.11.5 ( Aug 7, 2024 ) ###

- **fix:** Fixed data updating issue on Admin color picker settings.
Expand Down
26 changes: 13 additions & 13 deletions assets/css/vue-admin.css
Original file line number Diff line number Diff line change
Expand Up @@ -2138,58 +2138,58 @@ ul[data-v-525b077c] {
}
}

.combine_fields[data-v-14248927] {
.combine_fields[data-v-63d1027e] {
display: flex;
justify-content: right;
align-items: center;
}
.combine_fields .percent_fee[data-v-14248927] {
.combine_fields .percent_fee[data-v-63d1027e] {
padding-right: 10px;
}
.combine_fields .fixed_fee input[data-v-14248927],
.combine_fields .percent_fee input[data-v-14248927] {
.combine_fields .fixed_fee input[data-v-63d1027e],
.combine_fields .percent_fee input[data-v-63d1027e] {
width: 100px;
}

.wm-box-container[data-v-3b142b94] {
.wm-box-container[data-v-914aa92a] {
display: flex;
flex-direction: column;
}
.wm-box-container .wm-methods-box-container[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container[data-v-914aa92a] {
margin-top: 15px;
}
.wm-box-container .wm-methods-box-container .wm-methods-box[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container .wm-methods-box[data-v-914aa92a] {
border-bottom: 1px solid #f3f4f6;
padding: 0 30px;
display: flex;
justify-content: space-between;
align-items: center;
}
.wm-box-container .wm-methods-box-container .wm-methods-box[data-v-3b142b94]:last-child {
.wm-box-container .wm-methods-box-container .wm-methods-box[data-v-914aa92a]:last-child {
border-bottom: 0;
}
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-method[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-method[data-v-914aa92a] {
display: flex;
align-items: center;
}
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-charges[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-charges[data-v-914aa92a] {
display: flex;
align-items: center;
}
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-charges .wm-automated[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-charges .wm-automated[data-v-914aa92a] {
border: 1px solid #dbdbdb;
color: #838181;
padding: 5px 8px;
border-radius: 12px;
background: #f5f5f6;
}
@media only screen and (max-width: 782px) {
.wm-box-container .wm-methods-box-container .wm-methods-box[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container .wm-methods-box[data-v-914aa92a] {
flex-direction: column;
justify-content: start;
align-items: start;
}
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-charges[data-v-3b142b94] {
.wm-box-container .wm-methods-box-container .wm-methods-box .wm-charges[data-v-914aa92a] {
margin-left: -20px;
margin-bottom: 20px;
}
Expand Down
2 changes: 1 addition & 1 deletion assets/js/dokan.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/vue-admin.js

Large diffs are not rendered by default.

9 changes: 6 additions & 3 deletions assets/src/js/withdraw.js
Original file line number Diff line number Diff line change
Expand Up @@ -252,20 +252,23 @@
let withdrawMethod = $( "[name='withdraw_method'][id='withdraw-method']" ).val();
let withdrawAmount = $( "[name='withdraw_amount'][id='withdraw-amount']" ).val();

let { chargePercentage, chargeFixed } = $(
"select[name='withdraw_method'][id='withdraw-method'] option:selected"
).data();

withdrawAmount = accounting.unformat(
withdrawAmount,
dokan.mon_decimal_point
);
let { chargePercentage, chargeFixed } = $(
"select[name='withdraw_method'][id='withdraw-method'] option:selected"
).data();

let chargeAmount = 0;
let chargeText = '';

if ( chargeFixed ) {
chargeText += Dokan_Withdraw.formatMoney( chargeFixed );
chargeAmount += chargeFixed;
}

if ( chargePercentage ) {
let percentageAmount = chargePercentage / 100 * withdrawAmount;
chargeAmount += percentageAmount;
Expand Down
16 changes: 14 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"php": ">=7.4",
"appsero/client": "^v2.0.2",
"jakeasmith/http_build_url": "^1",
"appsero/updater": "^v2.0.0"
"appsero/updater": "^v2.2.0"
},
"require-dev": {
"wp-coding-standards/wpcs": "dev-develop",
Expand All @@ -23,7 +23,8 @@
"phpcompatibility/phpcompatibility-wp": "dev-master",
"phpunit/phpunit": "^9.6",
"wp-phpunit/wp-phpunit": "dev-master",
"yoast/phpunit-polyfills": "^1.0@dev"
"yoast/phpunit-polyfills": "^1.0@dev",
"brain/monkey": "^2.0"
},
"config": {
"platform": {
Expand All @@ -42,6 +43,11 @@
"includes/functions-dashboard-navigation.php"
]
},
"autoload-dev": {
"psr-4": {
"WeDevs\\Dokan\\Test\\": "tests/php/src"
}
},
"scripts": {
"phpcs": [
"vendor/bin/phpcs -p -s"
Expand All @@ -51,6 +57,12 @@
],
"phpcbf": [
"vendor/bin/phpcbf -p"
],
"test": [
"phpunit"
],
"test-f": [
"phpunit --filter"
]
}
}
Loading

0 comments on commit 9143147

Please sign in to comment.