diff --git a/content/applications/productivity/spreadsheet.rst b/content/applications/productivity/spreadsheet.rst index 001084e8f9..d09b5ea3f0 100644 --- a/content/applications/productivity/spreadsheet.rst +++ b/content/applications/productivity/spreadsheet.rst @@ -8,37 +8,24 @@ Spreadsheet .. toctree:: :titlesonly: - spreadsheet/insert - spreadsheet/functions spreadsheet/templates + spreadsheet/functions + spreadsheet/insert + spreadsheet/dynamic_pivot_tables spreadsheet/global_filters -Spreadsheet lets you organize, analyze, and visualize your data in tabular form. Among others, you -can: - -- :doc:`Insert and link your Odoo data (pivots, graphs, lists, and menus) `. -- :doc:`Use global filters `. -- :doc:`Use formulas and functions `. -- :doc:`Create and use templates `. -- Format data. -- Sort and filter data. - -.. _spreadsheet/glossary: - -Glossary -======== - -Some of Spreadsheet's main :abbr:`UI (user interface)` elements are highlighted and defined below. - -.. image:: spreadsheet/ui-elements.png - :align: center - :alt: Spreadsheet main UI elements - -#. Menu bar -#. Top bar -#. Formula bar -#. Filters button -#. Row header -#. Column header -#. Cell menu -#. Bottom bar +**Odoo Spreadsheet** allows you to organize, manipulate, analyze, and visualize data. It offers +similar functionality to other spreadsheet solutions with the added benefit of integrating directly +with your Odoo database. + +With **Odoo Spreadsheet**, you can: + +- create spreadsheets or upload existing `.xlsx` files and edit them +- create :doc:`templates ` +- :doc:`use functions, including Odoo-specific functions ` +- :doc:`insert and link to Odoo data ` +- :doc:`create and use dynamic pivot tables ` +- filter data across multiple Odoo data sources using :doc:`global filters + ` +- visualize data using charts and formatting +- share files internally and externally diff --git a/content/applications/productivity/spreadsheet/dynamic_pivot_tables.rst b/content/applications/productivity/spreadsheet/dynamic_pivot_tables.rst new file mode 100644 index 0000000000..23b9540769 --- /dev/null +++ b/content/applications/productivity/spreadsheet/dynamic_pivot_tables.rst @@ -0,0 +1,215 @@ +==================== +Dynamic pivot tables +==================== + +When a pivot view from an Odoo database is inserted in a spreadsheet, it is by default a static +pivot table. Each cell in a static pivot table contains an :ref:`Odoo-specific function +` that retrieves data from your database. + +.. image:: dynamic_pivot_tables/pivot-function-static.png + :alt: Function of static pivot table cell + +When the corresponding data in your database changes, e.g., the sales related to a given quarter or +an individual salesperson, the cells of your static pivot table are updated. + +However, a static pivot table does not expand automatically to accommodate new data, e.g., sales +data for a new quarter or for a newly hired salesperson. Neither is it possible to add or manipulate +dimensions (i.e., columns or rows) or measures via the pivot table properties. + +.. note:: + If you attempt to update or manipulate the properties of a pivot table that has just been + inserted into a spreadsheet, an error message appears in the top right corner of the screen: + + .. image:: dynamic_pivot_tables/pivot-table-error.png + :alt: Error message when trying to manipulate static pivot table + +To have more flexibility in how you can manipulate your pivot table, you can :ref:`create a dynamic +pivot table ` from a static pivot table. + +.. _spreadsheet/dynamic-pivot-tables/create: + +Create a dynamic pivot table +============================ + +There are two main ways to create a dynamic pivot table from a static pivot table: + +- **Duplicate the static pivot table from the pivot table properties**: :ref:`Open the pivot table + properties `, click the :icon:`fa-cog` + (:guilabel:`gear`) icon at the top right of the pane, then click :icon:`fa-clone` + :guilabel:`Duplicate`. + + A new data source is created and a dynamic version of the pivot table is inserted into a new + sheet. The dynamic pivot table has the same styling as the original pivot table. + + .. note:: + When you use this method, your new dynamic pivot table gets the next available pivot ID. This + means you can create multiple pivot views associated with the same model, but with distinct + settings, groupings, or calculations. + +- **Re-insert the dynamic pivot table from the Data menu**: On the sheet that contains your static + pivot table, position your cursor in an empty cell. Click :menuselection:`Data -->` + :icon:`os-insert-pivot` :menuselection:`Re-insert dynamic pivot` from the menu bar, then select + the relevant pivot table. + + A new, dynamic pivot table appears, with the same styling as the original pivot table. + + .. note:: + When you use this method, your static and dynamic pivot share the same data source, and, + consequently, the same pivot ID. To avoid confusion, delete the original static pivot table. + +.. tip:: + It is also possible to directly enter the :ref:`function + ` of the dynamic pivot table in an empty cell. + However, with this method, the table styling needs to be re-applied manually. + +.. _spreadsheet/dynamic-pivot-tables/functions: + +Dynamic pivot table functions +----------------------------- + +Instead of each cell containing a unique function that retrieves data from your database, as in a +:ref:`static pivot table `, a dynamic pivot table +has a single function: + +.. code-block:: text + + =PIVOT(pivot_id, [row_count], [include_total], [include_column_titles], [column_count] ) + +The arguments of the function are as follows: + +- `pivot_id`: the ID assigned when the pivot table is inserted. The first pivot table + inserted in a spreadsheet is assigned pivot ID `1`, the second, pivot ID `2`, etc. +- `row_count` and `column count`: the number of rows and columns respectively. +- `include_total` and `include_column_titles`: values of `0` remove the total and column + titles respectively. + +This is an array function, which allows the pivot table to expand automatically to accommodate the +results of the function. + +The top-left cell contains the editable function, while clicking on any other cell reveals this +formula greyed out. + +.. image:: dynamic_pivot_tables/pivot-function-dynamic.png + :alt: Array function of a dynamic pivot table + +.. tip:: + If necessary, you can update the function of a dynamic pivot table to remove elements like the + total or column titles. + + With the function open in the formula bar or the top-left cell of the pivot table, position your + cursor after the pivot ID then type `,` to advance to the optional field you want to modify. In + the example below, adding the value `0` for `[include_total]` removes both the row total and + column total from the pivot table. + + .. image:: dynamic_pivot_tables/modify-function.png + :alt: Modifying the function of a dynamic pivot table + +.. _spreadsheet/dynamic-pivot-tables/manipulate: + +Manipulate a dynamic pivot table +================================ + +To manipulate data in a dynamic pivot table, :ref:`open the pivot table properties +`. + +The following options are available by clicking the :icon:`fa-cog` (:guilabel:`gear`) icon: + +- :icon:`fa-exchange` :guilabel:`Flip axes`: to move all the dimensions represented in columns to + rows and vice versa. + + .. tip:: + Flipping the axes presents the data from a different perspective, possibly bringing new + insights. However, depending on the volume of data, it can result in #SPILL errors. This + happens when a formula tries to output a range of values, but something is blocking those + cells, such as other data, merged cells, or the boundaries of the current sheet. + + Hovering over the cell containing :guilabel:`#SPILL` details the error. + +- :icon:`fa-clone` :guilabel:`Duplicate`: to duplicate the dynamic pivot table and create a new data + source with distinct properties. +- :icon:`fa-trash` :guilabel:`Delete`: to delete the data source of the dynamic pivot table. + + .. note:: + Deleting the data source of a pivot table does not delete the visual representation of the + data. Delete the table from the spreadsheet using your preferred means, e.g., via keyboard + commands, spreadsheet menus, or by deleting the sheet. + +.. _spreadsheet/dynamic-pivot-tables/manipulate-dimensions: + +Dimensions +---------- + +The dimensions of the pivot table, i.e., how the data is grouped, are placed in :guilabel:`Columns` +and :guilabel:`Rows` according to how they appeared in the pivot view in your database, i.e., before +the pivot table was inserted in the spreadsheet. + +You can: + +- add new dimensions by clicking :guilabel:`Add` +- delete existing dimensions by clicking the :icon:`fa-trash` :guilabel:`(delete)` icon on the + relevant dimension +- change the order in which dimensions are displayed in :guilabel:`Columns` or :guilabel:`Rows` by + clicking then dragging the dimension to the desired position within its respective section +- change the axis on which a dimension is shown by clicking then dragging the dimension from + :guilabel:`Columns` to :guilabel:`Rows` or vice versa +- change how a dimension's values are ordered by selecting :guilabel:`Ascending`, + :guilabel:`Descending`, or :guilabel:`Unsorted` in the :guilabel:`Order by` field +- for date- or time-based dimensions, select the desired :guilabel:`Granularity` from the options in + the dropdown menu + +.. _spreadsheet/dynamic-pivot-tables/manipulate-measures: + +Measures +-------- + +The measures of your pivot table, i.e., what you are measuring, or analyzing, based on the +dimensions you have chosen, are listed in the order they appeared in the pivot view in your +database. + +You can: + +- add new measures, including :ref:`calculated measures + `, by clicking + :guilabel:`Add` +- hide (:icon:`fa-eye`), show (:icon:`fa-eye-slash`), or delete (:icon:`fa-trash`) existing measures +- edit the name of existing measures by clicking on the measure's name +- change the order in which measures are displayed by clicking then dragging the measure to the + desired position +- change how measures are displayed by clicking the :icon:`fa-cog` :guilabel:`(gear)` icon, then + selecting the desired option from the dropdown menu, e.g., :guilabel:`% of grand total` or + :guilabel:`Rank smallest to largest`. The pivot table data updates dynamically as different + options are selected. +- choose how measures are aggregated, e.g., by :guilabel:`Sum`, :guilabel:`Average`, + :guilabel:`Minimum` + +.. _spreadsheet/dynamic-pivot-tables/manipulate-measures-calculated-measures: + +Calculated measures +~~~~~~~~~~~~~~~~~~~ + +It is possible to add calculated measures if the desired measure did not exist in the original pivot +view. For example, a calculated measure could be added to show the average revenue per order or the +profit margin per product. + +To add a calculated measure: + +#. From the :guilabel:`Measures` section of the pivot table properties, click :guilabel:`Add`. +#. Below the scrollable list, click :icon:`os-formula` :guilabel:`Add calculated measure`. +#. Rename the calculated measure by clicking on the name and typing. +#. Click on the line starting with `=` and enter the formula. + + .. example:: + In the below example, the average revenue per order is added by dividing the sum of the sales + by the number of orders. + + .. image:: dynamic_pivot_tables/calculated-measure.png + :alt: Formula for a calculated measure + +#. Choose how the measure should be aggregated by selecting a value from the dropdown. + +.. tip:: + There are advantages to using a static pivot table, for example, being able to see the functions + behind individual cells. To have this possibility, select the relevant portion of your dynamic + pivot table, copy it, then paste it into an empty part of the sheet. Click on any pasted cell to + see the :ref:`Odoo function ` used to retrieve the data. + diff --git a/content/applications/productivity/spreadsheet/dynamic_pivot_tables/calculated-measure.png b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/calculated-measure.png new file mode 100644 index 0000000000..90f74d29f7 Binary files /dev/null and b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/calculated-measure.png differ diff --git a/content/applications/productivity/spreadsheet/dynamic_pivot_tables/modify-function.png b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/modify-function.png new file mode 100644 index 0000000000..734c047818 Binary files /dev/null and b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/modify-function.png differ diff --git a/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-function-dynamic.png b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-function-dynamic.png new file mode 100644 index 0000000000..9da4c77bc2 Binary files /dev/null and b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-function-dynamic.png differ diff --git a/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-function-static.png b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-function-static.png new file mode 100644 index 0000000000..7f16ead4d2 Binary files /dev/null and b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-function-static.png differ diff --git a/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-table-error.png b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-table-error.png new file mode 100644 index 0000000000..b0a0a348e8 Binary files /dev/null and b/content/applications/productivity/spreadsheet/dynamic_pivot_tables/pivot-table-error.png differ diff --git a/content/applications/productivity/spreadsheet/functions.rst b/content/applications/productivity/spreadsheet/functions.rst index b739665adc..668c18cc09 100644 --- a/content/applications/productivity/spreadsheet/functions.rst +++ b/content/applications/productivity/spreadsheet/functions.rst @@ -2,30 +2,32 @@ Functions ========= -Spreadsheet functions are divided in the following categories: - -- :ref:`Array ` -- :ref:`Database ` -- :ref:`Date ` -- :ref:`Engineering ` -- :ref:`Filter ` -- :ref:`Financial ` -- :ref:`Info ` -- :ref:`Logical ` -- :ref:`Lookup ` -- :ref:`Math ` -- :ref:`Misc ` -- :ref:`Odoo ` -- :ref:`Operators ` -- :ref:`Statistical ` -- :ref:`Text ` -- :ref:`Web ` +**Odoo Spreadsheet** supports formulas and functions found in most spreadsheet solutions. This page +presents the available functions by category. Odoo-specific functions are included both in the +relevant category and in a dedicated :ref:`Odoo ` category: + +- :ref:`Array ` +- :ref:`Database ` +- :ref:`Date ` +- :ref:`Engineering ` +- :ref:`Filter ` +- :ref:`Financial ` +- :ref:`Info ` +- :ref:`Logical ` +- :ref:`Lookup ` +- :ref:`Math ` +- :ref:`Operators ` +- :ref:`Parser ` +- :ref:`Statistical ` +- :ref:`Text ` +- :ref:`Web ` +- :ref:`Odoo-specific functions ` .. note:: Formulas containing functions that are not compatible with Excel are replaced by their evaluated result when exporting a spreadsheet. -.. _functions/array: +.. _spreadsheet/functions/array: Array ===== @@ -77,7 +79,7 @@ Array * - WRAPROWS(range, wrap_count, [pad_with]) - `Excel WRAPROWS article `_ -.. _functions/database: +.. _spreadsheet/functions/database: Database ======== @@ -113,7 +115,7 @@ Database * - DVARP(database, field, criteria) - `Excel DVARP article `_ -.. _functions/date: +.. _spreadsheet/functions/date: Date ==== @@ -148,12 +150,22 @@ Date - `Excel MINUTE article `_ * - MONTH(date) - `Excel MONTH article `_ + * - MONTH.END(date) + - Last day of the month following a date (not compatible with Excel) + * - MONTH.START(date) + - First day of the month preceding a date (not compatible with Excel) * - NETWORKDAYS(start_date, end_date, [holidays]) - `Excel NETWORKDAYS article `_ * - NETWORKDAYS.INTL(start_date, end_date, [weekend], [holidays]) - `Excel NETWORKDAYS.INTL article `_ * - NOW() - `Excel NOW article `_ + * - QUARTER(date) + - Quarter of the year a specific date falls in (not compatible with Excel) + * - QUARTER.END(date) + - Last day of the quarter of the year a specific date falls in (not compatible with Excel) + * - QUARTER.START(date) + - First day of the quarter of the year a specific date falls in (not compatible with Excel) * - SECOND(time) - `Excel SECOND article `_ * - TIME(hour, minute, second) @@ -172,24 +184,14 @@ Date - `Excel WORKDAY.INTL article `_ * - YEAR(date) - `Excel YEAR article `_ - * - YEARFRAC(start_date, end_date, [day_count_convention]) - - Exact number of years between two dates (not compatible with Excel) - * - MONTH.START(date) - - First day of the month preceding a date (not compatible with Excel) - * - MONTH.END(date) - - Last day of the month following a date (not compatible with Excel) - * - QUARTER(date) - - Quarter of the year a specific date falls in (not compatible with Excel) - * - QUARTER.START(date) - - First day of the quarter of the year a specific date falls in (not compatible with Excel) - * - QUARTER.END(date) - - Last day of the quarter of the year a specific date falls in (not compatible with Excel) - * - YEAR.START(date) - - First day of the year a specific date falls in (not compatible with Excel) * - YEAR.END(date) - Last day of the year a specific date falls in (not compatible with Excel) + * - YEAR.START(date) + - First day of the year a specific date falls in (not compatible with Excel) + * - YEARFRAC(start_date, end_date, [day_count_convention]) + - Exact number of years between two dates (not compatible with Excel) -.. _functions/engineering: +.. _spreadsheet/functions/engineering: Engineering =========== @@ -203,7 +205,7 @@ Engineering * - DELTA(number1, [number2]) - `Excel DELTA article `_ -.. _functions/filter: +.. _spreadsheet/functions/filter: Filter ====== @@ -216,10 +218,14 @@ Filter - Description or link * - FILTER(range, condition1, [condition2, ...]) - `Excel FILTER article `_ + * - ODOO.FILTER.VALUE(filter_name) + - Returns the current value of a spreadsheet filter (not compatible with Excel) + * - SORT(range, [sort_column, ...], [is_ascending, ...]) + - `Excel SORT article `_ * - UNIQUE(range, [by_column], [exactly_once]) - `Excel UNIQUE article `_ -.. _functions/financial: +.. _spreadsheet/functions/financial: Financial ========= @@ -234,10 +240,10 @@ Financial - `Excel ACCRINTM article `_ * - AMORLINC(cost, purchase_date, first_period_end, salvage, period, rate, [day_count_convention]) - `Excel AMORLINC article `_ - * - COUPDAYS(settlement, maturity, frequency, [day_count_convention]) - - `Excel COUPDAYS article `_ * - COUPDAYBS(settlement, maturity, frequency, [day_count_convention]) - `Excel COUPDAYBS article `_ + * - COUPDAYS(settlement, maturity, frequency, [day_count_convention]) + - `Excel COUPDAYS article `_ * - COUPDAYSNC(settlement, maturity, frequency, [day_count_convention]) - `Excel COUPDAYSNC article `_ * - COUPNCD(settlement, maturity, frequency, [day_count_convention]) @@ -286,20 +292,34 @@ Financial - `Excel NPER article `_ * - NPV(discount, cashflow1, [cashflow2, ...]) - `Excel NPV article `_ + * - ODOO.ACCOUNT.GROUP(type) + - Returns the account ids of a given group (not compatible with Excel) + * - ODOO.CREDIT(account_codes, date_range, [offset], [company_id], [include_unposted]) + - Get the total credit for the specified account(s) and period (not compatible with Excel) + * - ODOO.CURRENCY.RATE(currency_from, currency_to, [date]) + - This function takes in two currency codes as arguments, and returns the exchange rate from the first currency to the second as float (not compatible with Excel) + * - ODOO.DEBIT(account_codes, date_range, [offset], [company_id], [include_unposted]) + - Get the total debit for the specified account(s) and period (not compatible with Excel) + * - ODOO.BALANCE(account_codes, date_range, [offset], [company_id], [include_unposted]) + - Get the total balance for the specified account(s) and period (not compatible with Excel) + * - ODOO.FISCALYEAR.END(day, [company_id]) + - Returns the ending date of the fiscal year encompassing the provided date (not compatible with Excel) + * - ODOO.FISCALYEAR.START(day, [company_id]) + - Returns the starting date of the fiscal year encompassing the provided date (not compatible with Excel) * - PDURATION(rate, present_value, future_value) - `Excel PDURATION article `_ * - PMT(rate, number_of_periods, present_value, [future_value], [end_or_beginning]) - `Excel PMT article `_ * - PPMT(rate, period, number_of_periods, present_value, [future_value], [end_or_beginning]) - `Excel PPMT article `_ - * - PV(rate, number_of_periods, payment_amount, [future_value], [end_or_beginning]) - - `Excel PV article `_ * - PRICE(settlement, maturity, rate, yield, redemption, frequency, [day_count_convention]) - `Excel PRICE article `_ * - PRICEDISC(settlement, maturity, discount, redemption, [day_count_convention]) - `Excel PRICEDISC article `_ * - PRICEMAT(settlement, maturity, issue, rate, yield, [day_count_convention]) - `Excel PRICEMAT article `_ + * - PV(rate, number_of_periods, payment_amount, [future_value], [end_or_beginning]) + - `Excel PV article `_ * - RATE(number_of_periods, payment_per_period, present_value, [future_value], [end_or_beginning], [rate_guess]) - `Excel RATE article `_ * - RECEIVED(settlement, maturity, investment, discount, [day_count_convention]) @@ -310,10 +330,10 @@ Financial - `Excel SLN article `_ * - SYD(cost, salvage, life, period) - `Excel SYD article `_ - * - TBILLPRICE(settlement, maturity, discount) - - `Excel TBILLPRICE article `_ * - TBILLEQ(settlement, maturity, discount) - `Excel TBILLEQ article `_ + * - TBILLPRICE(settlement, maturity, discount) + - `Excel TBILLPRICE article `_ * - TBILLYIELD(settlement, maturity, price) - `Excel TBILLYIELD article `_ * - VDB(cost, salvage, life, start, end, [factor], [no_switch]) @@ -329,7 +349,7 @@ Financial * - YIELDMAT(settlement, maturity, issue, rate, price, [day_count_convention]) - `Excel YIELDMAT article `_ -.. _functions/info: +.. _spreadsheet/functions/info: Info ==== @@ -342,6 +362,8 @@ Info - Description or link * - CELL(info_type, reference) - `Excel CELL article `_ + * - ISBLANK(value) + - `Excel IS article `_ * - ISERR(value) - `Excel IS article `_ * - ISERROR(value) @@ -356,12 +378,10 @@ Info - `Excel IS article `_ * - ISTEXT(value) - `Excel IS article `_ - * - ISBLANK(value) - - `Excel IS article `_ * - NA() - `Excel NA article `_ -.. _functions/logical: +.. _spreadsheet/functions/logical: Logical ======= @@ -393,7 +413,7 @@ Logical * - XOR(logical_expression1, [logical_expression2, ...]) - `Excel XOR article `_ -.. _functions/lookup: +.. _spreadsheet/functions/lookup: Lookup ====== @@ -420,12 +440,14 @@ Lookup - `Excel LOOKUP article `_ * - MATCH(search_key, range, [search_type]) - `Excel MATCH article `_ - * - PIVOT(pivot_id, measure_name, [domain_field_name, ...], [domain_value, ...]) - - Get the value from a pivot (not compatible with Excel) - * - PIVOT.HEADER(pivot_id, [domain_field_name, ...], [domain_value, ...]) - - Get the header of a pivot (not compatible with Excel) - * - PIVOT.TABLE(pivot_id, [row_count], [include_total], [include_column_titles]) + * - OFFSET(reference, rows, cols, [height], [width]) + - `Excel OFFSET article `_ + * - PIVOT(pivot_id, [row_count], [include_total], [include_column_titles], [column_count]) - Get a pivot table (not compatible with Excel) + * - PIVOT.HEADER(pivot_id, [domain_field_name, ...], [domain_value, ...]) + - Get the header of a pivot table (not compatible with Excel) + * - PIVOT.VALUE(pivot_id, measure_name, [domain_field_name, ...], [domain_value, ...]) + - Get the value from a pivot table (not compatible with Excel) * - ROW([cell_reference]) - `Excel ROW article `_ * - ROWS(range) @@ -435,7 +457,7 @@ Lookup * - XLOOKUP(search_key, lookup_range, return_range, [if_not_found], [match_mode], [search_mode]) - `Excel XLOOKUP article `_ -.. _functions/math: +.. _spreadsheet/functions/math: Math ==== @@ -486,10 +508,6 @@ Math - `Excel COUNTIF article `_ * - COUNTIFS(criteria_range1, criterion1, [criteria_range2, ...], [criterion2, ...]) - `Excel COUNTIFS article `_ - * - COUNTUNIQUE(value1, [value2, ...]) - - Counts number of unique values in a range (not compatible with Excel) - * - COUNTUNIQUEIFS(range, criteria_range1, criterion1, [criteria_range2, ...], [criterion2, ...]) - - Counts number of unique values in a range, filtered by a set of criteria (not compatible with Excel) * - CSC(angle) - `Excel CSC article `_ * - CSCH(value) @@ -516,6 +534,8 @@ Math - `Excel ISODD article `_ * - LN(value) - `Excel LN article `_ + * - LOG(value, [base]) + - Get the logarithm of a number for a given base (not compatible with Excel) * - MOD(dividend, divisor) - `Excel MOD article `_ * - MUNIT(dimension) @@ -544,6 +564,8 @@ Math - `Excel SEC article `_ * - SECH(value) - `Excel SECH article `_ + * - SEQUENCE(rows, [columns], [start], ][step]) + - `Excel SEQUENCE article `_ * - SIN(angle) - `Excel SIN article `_ * - SINH(value) @@ -563,53 +585,7 @@ Math * - TRUNC(value, [places]) - `Excel TRUNC article `_ -.. _functions/misc: - -Misc -==== - -.. list-table:: - :header-rows: 1 - :stub-columns: 1 - - * - Name and arguments - - Description or link - * - FORMAT.LARGE.NUMBER(value, [unit]) - - Apply a large number format (not compatible with Excel) - -.. _functions/odoo: - -Odoo -==== - -.. list-table:: - :header-rows: 1 - :stub-columns: 1 - - * - Name and arguments - - Description or link - * - ODOO.CREDIT(account_codes, date_range, [offset], [company_id], [include_unposted]) - - Get the total credit for the specified account(s) and period (not compatible with Excel) - * - ODOO.DEBIT(account_codes, date_range, [offset], [company_id], [include_unposted]) - - Get the total debit for the specified account(s) and period (not compatible with Excel) - * - ODOO.BALANCE(account_codes, date_range, [offset], [company_id], [include_unposted]) - - Get the total balance for the specified account(s) and period (not compatible with Excel) - * - ODOO.FISCALYEAR.START(day, [company_id]) - - Returns the starting date of the fiscal year encompassing the provided date (not compatible with Excel) - * - ODOO.FISCALYEAR.END(day, [company_id]) - - Returns the ending date of the fiscal year encompassing the provided date (not compatible with Excel) - * - ODOO.ACCOUNT.GROUP(type) - - Returns the account ids of a given group (not compatible with Excel) - * - ODOO.CURRENCY.RATE(currency_from, currency_to, [date]) - - This function takes in two currency codes as arguments, and returns the exchange rate from the first currency to the second as float (not compatible with Excel) - * - ODOO.LIST(list_id, index, field_name) - - Get the value from a list (not compatible with Excel) - * - ODOO.LIST.HEADER(list_id, field_name) - - Get the header of a list (not compatible with Excel) - * - ODOO.FILTER.VALUE(filter_name) - - Return the current value of a spreadsheet filter (not compatible with Excel) - -.. _functions/operators: +.. _spreadsheet/functions/operators: Operators ========= @@ -651,7 +627,21 @@ Operators * - UPLUS(value) - A specified number, unchanged (not compatible with Excel) -.. _functions/statistical: +.. _spreadsheet/functions/parser: + +Parser +====== + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - CONVERT(number, from_unit, to_unit) + - `Excel CONVERT article `_ + +.. _spreadsheet/functions/statistical: Statistical =========== @@ -666,14 +656,14 @@ Statistical - `Excel AVEDEV article `_ * - AVERAGE(value1, [value2, ...]) - `Excel AVERAGE article `_ - * - AVERAGE.WEIGHTED(values, weights, [additional_values, ...], [additional_weights, ...]) - - Weighted average (not compatible with Excel) * - AVERAGEA(value1, [value2, ...]) - `Excel AVERAGEA article `_ * - AVERAGEIF(criteria_range, criterion, [average_range]) - `Excel AVERAGEIF article `_ * - AVERAGEIFS(average_range, criteria_range1, criterion1, [criteria_range2, ...], [criterion2, ...]) - `Excel AVERAGEIFS article `_ + * - AVERAGE.WEIGHTED(values, weights, [additional_values, ...], [additional_weights, ...]) + - Weighted average (not compatible with Excel) * - CORREL(data_y, data_x) - `Excel CORREL article `_ * - COUNT(value1, [value2, ...]) @@ -736,10 +726,10 @@ Statistical - `Excel RANK article `_ * - RSQ(data_y, data_x) - `Excel RSQ article `_ - * - SMALL(data, n) - - `Excel SMALL article `_ * - SLOPE(data_y, data_x) - `Excel SLOPE article `_ + * - SMALL(data, n) + - `Excel SMALL article `_ * - SPEARMAN(data_y, data_x) - Compute the Spearman rank correlation coefficient of a dataset (not compatible with Excel) * - STDEV(value1, [value2, ...]) @@ -771,7 +761,7 @@ Statistical * - VARPA(value1, [value2, ...]) - `Excel VARPA article `_ -.. _functions/text: +.. _spreadsheet/functions/text: Text ==== @@ -822,8 +812,10 @@ Text - `Excel TRIM article `_ * - UPPER(text) - `Excel UPPER article `_ + * - VALUE(text) + - `Excel VALUE article `_ -.. _functions/web: +.. _spreadsheet/functions/web: Web === @@ -836,3 +828,198 @@ Web - Description or link * - HYPERLINK(url, [link_label]) - `Excel HYPERLINK article `_ + +.. _spreadsheet/functions/odoo: + +Odoo-specific functions +======================= + +This section contains functions that interact directly with your Odoo database. + +Array +----- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - ARRAY.CONSTRAIN(input_range, rows, columns) + - Returns a result array constrained to a specific width and height (not compatible with Excel) + * - FLATTEN(range, [range2, ...]) + - Flattens all the values from one or more ranges into a single column (not compatible with Excel) + +Date +---- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - MONTH.END(date) + - Last day of the month following a date (not compatible with Excel) + * - MONTH.START(date) + - First day of the month preceding a date (not compatible with Excel) + * - QUARTER(date) + - Quarter of the year a specific date falls in (not compatible with Excel) + * - QUARTER.END(date) + - Last day of the quarter of the year a specific date falls in (not compatible with Excel) + * - QUARTER.START(date) + - First day of the quarter of the year a specific date falls in (not compatible with Excel) + * - YEAR.END(date) + - Last day of the year a specific date falls in (not compatible with Excel) + * - YEAR.START(date) + - First day of the year a specific date falls in (not compatible with Excel) + * - YEARFRAC(start_date, end_date, [day_count_convention]) + - Exact number of years between two dates (not compatible with Excel) + +Financial +--------- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - ODOO.ACCOUNT.GROUP(type) + - Returns the account ids of a given group (not compatible with Excel) + * - ODOO.CREDIT(account_codes, date_range, [offset], [company_id], [include_unposted]) + - Get the total credit for the specified account(s) and period (not compatible with Excel) + * - ODOO.CURRENCY.RATE(currency_from, currency_to, [date]) + - This function takes in two currency codes as arguments, and returns the exchange rate from -the first currency to the second as float (not compatible with Excel) + * - ODOO.DEBIT(account_codes, date_range, [offset], [company_id], [include_unposted]) + - Get the total debit for the specified account(s) and period (not compatible with Excel) + * - ODOO.BALANCE(account_codes, date_range, [offset], [company_id], [include_unposted]) + - Get the total balance for the specified account(s) and period (not compatible with Excel) + * - ODOO.FISCALYEAR.START(day, [company_id]) + - Returns the starting date of the fiscal year encompassing the provided date (not compatible with Excel) + * - ODOO.FISCALYEAR.END(day, [company_id]) + - Returns the ending date of the fiscal year encompassing the provided date (not compatible with Excel) + * - ODOO.PARTNER.BALANCE(partner_ids, [account_codes], [date_range], [offset], [company_id], [include_unposted]) + - Get the partner balance for the specified account(s) and period (not compatible with Excel) + * - ODOO.RESIDUAL([account_codes], [date_range], [offset], [company_id], [include_unposted]) + - Get the residual amount for the specified account(s) and period (not compatible with Excel) + +Lookup +------ + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - PIVOT(pivot_id, [row_count], [include_total], [include_column_titles], [column_count]) + - Get a pivot table (not compatible with Excel) + * - PIVOT.HEADER(pivot_id, [domain_field_name, ...], [domain_value, ...]) + - Get the header of a pivot table (not compatible with Excel) + * - PIVOT.VALUE(pivot_id, measure_name, [domain_field_name, ...], [domain_value, ...]) + - Get the value from a pivot table (not compatible with Excel) + +Math +---- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - COUNTUNIQUE(value1, [value2, ...]) + - Counts number of unique values in a range (not compatible with Excel) + * - COUNTUNIQUEIFS(range, criteria_range1, criterion1, [criteria_range2, ...], [criterion2, ...]) + - Counts number of unique values in a range, filtered by a set of criteria (not compatible with Excel) + +Misc +---- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - FORMAT.LARGE.NUMBER(value, [unit]) + - Apply a large number format (not compatible with Excel) + * - ODOO.LIST(list_id, index, field_name) + - Get the value from a list (not compatible with Excel) + * - ODOO.LIST.HEADER(list_id, field_name) + - Get the header of a list (not compatible with Excel) + +Operators +--------- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - ADD(value1, value2) + - Sum of two numbers (not compatible with Excel) + * - DIVIDE(dividend, divisor) + - One number divided by another (not compatible with Excel) + * - EQ(value1, value2) + - Equal (not compatible with Excel) + * - GT(value1, value2) + - Strictly greater than (not compatible with Excel) + * - GTE(value1, value2) + - Greater than or equal to (not compatible with Excel) + * - LT(value1, value2) + - Less than (not compatible with Excel) + * - LTE(value1, value2) + - Less than or equal to (not compatible with Excel) + * - MINUS(value1, value2) + - Difference of two numbers (not compatible with Excel) + * - MULTIPLY(factor1, factor2) + - Product of two numbers (not compatible with Excel) + * - NE(value1, value2) + - Not equal (not compatible with Excel) + * - POW(base, exponent) + - A number raised to a power (not compatible with Excel) + * - UMINUS(value) + - A number with the sign reversed (not compatible with Excel) + * - UNARY.PERCENT(percentage) + - Value interpreted as a percentage (not compatible with Excel) + * - UPLUS(value) + - A specified number, unchanged (not compatible with Excel) + +Statistical +----------- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - AVERAGE.WEIGHTED(values, weights, [additional_values, ...], [additional_weights, ...]) + - Weighted average (not compatible with Excel) + * - GROWTH(known_data_y, [known_data_x], [new_data_x], [b]) + - Fits points to exponential growth trend (not compatible with Excel) + * - MATTHEWS(data_x, data_y) + - Compute the Matthews correlation coefficient of a dataset (not compatible with Excel) + * - POLYFIT.COEFFS(data_y, data_x, order, [intercept]) + - Compute the coefficients of polynomial regression of the dataset (not compatible with Excel) + * - POLYFIT.FORECAST(x, data_y, data_x, order, [intercept]) + - Predict value by computing a polynomial regression of the dataset (not compatible with Excel) + * - SPEARMAN(data_y, data_x) + - Compute the Spearman rank correlation coefficient of a dataset (not compatible with Excel) + * - TREND(known_data_y, [known_data_x], [new_data_x], [b]) + - Fits points to linear trend derived via least-squares (not compatible with Excel) + +Text +---- + +.. list-table:: + :header-rows: 1 + :stub-columns: 1 + + * - Name and arguments + - Description or link + * - JOIN(delimiter, value_or_array1, [value_or_array2, ...]) + - Concatenates elements of arrays with delimiter (not compatible with Excel) diff --git a/content/applications/productivity/spreadsheet/global_filters.rst b/content/applications/productivity/spreadsheet/global_filters.rst index 85d127d888..ffc35a01f6 100644 --- a/content/applications/productivity/spreadsheet/global_filters.rst +++ b/content/applications/productivity/spreadsheet/global_filters.rst @@ -2,202 +2,277 @@ Global filters ============== -.. role:: raw-html(raw) - :format: html +Global filters, represented by the :icon:`os-global-filters` :guilabel:`Filters` icon at the top +right of an Odoo spreadsheet, allow you to apply one or more filters to all the Odoo data that has +been :doc:`inserted in that spreadsheet `. -.. |global-filter| replace:: :raw-html:`` :guilabel:`(global filter)` -.. |drag-handle| replace:: :raw-html:`` :guilabel:`(drag handle)` +These filters are particularly useful for reports and dashboards as users can easily and dynamically +customize the view to answer complex business questions spanning multiple data sources. -Create dynamic views of :doc:`inserted data `, by mapping data source fields to *global -filters* in the Odoo **Spreadsheets** app. +.. tip:: + When a spreadsheet with global filters is added to a dashboard, the filters appear as dropdown + menus at the top of the dashboard. In a spreadsheet, they appear in a pane to the right of the + spreadsheet. -.. note:: - The global filters are represented by the |global-filter| icon, and enable data that was inserted - via a pivot table, list, or chart to be filtered. Global filters differ from the *sort and - filter* feature for cell ranges represented by the :icon:`fa-filter` :guilabel:`(filter)` icon. + .. image:: global_filters/dashboard-global-filters.png + :alt: Global filters at the top of a dashboard -.. image:: global_filters/global-filters-menu.png - :align: center - :alt: The global filters menu sidebar on a spreadsheet. +Three types of global filters are available: -Add filters -=========== +- :ref:`Date `: filters data based on a specific time range, + with the options :guilabel:`Month / Quarter`, :guilabel:`Relative Period`, or :guilabel:`From / + To`. +- :ref:`Relation `: filters data based on a relational + field in a related model, e.g., by :guilabel:`Salesperson` with the *User* model set as the + related model. +- :ref:`Text `: filters data based on a string of text or a + range of predefined values, e.g., a product reference or barcode. -Navigate to the :menuselection:`Documents app` and click on the desired spreadsheet, then open the -|global-filter| filter menu. +Unlike the standard :icon:`fa-filter` :guilabel:`(Add filters)` spreadsheet function, which lets you +sort and temporarily hide data, global filters act on the underlying :ref:`data sources +`, filtering data *before* it is loaded into the spreadsheet. -Create a new filter by selecting one of the buttons under the :guilabel:`Add a new filter...` -section: +When a global filter is created, :ref:`field matching ` +for each data source ensures the filter acts on the correct database :doc:`fields +`. -- :ref:`Date `: filter dates by matching data source date fields to - a time range (e.g., *Month / Quarter*, *Relative Period*, or *From / To*). -- :ref:`Relation `: filter records by matching data source - fields to fields in a related model (e.g., *Lead/Opportunity*, *Sales Order*, or *Event - Registration*). -- :ref:`Text `: filter text by matching data source text fields to a - string of text (e.g., *Restrict values to a range* and/or provide a *Default value*). +.. tip:: + - Global filters work by adding extra conditions to the domains of all the data sources in the + spreadsheet. Therefore, if you intend to use global filters, do not use the same conditions + when configuring the initial list, pivot table, or chart in your database. + - Setting default values, where relevant, ensures that the spreadsheet or dashboard loads quickly + and provides a useful initial view that can be further customized if needed. For example, a + :guilabel:`Date` filter could be set to show data from the last 30 days by default. -.. note:: - Only filters that are able to be applied to the fields in the data source are shown. +.. _spreadsheet/global-filters/field-matching: + +Field matching +============== + +.. important:: + This process is crucial, as matching the wrong fields, or not setting matching fields at all, + results in global filters that do not show the desired results. + +To function as intended, a global filter needs to act on the correct database fields. Consider +a :guilabel:`Date` filter applied to sales data. As the *Sales Order* model contains several date +fields, it is crucial to determine which field is relevant for the filter, e.g., the order date, the +delivery date, the expected date, or the expiration date. + +When :ref:`creating a global filter `, the :guilabel:`Field +matching` section of the :guilabel:`Filter properties` allows you to determine, for each +:ref:`data source ` in the spreadsheet, which database field the +filter should act on, or match with. + +Field matching is further explained in the relevant sections on creating +:ref:`Date `, +:ref:`Relation `, and +:ref:`Text ` global filters. + +.. _spreadsheet/global-filters/create: + +Create global filters +===================== + +Open the desired spreadsheet from the **Odoo Documents** app or via the **Odoo Dashboards** app if +you are adding filters to a dashboard. + +.. tip:: + To access the underlying spreadsheet of a dashboard, with the **Dashboards** app open, + :ref:`activate developer mode `, then click the :icon:`fa-pencil` + :guilabel:`(Edit)` icon that appears when hovering over the dashboard name. + +To add a new filter, click :icon:`os-global-filters` :guilabel:`Filters`, then, under :guilabel:`Add +a new filter...` click :guilabel:`Date`, :guilabel:`Relation`, or :guilabel:`Text` as appropriate. +The :guilabel:`Filter properties` pane opens. -.. _spreadsheet/global-filter-date: +When saving a global filter, if any required information is missing or if any information provided +in the :ref:`Field matching ` section is not appropriate, +an error is shown stating :guilabel:`Some required fields are not valid`. + +.. _spreadsheet/global-filters/create-date: Date ---- -The *Date* global filter enables the filtering of data sources by a specific time range, to -automatically filter on the current period, or to offset the time range relative to the period. +.. note:: + A :guilabel:`Date` filter can only match with a :ref:`Date ` + or :ref:`Date & Time ` field. + +With the :guilabel:`Filter properties` pane open: -With the |global-filter| menu open, select the :guilabel:`Date` button to create a new date filter. -The :guilabel:`Filter properties` menu displays the following fields for configuration below. +#. Enter a name for the new date filter in the :guilabel:`Label` field. +#. From the :guilabel:`Time range` dropdown menu, select one of the following: -First, enter a name for the new date filter in the :guilabel:`Label` field. + - :guilabel:`Month / Quarter`: enables a dropdown menu of specific months and/or quarters and a + year selector for the year. The values :guilabel:`Months` and :guilabel:`Quarters` are enabled + by default. Disabling both of these values allows filtering by year only. -Then, select one of the three period options in the :guilabel:`Time range` field: + To set a :guilabel:`Default value`, enable + :guilabel:`Automatically filter on the current period` and choose whether to filter on the + current :guilabel:`Month`, :guilabel:`Quarter` or :guilabel:`Year`. -- :guilabel:`Month / Quarter`: enables a drop-down menu of specific months and quarters of a year - (i.e., *Q1*, *Q2*, *January*, etc.). -- :guilabel:`Relative Period`: enables a drop-down menu of specific moving time frames (i.e., *Year - to Date*, *Last 7 Days*, *Last 30 Days*, etc.). -- :guilabel:`From / To`: enables *Date from...* and *Date to...* date selection fields to define a - specific time range (e.g., `06/05/2024` to `06/27/2024`). + - :guilabel:`Relative Period`: enables a dropdown menu of specific time ranges relative to the + current date (e.g., :guilabel:`Year to Date`, :guilabel:`Last 7 Days`, + :guilabel:`Last 30 Days`, etc.). -Optionally, set a :guilabel:`Default value` for the :guilabel:`Time range`. + To set a :guilabel:`Default value`, select one of the available values. -.. note:: - The :guilabel:`Default value` field only appears for :guilabel:`Month / Quarter` or - :guilabel:`Relative Period` ranges. + - :guilabel:`From / To`: enables :guilabel:`Date from...` and :guilabel:`Date to...` date + selection fields to define a specific time range (e.g., `06/05/2024` to `06/27/2024`). - If the :guilabel:`Month / Quarter` range is selected, tick the :guilabel:`Automatically filter on - the current period` checkbox to define the default period of either :guilabel:`Month`, - :guilabel:`Quarter`, or :guilabel:`Year`. +#. In the :guilabel:`Field matching` section, for each data source, click below :guilabel:`Date + field` and select the field the filter should match with. -Next, configure the :guilabel:`Field matching` for each data source. To do so, expand the section by -clicking on the :guilabel:`Field matching` heading, to reveal a list of the data sources in the -spreadsheet where each data source has two fields for matching: + The :guilabel:`Period offset` feature enables comparisons to be made by shifting the time + range by one or two periods in the past or future. By default, no period offset is set. The + offsets available are: :guilabel:`Previous`, :guilabel:`Before previous`, :guilabel:`Next`, and + :guilabel:`After next`. -- :guilabel:`Date field`: select a date field from the data source model to apply the time range to. -- :guilabel:`Period offset`: (optionally) select an offset that shifts the time range by a relative - period. + .. tip:: - The options available are: :guilabel:`Previous`, :guilabel:`Before Previous`, :guilabel:`Next`, - :guilabel:`After Next`. + To compare data effectively using the :guilabel:`Period offset` feature, :ref:`duplicate the + relevant inserted list ` or :ref:`pivot table + `, then, when setting up field matching, set a + period offset for the second data source but not the first. -Lastly, once all the information is entered on the form, click the :guilabel:`Save` button. If any -of the data source fields do not match the data type of *date* (or *datetime*), an error is shown -stating :guilabel:`Some required fields are not valid`. + When applying the filter, the original list or pivot table shows data for the time range + selected, while the second shows data for a period before or after that time range, as + defined. + +#. Click :guilabel:`Save`. .. example:: - Consider a :guilabel:`Period offset` of :guilabel:`Next` when using the :guilabel:`Month / - Quarter` range to apply the filter to the *next* period relative to the set time range. + In the example below, a :guilabel:`Date` global filter has been created to allow the pivot table + and chart to show sales data per quarter. If only a year is selected, data is shown for the + entire year. + + .. image:: global_filters/example-date.png + :alt: A date filter to filter on quarter and year - With this configuration, selecting `January` `2024` as the date, filters data as `February` - `2024`; where the selected month is offset to the next month. + In the :guilabel:`Field matching` section of the :guilabel:`Filter properties`, the field + :guilabel:`Order Date` has been selected as the matching date field. A matching date field is not + needed for *List #1* as we will not use this filter on the data source in question. - .. image:: global_filters/date-period-offset.png - :align: center - :alt: A date filter with a period offset of "Next" configured. + .. image:: global_filters/field-matching-date.png + :alt: A date filter with the Order Date selected as the matching field + :scale: 80% -.. _spreadsheet/global-filter-relation: +.. _spreadsheet/global-filters/create-relation: Relation -------- -The *Relation* global filter enables the filtering of records in data sources by selecting a field -from a related model. - -With the |global-filter| menu open, select the :guilabel:`Relation` button to create a new relation -filter. The :guilabel:`Filter properties` menu displays the following fields for configuration. +.. note:: + A :guilabel:`Relation` filter can only match with a :ref:`Many2One + `, :ref:`One2Many + `, or :ref:`Many2Many + ` field. -First, enter a name for the new relation filter in the :guilabel:`Label` field. +With the :guilabel:`Filter properties` pane open: -Then, select or search for a model from the :guilabel:`Related model` field. +#. Enter a name for the new relation filter in the :guilabel:`Label` field. -Once a model is selected, the :guilabel:`Default value` and :guilabel:`Field matching` fields -appear. +#. In the :guilabel:`Related model` field, start typing the model name to reveal a list of all + models, then select the appropriate one. Once a model is selected, the + :guilabel:`Default value` and :guilabel:`Possible values` fields appear, as well as the + :guilabel:`Field matching` section. -Optionally, set a :guilabel:`Default value` for the :guilabel:`Related model`. The available options -are records of the model. +#. To set a :guilabel:`Default value`, select one of the available values; these are records from + the model. If the related model is the *User* model, the option :guilabel:`Automatically filter + on the current user` can be enabled. -Next, configure the :guilabel:`Field matching` for each data source. To do so, expand the section by -clicking on the :guilabel:`Field matching` heading, to reveal a list of the data sources in the -spreadsheet where each data source has a field for matching. +#. To limit the values that can be shown, enable :guilabel:`Restrict values with a domain`, then + click :ref:`Edit domain ` to add or edit rules. -Select a field from the data source model from which to apply the relation filter. +#. In the :guilabel:`Field matching` section, check if the correct matching field has been + assigned for each data source. If this is not the case, click below the data source name to + select the correct field. -Lastly, once all the information is entered on the form, click the :guilabel:`Save` button. If any -of the data source fields do not match the data type of the related model, an error is shown -stating :guilabel:`Some required fields are not valid`. +#. Click :guilabel:`Save`. .. example:: - Consider a *Relation* filter with the :guilabel:`Related model` set as :guilabel:`Contact`. The - :guilabel:`Field matching` *CRM* lead (`crm.lead`) pivot data sources are set to - :guilabel:`Customer`. + In the example below, a :guilabel:`Relation` filter has been created to allow the pivot table + and chart to show sales data related to selected salespeople only. The *User* model was set as + the :guilabel:`Related model`. - With this configuration, selecting a customer record filters the pivot table to only leads that - are related to the selected customer record. + .. image:: global_filters/example-relation.png + :alt: Relation filter set on a pivot table - .. image:: global_filters/relation-contact.png - :align: center - :alt: A relation filter with the Contact model configured. + In the :guilabel:`Field matching` section of the :guilabel:`Filter properties`, the field + :guilabel:`Salesperson` was automatically assigned as the matching field for both the pivot table + and the chart. A matching field is not needed for *List #1* as we will not use this filter on the + data source in question. -.. _spreadsheet/global-filter-text: + .. image:: global_filters/field-matching-relation.png + :alt: A relation filter with the User model configured + :scale: 80% + +.. _spreadsheet/global-filters/create-text: Text ---- -The *Text* global filter enables the filtering of text by matching data source text fields to a -string of text or to a range of predefined values. +.. note:: + A :guilabel:`Text` filter can only match with a :ref:`Text (char) + `, :ref:`Integer ` or + :ref:`Decimal (float) ` field. -With the |global-filter| menu open, select the :guilabel:`Text` button to create a new text filter. -The :guilabel:`Filter properties` menu displays the following fields for configuration. +With the :guilabel:`Filter properties` pane open: -First, enter a name for the new text filter in the :guilabel:`Label` field. +#. Enter a name for the new text filter in the :guilabel:`Label` field. +#. Optionally, enable :guilabel:`Restrict values to a range`. Doing so allows you to input a + spreadsheet range either by typing the range or selecting it from within the spreadsheet. +#. Optionally, enter a :guilabel:`Default value`. +#. In the :guilabel:`Field matching` section, for each data source click below the data source name + and select the field the :guilabel:`Text` filter should match with. -Then, choose whether or not to :guilabel:`Restrict values to a range` by ticking the checkbox. Doing -so, reveals a field to input a range within the spreadsheet. Either type in or select the range. +#. Click :guilabel:`Save`. -Next, configure the :guilabel:`Field matching` for each data source. To do so, expand the section by -clicking on the :guilabel:`Field matching` heading, to reveal a list of the data sources in the -spreadsheet where each data source has a field for matching. +.. example:: + In the example below, a :guilabel:`Text` global filter was created to allow the user to select a + product from the :guilabel:`Product` filter and have both the pivot table and chart only show + sales data related to that specific product. -Select a field from the data source model from which to apply the text filter. + .. image:: global_filters/example-text.png + :alt: Global filters set on a pivot table -Lastly, once all the information is entered on the form, click the :guilabel:`Save` button. If any -of the data source fields do not match the data type of the related model, an error is shown -stating :guilabel:`Some required fields are not valid`. + In the :guilabel:`Filter properties`, the :guilabel:`Possible values` of the filter were + restricted to the range :guilabel:`'Products (List #1)'!A2:A34`. This corresponds to the range + containing the :guilabel:`Display name` of the product on a list inserted in the spreadsheet. -.. example:: - Consider a text filter with the range `A2:A6` added to the :guilabel:`Restrict values to a range` - field. The spreadsheet has five different product names listed as values in the cells of column - `A`, rows `2` though `6`. + .. image:: global_filters/field-matching-text.png + :alt: A text filter with a restricted range + :scale: 80% - With the above configuration, a pivot table of products can be filtered by product name by - selecting one of the 5 predefined values available in the text filter. + With this configuration, the pivot table and chart can be filtered by product name by + selecting one of the predefined values available in the text filter. In this case, + :guilabel:`Furniture` has already been selected as the :guilabel:`Product category`, meaning + that only products of this category can be selected as possible values. - Furthermore, if the values in the range `A2:A6` are added dynamically– the text filter becomes - dynamic as well. + Furthermore, if the values in the range have been retrieved dynamically from the database, as in + this case, the text filter is also dynamic, i.e., will reflect changes made to those values. - .. image:: global_filters/text-values.png - :align: center - :alt: A dynamic text filter with a restricted range. +Manage and use global filters +============================= -Manage filters -============== - -Open the |global-filter| filter menu by navigating to the :menuselection:`Documents app` and -clicking on the desired spreadsheet. +Click the :icon:`os-global-filters` :guilabel:`Filters` icon at the top right of an Odoo spreadsheet +to access the global filters that have been created for that spreadsheet. -Existing global filters appear under the :guilabel:`Filters` section. Filters can be used -individually, or at the same time. +It is possible to: -.. tip:: - The order of existing filters can be changed by hovering over a filter and using the - |drag-handle| icon to change the position. +- **Apply one or more global filters** by selecting appropriate values per filter, as relevant. -To reset a filter with set values back to default, click on the :icon:`fa-times` (clear) icon next -to the value in the filter. + .. tip:: + Reloading the browser will cause any global filters to reset to their initial state or default + value, as relevant. To refresh data in an inserted list, pivot table, or chart without losing + global filters that have been applied, click :menuselection:`Data --> Refresh all data` from + the menu bar. -To edit an existing filter, select the :icon:`fa-cog` :guilabel:`(gear)` icon to open the filter's -:guilabel:`Filter properties` menu. From here, edits can be made or the filter can be deleted by -clicking the :guilabel:`Remove` button. +- **Change the order** of existing filters by hovering over a filter and using the + :icon:`os-thin-drag-handle` :guilabel:`(drag handle)` icon to change the position. +- **Clear filter values** (whether default or selected values) by clicking the :icon:`fa-times` + :guilabel:`(Clear)` icon next to the value in the filter. +- **Edit an existing filter** by selecting the :icon:`fa-cog` :guilabel:`(Edit)` icon to open the + filter's :guilabel:`Filter properties` then editing as needed. +- **Delete an existing filter** by selecting the :icon:`fa-cog` :guilabel:`(Edit)` icon to open the + filter's :guilabel:`Filter properties` then clicking :guilabel:`Remove`. diff --git a/content/applications/productivity/spreadsheet/global_filters/dashboard-global-filters.png b/content/applications/productivity/spreadsheet/global_filters/dashboard-global-filters.png new file mode 100644 index 0000000000..5d9b304782 Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/dashboard-global-filters.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/date-period-offset.png b/content/applications/productivity/spreadsheet/global_filters/date-period-offset.png deleted file mode 100644 index 4338694b71..0000000000 Binary files a/content/applications/productivity/spreadsheet/global_filters/date-period-offset.png and /dev/null differ diff --git a/content/applications/productivity/spreadsheet/global_filters/example-date.png b/content/applications/productivity/spreadsheet/global_filters/example-date.png new file mode 100644 index 0000000000..53b46ab9a2 Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/example-date.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/example-relation.png b/content/applications/productivity/spreadsheet/global_filters/example-relation.png new file mode 100644 index 0000000000..854fa682fe Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/example-relation.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/example-text.png b/content/applications/productivity/spreadsheet/global_filters/example-text.png new file mode 100644 index 0000000000..8077944da3 Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/example-text.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/field-matching-date.png b/content/applications/productivity/spreadsheet/global_filters/field-matching-date.png new file mode 100644 index 0000000000..3211a0c2d6 Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/field-matching-date.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/field-matching-relation.png b/content/applications/productivity/spreadsheet/global_filters/field-matching-relation.png new file mode 100644 index 0000000000..170426892e Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/field-matching-relation.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/field-matching-text.png b/content/applications/productivity/spreadsheet/global_filters/field-matching-text.png new file mode 100644 index 0000000000..f2d7e0a380 Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/field-matching-text.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/global-filters-menu.png b/content/applications/productivity/spreadsheet/global_filters/global-filters-menu.png deleted file mode 100644 index a6e78e9bc7..0000000000 Binary files a/content/applications/productivity/spreadsheet/global_filters/global-filters-menu.png and /dev/null differ diff --git a/content/applications/productivity/spreadsheet/global_filters/pivot-table-global-filters.png b/content/applications/productivity/spreadsheet/global_filters/pivot-table-global-filters.png new file mode 100644 index 0000000000..2de4520e37 Binary files /dev/null and b/content/applications/productivity/spreadsheet/global_filters/pivot-table-global-filters.png differ diff --git a/content/applications/productivity/spreadsheet/global_filters/relation-contact.png b/content/applications/productivity/spreadsheet/global_filters/relation-contact.png deleted file mode 100644 index 10cb205ff6..0000000000 Binary files a/content/applications/productivity/spreadsheet/global_filters/relation-contact.png and /dev/null differ diff --git a/content/applications/productivity/spreadsheet/global_filters/text-values.png b/content/applications/productivity/spreadsheet/global_filters/text-values.png deleted file mode 100644 index 153f068258..0000000000 Binary files a/content/applications/productivity/spreadsheet/global_filters/text-values.png and /dev/null differ diff --git a/content/applications/productivity/spreadsheet/insert.rst b/content/applications/productivity/spreadsheet/insert.rst index 3e7a3138bd..505d04768d 100644 --- a/content/applications/productivity/spreadsheet/insert.rst +++ b/content/applications/productivity/spreadsheet/insert.rst @@ -1,58 +1,776 @@ -============== -Link Odoo data -============== +============================ +Insert and link to Odoo data +============================ + +Several elements from your Odoo database can be inserted into an Odoo spreadsheet, namely: + +- lists, i.e., data from a :ref:`list view ` +- pivot tables, i.e., data from a :ref:`pivot view ` +- charts, i.e., data from a :ref:`graph view ` + +Each time a list, pivot table, or chart is inserted, a :ref:`data source +` is created. This data source connects the spreadsheet to your +Odoo database, retrieving up-to-date information every time the spreadsheet is opened or reloaded. + +:ref:`Inserted lists ` and :ref:`inserted pivot tables +` use formulas with Odoo-specific :ref:`list functions +` and :ref:`pivot table functions +` to retrieve data from your database and can be +further manipulated in the spreadsheet. Certain elements of :ref:`inserted charts +` can be modified, but no data manipulation or computation is possible. + +.. tip:: + If you intend to use :doc:`global filters ` to dynamically filter Odoo data in + a spreadsheet or dashboard, do not use the same conditions to establish the initial list, pivot + table, or chart in your database. -You can insert and link several elements from your database in your spreadsheets, namely: +It is also possible to: -- pivots, -- graphs, -- lists, and -- links to menus (i.e., a clickable link to a view of a specific model). +- :ref:`add clickable links ` to Odoo menu items, to other + sheets of the same spreadsheet, or to external URLs +- :ref:`insert financial data ` from your Odoo database using + Odoo-specific spreadsheet :doc:`functions ` +- paste data from another Odoo spreadsheet, Excel spreadsheet, or Google Sheet directly into any + Odoo spreadsheet -Before inserting :ref:`pivots `, :ref:`graphs `, or -lists, ensure they are tailored to your needs, as some elements are more quickly - or only - -configurable in their respective view. +.. _spreadsheet/insert/data-sources: -- To insert pivots and graphs, click :guilabel:`Insert in spreadsheet` from any pivot or graph view. -- To insert lists, click :menuselection:`Favorites --> Insert list in spreadsheet` from any list - view. -- To insert links to menus, click :menuselection:`Favorites --> Link menu in spreadsheet` from any - view. +Data sources +============ -In the pop-up box, either create a new spreadsheet by selecting :guilabel:`Blank spreadsheet` or -insert it in an existing one by selecting it and clicking :guilabel:`Confirm`. +Data sources, which are created each time a :ref:`list `, :ref:`pivot table +` or :ref:`graph ` is inserted into an +Odoo spreadsheet, connect the spreadsheet and the relevant :doc:`model +<../../studio/models_modules_apps>` in your database. -.. image:: insert/insert-spreadsheet.png - :align: center - :alt: Inserting a pivot in a spreadsheet +Each data source is defined by properties that can be accessed via the :guilabel:`Data` menu. Data +sources are identified by their respective :icon:`oi-view-pivot` :guilabel:`(pivot table)`, +:icon:`oi-view-list` :guilabel:`(list)` or :icon:`fa-bar-chart` :guilabel:`(chart)` icon, followed +by their ID and name, e.g., :icon:`oi-view-pivot` *(#1) Sales Analysis by Product*. + +.. image:: insert/data-menu.png + :alt: Data sources listed in Data menu + +Clicking on a data source opens its properties in a pane to the right of the spreadsheet. + +.. tip:: + Once the properties of a specific data source are open, they remain open even when navigating + between spreadsheet tabs. To close the properties pane, click the :icon:`fa-times` + :guilabel:`(close)` icon at the top right of the pane. .. note:: - By default, new spreadsheets are saved under the :guilabel:`Spreadsheet` workspace of the - Documents app. + Deleting an inserted list or pivot table, or deleting the sheet into which it was inserted, does + not delete the underlying data source. The data source of an inserted list or pivot table can + only be deleted via the data source's properties. + + A warning in the :guilabel:`Data` menu identifies any data sources for which the corresponding + list or pivot table no longer appears in the spreadsheet. -.. _insert/update: + .. image:: insert/list-deleted.png + :alt: Warning message about unused list -Updating data + Deleting an inserted chart, on the other hand, also deletes the underlying data source. + +.. _spreadsheet/insert/list: + +Insert a list ============= -Once inserted in a spreadsheet, your data is kept up-to-date, reflecting any changes made to your -database. Reopening the spreadsheet reloads the linked data. +.. important:: + Before inserting a list in a spreadsheet, ensure the list is tailored to your needs. Consider + which fields should be visible as well as how the records are filtered and/or sorted. This can + impact both the loading time and the user-friendliness of your spreadsheet. + +To insert a list: + +#. With the list view selected, click the :icon:`fa-cog` :guilabel:`(Actions)` icon + beside the name of the view, then :menuselection:`Spreadsheet -->` :icon:`oi-view-list` + :menuselection:`Insert list in spreadsheet`. + + .. note:: + To insert only specific records, select the relevant records, click the :icon:`fa-cog` + :guilabel:`Actions` button that appears at the top center of the screen, then + :icon:`oi-view-list` :guilabel:`Insert in spreadsheet`. + +#. In the window that opens, edit the :guilabel:`Name of the list` if needed. + + The list name is used in the sheet name and in the :ref:`list properties + `. + + .. image:: insert/insert-list.png + :alt: Inserting a list in a spreadsheet + +#. Edit the number of records, i.e., rows, to be inserted if needed. + + By default, the number shown is the number of records visible on the first page of the list. For + example, if the list contains 150 records but only 80 are visible, this field will show 80. + + .. note:: + While the data in your list is kept up to date thanks to the connection to your database, an + inserted list will not automatically expand to accommodate new records, e.g., a new product + category or a new salesperson. + + If you anticipate new records being added, consider adding extra rows when inserting the list. + Records/rows can also be :ref:`added manually ` after the + spreadsheet has been inserted. + + .. example:: + Your company currently has ten product categories and you insert this list in a + spreadsheet. If an 11th product category is created and your inserted list only had ten + rows, the new category will be inserted in the appropriate position in the spreadsheet, + thereby removing an existing category. + + One way to avoid this is to :ref:`add extra rows ` + when inserting the list. + +#. Click :guilabel:`Blank spreadsheet` or select in which existing spreadsheet the list should be + inserted. + + .. note:: + New spreadsheets are saved in the **Odoo Documents** app in either the :icon:`fa-hdd-o` + :guilabel:`My Drive` personal workspace or, if :ref:`file centralization + ` has been enabled for spreadsheets, in the + :guilabel:`Spreadsheet` workspace. + +#. Click :guilabel:`Confirm`. + +The list is inserted into a new sheet in the spreadsheet. The sheet tab in the bottom bar shows the +name of the list followed by the list ID, e.g., *Quotations by Total (List #1)*. A pane on the right +side of the screen shows the :ref:`list properties `. + +.. tip:: + - To sever the link between an inserted list and your database, select the entire list, + right-click and select :icon:`fa-clone` :guilabel:`Copy` then right-click again and select + :menuselection:`Paste special --> Paste as value`. + - Do not modify the list ID in the sheet name, as the inserted list retains this ID for the + lifetime of the spreadsheet. This list ID is used in the :ref:`spreadsheet functions + ` that retrieve data from your database. + +.. _spreadsheet/insert/list-functions: + +List functions +-------------- + +When a list is inserted into a spreadsheet, the following :doc:`functions ` are used to +retrieve the header and field values, respectively: + +.. code-block:: text + + =ODOO.LIST.HEADER(list_id, field_name) + =ODOO.LIST(list_id, index, field_name) + +The arguments of the function are as follows: + +- `list_id`: the ID assigned when the list is inserted. The first list inserted into a spreadsheet + is assigned list ID `1`, the second, list ID `2`, etc. +- `index`: identifies the line on which the record appeared in the list before insertion. The + first line has an index of `1`, the second an index of `2`, etc. +- `field_name`: the technical name of the field. + +.. tip:: + To see the formulas of spreadsheet cells, click :menuselection:`View -->` :icon:`fa-eye` + :menuselection:`Show --> Formulas` on the menu bar. The example below shows the functions used to + retrieve list values. + + .. image:: insert/list-formulas.png + :alt: Viewing formulas of spreadsheet cells + +.. _spreadsheet/insert/list-properties: + +List properties +--------------- + +The list properties appear on the right side of the screen when a list is inserted. They can be +accessed at any time via the :guilabel:`Data` menu by clicking the relevant list, as prefaced by +the :icon:`oi-view-list` :guilabel:`(list)` icon. + +The following list properties are shown, some of which can be edited: + +- :guilabel:`List #`: the list ID. List IDs are assigned sequentially as additional lists are + inserted into the spreadsheet. +- :guilabel:`List Name`: the name of the list. Edit this if needed. Note that editing the list name + in the list properties does not modify the list name shown in the sheet name, and vice versa. +- :guilabel:`Model`: the model from which the data has been extracted. +- :guilabel:`Columns`: the fields of the model that were visible when the list was inserted. +- :guilabel:`Domain`: the rules used to determine which records are shown. Click + :ref:`Edit domain ` to add or edit rules. + + .. note:: + When :doc:`global filters ` are used, this domain is combined with the selected + values of the global filter before the data is loaded into the spreadsheet. + +- :guilabel:`Sorting`: how the data is sorted, if applicable. To add a sorting rule, click + :guilabel:`Add`, select the field, then choose whether sorting should be :guilabel:`Ascending` or + :guilabel:`Descending`. Delete a sorting rule by clicking the :icon:`fa-times` + :guilabel:`(delete)` icon. + +To :ref:`duplicate ` or :ref:`delete +` a list's data source, click the :icon:`fa-cog` :guilabel:`(gear)` +icon, then click :icon:`fa-clone` :guilabel:`Duplicate` or :icon:`fa-trash` :guilabel:`Delete` as +relevant. + +.. _spreadsheet/insert/list-manage: + +Manage an inserted list +----------------------- + +Once a list from an Odoo database has been inserted into an Odoo spreadsheet, you can: + +- :ref:`add records `, i.e., rows +- :ref:`add fields `, i.e., columns +- :ref:`duplicate the list ` to create a new, identical data + source +- :ref:`delete the list and its underlying data source ` + +.. _spreadsheet/insert/list-add-records: + +Add records/rows to a list +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +To add records to a list, use one of the following methods: + +- Select the last row of the table, then hover over the blue square until the plus icon appears. + Click and drag down to add the desired number of rows. The cells of the new rows are populated + with the :ref:`appropriate formula ` to retrieve the list + values. If there is corresponding data in your database, the cells are populated. + + .. image:: insert/list-add-records.png + :alt: Add records by dragging the cell down + +- Position your cursor in the top left cell of the sheet, click :menuselection:`Data --> Re-insert + list` from the menu bar, then select the appropriate list. In the pop-up window, indicate the + number of records to insert and click :guilabel:`Confirm`. An updated list is inserted, + overwriting the previous list. + +.. tip:: + The above methods can also be used to add additional blank rows to your spreadsheet table. This + may be useful for lists where you expect additional records to be generated in your database, + e.g., new product categories or new salespersons. + +.. _spreadsheet/insert/list-add-fields: + +Add fields/columns to a list +~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +To add fields/columns to a list: + +#. Select the column to the right or left of where the new column should be inserted. +#. Click :menuselection:`Insert -->` :icon:`os-insert-col` :menuselection:`Insert column` then + :icon:`os-insert-col-before` :menuselection:`Column left` or :icon:`os-insert-col-after` + :menuselection:`Column right` from the menu bar, or right-click then :icon:`os-insert-col-before` + :guilabel:`Insert column left` or :icon:`os-insert-col-after` :guilabel:`Insert column right` as + appropriate. +#. Copy the header cell of any column, paste it into the header cell of the new column, and press + `Enter`. +#. Double-click the new header cell then click on the field name that appears in quotation marks at + the end of the formula; a list of all the technical names of the fields of the related model + appears. + + .. image:: insert/list-add-columns.png + :alt: Add fields/columns by editing the formula + +#. Select the appropriate field name and press `Enter`. The field's label appears in the header. + + .. tip:: + To know a field's technical name, navigate to the relevant view, :ref:`activate developer mode + `, then check the field name by hovering over the question mark beside a + field's label. + +#. With the header cell selected, double-click on the blue square in the bottom-right corner. The + cells of the column are populated with the appropriate formula to retrieve the list values. If + there is corresponding data in your database, the cells are populated. + +.. _spreadsheet/insert/list-duplicate: + +Duplicate a list +~~~~~~~~~~~~~~~~ + +Duplicating a list via the list's properties creates an additional data source. This allows for +different manipulations to be performed on the same data within one spreadsheet. + +With the :ref:`list properties ` open, click the :icon:`fa-cog` +:guilabel:`(gear)` icon then :icon:`fa-clone` :guilabel:`Duplicate`. + +The new data source is assigned the next available list ID. For example, if no other lists have been +inserted in the meantime, duplicating *List #1* results in the creation of *List #2*. + +Unlike when you insert a list, a duplicated list is not automatically inserted into the spreadsheet. +To insert it, perform the following steps: + +#. Add a new sheet by clicking the :icon:`os-plus` :guilabel:`(add sheet)` icon at the bottom left + of the spreadsheet. +#. Click :menuselection:`Data --> Re-insert list` from the menu bar, then select the appropriate + list. +#. Define the number of records to insert and click :guilabel:`Confirm`. +#. Edit the :guilabel:`List Name` in the properties pane if needed. +#. Rename the sheet by right-clicking on the sheet tab, selecting :guilabel:`Rename`, and entering + the new sheet name. + +.. note:: + Duplicating an inserted list by copying and pasting it or by duplicating the sheet into which it + has been inserted does not create a new data source. Any changes made to the list's properties + would therefore impact any copies of the list. + +.. _spreadsheet/insert/list-delete: + +Delete a list +~~~~~~~~~~~~~ + +To fully delete a list and the underlying data source from a spreadsheet, perform the following +steps in any order: + +- Delete the spreadsheet table using your preferred means, e.g., via keyboard commands, spreadsheet + menus, or by deleting the sheet. This deletes the visual representation of the data. +- From the :ref:`properties pane ` of the relevant list, click + the :icon:`fa-cog` :guilabel:`(gear)` icon then :icon:`fa-trash` :guilabel:`Delete`. This deletes + the data source of the list from the spreadsheet. + +.. _spreadsheet/insert/pivot-table: + +Insert a pivot table +==================== + +.. tip:: + When a pivot table is inserted into a spreadsheet, it is by default static. Converting a static + pivot table to a :doc:`dynamic pivot table ` ensures the pivot table can + expand to accommodate new data series, such as sales data for a new quarter, and allows you to + modify the dimensions (i.e., columns and rows) and measures. + + It is therefore possible to insert a basic pivot table with minimal configuration and refine it + directly in the spreadsheet after converting it to a dynamic pivot table. + +To insert a pivot table: + +#. With the pivot view selected, click :guilabel:`Insert in Spreadsheet`. +#. In the window that opens, edit the :guilabel:`Name of the pivot` if needed. + + This name is used in the sheet name and in the :ref:`pivot table properties + `. + + .. image:: insert/insert-pivot-table.png + :alt: Inserting a pivot table in a spreadsheet + +#. Click :guilabel:`Blank spreadsheet` or select in which existing spreadsheet the pivot table + should be inserted. + + .. note:: + New spreadsheets are saved in the **Odoo Documents** app in either the :icon:`fa-hdd-o` + :guilabel:`My Drive` personal workspace or, if :ref:`file centralization + ` has been enabled for spreadsheets, in the + :guilabel:`Spreadsheet` workspace. + +#. Click :guilabel:`Confirm`. + +The pivot table is inserted into a new sheet in the spreadsheet. The sheet tab in the bottom bar +shows the name of the pivot table followed by the pivot table ID, e.g., *Sales Analysis by Sales +Team (Pivot #1)*. A pane on the right side of the screen shows the :ref:`pivot table properties +`. + +.. _spreadsheet/insert/pivot-table-functions-static: + +Pivot table functions +--------------------- + +An inserted pivot table that has not been converted to a :doc:`dynamic pivot table +` uses the following :doc:`functions ` to retrieve the header and +field values, respectively: + + .. code-block:: text + + =PIVOT.HEADER(pivot_id, [domain_field_name, …], [domain_value, …]) + =PIVOT.VALUE(pivot_id, measure_name, [domain_field_name, …], [domain_value, …]) + +The arguments of the functions are as follows: + +- `pivot_id`: the ID assigned when the pivot table is inserted. The first pivot table inserted + in a spreadsheet is assigned pivot ID `1`, the second, pivot ID `2`, etc. +- `measure_name`: the technical name of what is being measured, followed by the type of aggregation, + e.g., `product_uom_qty:sum`. +- `domain_field_name`: the technical name of the field used as a dimension, e.g., `user_id`, or, if + the dimension is a time period, the technical name of the date field, followed by the time period, + e.g., `date_order:month`. +- `domain_value`: the ID of the record, or, if the dimension is a time period, the date or time + period targeted. + +.. tip:: + To see the formulas of spreadsheet cells, click :menuselection:`View -->` :icon:`fa-eye` + :menuselection:`Show --> Formulas` on the menu bar. The example below shows the functions for a + static pivot table. + + .. image:: insert/pivot-table-formulas.png + :alt: Functions of a static pivot table + +.. _spreadsheet/insert/pivot-table-properties: + +Pivot table properties +---------------------- + +The pivot table properties appear on the right side of the screen when a pivot table is inserted. +They can be accessed at any time via the :guilabel:`Data` menu by clicking the relevant pivot table, +as prefaced by the :icon:`oi-view-pivot` :guilabel:`(pivot)` icon, or by right-clicking anywhere on +the pivot table and clicking :icon:`oi-view-pivot` :guilabel:`See pivot properties`. + +The following pivot table properties are shown, some of which can be edited: + +- :guilabel:`Pivot #`: the pivot table ID. Pivot table IDs are assigned sequentially as additional + pivot tables are inserted in the spreadsheet. +- :guilabel:`Name`: the name of the pivot table. Edit this if needed. Note that editing the name + in the pivot table properties does not modify the name shown in the sheet name, and vice versa. +- :guilabel:`Model`: the model from which the data has been extracted. +- :guilabel:`Columns` and :guilabel:`Rows`: dimensions you are using to categorize or group data + from the model. +- :guilabel:`Measures`: what you are measuring, or analyzing, based on the dimensions you have + chosen. + + .. tip:: + If you attempt to make changes to the columns, rows, or measures of a pivot table that has just + been inserted into a spreadsheet, an error appears at the top right of the screen. + + .. image:: dynamic_pivot_tables/pivot-table-error.png + :alt: Error message when trying to manipulate static pivot table + + To be able to manipulate a pivot table's properties, convert a static pivot table to a + :ref:`dynamic pivot table `. + +- :guilabel:`Domain`: the rules used to determine which records are shown. Click + :ref:`Edit domain ` to add or edit rules. + + .. note:: + When :doc:`global filters ` are used, this domain is combined with the selected + values of the global filter before the data is loaded into the spreadsheet. + +To :ref:`duplicate ` or :ref:`delete +` a pivot table's data source, click the :icon:`fa-cog` +:guilabel:`(gear)` icon then :icon:`fa-copy` :guilabel:`Duplicate` or :icon:`fa-trash` +:guilabel:`Delete`. + +.. _spreadsheet/insert/pivot-table-manage: + +Manage an inserted pivot table +------------------------------ + +Once a pivot table from an Odoo database has been inserted into an Odoo spreadsheet, you can: + +- :ref:`convert it to a dynamic pivot table ` to be able to + manipulate the dimensions and measures +- :ref:`duplicate the pivot table ` to create a new, + identical data source +- :ref:`delete the pivot table and its underlying data source + ` + +.. _spreadsheet/insert/pivot-table-duplicate: + +Duplicate a pivot table +~~~~~~~~~~~~~~~~~~~~~~~ + +Duplicating a pivot table via the pivot table's properties creates an additional data source. This +allows for different manipulations to be performed on the same data within one spreadsheet. + +For example, you can see the same data aggregated by different dimensions or use :doc:`global +filters ` to offset the date and create pivot tables that compare the current +period's data with a previous period. + +To duplicate a pivot table, perform the following steps: + +#. With the :ref:`pivot table properties ` open, click + the :icon:`fa-cog` :guilabel:`(gear)` icon then :icon:`fa-clone` :guilabel:`Duplicate`. + + The duplicated pivot table is automatically inserted into a new sheet in the spreadsheet, with + the pivot table properties open in the right pane. +#. Edit the :guilabel:`Name` in the properties pane and the sheet tab if needed. + +The new data source is assigned the next available pivot table ID. For example, if no other pivot +tables have been inserted in the meantime, duplicating *Pivot #1* results in the creation of +*Pivot #2*. .. note:: - To update pivots and lists data without reopening a spreadsheet, go to the menu bar and click - :menuselection:`Data --> Refresh all data`. + - Duplicating an inserted pivot table by copying and pasting it or by duplicating the sheet does + not create a new data source. Any changes made to the pivot table's properties would therefore + impact any copies of the pivot table. + - When a pivot table is duplicated, the new pivot table is by default a :doc:`dynamic pivot table + `. + +.. _spreadsheet/insert/pivot-table-delete: + +Delete a pivot table +~~~~~~~~~~~~~~~~~~~~ + +To fully delete a pivot table and the underlying data source from a spreadsheet, perform the +following steps in any order: + +- Delete the spreadsheet table using your preferred means, e.g., via keyboard commands, spreadsheet + menus, or by deleting the sheet. This deletes the visual representation of the data. +- From the :ref:`properties pane ` of the relevant pivot + table, click the :icon:`fa-cog` :guilabel:`(gear)` icon then :icon:`fa-trash` :guilabel:`Delete`. + This deletes the data source of the pivot table. + +.. _spreadsheet/insert/chart: + +Insert a chart +============== + +To insert a chart from an Odoo database into an Odoo spreadsheet: + +#. With the graph view selected, click :guilabel:`Insert in Spreadsheet`. +#. In the window that opens, edit the :guilabel:`Name of the graph` if needed. + +#. Click :guilabel:`Blank spreadsheet` or select in which existing spreadsheet the chart should be + inserted. + + .. note:: + New spreadsheets are saved in the **Odoo Documents** app in either the :icon:`fa-hdd-o` + :guilabel:`My Drive` personal workspace or, if :ref:`file centralization + ` has been enabled for spreadsheets, in the + :guilabel:`Spreadsheet` workspace. + +#. Click :guilabel:`Confirm`. + +Charts are inserted on the first sheet of the spreadsheet. + +.. _spreadsheet/insert/chart-properties: + +Chart properties +---------------- + +When you insert a chart into a spreadsheet, the chart properties appear on the right side of the +screen. Access these at any time via the :guilabel:`Data` menu by clicking the relevant chart, as +prefaced by the :icon:`fa-bar-chart` :guilabel:`(chart)` icon. Alternatively, hover over the chart +then click the :icon:`fa-bars` :guilabel:`(menu)` icon and click :icon:`fa-pencil-square-o` +:guilabel:`Edit`. + +In the chart properties, the :icon:`fa-sliders` :guilabel:`Configuration` and :icon:`fa-paint-brush` +:guilabel:`Design` tabs let you modify various elements of the chart. + +Configuration +~~~~~~~~~~~~~ + +The :icon:`fa-sliders` :guilabel:`Configuration` tab includes the following sections: + +- :guilabel:`Chart type`: the type of chart. By default, this indicates the type of chart you + selected in the graph view in the database before inserting the chart in the spreadsheet. + + After a chart has been inserted, more chart types are available. Click the dropdown menu to + select the most appropriate chart type for the data. + + .. tabs:: + + .. tab:: Line + + .. image:: insert/chart-type-line.png + :alt: Line chart icon + + :guilabel:`Line`: best for showing trends or changes over time, such as sales + growth across months or temperature variations. + + .. image:: insert/chart-type-line-stacked.png + :alt: Stacked line chart icon + + :guilabel:`Stacked Line`: useful for visualizing cumulative trends where multiple series + contribute to a total, like revenue by department over time. + + .. tab:: Column + + .. image:: insert/chart-type-column.png + :alt: Column chart icon + + :guilabel:`Column`: ideal for comparing values across discrete categories, such as sales per + product or revenue by region. + + .. image:: insert/chart-type-column-stacked.png + :alt: Stacked column chart icon + + :guilabel:`Stacked Column`: displays part-to-whole relationships within categories, such as + regional contributions to total sales. + + .. tab:: Area + + .. image:: insert/chart-type-area.png + :alt: Area chart icon + + :guilabel:`Area`: similar to a line chart but fills the area beneath the lines to emphasize + magnitude, perfect for cumulative metrics over time. + + .. image:: insert/chart-type-area-stacked.png + :alt: Stacked area chart icon + + :guilabel:`Stacked Area`: visualizes the composition of changes over time, such as market + share by product category. + + .. tab:: Pie + + .. image:: insert/chart-type-pie.png + :alt: Pie chart icon + + :guilabel:`Pie`: best for showing proportions or percentages of a whole, such as market + share or budget allocation. + + .. tab:: Other + + When creating a chart from spreadsheet data, rather than inserting one from a graph view, + the following chart types are also available: + + .. image:: insert/chart-type-line-combo.png + :alt: Combo chart icon + + :guilabel:`Combo`: combines multiple chart types (e.g., bars and lines) to compare different + data types or highlight key metrics alongside trends. + + .. image:: insert/chart-type-bar.png + :alt: Bar chart icon + + :guilabel:`Bar`: similar to a column chart but horizontal, making it better for comparing + long category names or datasets. + + .. image:: insert/chart-type-bar-stacked.png + :alt: Stacked bar chart icon + + :guilabel:`Stacked Bar`: highlights cumulative contributions across categories, often used + in demographic or resource allocation analysis. + + .. image:: insert/chart-type-doughnut.png + :alt: Doughnut chart icon + + :guilabel:`Doughnut`: A variation of the pie chart with a hollow center, offering similar + use cases but with a modern aesthetic. + + .. image:: insert/chart-type-scatter.png + :alt: Scatter chart icon + + :guilabel:`Scatter`: ideal for analyzing relationships or correlations between two numerical + variables, such as price vs. quantity sold. + + .. image:: insert/chart-type-gauge.png + :alt: Gauge chart icon + + :guilabel:`Gauge`: displays progress toward a goal or a single key metric, such as + performance against a target. + + .. image:: insert/chart-type-scorecard.png + :alt: Scorecard icon + + :guilabel:`Scorecard`: used to summarize key performance indicators (KPIs) in a compact + format, such as total sales or conversion rates, and compare to a baseline or a previous + value. + + .. image:: insert/chart-type-waterfall.png + :alt: Waterfall chart icon + + :guilabel:`Waterfall`: ideal for visualizing cumulative effects of sequential positive and + negative values, such as profit/loss analysis. + + .. image:: insert/chart-type-population-pyramid.png + :alt: Population pyramid chart icon + + :guilabel:`Population Pyramid`: a specialized chart for comparing distributions, often used + in demographics, such as age and gender group analysis. + +- :guilabel:`Domain`: the rules used to determine which records are shown. Click :ref:`Edit domain + ` to add or edit rules. +- :guilabel:`Link to Odoo menu`: to add a :ref:`clickable link ` + from a chart to an Odoo menu item, i.e., a specific view of a model. + +Design +~~~~~~ + +Depending on the chart type, the :icon:`fa-paint-brush` :guilabel:`Design` tab has one or more +sections. + +The :guilabel:`General` section lets you modify the following elements: + +- :guilabel:`Background color`: Add or change the background color by clicking on the circle. Choose + one of the standard colors or click the :icon:`fa-plus` icon to manually select a custom color. +- :guilabel:`Chart title`: Edit the chart title. The font formatting, horizontal alignment and + color of the title can be modified using the editor. +- :guilabel:`Vertical axis position`: Choose whether the vertical axis is placed on the left or + right in line, column, and area charts. +- :guilabel:`Legend position`: Change the position of the legend or opt to have no legend. +- Enable :guilabel:`Show values` to add numeric values to the data points on the + chart. +- Enable :guilabel:`Show trend line` to add a trend line to line, column, and area charts. + +For line, column, and area charts, the :guilabel:`Axis` section lets you add a title to one or both +axes. The font formatting, horizontal alignment, and color of the title can be modified using the +editor. + +.. _spreadsheet/insert/clickable-links: + +Insert clickable links +====================== + +Adding links to related or supporting information can make your report or dashboard more +user-friendly and effective. + +You can :ref:`insert a clickable link from any spreadsheet cell +` to: + +- an Odoo menu item +- another sheet inside the same spreadsheet +- an external URL + +.. note:: + - Clicking a link to a menu item provides the same result as navigating via the Odoo menu within + an app, e.g., the menu item :guilabel:`Sales/Orders/Quotations` corresponds to the default view + when navigating to :menuselection:`Sales --> Orders --> Quotations`. + - It is also possible to insert a clickable link to a specific view of a model in a spreadsheet + starting from the view itself. However, as this method inserts each new link in a new sheet, it + is more efficient to create links to specific views starting from the spreadsheet. + +You can :ref:`insert a clickable link from any chart ` to +an Odoo menu item. + +.. _spreadsheet/insert/clickable-links-cell: + +Insert a clickable link from a cell +----------------------------------- + +To insert a clickable link from a cell: + +#. Click :menuselection:`Insert -->` :icon:`fa-link` :menuselection:`Link` from the menu bar or + right-click on the cell, then click :icon:`fa-link` :guilabel:`Insert link`. Next, depending on + the desired outcome, perform one of the following actions: + + - Click the :icon:`fa-bars` :guilabel:`(menu)` icon, then :guilabel:`Link an Odoo menu`. Select the relevant + menu item from the list or click :guilabel:`Search more` to choose from a list of all menu + items. Click :guilabel:`Confirm`. + - Click the :icon:`fa-bars` :guilabel:`(menu)` icon, then :guilabel:`Link sheet`, then choose the + relevant sheet from the current spreadsheet. + - Under :guilabel:`Link`, type a URL. + +#. Enter or edit the label for the link in the :guilabel:`Text` field. +#. Click :guilabel:`Confirm`. + +.. _spreadsheet/insert/clickable-links-chart: + +Insert a clickable link from a chart +------------------------------------ + +To insert a clickable link from a chart to an Odoo menu item: + +#. Hover over the top right of the chart's box, then click the :icon:`fa-bars` :guilabel:`(menu)` + icon, then :icon:`fa-pencil-square-o` :guilabel:`Edit`. The chart properties appear at the right + of the screen. +#. At the bottom of the :icon:`fa-sliders` :guilabel:`Configuration` tab of the chart properties + pane, click under :guilabel:`Link to Odoo menu`, then select a menu. + +Hover over the top right of the chart's box to see that a new :icon:`fa-external-link` +:guilabel:`(external link)` icon has been added. + +.. tip:: + Clicking on a data point in a chart opens the relevant list view in the database. In the example + clicking on :guilabel:`Jessica Childs` opens the list view of all sales by this salesperson that + match the domain of the chart. + + .. image:: insert/clickable-link-chart.png + :alt: A clickable link to an Odoo menu plus clickable data point -Pivot data ----------- +.. _spreadsheet/insert/financial-data: -Using :guilabel:`Refresh all data` only updates existing pivot cells. If new cells need to be added, -go to the menu bar and click :menuselection:`Data --> Re-insert pivot` to fully update the pivot. -Alternatively, click :guilabel:`Insert pivot`, select the pivot, and tick :guilabel:`Display missing -cells only` to preview first the missing data. +Insert financial data +===================== - .. image:: insert/missing-cells.png - :align: center - :alt: Displaying missing cells in a pivot +When building reports and dashboards, it may be useful to include certain accounting-related data, +such as account IDs, credits and debits for specific accounts, and dates of the start and end of the +tax year. -To change which records are :ref:`used by the pivot `, right-click on -a pivot cell, select :guilabel:`See pivot properties`, and click :guilabel:`Edit domain`. +:ref:`Odoo-specific spreadsheet functions ` allow you to retrieve such +accounting data from your database and insert it into a spreadsheet. diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-area-stacked.png b/content/applications/productivity/spreadsheet/insert/chart-type-area-stacked.png new file mode 100644 index 0000000000..bed4b5d0a7 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-area-stacked.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-area.png b/content/applications/productivity/spreadsheet/insert/chart-type-area.png new file mode 100644 index 0000000000..6dda39e373 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-area.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-bar-stacked.png b/content/applications/productivity/spreadsheet/insert/chart-type-bar-stacked.png new file mode 100644 index 0000000000..3c31dceca4 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-bar-stacked.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-bar.png b/content/applications/productivity/spreadsheet/insert/chart-type-bar.png new file mode 100644 index 0000000000..025ede44cd Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-bar.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-column-stacked.png b/content/applications/productivity/spreadsheet/insert/chart-type-column-stacked.png new file mode 100644 index 0000000000..059ef8a564 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-column-stacked.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-column.png b/content/applications/productivity/spreadsheet/insert/chart-type-column.png new file mode 100644 index 0000000000..ed67b8ae7f Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-column.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-doughnut.png b/content/applications/productivity/spreadsheet/insert/chart-type-doughnut.png new file mode 100644 index 0000000000..d218c27f7d Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-doughnut.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-filled-radar.png b/content/applications/productivity/spreadsheet/insert/chart-type-filled-radar.png new file mode 100644 index 0000000000..b8b5f8d5d4 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-filled-radar.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-gauge.png b/content/applications/productivity/spreadsheet/insert/chart-type-gauge.png new file mode 100644 index 0000000000..a668537538 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-gauge.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-geo.png b/content/applications/productivity/spreadsheet/insert/chart-type-geo.png new file mode 100644 index 0000000000..1885d634af Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-geo.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-line-combo.png b/content/applications/productivity/spreadsheet/insert/chart-type-line-combo.png new file mode 100644 index 0000000000..f3353812b8 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-line-combo.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-line-stacked.png b/content/applications/productivity/spreadsheet/insert/chart-type-line-stacked.png new file mode 100644 index 0000000000..17121323be Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-line-stacked.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-line.png b/content/applications/productivity/spreadsheet/insert/chart-type-line.png new file mode 100644 index 0000000000..1cc1511e35 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-line.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-pie.png b/content/applications/productivity/spreadsheet/insert/chart-type-pie.png new file mode 100644 index 0000000000..8bfea76392 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-pie.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-population-pyramid.png b/content/applications/productivity/spreadsheet/insert/chart-type-population-pyramid.png new file mode 100644 index 0000000000..de887710bd Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-population-pyramid.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-radar.png b/content/applications/productivity/spreadsheet/insert/chart-type-radar.png new file mode 100644 index 0000000000..8c112a1944 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-radar.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-scatter.png b/content/applications/productivity/spreadsheet/insert/chart-type-scatter.png new file mode 100644 index 0000000000..57e8eca2ea Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-scatter.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-scorecard.png b/content/applications/productivity/spreadsheet/insert/chart-type-scorecard.png new file mode 100644 index 0000000000..ea80d8fd15 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-scorecard.png differ diff --git a/content/applications/productivity/spreadsheet/insert/chart-type-waterfall.png b/content/applications/productivity/spreadsheet/insert/chart-type-waterfall.png new file mode 100644 index 0000000000..3e14dd7cf4 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/chart-type-waterfall.png differ diff --git a/content/applications/productivity/spreadsheet/insert/clickable-link-chart.png b/content/applications/productivity/spreadsheet/insert/clickable-link-chart.png new file mode 100644 index 0000000000..0aaea2b80c Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/clickable-link-chart.png differ diff --git a/content/applications/productivity/spreadsheet/insert/data-menu.png b/content/applications/productivity/spreadsheet/insert/data-menu.png new file mode 100644 index 0000000000..57cb2e1cc3 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/data-menu.png differ diff --git a/content/applications/productivity/spreadsheet/insert/insert-list.png b/content/applications/productivity/spreadsheet/insert/insert-list.png new file mode 100644 index 0000000000..661c9beefb Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/insert-list.png differ diff --git a/content/applications/productivity/spreadsheet/insert/insert-pivot-table.png b/content/applications/productivity/spreadsheet/insert/insert-pivot-table.png new file mode 100644 index 0000000000..a974a09b9a Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/insert-pivot-table.png differ diff --git a/content/applications/productivity/spreadsheet/insert/insert-spreadsheet.png b/content/applications/productivity/spreadsheet/insert/insert-spreadsheet.png deleted file mode 100644 index b6359ce599..0000000000 Binary files a/content/applications/productivity/spreadsheet/insert/insert-spreadsheet.png and /dev/null differ diff --git a/content/applications/productivity/spreadsheet/insert/list-add-columns.png b/content/applications/productivity/spreadsheet/insert/list-add-columns.png new file mode 100644 index 0000000000..0a58e39093 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/list-add-columns.png differ diff --git a/content/applications/productivity/spreadsheet/insert/list-add-records.png b/content/applications/productivity/spreadsheet/insert/list-add-records.png new file mode 100644 index 0000000000..b205128124 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/list-add-records.png differ diff --git a/content/applications/productivity/spreadsheet/insert/list-deleted.png b/content/applications/productivity/spreadsheet/insert/list-deleted.png new file mode 100644 index 0000000000..95799cbf39 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/list-deleted.png differ diff --git a/content/applications/productivity/spreadsheet/insert/list-formulas.png b/content/applications/productivity/spreadsheet/insert/list-formulas.png new file mode 100644 index 0000000000..0cd9301ad1 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/list-formulas.png differ diff --git a/content/applications/productivity/spreadsheet/insert/missing-cells.png b/content/applications/productivity/spreadsheet/insert/missing-cells.png deleted file mode 100644 index 08a538b508..0000000000 Binary files a/content/applications/productivity/spreadsheet/insert/missing-cells.png and /dev/null differ diff --git a/content/applications/productivity/spreadsheet/insert/pivot-table-error.png b/content/applications/productivity/spreadsheet/insert/pivot-table-error.png new file mode 100644 index 0000000000..b0a0a348e8 Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/pivot-table-error.png differ diff --git a/content/applications/productivity/spreadsheet/insert/pivot-table-formulas.png b/content/applications/productivity/spreadsheet/insert/pivot-table-formulas.png new file mode 100644 index 0000000000..b1c4c8fd2a Binary files /dev/null and b/content/applications/productivity/spreadsheet/insert/pivot-table-formulas.png differ diff --git a/content/applications/productivity/spreadsheet/ui-elements.png b/content/applications/productivity/spreadsheet/ui-elements.png deleted file mode 100644 index 618ec00cf4..0000000000 Binary files a/content/applications/productivity/spreadsheet/ui-elements.png and /dev/null differ