Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
In cases where the server dictates the link share expiration the date…
… is not updated on consequitive changes and enable/disable actions
  • Loading branch information
DeepDiver1975 authored and LukasReschke committed Aug 29, 2016
commit 5856616d95aa1b50568259baf8425dbd2f4b5f33
5 changes: 4 additions & 1 deletion core/js/sharedialogexpirationview.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@
this.$el.find('.expirationDateContainer').toggleClass('hidden', !state);
if (!state) {
// discard expiration date
this.model.get('linkShare').expiration = '';
this.model.saveLinkShare({
expireDate: ''
});
Expand All @@ -104,8 +105,10 @@
$target.tooltip('hide');
$target.removeClass('error');

expiration = moment($target.val(), 'DD-MM-YYYY').format('YYYY-MM-DD');
this.model.get('linkShare').expiration = expiration;
this.model.saveLinkShare({
expiration: moment($target.val(), 'DD-MM-YYYY').format('YYYY-MM-DD')
expiration: expiration
}, {
error: function(model, message) {
if (!message) {
Expand Down