Commit Graph

588 Commits

Author SHA1 Message Date
Isaac Janzen 74dfc39530
Upgrade query-row-content to Octane (#194)
* Upgrade query-row-content to octane
2022-12-13 09:21:01 -06:00
Isaac Janzen fea231f200
Upgrade share-report to Octane (#195)
* Upgrade share-report to Octane

* add requested changes
2022-12-13 08:49:39 -06:00
Discourse Translator Bot 467b6c8a91
Update translations (#193) 2022-11-29 15:36:46 +01:00
Sam 2313237a95
FIX: better handling of edge cases (#187)
- Require query name is present
- Ensure all routes are treated by default as .json, so errors flow correctly
- Remove superflous save/cancel controls from group settings
- Remove group control when item is destroyed
- Disable editing of query when it is deleted

Co-authored-by: Osama Sayegh <asooomaasoooma90@gmail.com>
2022-11-18 07:09:50 +11:00
discoursebot 41a5e0a27a
DEV: Update CI workflows (#192)
Co-authored-by: discoursebuild <build@discourse.org>
2022-11-07 12:32:48 -06:00
Martin Brennan bf1a79c9ad
FIX: Click not opening query (#191)
Due to recent core changes for Ember in
0221855ba7
and 952b033165
the correct way of calling these actions must be observed,
otherwise clicking on a query did nothing.

This commit fixes the click and also makes scrollTop
work with the new {{on X}} Ember syntax.
2022-10-28 14:56:01 +10:00
Penar Musaraj 0deecbe2ae
DEV: Replace bootbox alert dialogs (#190) 2022-10-18 14:13:00 -04:00
Alan Guo Xiang Tan 4236689d27
FIX: Errors when running query due to PG template patterns or comments (#189)
Before this fix, the use of PG template patterns containing ":" or the
use of "?" in comments in the SQL will result in an error being raised
because `DB.param_encoder.encode` calls ActiveRecord's `sanitize_sql_array` which is
meant for SQL fragments and not an entire SQL string.

Instead we change data-explorer to use `MiniSql::InlineParamEncoder`
instead which takes into account of template patterns and does not trip
on `?` which is a special param encoding character used by ActiveRecord.
2022-10-10 09:03:37 +08:00
David Taylor 729e5a2add
DEV: Bump rubocop-discourse (#188)
* DEV: Bump rubocop-discourse

* Fix rubocop violations
2022-10-03 22:20:04 +02:00
Frank 16bb6a946c
FIX: Allow groups to access system queries (#185)
* FIX: allow groups to access system queries (without having to run the query once first)

Bug is: Trying to allow a group to access a system query results in a Discourse::NotFound unless the query is run first.

Cause:

 - System queries don't exist in the database by default
 - update calls set_query before action
 - set_query searches the database for the system query with Query.find_by(:id), which will not exist by default.
 - running system queries first fixes this because Query.find is overridden to include system queries (Queries.default) in its results, avoiding the Discourse::NotFound.

Solution: use the overridden Query.find in set_query to include system queries in the search, instead of Query.find_by(:id)

* Added test for fixing allowing groups to access system query.

* Fixed test formatting.
2022-08-19 00:14:07 +08:00
Frank 82ec10d844
FIX: fixed the blueing of the bookmark icon (#186) 2022-08-19 00:07:35 +08:00
Osama Sayegh bf56ab3559
DEV: Update last .discourse-compatibility entry's target to 2.9.0.beta6
We can't target 2.9.0.beta7 because it pins the plugin version on installed on `tests-passed` site because the Discourse version in `tests-passed` is 2.9.0.beta7.

Follow-up to a48b7d1ab5
2022-07-18 14:59:14 +03:00
Martin Brennan a48b7d1ab5
DEV: Bookmarkable reminder refinement (#183)
Incorporates changes from core
 0ca1152c1c
2022-07-18 13:40:24 +10:00
Constanza 272e9dd760
UX: Making the headers of the query results table sticky (#182) 2022-07-06 19:08:37 -04:00
Discourse Translator Bot 8a1bdb5759
Update translations (#181) 2022-06-21 15:27:08 +02:00
discoursebot 00b669a37d
DEV: Update CI workflows (#180)
Co-authored-by: discoursebuild <build@discourse.org>
2022-06-17 21:34:29 +02:00
Jarek Radosz 07e009e862
DEV: Update linting setup and fix issues (#179) 2022-06-17 15:01:34 +02:00
Isaac Janzen 780232c902
DEV: Remove use of run-loop-and-computed-dot-access (#178)
Context: https://deprecations.emberjs.com/v3.x/#toc_deprecated-run-loop-and-computed-dot-access
2022-06-17 14:18:36 +02:00
Frank 45b6e7eb4f
FEATURE: Bookmarkable QueryGroups. (#177)
Adds the ability for non-Admin users to bookmark Queries from inside Group > Reports > Query view.
2022-06-14 23:07:02 +08:00
Isaac Janzen 92bdea38b2
DEV: Remove 'htmlSafe' string prototype extensions (#176)
Context: https://deprecations.emberjs.com/v3.x/#toc_ember-string-prototype_extensions
2022-06-01 11:42:50 -05:00
discoursebot 6223c2d8a5
DEV: Update CI workflows (#175)
Co-authored-by: discoursebuild <build@discourse.org>
2022-05-23 17:00:09 +02:00
Gerhard Schlager 65a112c8d2
FIX: Edit button shouldn't be visible for seeded queries (#174) 2022-05-17 18:05:05 +02:00
Isaac Janzen 01f52dc5c5
DEV: Remove 'dasherize' string prototype extensions (#173)
Context: https://deprecations.emberjs.com/v3.x/#toc_ember-string-prototype_extensions
2022-05-13 12:43:37 -05:00
Isaac Janzen d5e11a2c65
DEV: Remove 'capitalize' string prototype extensions (#172)
Context: https://deprecations.emberjs.com/v3.x/#toc_ember-string-prototype_extensions
2022-05-13 12:33:38 -05:00
dependabot[bot] 9d9bf9051f
Build(deps): Bump async from 2.6.3 to 2.6.4 (#171)
Bumps [async](https://github.com/caolan/async) from 2.6.3 to 2.6.4.
- [Release notes](https://github.com/caolan/async/releases)
- [Changelog](https://github.com/caolan/async/blob/v2.6.4/CHANGELOG.md)
- [Commits](https://github.com/caolan/async/compare/v2.6.3...v2.6.4)

---
updated-dependencies:
- dependency-name: async
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-29 18:04:10 +02:00
dependabot[bot] baaac7ce67
Build(deps): Bump ansi-regex from 4.1.0 to 4.1.1 (#170)
Bumps [ansi-regex](https://github.com/chalk/ansi-regex) from 4.1.0 to 4.1.1.
- [Release notes](https://github.com/chalk/ansi-regex/releases)
- [Commits](https://github.com/chalk/ansi-regex/compare/v4.1.0...v4.1.1)

---
updated-dependencies:
- dependency-name: ansi-regex
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-12 12:33:07 +02:00
dependabot[bot] fd30b4c7ab
Build(deps): Bump minimist from 1.2.5 to 1.2.6 (#169)
Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6.
- [Release notes](https://github.com/substack/minimist/releases)
- [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6)

---
updated-dependencies:
- dependency-name: minimist
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-12 12:18:25 +02:00
Osama Sayegh 43d699769a
DEV: Lock plugin version to beta2 instead of beta3 (#168)
Follow-up to 50e9242d61

Discourse `main` branch is currently on beta3 so we can't lock the plugin version against that because otherwise the plugin would be locked at e7c19ac107 until core's bumped to beta4.
2022-04-06 15:32:40 +03:00
Martin Brennan 50e9242d61
FIX: Use new properties for pick-files-button (#167)
Companion commit to core discourse/discourse#16375
2022-04-06 12:48:02 +10:00
discoursebot e7c19ac107
DEV: Update CI workflows (#166)
Co-authored-by: discoursebuild <build@discourse.org>
2022-03-22 14:03:16 +01:00
Jarek Radosz 86cda5f213
DEV: Lose the es6 suffix (#165) 2022-03-05 17:21:01 +01:00
Gavin 9f7d4a6f0c
DEV: Update README.md (#164) 2022-02-21 20:59:32 +01:00
Discourse Translator Bot 2c6cde8eea
Update translations (#163) 2022-02-15 15:10:05 +01:00
Discourse Translator Bot 4ecbca8fe3
Update translations (#162) 2022-02-08 14:13:10 +01:00
Jarek Radosz a9403561ef
DEV: Fix specs flakyness (#160) 2022-02-01 21:38:31 +01:00
Jarek Radosz bac43572cb
DEV: Clean up some specs code (#161) 2022-02-01 21:38:24 +01:00
Discourse Translator Bot 4813615488
Update translations (#159) 2022-02-01 16:15:13 +01:00
David Taylor 2a17f49f66 DEV: Bump eslint-config-discourse and correct violations 2022-01-26 14:44:10 +00:00
discoursebuild 2881aa771f DEV: Update CI workflows 2022-01-26 14:44:10 +00:00
Discourse Translator Bot 45f1a04ca5
Update translations (#158) 2022-01-25 14:27:01 +01:00
Gerhard Schlager b6dadcae54
Update client.en.yml (#156) 2022-01-24 16:02:42 +01:00
Osama Sayegh 8464d517b2
DEV: Improve tests (#155) 2022-01-21 07:15:23 +03:00
Osama Sayegh ea66bcdc75
FEATURE: Add an API scope for running queries (#154) 2022-01-21 07:15:04 +03:00
Martin Brennan 70b973ea9a
FEATURE: Move query limit to hidden site setting (#153)
Previously the `QUERY_RESULT_DEFAULT_LIMIT` const was used
to limit the number of query results. This commit adds the
`data_explorer_query_result_limit` site setting which defaults
to 1000 and has a max of 10000 which matches the const
`QUERY_RESULT_MAX_LIMIT`.
2022-01-19 12:27:21 +10:00
Discourse Translator Bot 8aca7767e2
Update translations (#152) 2022-01-18 14:41:37 +01:00
Bianca Nenciu c6dd79c805
FIX: Do not stringify null parameters (#151)
Sometimes the query page did not load if one of the query was null
because it called null.toString() and raised an exception.
2022-01-17 13:45:40 +02:00
Andrei Prigorshnev 58cfe737f7
DEV: migrate routes to the new @action pattern (#149) 2022-01-06 15:16:51 +04:00
Discourse Translator Bot b8763be6d6
Update translations (#150) 2022-01-04 17:39:28 +01:00
Discourse Translator Bot a8f4b9ea7c
Update translations (#148) 2021-12-28 14:13:54 +01:00
discoursebot f77f599906
DEV: Update CI workflows (#147)
Co-authored-by: davidtaylorhq <davidtaylorhq@users.noreply.github.com>
2021-12-16 16:18:12 +00:00