mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
fix(files_sharing): Remove debounce from expiration date formatting
This should be done as soon as changed, as the value is not passed to API but needs to be tracked internally (e.g. if you quickly press "save"). Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
This commit is contained in:
parent
260e82a8c4
commit
214a084d92
2 changed files with 6 additions and 4 deletions
|
|
@ -128,7 +128,7 @@ export default {
|
|||
return this.config.isDefaultExpireDateEnforced
|
||||
}
|
||||
if (this.isRemoteShare) {
|
||||
return this.config.isDefaultRemoteExpireDateEnforced
|
||||
return this.config.isDefaultRemoteExpireDateEnforced
|
||||
}
|
||||
return this.config.isDefaultInternalExpireDateEnforced
|
||||
},
|
||||
|
|
@ -209,9 +209,10 @@ export default {
|
|||
*
|
||||
* @param {Date} date
|
||||
*/
|
||||
onExpirationChange: debounce(function(date) {
|
||||
onExpirationChange(date) {
|
||||
this.share.expireDate = this.formatDateToString(new Date(date))
|
||||
}, 500),
|
||||
},
|
||||
|
||||
/**
|
||||
* Uncheck expire date
|
||||
* We need this method because @update:checked
|
||||
|
|
|
|||
|
|
@ -144,7 +144,8 @@
|
|||
:value="new Date(share.expireDate ?? dateTomorrow)"
|
||||
:min="dateTomorrow"
|
||||
:max="maxExpirationDateEnforced"
|
||||
:hide-label="true"
|
||||
hide-label
|
||||
:label="t('files_sharing', 'Expiration date')"
|
||||
:placeholder="t('files_sharing', 'Expiration date')"
|
||||
type="date"
|
||||
@input="onExpirationChange" />
|
||||
|
|
|
|||
Loading…
Reference in a new issue