var httpData=GetRequest(); parent.$("#layui-layer" + parent.photoLayerIndex + " .layui-layer-setwin").addClass("set-close-btn") new Vue({ el: "#app", data: { src: httpData.src }, methods: { setImg: function(str) { return httpRequest.getImgUrl(str); } } })