[solidus_admin] Add stores editor - #6589
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6589 +/- ##
==========================================
+ Coverage 92.26% 92.29% +0.02%
==========================================
Files 1037 1040 +3
Lines 21241 21274 +33
==========================================
+ Hits 19598 19634 +36
+ Misses 1643 1640 -3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
914aa77 to
f9b25d2
Compare
|
I am still absorbing the best practices for committing to |
4ffd364 to
aceb5cb
Compare
Store deletion can be aborted if we are deleting a default store, so we'll show alert in that case.
We don't have to use turbo_frames on these pages since we are not loading content into it but always do a page visit to /new and /edit routes, and when server responds with 422 and templates with validation errors we can just place relevant "id" on the topmost element of the page so its content will be replaced with turbo stream.
To fix the following issues:
standard: Use Ruby Standard Style (https://github.com/standardrb/standard)
admin/app/components/solidus_admin/stores/form/component.rb:14:15: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/components/solidus_admin/stores/index/component.rb:35:15: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/components/solidus_admin/stores/index/component.rb:36:35: Style/TrailingCommaInHashLiteral: Avoid comma after the last item of a hash.
admin/app/components/solidus_admin/stores/index/component.rb:37:8: Style/TrailingCommaInArrayLiteral: Avoid comma after the last item of an array.
admin/app/components/solidus_admin/stores/index/component.rb:46:21: Style/TrailingCommaInArrayLiteral: Avoid comma after the last item of an array.
admin/app/components/solidus_admin/stores/index/component.rb:56:54: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/components/solidus_admin/stores/index/component.rb:65:53: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/components/solidus_admin/stores/index/component.rb:74:54: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/components/solidus_admin/stores/index/component.rb:83:36: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/components/solidus_admin/stores/index/component.rb:83:64: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/controllers/solidus_admin/stores_controller.rb:26:26: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
admin/app/controllers/solidus_admin/stores_controller.rb:26:36: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
admin/app/controllers/solidus_admin/stores_controller.rb:26:80: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
admin/app/controllers/solidus_admin/stores_controller.rb:26:82: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
admin/app/controllers/solidus_admin/stores_controller.rb:28:28: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/app/controllers/solidus_admin/stores_controller.rb:51:30: Style/TrailingCommaInArguments: Avoid comma after the last parameter of a method call.
admin/spec/requests/solidus_admin/stores_spec.rb:4:9: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/spec/requests/solidus_admin/stores_spec.rb:9:20: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/spec/requests/solidus_admin/stores_spec.rb:9:46: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
admin/spec/requests/solidus_admin/stores_spec.rb:11:31: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
admin/spec/requests/solidus_admin/stores_spec.rb:11:118: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
admin/spec/requests/solidus_admin/stores_spec.rb:12:33: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
admin/spec/requests/solidus_admin/stores_spec.rb:12:42: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
core/spec/models/spree/store_spec.rb:145:58: Lint/AmbiguousRegexpLiteral: Ambiguous regexp literal. Parenthesize the method arguments if it's surely a regexp literal, or add a whitespace to the right of the `/` if it should be a division.
standard: Run `standardrb --fix` to fix up to 24 problems.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/TrailingCommaInHashLiteral: Avoid comma after the last item of a hash.
Error: Style/TrailingCommaInArrayLiteral: Avoid comma after the last item of an array.
Error: Style/TrailingCommaInArrayLiteral: Avoid comma after the last item of an array.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/TrailingCommaInArguments: Avoid comma after the last parameter of a method call.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Style/StringLiterals: Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside { detected.
Error: Layout/SpaceInsideHashLiteralBraces: Space inside } detected.
Error: Lint/AmbiguousRegexpLiteral: Ambiguous regexp literal. Parenthesize the method arguments if it's surely a regexp literal, or add a whitespace to the right of the `/` if it should be a division.
Error: Process completed with exit code 1.
aceb5cb to
f7c77a8
Compare
tvdeyen
left a comment
There was a problem hiding this comment.
Works great. Thanks for taking this over.
That's what I post to everyone asking me about commit messages: https://cbea.ms/git-commit/ Especially this
I don't have to add much to that :) |
Summary
Replaces #6228.
This pull request creates the initial store creator and editor interface for
solidus_admin. I have co-opted an old pull request implementing this feature and have verified, after rebasing againstmainand resolving merge conflicts, that it's in working order.Since I am creating this replacement PR, I will take responsibility for resolving any issues that come up as the result of code review.
Checklist
The original author checked off all checklist items on the original pull request #6228.
Check out our PR guidelines for more details.
The following are mandatory for all PRs:
The following are not always needed: