前端代码
data(){
return{
moveLists:[]
}
}
methods: {
var JobNum = JSON.parse(localStorage.getItem("baseJobNum"));
var moveMap = new Map();
moveMap.set(JobNum, this.moveLists);
let obj = Object.create(null);
for (let [k, v] of moveMap) {
obj[k] = v;
}
//object转json
let specialty = JSON.stringify(obj);
updateBaseInfo(specialty)
.then((res) => {})
}