Commit graph

66 commits

Author SHA1 Message Date
Paweł Chyła
8592c6a4dc
Add order details new column picker (#3934)
Co-authored-by: Renata <renata.gajzlerowicz@gmail.com>
Co-authored-by: wojteknowacki <124166231+wojteknowacki@users.noreply.github.com>
Co-authored-by: wojteknowacki <wojciech.nowacki@saleor.io>
2023-07-25 15:13:57 +02:00
Michał Droń
a333adbb43
Customer list datagrid (#3940)
* Add default columns to customers list view

* Customer list datagrid implementation

* Fix types

* Remove old code

* Migrate some of the files to strict null checks

* Extract messages

* Add changeset

* Drop Tabs

* Fix filter presets typo

* Reuse bulk delete button

* Fix crashing presets

* Enlarge columns

* Extract to a separat function

* Fix race condition

* Fix type post-merge
2023-07-24 09:49:13 +02:00
Paweł Chyła
ce1854b2ca
Introduce datagrid in grift cards list (#3894)
Co-authored-by: wojteknowacki <124166231+wojteknowacki@users.noreply.github.com>
2023-07-19 15:31:33 +02:00
Paweł Chyła
52f58eb00a
Introduce datagrid on Discounts list (#3939)
Co-authored-by: wojteknowacki <wojciech.nowacki@saleor.io>
2023-07-19 15:31:13 +02:00
Paweł Chyła
09c9024e0d
Order drafts list datagrid (#3765) 2023-07-04 09:27:17 +02:00
Paweł Chyła
adf3342d5c
Replace ConfirmButton from old macaw (#3647)
* New ConfirmButton component

* Update macaw ui

* Remove old confim button

* New confirm button

* Replace all place with new confirm button

* Remove ConfirmButtonTransitionState use from mcaw

* Does not change button width when showing loader and success state

* Test ConfirmButton

* Remove story, update tests

* WIP change pull_request to push for chromatic

* Revert "WIP change pull_request to push for chromatic"

This reverts commit 8f0909bf54f185898a7f1d236f072d6544fd5d86.

* Add comments

* Remove css prop from DialogTable

* Make confirm button larger in order send refund
2023-05-30 09:42:22 +02:00
Paweł Chyła
63b98a08bf
Select filter presets (#3412) 2023-04-12 09:11:11 +02:00
Krzysztof Żuraw
04247d3f95
Migrate from @saleor alias to @dashboard (#2981) 2023-01-16 10:45:12 +01:00
Michał Droń
e900f2e1df
Fix strict null checks in webhooks (#2678)
* Fix strict null errors in webhooks

* Disable strict null checks

* Update snapshots

* Add migration comment in tsconfig

* Fix 404 on loading

* Fix loading case
2022-12-01 14:42:18 +01:00
Michał Droń
d5c9a3dae8
Add trailing commas (#2062)
* Require trailing commas

* Add trailing commas

* Add trailing commas in testUtils dir

* Add trailing commas
2022-06-21 11:36:55 +02:00
Jonatan Witoszek
1a19289e43
Enhancements to pagination navigation (#2063)
* Update macaw to include Paginator changes

* Add link support to TablePagination component

* Rewrite usePaginator to use context and links instead of onClick

* Refactor ProductList to use new usePaginator hook

* Add decorator for PaginatorContext in ProductList stories

* Refactor AppList to use new usePaginator hook

* Refactor AttributeList to use new usePaginator hook

* Add missing pagination props for local pagination to AttributeValues

* Refactor CategoryList to use new usePaginator hook

* Refactor CategoryDetails to use useLocalPaginator and context

* Refactor CollectionList to use new usePaginator hook

* Refactor CollectionProducts to use new usePaginator hook

* Refactor CustomerList to use new usePaginator hook

* Refactor VoucherDetailsPage to use PaginationContext

* Refactor SaleDetails to use PaginatorContext

* Refactor SaleList to use new usePaginator hook

* Refactor VoucherList to use new usePaginator hook

* Fix type error in paginatorContextValues fixture

* Refactor GitfCardList to use new usePaginator hook

* Remove unused imports

* Refactor MenuList to use new usePaginator hook

* Refactor OrderDraftList to use new usePaginator hook

* Refactor OrderListPage to use new usePaginator hook

* Refactor PageList to use new usePaginator hook

* Refactor PageTypeList to use new usePaginator hook

* Refactor PermissionGroupList to use new usePaginator hook

* Refactor PluginsList to use new usePaginator hook

* Refactor ProductTypeList to use new usePaginator hook

* Refactor ShippingMethodProducts to use PaginationContext

* Refactor ShippingZonesList to use new usePaginator hook

* Refactor StaffList to use new usePaginator hook

* Fix TS errors

* Update TranslationEntities and TranslationFields to use new usePaginator

* Refactor WarehouseList to use new usePaginator hook

* Fix errors in stories that didn't use PaginationContextDecorator

* Mention changes in changelog

* Update to latest macaw version, update snapshots
2022-05-31 14:53:16 +02:00
Jonatan Witoszek
1e38c14116
Use links instead of onClick navigate function (#1969)
Add links instead of navigate + onClick in:
* Lists - ex. product list (except Plugins, see below)
* SortableTables - ex. product variants
* Sidebar
* Buttons that open new page - ex. "Create product"
* Backlinks
* Menus - ex. "Account Settings"
* Links that actually used onClick - ex. warehouse shipping zone, reset password
2022-05-06 10:59:55 +02:00
Dominik Żegleń
8c667cc7b8
Add filtering by metadata (#1995)
* Add metadata field to filters

* Fix type

* Add metadata filters to orders list

* Refactor key value filter into separate component

* Update Filter types to support other values than string[]

* Rename IFilterElement to FilterElement, remove duplication in types

* Add new messages for Metadata filter

* Fix metadata key-value pair not formatted correctly in the URL

* Add delete metadata button

* Update snapshots

Co-authored-by: Jonatan Witoszek <jonatanwitoszek@gmail.com>
2022-04-26 10:10:12 +02:00
Dominik Żegleń
fc0e3757ae
Disable query batching (#1922)
* Remove query batching

* Fix imports

* Update changelog
2022-03-17 16:00:17 +01:00
Dominik Żegleń
5b85d6c086
Use graphql-codegen (#1874)
* Use generated hooks in apps

* Remove unused files

* Use proper types in apps

* Use generated hooks in attributes

* Use generated hooks in auth module

* Use generated hooks in categories

* Use generated hooks in channels

* Use generated types in collections

* Remove legacy types from background tasks

* Use generated hooks in customers

* Use generated hooks in discounts

* Use generated hook in file upload

* Use generated types in gift cards

* Use generated types in home

* Use generated hooks in navigation

* Use generated hooks in orders

* Use generated hooks in pages

* Use generated hooks in page types

* Use generated hooks in permission groups

* Use generated hooks in plugins

* Use generated hooks in products

* Use fragment to mark product variants

* Improve code a bit

* Use generated hooks in page types

* Use generated types in searches

* Use generated hooks in shipping

* Use generated hooks in site settings

* Use generated hooks in staff members

* Use generated hooks in taxes

* Place all gql generated files in one directory

* Use generated hooks in translations

* Use global types from new generated module

* Use generated hooks in warehouses

* Use generated hooks in webhooks

* Use generated fragment types

* Unclutter types

* Remove hoc components

* Split hooks and types

* Fetch introspection file

* Delete obsolete schema file

* Fix rebase artifacts

* Fix autoreplace

* Fix auth provider tests

* Fix urls

* Remove leftover types

* Fix rebase artifacts
2022-03-09 09:56:55 +01:00
Wojciech Mista
29461658a2
Add api error log in notifications (#1873)
* add api error log in notifications

* Refactor graphql error handling

* Update messages

* Install macaw-ui from commit hash

* Make notification id be ref index rather than date

* Refactor notification container styles to allow scroll

* Add fix to apollo onError function to get operation name

* Fix userPermission race-condition

* Add refactored error handling

* Temporarly install macaw from pill PR

* Handle case when there are no graphql errors

* Update errors

* Run build-types

* Update stories to include messages

* Update shipping types

* Traverse through onCompleted data and show errors

* Update tests

* Update messages

* Clear error notifications on submit

* Check if context exists - fix tests
2022-03-04 11:52:58 +01:00
Dominik Żegleń
2a52eb581c
Update apollo to v3 (#1837)
* Update apollo to v3

* Fix imports

* Add generated file to ignored

* Use proper import

* Tidy up code

* Remove unused packages

* Fix tests
2022-02-21 14:32:38 +01:00
Michał Droń
f5f4858cf1
Change StatusLabels to Pills (#1867)
* Change StatusLabels to Pills (#1819)

* Refactor StatusLabel component to use Pills

* Remove StatusLabel component

* Remove StatusChip component

* Refactor ChannelsAvailibilityDropdown for usage with Pills

* Remove AvailabilityStatusLabel

* Fix FilterErrorsList dot

* Refactor plugin availability

* Update messages

* Update snapshots & solve rebase conflicts

* Fix rebase conflict - duplicate intl

* Handle products & collections without channels

* Change plugins messages from inactive to deactivated

* Remove redundant ChannelConfigPopup

* Change AvailabilityMenu from onClick to onHover

* Update snapshots & fix rebase conflicts

* Add order title

* Fix status colors

* Remove unused import

* Fix extra spacing in unfulfilled pill

* Add payment card title & move messages outside file

* Fix impromper skeleton rendering in product list

* Update snapshots & fix rebase conflicts

* Change plugins pills to interactive

* Update snapshots

* Trigger deployment

* Apply minor CR fixes

* Change callb
acks props to mapped objects in ChannelsAvailabilityMenu

* Rebase / update snapshots

* Fix fulfilled from label position

* Update snapshots

* Change messages names in oRderPayment

* Fix Pill overflowing

* Update snapshots
2022-02-17 12:08:17 +01:00
Michał Droń
394c33c0b5
Refactor changing address in order details directly (#1697) (#1818)
* Refactor changing address in order details directly (#1697)

* wip change address edit buttons behaviour in order draft

* wip modify dialog view when customer is not changed

* wip remove old address edit modal

* wip rm old address modal storybook

* wip async search state change

* wip disable edit in draft when no customer is selected

* wip fix submitting issues

* wip allow single address mutation

* wip fix billing change & manual address change

* wip fix covered country dropdown

* wip add address clone checkbox

* wip normal order details & unconfirmed views

* wip messages minor fixes

* wip clone address checkbox on new address input option

* Storybook update

* cleanup

* billing same as shipping fixes

* improve stories titles & move to component folder

* improve continueToAddressSearchState readibility

* improve dialog title/description message descriptors

* change .then() to await

* Remove redundant onClick arrow function

Co-authored-by: Dominik Żegleń <flesz3@o2.pl>

* Improve OrderAddressFields component

* move shipping & billing address edit props outside file

* Update snapshots

* fix mutation output types in order views

* Fix confirm button state type

* fix skipping query when modal is refreshed

* fix cancel button to match designs

* update dialog headers

* fix customer address choice card styling for blue theme

* change hidecard to showcard

* export types to local file

* improve isAnyAddressEditModalOpen function

* fix cut hover effect on inputs

* fix submitting modal when modal is closed with x button

* fix validation & initial form data

* update messages

* Update partial mutation return type

* Add vertical spacer component

* Revert CardSpacer changes

* Change some of Form & Card spacers to Vertical Spacers

* Fix makeStyles import in VerticalSpacer

* Fix border color for AddressCards

* Add type to addressFieldsCommonProps object

* Change stories subtitles to lowercase

* Fix country choices type

* Fix setState react type

* Improve address change handlers

* Update snapshots

* Fix default country not showing up in address edit single autocomplete field

Co-authored-by: Dominik Żegleń <flesz3@o2.pl>
Co-authored-by: Magdalena Markusik <magdalena.markusik@mirumee.com>

* Fix linter issue

Co-authored-by: Dominik Żegleń <flesz3@o2.pl>
Co-authored-by: Magdalena Markusik <magdalena.markusik@mirumee.com>
2022-02-02 12:22:39 +01:00
Michał Droń
519b816afa
Add hover tooltip on sorting disabled columns (#1811)
* Add hover tooltip on sorting disabled columns in lists (#1784)

* Update macaw

* Add TooltipTableCellHeader component

* Add filterDependency type to lists

* Add tooltip to conditional columns in Voucher List

* Add tooltip to conditional columns in Sale List

* Add tooltip to conditional columns in Collection List

* Add tooltip to conditional columns in Product List

* Update snapshots

* Improve component clarity

* Change TableCellHeader to React.forwardRef component

* Change TooltipTableCellHeader to use TableCellHeader

* Remove RefTableCellHeader

* Bump macaw

* Update snapshots

* Remove merge conflict leftovers

* Add tooltip header to gift card list

* Refactor gift card list tooltip

Co-authored-by: Wojciech <wojciech.mista@hotmail.com>
2022-02-02 09:48:12 +01:00
Dominik Żegleń
f8254fd11b
Bump macaw to 0.3 (#1807)
* Update to new design theme (#1631)

* Update macaw to 0.3.0 (#1623)

* Update macaw to 0.3

* Use proper pagination component

* Fix type errors

* Remove leftover import

* Remove variant and color from confirm button

* Remove alias

* Update macaw

* Fix button type

* Random fixes (#1633)

* Improve layout components

* Use colored svgs

* Minor fixes

* Fix autocomplete loaders

* Fix padding

* Fix button variant

* Remove codegen file

* Fixes after bumping macaw to 0.3 part 2 (#1638)

* Fix various visual bugs

* Fix type errors

* Bump macaw

* Random fixes part 3 (#1647)

* wip

* Fix mismatched paddings

* Fix actions container padding

* Put story in the right directory

* Fix shipping zone picker

* Fix minor visual bugs

* Remove unused imports

* Move styles to separate file

* Random fixes part 4 (#1641)

* Fix various visual bugs

* Fix type errors

* Fix last table item padding

* Add outline on hover

* Fix spaces

* Fix spaces

* Remove dead code

* Fix elevation

* Remove dead code

* Fix shadows

* Add outline to expand button

* Fix spacing

* Fix spacings

* Fix selectable tables hover

* Use proper delete icon

* Fix ConfirmButtonTransitionState imports

* Update src/apps/components/CustomApps/CustomApps.tsx

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>

* Rework error page (#1670)

* Remake error page

* Fix types

* Update error id styles

* Fix types

* Login page rework (#1703)

* Rework login page

* Remove outline

* Fix logo and footer placement

* Sort imports

* Random fixes part 5 (#1669)

* Fix text color in dark mode

* Update password reset pages (#1714)

* Update password reset pages

* Update src/auth/components/ResetPasswordPage/ResetPasswordPage.tsx

Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>

Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>

* Fix collection page

* Update dark mode logo

* Bring back "create app" button

* Fix spacings

* Fix selects

* Fix login e2e test

* Fix not found page displaying

* Update selector

* Add missing package

* Let dropdown overflow through card

* Fix scroll

* Fix scroll

* Fix overflow on grid element

* Fix e2e tests

* Fix data-test-id

* Update snapshots

* Update messages

* Update macaw

* Update snapshots

* Use stable macaw version

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>
Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>

* Update to new design theme (#1631)

* Update macaw to 0.3.0 (#1623)

* Update macaw to 0.3

* Use proper pagination component

* Fix type errors

* Remove leftover import

* Remove variant and color from confirm button

* Remove alias

* Update macaw

* Fix button type

* Random fixes (#1633)

* Improve layout components

* Use colored svgs

* Minor fixes

* Fix autocomplete loaders

* Fix padding

* Fix button variant

* Remove codegen file

* Fixes after bumping macaw to 0.3 part 2 (#1638)

* Fix various visual bugs

* Fix type errors

* Bump macaw

* Random fixes part 3 (#1647)

* wip

* Fix mismatched paddings

* Fix actions container padding

* Put story in the right directory

* Fix shipping zone picker

* Fix minor visual bugs

* Remove unused imports

* Move styles to separate file

* Random fixes part 4 (#1641)

* Fix various visual bugs

* Fix type errors

* Fix last table item padding

* Add outline on hover

* Fix spaces

* Fix spaces

* Remove dead code

* Fix elevation

* Remove dead code

* Fix shadows

* Add outline to expand button

* Fix spacing

* Fix spacings

* Fix selectable tables hover

* Use proper delete icon

* Fix ConfirmButtonTransitionState imports

* Update src/apps/components/CustomApps/CustomApps.tsx

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>

* Rework error page (#1670)

* Remake error page

* Fix types

* Update error id styles

* Fix types

* Login page rework (#1703)

* Rework login page

* Remove outline

* Fix logo and footer placement

* Sort imports

* Random fixes part 5 (#1669)

* Fix text color in dark mode

* Update password reset pages (#1714)

* Update password reset pages

* Update src/auth/components/ResetPasswordPage/ResetPasswordPage.tsx

Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>

Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>

* Fix collection page

* Update dark mode logo

* Bring back "create app" button

* Fix spacings

* Fix selects

* Fix login e2e test

* Fix not found page displaying

* Update selector

* Add missing package

* Let dropdown overflow through card

* Fix scroll

* Fix scroll

* Fix overflow on grid element

* Fix e2e tests

* Fix data-test-id

* Update snapshots

* Update messages

* Update macaw

* Update snapshots

* Use stable macaw version

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>
Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>

* Fix visual bugs and artifacts

* Fix dropdown menus being clipped (#1762)

* wip

* Fix clipped select menus

* Remove unused import

* Fix spacing

* Fix tests

* Fix select content appearing under dialogs (#1777)

* Fix type errors

* Fix bulk delete button placement

* Fix filter arrow buttons

* Fix messages

* Remove backling from pages list

* Move status above events

* Update messages and snapshots

Co-authored-by: Wojciech Mista <wojciech.mista@saleor.io>
Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>
2022-01-28 13:34:20 +01:00
Magdalena Markusik
185a48b421
Add filters and search to gift cards list (#1466)
* Fix filters not handling autocomplete values properly

* Add handling single selection to filter autocomplete field

* Change giftCardsListUrl function name to GiftCardListUrl for consistency

* Update schema

* Add gift card currencies query and update types

* Add validating function for filter number fields

* Add util function for mapping person node to select choice, fix types

* Add gift card list filters and search

* Add handling of gift card list search and filters dialogs in dialogs provider

* Add gift card search bar in gift card list

* Update gift card list queries and types, add filters to gift card list provider

* Fix types

* Fix types

* Fix currency filters in gift card list

* Update messages

* Remove unnecessary usages of maybe

* Change gift card balance filters not to be send to api when currency filter not present

* Update messages
2021-10-13 14:42:20 +03:00
mmarkusik
dae95cb410
Add Gift Cards #1 (#1291)
* Add gift cards section to menu and add empty list component

* Update messages

* Change styling of app wide page header to match design

* Add gift cards list table wip

* Update prop name for status chip component to make it more consistent with other components

* Replace old trash icon with new one

* Add Size type based on action dialog sizes to be used app wide

* Add delete icon button

* Add new sizes option to status chip component

* Add / update gift cards list components

* Add bulk actions type

* Work on gift cards list WIP

* Small refactor

* Fix styling of gift cards table

* Remove temp files

* Remove unnecessary type

* Add gift cards section to menu and add empty list component

* Update schema and types

* Add link to gift card update page to gift cards list and add route to gift cards index

* Extract order page title with status chip into a separate generic component and use it in order page title

* wip

* Update money component

* Add gift card details card balance section

* Refactor gift card details

* Add vertical spacer component

* Update schema and types

* Add gift card tag input component along with necessary queries

* Add gift card tag input to gift card update page

* Add gift card update details card expiry section WIP

* Add time period select field WIP

* Post rebase refactor

* Add time period select field to gift card update view

* Fixes after review

* Update schema, types and gift cards query

* Add getFullName util function and replace existing manual usages

* Add text with select field component

* Add gift card update info card and refactor

* Fix import

* Add displaying order link in gift card update

* Refactor

* Connect gift card list to api

* refactor

* Add gift card create dialog

* Fix gift card list styles, change location for gift card list query, minor refactor

* Fix menu structure data for gift cards

* Add channel currencies type to shop

* Refactor text with select field

* Add gift card expiry select component

* Add gift card error type and fragment

* Update global types

* Add default prop to getFormErrors function

* Move gift card details provider to providers dir

* Update global utils with mapSingleValueNodeToChoice function

* Update gift card tag input

* Move and refactor time period field

* Update schema

* move format money function to other money ulities

* Update gift card urls

* Add content or skeleton component

* Add gift card create util for extracting expiry settings input data

* Remove content or skeleton component and move displaying logic to existing skeleton

* Move displaying logic of gift card create dialog to list

* Refactor

* Add hooks for gift card bulk actions and gift card list to be used instead of context directly

* Fix types for text with select field + add parsing for number typed field

* Add initial currency to gift card create form

* Fix gift card create dialog closing animation

* Add gift card update info card

* Refactor gift card update details card

* Add gift card balance dialog

* Move gift card update form providers to providers dir

* Connect gift card update page to api, add necessary contexts etc.

* Refactor

* Refactor

* Add hooks to use instead of gift card contexts directly

* Fix types

* Fix text field target name missing in passed event in text with select field

* Add minimal value option to text with select field, add to gift card inputs

* Fix gift card update balance dialog not changing hasChanged prop after submit

* Refactor

* Fix update balance dialog crashing the app when enetered wrong amount

* Fix gift card list table header styles

* Add enable / disable section to gift card update

* Refactor

* Refactor

* Refactor

* Add metadata to gift card update

* Update messages ids

* Refactor

* Refactor

* Refactor

* Refactor

* Update types after rebase

* Fix types

* Fixes after qa

* Fix tests
2021-08-16 15:44:00 +02:00
Dawid Tarasiuk
64c0f0fcc4
Update list settings types (#1165) 2021-06-15 17:15:14 +02:00
Dawid Tarasiuk
88e5db054f
Fix product type translations (#1163)
* Fix product type translations

* Update changelog
2021-06-15 10:10:13 +02:00
Dawid Tarasiuk
c3e720a47e
Saleor 3087 Paginate attribute values in filters (#1152)
* Dynamic fetch attribute values in filter list

* Update filter attributes fixtures

* Change attribute values filter to autocomplete field

* Fix unchecking attribute value filter failure

* Update test snapshots

* Update changelog

* Fix cypress tests

* Add slug node mapping util
2021-06-14 15:31:41 +02:00
Dawid Tarasiuk
f5324cee60 SALEOR-3345 Attribute values pagination on attribute details page (#1116)
* Attribute values pagination on attribute details page

* Update test snapshots

* Update values pagination in attribute create page

* Trigger CI

* Update attribute valus list pagination settings

* Update attribute details queries

* Fetch only attribute values after values update
2021-06-08 09:51:26 +02:00
mmarkusik
bb441ea11a
Add product / page delete warning (#1095)
* Add Delete button component

* Add product / page type delete warning dialog

* Replace old product types delete dialog with new one, add products total count query

* Update schema, types and queries for pages, add use page count query and add warning delete dialog to page types

* Move type delete warning dialog data to proper hooks, refactor

* Remove unused components and stories

* Add plural forms to messages for product / page type delete warning, refactor

* Add type delete warning dialog stories

* Move type delete hooks to proper directiories, fix imports

* Fix imports

* Remove countallproducts query and instead use useproductcountquery

* Remove unnecessary types and imports
2021-05-11 14:26:17 +02:00
mmarkusik
8fe66a3bde
Add channel shipping zones (#1015)
* Add naked input option to SingleAutocompleteSelectField and update it's stories

* Add new icons - chevron up, down & trash

* Add deletable item component and stories

* Add card add items footer component to be used in warehouses and product stocks assign

* Update schema and types

* Add shipping zones card components

* Update channel details page form to also include shipping zones

* Update makeTopLevelSearch hook files directory and add getSearchFetchMoreProps function to avoid extracting it manually every time

* Update channels types & fragments

* Move getDefaultNotifierSuccessErrorData function to useNotifier utils, update dir etc., also make order discount provider use it from the new dir

* Add shippinh zone to channel update and create and add shipping zone search

* Update messages

* Fix types

* Fix lint, types etc

* Small refactor from review and quick fix styles of shipping zones card

* Refactor a bit and update snapshots

* Refactor a bit and update snapshots

* Addd / refactor channels availability components

* Add useChannelsWithProductVariants hook with utils and types

* Add / refactor more channels availability components

* Move avatar from table cell avatar to separate component for it to be usable outside of tables

* Add channels with variants logic to product create and update pages & views

* Refactor components to use updated channels availability components

* Remove unnecessary comments

* Update storybook

* Update types

* Update messages

* Fix prices for variants / simple product not uodating properly

* Post merge cleanup, update schema, types, etc.

* Change shipping zone details warehouses card into settings card and add ability to assign channels to shipping zone

* Update types

* Update snapshots

* Fix selecting / deselecting all channels in channels with variants modal

* Fixes after review, some types changes etc.

* Update snapshots

* Small types fixes

* Make price rates views use parent shipping method channels instead of all

* Make price rates views use parent shipping method channels instead of all

* Update types

* Fix bugs

* Fixes after review

* Fix channels availability data submission

* Fix lint

* Fix variant pricing card showing not related channels

* Fixes after review

* Fix types

* Hide unaviable variants in add products to draft order dialog

* Fix channels with variants availability modal showing confirm button as enabled when it shouldn't

* Fix types

* Update semi checked icon to match old designs

* Update types

* Update channels icon in channels with variants availability

* Fix product cypress test after product channels mutation changed

* Fix trash and chevron down colors in dark mode

* Fix shipping zones card footer not updating query after click away

* Fix types in schema, add condition not to display shipping zones select in channel details if all zones have already been selected

* Fix products adding in order draft dialog

* Fix simple productupdate

* Update snapshots after merge with master

* Update messages

* Fix product api request for cypress

* Add missing test id

* Fix selecting if product is simple -> form being submitted with empty data sometimes

* Update snapshots, messages and add fix for invalid date at product update

* Remove unnecessary imports

* Fix failing test in saleor 2552 (#1061)

* fix

* fix

* fix

Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>
Co-authored-by: Karolina <rakoczy.karolina@gmail.com>
2021-04-14 15:44:25 +02:00
Jakub Majorek
a7736e2bf9
Attach permission variables to all queries (#1000)
* [SALEOR-2190] Attach permission variables to all queries

* Fix TS linter issues

* Update package-lock
2021-03-09 09:44:09 +01:00
Dominik Żegleń
a175fb9497
Add global channel picker (#841)
* Move theme switch to user menu

* Add global channel picker

* Fix picker styles

* Use app channel state

* Improve prop naming to indicate id vs slug

* Disable picker if no reason to pick channel

* Remove settings modal leftovers

* Remove channel settings dialog

* Remove unused props

* Skip channel fetching if user is not authenticated

* Remove channel selection from components

* Update messages

* Fix e2e tests

* Remove channel picker leftover

* Revert ChannelSettingsDialog deletion

* Update snapshots

* Update messages
2020-11-23 10:39:24 +01:00
Dawid Tarasiuk
fc02fce701
Page types (#807)
* Create attribute class selector

* Use ProductAttributeType to check if product is simple or with variants

* Allow attribute class selection only during its creation

* Update attribute type selection translations

* Show only product attributes in columns picker on product list view

* Cleanups in Attribute Organization component

* Create Page Types list page

* Create content management section in settings

* Implement page types list view

* Remove unused imports from page type list

* Updatte page type list style

* Remove legacy code from page type list component

* Update PageTypeListPage component

* Create Page Types details page

* Fix page type attribute reordering

* Implement PageType create view

* Implement PageType update view

* gUpdate page type details components

* Fix page type update component

* Update page type components stories

* Update page type errors handling

* Update page type details view

* Create Page Types details page

* Implement PageType create view

* Update product attribute assignment mutations

* Add page types attribute assignment mutations

* Add page types attribute assignment handling

* Temporarily fix page create mutation

* Update page type error messages

* Remove legacy storybook page type stories

* Update attribute assignment dialogs stories

* Update page type details error handling

* Update props for page type components

* Create attribute class selector

* Implement page types list view

* Add page type selector on page create and details views

* Add attributes list to page details views

* Update page types list

* Use attribute errors for attributes muatations

* Save attribute values on page create and update

* Update messages for page view

* Update page attributes fragment

* Use AttributeError in AttributeBulkDelete

* Update page type and its attribute selection

* Handle page types deleting

* Update page types deleting messages

* Handle page types attribute reorder

* Fix PageOrganizeContent component types

* Update graphqql types

* Fix page fixture

* Update messages

* Update test snapshots

* Pass pageTypes to PageForm

* Update changelog with page type addition note

* Update package-lock

* Update test snapshots

* Fix malformed generated type

* Update messages after rebase
2020-11-19 15:42:14 +01:00
Dominik Żegleń
6f9060144a
Multichannel (#833)
* add multichannel to configuration view

* create multichannels list view

* create multichannels list view

* add ChannelsCreate view

* update channels in configuration

* add stories

* update default messages

* fix ChannelForm props

* update channels list styles

* update snapshots

* update channel form currency input

* update Channels fragments

* extract messages

* remove tabs from channelsList

* channel details, channel delete modal (#598)

* create Channel details view

* create ChannelDeleteDialog

* add channels delete dialog to channels list

* update messages and types

* fixes after review

* channels availability (#609)

* create Channel details view

* update messages and types

* create ChannelsAvailability component

* create more product channels components

* create channels stories, update fixtures, types

* update product views with channels data

* update schema and snapshots

* update defaultMessages

* update ProductUpdate view

* create ChannelsAvailabilityDropdown component

* add product channels to local storage

* update globalTypes

* Update to new schema and resolve issues

* Update messages

* create deleteChannel mutation

* add channels availability component to product create view

* refactor ProductCreate and ProductUpdate views

* CollectionProducts view cleanup

* add disabled prop to ActionDialog

* use updateChannels mutation in ProductCreate view

* ProductCreate - update submit function

* fixes after review

* update snapshots and messages

Co-authored-by: Krzysztof Wolski <krzysztof.k.wolski@gmail.com>

* channels shipping components (#655)

* create PricingCard, OrderValue and OrderWeight components

* create ShippingZoneRatesPage and DeleteShippingRateDialog

* update ChannelsAvailability component

* updates after review

* channels shipping views (#662)

* update ChannelsAvailability component

* updates after review

* create PriceRate views, update types

* create weight rates views

* update shipping views, stories, messages

* update snapshots

* update snapshots

* update useChannels hook

* orders channels components (#698)

* create OrderChannelSectionCard component

* update OrderDetailsPage

* update DraftOrderChannelCard

* update snapshots

* update fixtures

* small change after review, update snapshots

* product pricing (#702)

* update product types

* update Pricing in simple product view

* use productVariantCreate mutation in simple product view

* update snapshots and messages

* handle create variant (#715)

* update product types

* update Pricing in simple product view

* handle product create and update errors

* update snapshots and messages

* fix update and create product handlers

* update pricing types

* channels modal - new styles, search input (#717)

* update product types

* update Pricing in simple product view

* handle product create and update errors

* update pricing types

* add search input in ChannelsAvailabilityDialog

* update ChannelsAvailabilityDialog in all views

* update snapshots

* fix search input label styles

* update toggleAllChannels function

* update variant creator (#724)

* update product types

* update Pricing in simple product view

* handle product create and update errors

* update pricing types

* add search input in ChannelsAvailabilityDialog

* update ChannelsAvailabilityDialog in all views

* update snapshots

* add channelLisitngs to variant creator

* update variant creator price styles

* update product variant creator reducer tests

* update createVariants tests

* update error handling in product variant creator

* add Skip pricing for now option

* use PriceField instead of TextField in ProductVariantCreatorSummary

* create price validation function

* fix errors handling in ProductVariantPrice component

* fixes after review

* Product List - remove publish/unpublish buttons (#727)

* ProductList - remove publish and unpublish buttons

* update messages

* update snapshots, messages

* revert changes in ChannelsAvailabilityDropdown

* products/shipping/discount list settings (#739)

* create ChannelSettingsDialog component

* update snapshots

* ProductList - open settings modal when there is no selected channel

* add settings modal to vouchers list

* add settings dialog to sales list

* add setting modal to shipping list

* update shipping

* update snapshots, messages

* useChannelsSettings - remove selectedChannelSlug

* fix channels update handler in product and shipping view

* messages update in ChannelSettingsDialog

* handle product/discount list when there is no channels

* update onSettingsOpen prop

* collection availability dropdown (#743)

* add availability dropdown to collection products list

* update channelListingProduct fragment name

* update voucher view/components with channels (#746)

* update voucher view/components with channels

* update VoucherSummary, remove defaultCurrency from voucher components

* update snapshots

* move getChannelsVariables func to discounts handlers

* update voucher messages

* sale view/components with channels (#750)

* update sale views with channels

* small fixes in discounts

* order views with channels (#752)

* update draft orders with channels

* add channel activate/deactivate mutations

* remove sort by total in orders list

* add error notification on channel activate/deactivate

* product variants channel select (#755)

* add channels selector to ProductVariants component

* remove selectedChannel from ProductUpdate, update messages and snapshots

* update product fragments

* update translations (#762)

* update translations

* fix translation types

* update messages

* update Availability component (#766)

* update ChannelsAvailability component

* update product fixtures

* update collection and channel fixtures

* ChannelsAvailability - handle errors

* update product handlers

* update ChannelsAvailability styles

* update ProductVariant

* update snapshots

* fix missing things in multichannel  (#785)

* add availability dropdown to discount products list

* fix error handling in shipping components

* update product views and components

* update messages

* update category view/components

* update CategoryProducts styles

* remove defaultCurrency from shipping components

* create ChannelsSelect component

* update channels error handling after review

* another fixes after review

* Add channels to collection views/components (#791)

** update collection components and views

* update create collection view

* update error handling in collection

* remove filter bar from collection list

* update products fragments

* small fix in collection create view

* use collectionFragment in useCatalogSearch

* update defaultMessages and snapshots

* update homepage view/drop defaultCurrency (#801)

* update homepage view

* drop defaultCurrency prop

* fix onChannelChange function in home view

* remove visibility from product list filters

* update export products with channels (#803)

* update ProductExportDialog with channels

* add new channel error code

* remover VISIBLE from product export dialog Financial information

* fix input size in ProductVariantCreatorSummary (#804)

* channels currency code select (#806)

* create select with currency codes

* fix ChannelDeleteDialog

* update defaultMessages, remove unneeded ChannelDetails handlers

* fixes after rebase

* replace channelListing with channelListings

* [multichannel] Update schema]

* Fix product create test

Co-authored-by: AlicjaSzu <alicja.szukuc@gmail.com>
Co-authored-by: Krzysztof Wolski <krzysztof.k.wolski@gmail.com>
Co-authored-by: Jakub Majorek <majorek.jakub@gmail.com>
2020-11-17 17:10:42 +01:00
AlicjaSzu
211b0b892d
Apps (#599)
* create Apps view

* create more app components, generate types and messages

* apps refactor, update snapshots

* show error message in tooltip  when app installation fail

* update apps components and view, add apps list to storybook

* update defaultMessages

* create app details view

* update AppListPage with Skeleton component

* create app activate/deactivate dialogs, create app details stories

* add AppHeader to AppDetailsPage

* update defaultMessages

* update AppDetails view and components after review

* create custom app details view

* refactor webhooks

* update webhooks fixtures

* update WebhookDetailsPage story

* update strings

* create CustomAppCreate view and components

* update AppListPage story

* create AppInstall view and page

* handle errors in AppInstall view

* update defaultMessages

* add AppInstallPage to storybook

* add status prop to MessageManager

* update defaultMessages

* remove service account section

* remove service account routes

* remove as operator from notify status

* add notifications for app installations

* update styles for deactivated app

* update app installations with local storage

* update defaultMessages

* AppInstall update

* dd delete button to ongoin installations table

* fix active installations condition

* fix error messages in AppsList

* update defaultMessages

* add iframe to AppDetailsPage

* create AppDetailsSettingsPage

* install macaw-ui

* apps styles clean up

* update schema, fixtures

* few apps updates

* WebhookCreate - fix onBack button name

* WebhookCreatePage story update

* rename apps table from external to thirdparty

* update defaultMessages

* fix test, update snapshots

* AppDetailsSettings - add token to headers

* fix first number in local apps query

* app details settings - use shop domain host

* add onSettingsRowClick to InstalledApps

* resolve conflicts

* update changelog and messages

* add noopener noreferrer do app privacy link

* update snapshots

* update snapshots

* updates after review

* update defaultMessages

* CustomAppDetails - add missing notify status
2020-07-22 12:54:15 +02:00
dominik-zeglen
eddec1a5c2 Move fragments to avoid circular imports 2020-07-07 12:14:12 +02:00
dominik-zeglen
fbc809879f Add warehouse search 2020-04-28 16:33:10 +02:00
dominik-zeglen
414f6d7a3d Add warehouse list view 2020-04-28 16:28:33 +02:00
Krzysztof Wolski
082a12e0b8
Permission groups section (#406)
* Add permission groups 👪
2020-04-23 17:43:08 +02:00
dominik-zeglen
381665409f Rebase fixes 2020-03-24 15:05:26 +01:00
Dominik Żegleń
bf92214fc3
Revert "Use error formatting in product type section" 2020-03-11 10:56:04 +01:00
dominik-zeglen
db14154c34 Use error formatting in attribute view 2020-03-04 13:50:25 +01:00
dominik-zeglen
c4863ece60 Do not store errors in form component 2020-02-24 15:14:48 +01:00
dominik-zeglen
8ddf66f134 Add attribute filter 2020-01-20 16:47:46 +01:00
dominik-zeglen
aeb209744a Add category and collection filter 2020-01-20 16:47:18 +01:00
dominik-zeglen
a7304dabb0 Create generic filtering handlers 2020-01-20 16:46:02 +01:00
dominik-zeglen
1f3cbfda82 Code cleanup 2020-01-20 16:45:10 +01:00
dominik-zeglen
32cdb56e6f Make order filters work 2020-01-20 16:45:08 +01:00
dominik-zeglen
aafa6b62dc Refactor filter components 2020-01-20 16:45:07 +01:00
dominik-zeglen
bf0bad5a5e Rename state to status prop 2019-12-06 18:17:44 +01:00
dominik-zeglen
491f1decff Unify interfaces 2019-12-06 18:14:19 +01:00