Ver código fonte

fix post json parameter for real updating content

weichen 4 anos atrás
pai
commit
7ada4c85d1
1 arquivos alterados com 1 adições e 3 exclusões
  1. 1 3
      backstage/static/js/editor.js

+ 1 - 3
backstage/static/js/editor.js

@@ -93,9 +93,7 @@ axios.get(contentApiUrl).then(({ data }) => {
 
     const postData = {
       content: mdContent,
-      path: '家具規劃作品/公仔與爵士鼓/index.md',
-      title: 'test_post_index',
-      url: '/collection/test_post_index'
+      url: (JSON.parse(document.getElementById('url').textContent)).url
     }
     axios.post(contentApiUrl, json=postData);
   }