Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v0.6.0 #327

Merged
merged 64 commits into from
Oct 13, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
6929941
New error handling method introduced in the "addToCart" mutation
kidunot89 Jun 26, 2020
cdba4e2
"allowed_restricted_fields" list updated.
kidunot89 Jul 6, 2020
a95b406
version numbers updated.
kidunot89 Jul 29, 2020
6744e17
Example sections added
kidunot89 Jul 29, 2020
59ec0e7
Update testing-integration.yml
kidunot89 Aug 4, 2020
fa0e01d
Update wordpress-coding-standards.yml
kidunot89 Aug 4, 2020
aed99ef
"galleryImages" connection refactored.
kidunot89 Jun 26, 2020
cdf7bd9
"build-release" workflow added.
kidunot89 Aug 4, 2020
173a13f
.gitignore updated.
kidunot89 Aug 4, 2020
4ad70f4
vendor directory restored
kidunot89 Aug 4, 2020
37faa95
Merge pull request #311 from kidunot89/bugfix/product-gallery-images-…
kidunot89 Aug 5, 2020
1b78f92
Merge pull request #312 from kidunot89/feature/better-add-to-cart-err…
kidunot89 Aug 5, 2020
1039e6a
Github workflows updated
kidunot89 Aug 5, 2020
4523c87
Cognitive complexity of "mutate_and_get_payload" reduced.
kidunot89 Aug 5, 2020
d79c730
Cognitive complexity of "mutate_and_get_payload" reduced.
kidunot89 Aug 5, 2020
f9191c7
product attibute label fields added
kidunot89 Jul 4, 2020
757bf0a
Removes debug line
kidunot89 Jul 6, 2020
8c7951b
"label" field added.
kidunot89 Jul 6, 2020
cf25353
ProductAttributeQueriesTest updated
kidunot89 Jul 6, 2020
ee9b210
GlobalProductAttribute "label" field defined.
kidunot89 Aug 6, 2020
9dc34dd
Merge pull request #316 from kidunot89/bugfix/downloadable-items-rest…
kidunot89 Aug 6, 2020
c64c094
Two new fields added to the "ProductCategory" type.
kidunot89 Jul 7, 2020
edf10a8
WC_Term_Connection_Resolver class removed.
kidunot89 Aug 6, 2020
65c7fc8
ProductQueriesTest updated.
kidunot89 Aug 6, 2020
09158c4
Merge pull request #314 from kidunot89/feature/attribute-labels
kidunot89 Aug 6, 2020
3b7bd5d
Merge pull request #318 from kidunot89/feature/product-category-meta
kidunot89 Aug 6, 2020
9fa1a15
"price" field added to "GroupProduct" type.
kidunot89 Jul 7, 2020
fe91fc5
Product gallery image test added.
kidunot89 Jul 13, 2020
664bacf
Heavy refactor of productconnection "resolve" functions.
kidunot89 Jul 17, 2020
87eb81d
"Root_Query" class implemented.
kidunot89 Aug 11, 2020
fe46ea0
Field caps removed from product raw price and description fields.
kidunot89 Aug 11, 2020
725bd12
vendor cleaned
kidunot89 Aug 12, 2020
d479a73
"Root_Query::register_fields()" refactored.
kidunot89 Aug 12, 2020
f221571
Grouped product and product variation connection tests refactored.
kidunot89 Sep 3, 2020
872e87f
Merge pull request #319 from kidunot89/feature/grouped-product-price
kidunot89 Sep 7, 2020
12231bb
Merge pull request #331 from kidunot89/feature/root-queries
kidunot89 Sep 7, 2020
f2a6a3d
Merge pull request #332 from kidunot89/bugfix/price-format-permission…
kidunot89 Sep 7, 2020
589cede
Support for some node interfaces added to the product and order models.
kidunot89 Sep 7, 2020
449d3b1
"typeId" fields replaced by "databaseId".
kidunot89 Sep 16, 2020
4967d60
CoreInterfaceQueriesTest added.
kidunot89 Sep 17, 2020
55fa706
initial commit
kidunot89 Apr 4, 2020
f700c4d
Stripe payment gateway support implemented
kidunot89 Apr 4, 2020
f1e9322
version numbers updated.
kidunot89 Apr 6, 2020
704845e
initial commit
kidunot89 Apr 4, 2020
2456586
Stripe test cleaned up
kidunot89 Apr 6, 2020
de0615d
github actions and php-jwt updated.
kidunot89 Apr 6, 2020
5271fe4
testing workflow updated.
kidunot89 Apr 6, 2020
f5fa2a3
Docker CI configurations updated.
kidunot89 Apr 8, 2020
3150b9e
composer.json updated.
kidunot89 Apr 8, 2020
0ffe6d5
Product review mutations implemented and tested.
kidunot89 Apr 16, 2020
331bfe5
Crud_CPT renamed to WC_Post
kidunot89 Apr 30, 2020
b66f52c
autoloader files rebuilt
kidunot89 Apr 30, 2020
80b87eb
Large refactor of Post models
kidunot89 Sep 22, 2020
b7a14f9
Session Handler upgraded.
kidunot89 Oct 1, 2020
b123275
Merge pull request #2 from kidunot89/feature/ql-session-handler-v2.5
kidunot89 Oct 1, 2020
0cbd8de
Deprecated code removed.
kidunot89 Jul 6, 2020
c8ce2db
Support for WooCommerce v4.5+ added.
kidunot89 Oct 2, 2020
6026ed9
"testCheckoutMutationCartItemValidation" completed.
kidunot89 Oct 3, 2020
fcda02c
Syntax error fixed in workflow
kidunot89 Oct 3, 2020
531fac9
Merge pull request #315 from kidunot89/bugfix/cart-item-checkout-vali…
kidunot89 Oct 3, 2020
e708346
Merge branch 'release/v0.6.0' into feature/some-node-interfaces-support
kidunot89 Oct 3, 2020
d063337
Merge pull request #337 from kidunot89/feature/some-node-interfaces-s…
kidunot89 Oct 3, 2020
4cbe56b
Interface type resolve callback implemented.
kidunot89 Oct 12, 2020
86a7ef1
final cleanups in code.
kidunot89 Oct 13, 2020
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
3 changes: 1 addition & 2 deletions .env.dist
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ CORE_BRANCH=develop
JWT_AUTH_BRANCH=develop
STRIPE_GATEWAY=1
GRAPHQL_JWT_AUTH_SECRET_KEY=testingtesting123
STRIPE_API_PUBLISHABLE_KEY=test_key
STRIPE_API_SECRET_KEY=test_secret
SKIP_TESTS_CLEANUP=1
49 changes: 49 additions & 0 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: build_release

on:
push:
tags:
- "v*"

jobs:
build_release:
name: "Build Release"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 7.3
extensions: mbstring, intl
tools: composer

- name: Install dependencies
run: composer install --no-dev

- name: List files
run: ls -laR

- name: Generate draft release
uses: meeDamian/github-release@2.0
with:
token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: true
draft: true
title: "Release {{ github.ref }}"
gzip: true
files: >
includes/
vendor/
.distignore
access-functions.php
CHANGELOG.md
class-inflect.php
LICENSE
logo.svg
README.md
README.txt
SECURITY.md
wp-graphql-woocommerce.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Testing Integration
name: continuous_integration

on:
schedule:
Expand All @@ -7,15 +7,17 @@ on:
branches:
- develop
- master
- release/v0.6.0
pull_request:
branches:
- develop
- release/v0.6.0
paths:
- '**.php'
- '!docs/**'

jobs:
run:
continuous_integration:
env:
STRIPE_API_PUBLISHABLE_KEY: ${{ secrets.STRIPE_API_PUBLISHABLE_KEY }}
STRIPE_API_SECRET_KEY: ${{ secrets.STRIPE_API_SECRET_KEY }}
Expand Down Expand Up @@ -47,6 +49,20 @@ jobs:
php-version: ${{ matrix.php }}
extensions: json, mbstring

- name: Get Composer Cache Directory
id: composercache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composercache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --no-dev

- name: Build "testing" Docker Image
env:
PHP_VERSION: ${{ matrix.php }}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,26 +1,29 @@
name: WordPress Coding Standards
name: lint_code

on:
push:
branches:
- develop
- master
- release/v0.6.0
pull_request:
branches:
- develop
- release/v0.6.0
paths:
- '**.php'
- '!docs/**'

jobs:
run:
lint_code:
runs-on: ubuntu-latest
name: "Lint code with PHPCS"
steps:
- name: Checkout
uses: actions/checkout@v1

- name: Setup PHP
uses: shivammathur/setup-php@v1
uses: shivammathur/setup-php@v2
with:
php-version: 7.3
extensions: mbstring, intl
Expand All @@ -32,11 +35,7 @@ jobs:

- name: Install dependencies
run: |
composer require \
squizlabs/php_codesniffer \
phpcompatibility/phpcompatibility-wp wp-coding-standards/wpcs \
dealerdirect/phpcodesniffer-composer-installer
composer install --no-dev
composer install

- name: Cache dependencies
uses: actions/cache@v1
Expand All @@ -46,4 +45,4 @@ jobs:
restore-keys: ${{ runner.os }}-composer

- name: Run PHP CodeSniffer
run: vendor/bin/phpcs
run: composer lint
8 changes: 5 additions & 3 deletions .phpcs.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0"?>
<ruleset name="WordPress Coding Standards based custom ruleset for your plugin">
<config name="installed_paths" value="vendor/wp-coding-standards/wpcs" />
<description>Generally-applicable sniffs for WordPress plugins.</description>

<!-- What to scan -->
Expand All @@ -19,15 +20,16 @@
<arg name="colors"/>
<arg name="extensions" value="php"/>
<arg name="parallel" value="8"/><!-- Enables parallel processing when available for faster results. -->

<!-- Rules: Check PHP version compatibility -->
<!-- https://github.com/PHPCompatibility/PHPCompatibility#sniffing-your-code-for-compatibility-with-specific-php-versions -->
<config name="testVersion" value="7.0-"/>
<!-- https://github.com/PHPCompatibility/PHPCompatibilityWP -->
<rule ref="PHPCompatibilityWP"/>

<!-- Rules: WordPress Coding Standards -->
<!-- https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards -->
<rule ref="WordPress-Core" />
<rule ref="WordPress-Docs" />
<rule ref="WordPress-Extra" />

<!-- https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/wiki/Customizable-sniff-properties -->
<config name="minimum_supported_wp_version" value="4.9"/>
<rule ref="WordPress.NamingConventions.PrefixAllGlobals">
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
2. Install & activate [WPGraphQL](https://www.wpgraphql.com/)
3. Clone or download the zip of this repository into your WordPress plugin directory & activate the **WP GraphQL WooCommerce** plugin.
4. (Optional) Install & activate [WPGraphQL-JWT-Authentication](https://github.com/wp-graphql/wp-graphql-jwt-authentication) to add a `login` mutation that returns a JSON Web Token.
5. (Optional) Install & activate [WPGraphQL-CORS](https://github.com/funkhaus/wp-graphql-cors) to add an extra layer of security using HTTP CORS and some of WPGraphQL advanced functionality.
5. (Optional) Install & activate [WPGraphQL-CORS](https://github.com/funkhaus/wp-graphql-cors) to add an extra layer of security using HTTP CORS and some of WPGraphQL advanced functionality.

## What does this plugin do?
It adds WooCommerce functionality to the WPGraphQL schema using WooCommerce's [CRUD](https://github.com/woocommerce/woocommerce/wiki/CRUD-Objects-in-3.0) objects.
Expand All @@ -37,6 +37,10 @@ Feel free to test out the extension using this [GraphiQL Playground](https://woo

## Follow [![alt text](http://i.imgur.com/tXSoThF.png)](https://twitter.com/woographql)[![alt text](http://i.imgur.com/P3YfQoD.png)](https://www.facebook.com/woographql)

## Demo/Examples

## Who using WooGraphQL

## Contributors

### Code Contributors
Expand Down
32 changes: 16 additions & 16 deletions README.txt
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
=== WP GraphQL WooCommerce ===
Contributors: kidunot89, ranaaterning, jasonbahl, saleebm
Tags: GraphQL, WooCommerce, WPGraphQL
Requires at least: 4.9
Tested up to: 5.2
Requires PHP: 7.0
Requires WooCommerce: 3.0.0
Requires WPGraphQL: 0.8.0+
Works with WPGraphQL-JWT-Authentication: 0.4.0+
Stable tag: 0.5.1
License: GPL-3
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Maintained at: https://github.com/wp-graphql/wp-graphql-woocommerce

== Description ==
Adds WooCommerce functionality to the WPGraphQL schema.
=== WP GraphQL WooCommerce ===
Contributors: kidunot89, ranaaterning, jasonbahl, saleebm
Tags: GraphQL, WooCommerce, WPGraphQL
Requires at least: 4.9
Tested up to: 5.2
Requires PHP: 7.0
Requires WooCommerce: 4.7.0
Requires WPGraphQL: 0.13.4+
Works with WPGraphQL-JWT-Authentication: 0.4.0+
Stable tag: 0.6.0
License: GPL-3
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Maintained at: https://github.com/wp-graphql/wp-graphql-woocommerce
== Description ==
Adds WooCommerce functionality to the WPGraphQL schema.
36 changes: 27 additions & 9 deletions bin/run-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@

set -eu

print_usage_instructions() {
echo "Usage: $0 build|run [-e=env-file ] [-a|-t]";
exit 1
}

if [ -z "$1" ]; then
print_usage_instructions
fi

env_file=".env.dist";

subcommand=$1; shift
case "$subcommand" in
"build" )
Expand All @@ -20,23 +31,30 @@ case "$subcommand" in
--build-arg WP_VERSION=${WP_VERSION-5.4} \
--build-arg PHP_VERSION=${PHP_VERSION-7.4} \
.

docker build -f docker/testing.Dockerfile \
-t woographql-testing:latest \
--build-arg USE_XDEBUG=${USE_XDEBUG-} \
.
;;
\? ) echo "Usage: $0 build [-a|-t]";;
* ) echo "Usage: $0 build [-a|-t]";;
\? ) print_usage_instructions;;
* ) print_usage_instructions;;
esac
done
shift $((OPTIND -1))
;;
"run" )
while getopts ":a:t" opt; do
while getopts "e:at" opt; do
case ${opt} in
a ) docker-compose up -d --scale testing=0 --build;;
e )
env_file=${OPTARG};
if [ ! -f $env_file ]; then
echo "No file found at $env_file"
fi
;;
a ) docker-compose up --scale testing=0;;
t )
source ${env_file}
docker-compose run --rm \
-e STRIPE_API_PUBLISHABLE_KEY=${STRIPE_API_PUBLISHABLE_KEY-} \
-e STRIPE_API_SECRET_KEY=${STRIPE_API_SECRET_KEY-} \
Expand All @@ -46,13 +64,13 @@ case "$subcommand" in
-e SKIP_TESTS_CLEANUP=${SKIP_TESTS_CLEANUP-} \
testing --scale app=0
;;
\? ) echo "Usage: $0 run [-a|-t]";;
* ) echo "Usage: $0 run [-a|-t]";;
\? ) print_usage_instructions;;
* ) print_usage_instructions;;
esac
done
shift $((OPTIND -1))
;;

\? ) echo "Usage: $0 <build|run> [-a|-t]";;
* ) echo "Usage: $0 <build|run> [-a|-t]";;
\? ) print_usage_instructions;;
* ) print_usage_instructions;;
esac
Loading