實例方法:
that.$delete(data,"dateTime")
代碼:
getDocSource: function(data) { var that = this; //刪除數組對象中的undefined,防止接口報錯 if (data.dateTime == undefined) { // data 是數組名 dateTime 是屬性 that.$delete(data,"dateTime") } that.$request.HttpData("/applet/scheduling/opSch", data, "POST", true, '加載中', function(res) { console.info(res) if (res.data.code == 1) { that.docSource = res.data.data; that.isloading = false; } }, function(err) { }) }