This project is mirrored from https://github.com/metabase/metabase.
Pull mirroring updated .
- Sep 12, 2022
-
-
Cam Saul authored
* Support starting Metabase without initializing the Quartz scheduler * Fix
-
Cal Herries authored
* Show a basic banner if token status is "unpaid" or "past_due" * Add warning emoji to banner message * Swap unpaid and past-due meanings * Make links consistent between messages * Replace useLicense with token-status setting * Add token-status to SettingName * Extract AppBanner logic to selector and reuse Banner component * Create TokenStatus type and createMockTokenStatus * Remove hard-coded status * Make token-status have internal visibility * Revert "Make token-status have internal visibility" This reverts commit 8983617a0f7f1e1a9e36206d93d871df5c290965. * Write test for token-status setting * Bring back AppBanner to render message correctly * Test banner isn't present for normal users * Address Alex's comments
-
- Sep 09, 2022
-
-
Noah Moss authored
* use .p12 file extension for pkcs-12 keys * test * fix messed up indentation * default to empty string ssl password * address feedback * fix tests
-
adam-james authored
* Respect custom series names in static viz * Remove change that isn't actually necessary * Revert "Remove change that isn't actually necessary" This reverts commit 617ff4a9719bd5386bf69651cad696948a1fea7b. * Remove uneeded change * Add helper fn * Add back a change I actually did need... brain fart, oops * Add a test to make sure the correct :name key is used for series * Remove unused function
-
- Sep 08, 2022
-
-
adam-james authored
* Add goal line settings to the viz-settings map passed to combo chart * Add a test to check that goal lines are added to line/area/bar/combo
-
Case Nelson authored
* [Apps] Prototype backend app scaffolding WIP Given a set of table-ids, we try to build out an app. Ideally the produced scaffold is done on the frontend and passed in to 1. avoid code duplication 2. allow the front end to maintain ownership of visualization_settings 3. avoid regressions on frontend code changes However, this currently builds the scaffold on the backend due to FE dev bandwidth. In theory, it is done in such a way that it both matches the FE as closely as possible as well as becomes easy to change this code to accept a scaffold rather than generating one itself. It uses `scaffold-target` to map cards and dashboards in the scaffold with the inserted ids. Things that are still being worked out elsewhere: 1. The shape of nav-items 2. The shape of implicit action buttons * Sort namespace * Update and fix scaffold based on demo * Address review comments Deduplicate table-ids and make sure they are valid. i18n page suffixes. Check that tables have exactly one primary key column. Check that card scaffold has a `scaffold-target` Remove redudant check in scaffold-target replacement that the map lookup took care of.
-
Case Nelson authored
-
Case Nelson authored
* [Apps] Allow extra parameters to be passed to action execution For actions, unlike queries, the user will be asked to fill in unmapped parameters. This change allows the dashboard action execution to accept incoming parameters without an "id" but with a "target". If that target exists on the action, it will be accepted. * Update doc string and validation message * Review changes Remove action-id from the execute endpoint, this will be looked up through the dashcard. Revert map-parameters and split parameters into an extra_parameters value. extra_parameters are combined with the mapped parameters and passed to execution. * Fixing tests
-
- Sep 07, 2022
-
-
metamben authored
Hydrate app_id for dashboard activities Part of #25254. Only the /recent_views and /popular_items endpoints have been extended. The / endpoint currently doesn't deliver additional information like the other endpoints do. (The other endpoints deliver at most 5 items, but the / endpoint doesn't limit the number of results.)
-
Bryan Maass authored
* adds schema based api error messages for maps - e.g. in defendpoint. see: the error for `metabase.api.action/HTTPActionTemplate`: value must be a map with schema: ( body (optional) : value may be nil, or if non-nil, value must be a string. headers (optional) : value may be nil, or if non-nil, value must be a string. parameter_mappings (optional) : value may be nil, or if non-nil, value must be a map. parameters (optional) : value may be nil, or if non-nil, value must be an array. Each value must be a map. method : value must be one of: `DELETE`, `GET`, `PATCH`, `POST`, `PUT`. url : value must be a string. ) * use deferred-tru for error message - fix spacing in api-error-message - spruce up test * sort ns * swap another test to using str/join "\n"
-
- Sep 06, 2022
-
-
metamben authored
* Support filtering by "app" and "page" models * Fetch pages instead of dashboards for app sidebar * Fix pages display Co-authored-by:
Anton Kulyk <kuliks.anton@gmail.com>
-
adam-james authored
-
Cam Saul authored
* Rename DashboardCard `sizeX` and `sizeY` to `size_x` and `size_y` (#16344) * Fix migration * Fix MySQL/MariaDB
-
metamben authored
Fixes #25213.
-
metamben authored
-
- Sep 05, 2022
-
-
Alexander Polyankin authored
-
- Sep 01, 2022
-
-
metamben authored
* Return app collections as apps, page dashboards as pages * Fix bug: descriptions of datasets should also be searchable
-
adam-james authored
* Send show_values key to static-viz js The static viz components expect certain keys on the settings map passed into the js. At this time, the contract between the backend (Clojure) and the static-viz (js) feels a little under-specified. However, for the change to XY Charts here, we follow the existing method in code of checking the backend viz-settings map for some key, and passing it into js in a 'simplified' form. For instance, in this change, `:graph.show-values` is taken and placed into the settings map as `:show_values` for the static-viz js to use. * De-dupe key * Keep this PR super simple, don't eliminate sparkline stuff yet * Add :line earlier in cond, try to fix tests that fail * Get the :line conditional in the right place, allowing :scalar
-
adam-james authored
* Format Pie Chart Legend Labels as Month, YYYY On the backend, the pie chart legend is not rendered in the javascript, it is instead re-created server side as a set of html elements. This means "YYYY-MM-DD" formatted dates do not get passed through the frontend code responsible for formatting date times (I believe this is done with a library called 'moment.js'). And, since the SVG cannot contain html foreignObjects (the backend SVG renederer 'batik' ignores foreign objects), the legend is left as a responsiblility for Clojure land. This PR adds a `format-month` function to handle this case. Current caveats with this approach: - doesn't consider localization (yet) - adjusted the html to use a table instead of a div full of spans and the formatting could use some tweaks - assumes any string that is parse-able into a Jave DateTime object will be displayed in this Month, Year format, - which might not be true in all cases * Improve label formatting by using viz-settings transform fns * Rework Static Pie Chart legend Try to make it look a bit nicer: - splits legends into 2 tables if there are more than 8 entries - larger colored circle - use tables to help lay things out more evenly (CSS flexbox doesn't seem to work) - handle some legend label formatting cases beyond just timestamps (eg weeks of year, yearly quarters) Also fixed the failing test * Adding a month formatter. Sometimes, the label values are not passed in as timestamps, but just numbers (as strings). In these cases, the Datetime formatters won't be useful, so there are some cases built to handle these. * Remove print statement * Change temporal format fns to more closely follow viz-settings Various changes are made to improve static-viz's use of viz-settings from the frontend. - abbreviation is considered (eg. so "January" is rendered as "Jan" when setting is true) - abbreviation also works for Days of week - x-of-y cases are handled a bit better - separator settings are properly reflected (eg. 2022/05 becomes 2022-05 if separator changed to "-") * Remove unused key from the let * Fix some failing tests * Adding more tests * Prevent non-temporal legend labels from being rendered via datetime If a legend's label is some string, we want to pass it unmodified. If it's a number or a timestamp, we can pass it through to the date time render function to format the string to match the viz-settings/column units * Add missed docstring * Don't lowercase 'D' format, pass correct lowercase 'd' before 'D' format = day of year, which in most human-readable formats is not what we want, but it IS what we want in a :day-of-year case. Instead of always lowercasing, just make sure the lowercase 'd' is in the defaults/overrides * Better way to handle day of week and month of year Also got rid of bad use of read-string by using parse-long * Use a java lib. to format ordinal numbers, respecting site locale
-
metamben authored
Fixes #25143 and #25157. For recent_views and popular_items hydrate the is_app_page flag for dashboards.
-
- Aug 31, 2022
-
-
Braden Shepherdson authored
* Add `serdes-descendants` for "containment" to serialize a subtree This allows naming eg. a Collection and will recursively serialize: all dashboards, cards and dashcards it contains directly, plus all child collections and everything they contain. Currently this words on Collection, Dashboard, DashboardCard, and Card. * lint * Switch to plural `extract-subtrees` with a list of `targets`
-
metamben authored
Hydrate app_id on collections in the search endpoint
-
metamben authored
-
metamben authored
See #25097 for context.
-
adam-james authored
* Remove sort-by first from combo chart rendering The card query (seems to) return the rows in a vector in the same order presented on the frontend UI. Having the row selection function sort the selected rows by first will always just sort things alphabetically. This may be fine in some generic case, but can break in situations where a user has created a query with a sort on some quantity. * Fix test
-
- Aug 30, 2022
-
-
Case Nelson authored
* [Apps] Hydrate action on dashcards It is useful for the frontend if we hydrate :action in the same way that we hydrate :card on :ordered_cards. * Add docstring
-
Case Nelson authored
* [Apps] Hydrate action_id on is_write Card It'll be helpful for the frontend if we send back the created action_id when saving an `is_write` Card. Also update the `api/card` tests to ensure that a QueryAction (and by fk constraints the Action) is created/deleted as expected when changing `is_write`. * Add extra arg to more result-fns
-
- Aug 29, 2022
-
-
Case Nelson authored
Like `parameters`, it is desirable to use an `is_write` card's visualization_settings to store information for form customizations. When fetching an action, pull up the card's visualization_settings to the root of action, later http actions can add a visualization_settings field and they can be unified with query actions in the same way that wwe do parameters.
-
- Aug 26, 2022
-
-
Cal Herries authored
* Add disable-max-results? to query middleware options when refreshing cached card results * Add docstrings * Add test for `add-default-limit`
-
- Aug 25, 2022
-
-
Case Nelson authored
* [App] Add action_id to dashcard and endpoint for execution With app forms, we will be inlining action execution. So this PR is in preparation for that inlining and removing the need for createing Emitters in order to execute actions. Mirrors card querying from dashcards. This expects parameter_mappings of the dashboardcard to hold the mappings for execution, in the same shape as other dashcards. Instead of referencing a card_id, we reference an action_id. Emitters may be removed entirely in a future PR. * Fix extra require lint * Add checks for superuser and feature enabled to execution route. Fix code review comments * Add missing comment to migration
-
metamben authored
Addresses #24951, part of #24861. * Create collection together with the app * Don't create an app collection on FE Co-authored-by:
Anton Kulyk <kuliks.anton@gmail.com>
-
metamben authored
-
- Aug 23, 2022
-
-
Bryan Maass authored
* disallow writable queries outside of actions api - handles cards, dashboards, embedding and pulses - tests for disallowing writable query execution - fix namespace decl * fix ns decl * use `false?` to avoid any nil cards causing a 405 * check that the card is there * Revert "check that the card is there" This reverts commit 5b56e2d00291bd21c0461a0567537769b5f73a83. * Revert "use `false?` to avoid any nil cards causing a 405" This reverts commit 72569d353ee5830f37d1a14c46289afbe511841b.
-
Cam Saul authored
* [Toucan 2 prep] Don't invoke Toucan models as functions * Some fixes * Test fixes * Test fix * [Toucan 2 prep] Don't call `type` or `class` on Toucan models * Test fixes * More test fixes
* Replace perms protocol with multimethods; derive models from perms policy keywords * Test fixes * Appease Eastwood * Fix errors now that App has been merged in * Empty commit to trigger CI -
metamben authored
* Hydrate app_id for collections with apps attached Addresses #24941, part of #24861
-
Cal Herries authored
* Add validation to card PUT and POST endpoints to invalidate saving models with variables * Fix validation for snippets and saved question CTEs * Move validation to pre-update and pre-insert instead of API endpoints * Fix lint warning * Replace hard-coded id * Optimize DB calls in card pre-update * Accept formatting suggestion Co-authored-by:
Ngoc Khuat <qn.khuat@gmail.com> Co-authored-by:
Ngoc Khuat <qn.khuat@gmail.com>
-
- Aug 22, 2022
-
-
Cam Saul authored
* [Toucan 2 prep] Don't invoke Toucan models as functions * Some fixes * Test fixes * Test fix * [Toucan 2 prep] Don't call `type` or `class` on Toucan models * Test fixes * More test fixes
-
Case Nelson authored
* [Apps] Initial migrations and endpoints Addresses #24879 and #24880, part of #24861 `App` is a container that brings various dashboards together into a cohesive unit. The field `nav_items` is used for sidebar navigation within the app. The items in it will be managed by the front end and could contain link definitions to dashboards or arbitrary urls.
-
Cam Saul authored
* [Toucan 2 prep] Don't invoke Toucan models as functions * Some fixes * Test fixes
-
- Aug 18, 2022
-
-
Aleksandr Lesnenko authored
* fix static viz waterfall colors * tests * Pass colors into StaticChart as third argument This might not be the best design, so changes are welcome, but I added this to properly consider the case where the application-colors are different, but the chart has no viz-settings: application-colors were being ignored (as they were passed into options, but not pulled out of options into the colors arg). * review Co-authored-by:
Adam James <adam.vermeer2@gmail.com>
-