Commit Graph
53 Commits
Author SHA1 Message Date
Cédric Krier 276cf8277b Disable button and action when screen and records are readonly 2023-03-19 01:44:45 +01:00
Cédric Krier bb0445d52d Set record as readonly when group is readonly 2023-03-19 01:44:05 +01:00
Cédric Krier 0bff126745 Disable new button when record is modified
To simplify the management of the state of button, activate_save is merged
with set_buttons_sensitive.

Closes #8053
2023-03-19 01:20:45 +01:00
Cédric Krier c7a0be2a76 Call record saved after saving the current record of the screen
Since 403bc7a95b0a record_saved has been implemented but it is not called by
the Screen when saving record.

Closes #12117, #12137
2023-03-09 00:21:06 +01:00
Nicolas Évrard 4dfea2f82c Catch error when rendering cells in treeviews
Closes #11835
2023-03-01 18:21:10 +01:00
Cédric Krier c2f8c05724 Instantiate with jQuery elements from .each when clearing info bar
fae13a75319f introduced clearing per kind but .each method return DOM element
instead of jQuery instance.
2023-03-09 00:14:45 +01:00
Cédric Krier 54630b81dc Remove unused set_value method from board action
Closes #5046
2023-02-20 17:03:50 +01:00
Cédric Krier 82b0f2779b Enforce unique value for invisible field
Closes #12034
2023-02-11 18:07:06 +01:00
Cédric Krier 98adfc2c3e Add kind to info bar message to keep notification message longer
The notification message should not be cleared when the record is changed but
only when a new notification is computed.

Closes #12050
2023-01-30 00:23:16 +01:00
Cédric Krier 7843e47389 Add scroll time for calendar view 2023-01-28 10:42:58 +01:00
Cédric Krier 90c3c5cc13 Compute calendar height to fit to the page of sao
This way if needed the scroll bar are inside the fullcalendar view and it can
scroll to an initial time.
2023-01-27 23:38:55 +01:00
Cédric Krier 1d0bd3aef6 Remove user name placeholder which repeat the label
Closes #7180
2023-01-23 23:28:09 +01:00
Nicolas Évrard c989938e68 Do not trigger button on not selected records
Closes #11824
2023-02-03 18:19:31 +01:00
Cédric Krier 3c771cff02 Implement listed records for calendar and list-form views 2022-12-31 00:57:23 +01:00
Cédric Krier 56a332d18e Set record as modified after calling changed
The record must be modified after the call to changed because set_modified
trigger the changed calls of the parent which need to have the changed values.

Closes #12065, #12072
(backout 6b882007fd6e)
2023-02-06 18:09:20 +01:00
Cédric Krier 58d00ed942 Search also for select tag for the focus chain
Closes #12051
2023-01-30 00:44:18 +01:00
Nicolas Évrard 5414f334e8 Restore tree sates on List Form
Closes #12023
2023-01-19 19:03:42 +01:00
Nicolas Évrard 7d4a991104 Do record (pre)validation and saving on selection change for list-form views
Closes #12025
2023-01-29 00:56:28 +01:00
Cédric Krier a6419fd273 Append domain label to link
The domain labels are replacing the link label instead of being appended.
2023-01-26 14:56:44 +01:00
Cédric Krier e7d357098f Set correct limit/offset in search_count of Link
a96bf0b0b065 adds limit to the search_count call but the argument position is
wrong in the call for the Link widget.
2023-01-26 14:55:50 +01:00
Cédric Krier 5403074f1d Convert empty value as null instead of 0 in Dict numeric fields
Closes #12038
2023-01-25 00:38:36 +01:00
Cédric Krier 65c8d8dd36 Set width on numeric input instead of the input group
Closes #12037
2023-01-25 00:28:00 +01:00
Nicolas Évrard 5ea2598611 Call set_modified on record in set_client
403bc7a95b0a introduced set_modified as a record method but not a field one.
It was unfortunately called on the field in set_client in the same commit.

Closes #12061
2023-02-01 17:54:26 +01:00
Cédric Krier 7958f04d66 Set default badge and sent record message when current record is None
Closes #12032
2023-01-24 01:00:12 +01:00
Cédric Krier ef11936771 Apply muted visual for deleted or removed row
Closes #7355
2023-01-24 00:41:48 +01:00
Nicolas Évrard 1fdfe31b1e Get directly the string value of Selection fields in non editable views
Closes #10331
2023-01-29 01:12:24 +01:00
Cédric Krier 8532fa3bd5 Update One2Many validate to use promise based API of pre_validate
Closes #12039
2023-01-30 00:16:07 +01:00
Cédric Krier 4573a5c90e Call preventDefault as soon as possible in sao
This is safer in case exception is raised before so the browser may try to
submit the form and trigger a reload of the application.

Closes #6419
2023-01-27 00:03:00 +01:00
Nicolas Évrard e1361ddac3 Use arrow functions in Sao.Window.Form.response 2023-01-26 22:46:53 +01:00
Nicolas Évrard 45043d706e Use a promise based API for Record.pre_validate()
Closes #12039
2023-01-25 15:14:26 +01:00
Cédric Krier d62f2acb08 Instantiate always Screen for xxx2Many fields with the same parameters
The screen must be instantiated with the context of the parent screen so
eventual field_view_get would give the same result.
The limit must always be set to None/null to ensure to load all the records.
The breadcrumb must be set to show navigation to the user.

Closes #3140
2023-01-21 19:37:19 +01:00
Cédric Krier 82b10ce017 Fix typo when calling get_state_attrs introduced by a151a379886f 2023-01-21 19:39:55 +01:00
Cédric Krier 5836fd178c Do not select first record by default
Closes #11814
2022-12-30 23:41:40 +01:00
Cédric Krier 26b9f97577 Use & and | as boolean operator in search widget
Closes #11962, #8714
2022-12-27 17:36:16 +01:00
Cédric Krier 3aadada047 Use toggle button and label on translate dialog
A toggle button with a label is easier to understand that it should be toggled
to edit.
It is cleaner to only display a fuzzy label than having a column of
checkboxes.

Closes #3125
2023-01-13 00:54:37 +01:00
Hodei Navarro 8afe6df925 Add border type to images
Closes #11458
2023-01-03 11:17:34 +01:00
Cédric Krier 9d402b3807 Set record as modified before calling changed methods
Setting the record as modified clear the info bar but the changed methods
result may add messages to the info bar. So they must be added after the
clearing to let user see them.

Closes #11970
2022-12-29 13:24:06 +01:00
Cédric Krier ad6931ab5c Send record modified only when widget is actually modified
#11970
2022-12-29 13:21:39 +01:00
Cédric Krier 84d80a454f Refresh info bar when record is modified
#11970
2022-12-29 13:20:31 +01:00
Cédric Krier 6bcb3c9868 Do not trigger record message if the current record did not changed
#11970
2022-12-29 13:19:01 +01:00
Nicolas Évrard 3632c51c18 Manage domain on id in single value list as unique
Closes #11953
2023-01-02 11:49:34 +01:00
Nicolas Évrard 8d3d4c79ff Do not validate domain on empty fields unless they're required 2022-12-21 22:29:24 +01:00
Cédric Krier 62e8201d5a Add unit test reports 2023-01-08 01:55:20 +01:00
Cédric Krier 5f8b891f62 Increase verbosity of tox 2022-12-28 00:26:31 +01:00
Cédric Krier e745f06e5f Add more prefixes for humanized number
Closes #11918
2022-12-26 13:00:02 +01:00
Cédric Krier 42b023587e Cache digits and symbol on the field instance of the client
Closes #11825
2022-12-30 23:34:52 +01:00
Cédric Krier e76de7cb81 Convert multiselection into selection for screen domain parser
When the selection of multiselection fields is a method, it must be converted
into a list like the selection fields.

Closes #11968
2022-12-28 10:41:52 +01:00
Nicolas Évrard c1f8fdf664 Do not use default record size limit when it is null
Closes #11924
2022-12-29 10:51:47 +01:00
Cédric Krier c3867c6423 Display the number of selected records on xxx2Many
Closes #11813
2022-12-23 19:39:29 +01:00
Nicolas Évrard 2b6801f02c Use record from group when setting O2M from values
Closes #11951
2022-12-23 23:54:21 +01:00