Skip to content

Commit

Permalink
fix: css class status after save don't update
Browse files Browse the repository at this point in the history
  • Loading branch information
wonknu committed Oct 26, 2016
1 parent ecf81ab commit 7bd93e7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/server/public/scripts/modules/EditorSave.js
Expand Up @@ -145,6 +145,11 @@ export default class EditorSave {
if(result.success === 1) {
window.json = result.json
}
var formWrapper = document.querySelector('#abeForm')
formWrapper.classList.forEach(function (classStr) {
if(classStr.indexOf('status-') > -1) formWrapper.classList.remove(classStr)
})
formWrapper.classList.add('status-' + result.json.abe_meta.status)
this.onFileSaved._fire()
}).catch(function(e) {
console.error(e)
Expand Down

0 comments on commit 7bd93e7

Please sign in to comment.