comparison core/modules/quickedit/js/views/AppView.js @ 4:a9cd425dd02b

Update, including to Drupal core 8.6.10
author Chris Cannam
date Thu, 28 Feb 2019 13:11:55 +0000
parents c75dbcec494b
children
comparison
equal deleted inserted replaced
3:307d7a7fd348 4:a9cd425dd02b
61 delete entityModel.toolbarView; 61 delete entityModel.toolbarView;
62 } 62 }
63 63
64 if (reload) { 64 if (reload) {
65 reload = false; 65 reload = false;
66 location.reload(); 66 window.location.reload();
67 } 67 }
68 break; 68 break;
69 } 69 }
70 }, 70 },
71 acceptEditorStateChange: function acceptEditorStateChange(from, to, context, fieldModel) { 71 acceptEditorStateChange: function acceptEditorStateChange(from, to, context, fieldModel) {
285 var htmlForOtherViewModes = updatedField.get('htmlForOtherViewModes'); 285 var htmlForOtherViewModes = updatedField.get('htmlForOtherViewModes');
286 Drupal.quickedit.collections.fields.where({ logicalFieldID: updatedField.get('logicalFieldID') }).forEach(function (field) { 286 Drupal.quickedit.collections.fields.where({ logicalFieldID: updatedField.get('logicalFieldID') }).forEach(function (field) {
287 if (field === updatedField) {} else if (field.getViewMode() === updatedField.getViewMode()) { 287 if (field === updatedField) {} else if (field.getViewMode() === updatedField.getViewMode()) {
288 field.set('html', updatedField.get('html')); 288 field.set('html', updatedField.get('html'));
289 } else if (field.getViewMode() in htmlForOtherViewModes) { 289 } else if (field.getViewMode() in htmlForOtherViewModes) {
290 field.set('html', htmlForOtherViewModes[field.getViewMode()], { propagation: true }); 290 field.set('html', htmlForOtherViewModes[field.getViewMode()], {
291 propagation: true
292 });
291 } 293 }
292 }); 294 });
293 }, 295 },
294 rerenderedFieldToCandidate: function rerenderedFieldToCandidate(fieldModel) { 296 rerenderedFieldToCandidate: function rerenderedFieldToCandidate(fieldModel) {
295 var activeEntity = Drupal.quickedit.collections.entities.findWhere({ isActive: true }); 297 var activeEntity = Drupal.quickedit.collections.entities.findWhere({
298 isActive: true
299 });
296 300
297 if (!activeEntity) { 301 if (!activeEntity) {
298 return; 302 return;
299 } 303 }
300 304