Daniel Supernault 6 年之前
父节点
当前提交
e9c8646137
共有 1 个文件被更改,包括 4 次插入2 次删除
  1. 4 2
      resources/assets/js/components/PostComponent.vue

+ 4 - 2
resources/assets/js/components/PostComponent.vue

@@ -728,8 +728,10 @@ export default {
               type: 'status',
               item: this.status.id
             }).then(res => {
-              swal('Success', 'You have successfully deleted this post', 'success');
-              window.location.href = '/';
+              setTimeout(function() {
+                swal('Success', 'You have successfully deleted this post', 'success');
+                window.location.href = '/';
+              }, 2000);
             }).catch(err => {
               swal('Error', 'Something went wrong. Please try again later.', 'error');
             });