fix(store-service, owner vue): category Dto 리팩토링

-category Dto  에 Store entity가 존재하는것 수정
-owner vue에 category 조회시 error 수정
This commit is contained in:
hoon7566
2022-03-10 15:46:37 +09:00
parent d012fe3fb0
commit 55ec97af93
7 changed files with 19 additions and 36 deletions

View File

@@ -56,7 +56,7 @@
<script>
import draggable from 'vuedraggable'
import store from "@/api/store";
import storeApi from "@/api/store";
import {
mdiContentSave, mdiDelete,
mdiPlus,
@@ -103,7 +103,7 @@ export default {
let data = {
storeId : "1",
categoryList: [],
deletedList: vm.deletedList
deletedList: this.deletedList
}
var categoryEl = document.querySelector("#categoryEl");
@@ -116,16 +116,17 @@ export default {
data.categoryList.push(category)
})
store.putCategoryList(data)
storeApi.putCategoryList(data)
.then(function () {
vm.deletedList=[]
vm.getCategoryList()
});
},
getCategoryList:function(){
this.deletedList=[]
this.categoryList = [];
var vm =this;
store.getCategoryList()
storeApi.getCategoryList()
.then(function (response) {
vm.categoryList = response.data.data;
});