mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2025-01-31 04:46:11 +01:00
Merge branch 'bugfix/null-keyword' into 'dev'
Empty Keyword List See merge request crafty-controller/crafty-4!819
This commit is contained in:
commit
83dcbe4ed0
@ -9,6 +9,7 @@ TBD
|
|||||||
### Bug fixes
|
### Bug fixes
|
||||||
- Bump requests to resolve yank for CVE-2024-35195 ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/808))
|
- Bump requests to resolve yank for CVE-2024-35195 ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/808))
|
||||||
- Better handle malformed mcping data ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/799))
|
- Better handle malformed mcping data ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/799))
|
||||||
|
- Resolves type issue when posting no keywords in the "keyword" field in config.json tab ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/819))
|
||||||
### Tweaks
|
### Tweaks
|
||||||
- Dyamically change child action translation for backups ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/806))
|
- Dyamically change child action translation for backups ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/806))
|
||||||
- Remove EXIF image data on app Background Photos ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/805))
|
- Remove EXIF image data on app Background Photos ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/805))
|
||||||
|
@ -148,7 +148,7 @@
|
|||||||
{% block js %}
|
{% block js %}
|
||||||
<script>
|
<script>
|
||||||
function replacer(key, value) {
|
function replacer(key, value) {
|
||||||
if (key == "disabled_language_files" || key == "monitored_mounts") {
|
if (key == "disabled_language_files" || key == "monitored_mounts" || key == "keywords") {
|
||||||
if (value == 0) {
|
if (value == 0) {
|
||||||
return []
|
return []
|
||||||
} else {
|
} else {
|
||||||
@ -177,6 +177,7 @@
|
|||||||
formDataObject.disabled_language_files = $('#lang_select').val();
|
formDataObject.disabled_language_files = $('#lang_select').val();
|
||||||
formDataObject.monitored_mounts = $('#mount_select').val();
|
formDataObject.monitored_mounts = $('#mount_select').val();
|
||||||
formDataObject.keywords = $('#keywords').val().split(",");
|
formDataObject.keywords = $('#keywords').val().split(",");
|
||||||
|
|
||||||
$('#config-form input[type="radio"]:checked').each(function () {
|
$('#config-form input[type="radio"]:checked').each(function () {
|
||||||
if ($(this).val() == 'True') {
|
if ($(this).val() == 'True') {
|
||||||
formDataObject[this.name] = true;
|
formDataObject[this.name] = true;
|
||||||
@ -184,12 +185,10 @@
|
|||||||
formDataObject[this.name] = false;
|
formDataObject[this.name] = false;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
console.log(formDataObject);
|
|
||||||
// Format the plain form data as JSON
|
// Format the plain form data as JSON
|
||||||
let formDataJsonString = JSON.stringify(formDataObject, replacer);
|
let formDataJsonString = JSON.stringify(formDataObject, replacer);
|
||||||
|
|
||||||
console.log(formDataJsonString);
|
|
||||||
|
|
||||||
let res = await fetch(`/api/v2/crafty/config/`, {
|
let res = await fetch(`/api/v2/crafty/config/`, {
|
||||||
method: 'PATCH',
|
method: 'PATCH',
|
||||||
headers: {
|
headers: {
|
||||||
@ -316,4 +315,4 @@
|
|||||||
</script>
|
</script>
|
||||||
<script src="../../static/assets/vendors/js/bootstrap-select.min.js">
|
<script src="../../static/assets/vendors/js/bootstrap-select.min.js">
|
||||||
</script>
|
</script>
|
||||||
{% end %}
|
{% end %}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user