require('../common/vendor.js');(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages_user/user/addDocRecord"],{676:function(e,t,n){"use strict";(function(e,t){var i=n(4);n(26);i(n(25));var o=i(n(677));e.__webpack_require_UNI_MP_PLUGIN__=n,t(o.default)}).call(this,n(1)["default"],n(2)["createPage"])},677:function(e,t,n){"use strict";n.r(t);var i=n(678),o=n(680);for(var r in o)["default"].indexOf(r)<0&&function(e){n.d(t,e,(function(){return o[e]}))}(r);n(682);var c,s=n(34),u=Object(s["default"])(o["default"],i["render"],i["staticRenderFns"],!1,null,null,null,!1,i["components"],c);u.options.__file="pages_user/user/addDocRecord.vue",t["default"]=u.exports},678:function(e,t,n){"use strict";n.r(t);var i=n(679);n.d(t,"render",(function(){return i["render"]})),n.d(t,"staticRenderFns",(function(){return i["staticRenderFns"]})),n.d(t,"recyclableRender",(function(){return i["recyclableRender"]})),n.d(t,"components",(function(){return i["components"]}))},679:function(e,t,n){"use strict";var i;n.r(t),n.d(t,"render",(function(){return o})),n.d(t,"staticRenderFns",(function(){return c})),n.d(t,"recyclableRender",(function(){return r})),n.d(t,"components",(function(){return i}));var o=function(){var e=this,t=e.$createElement,n=(e._self._c,e.imgList.length);e.$mp.data=Object.assign({},{$root:{g0:n}})},r=!1,c=[];o._withStripped=!0},680:function(e,t,n){"use strict";n.r(t);var i=n(681),o=n.n(i);for(var r in i)["default"].indexOf(r)<0&&function(e){n.d(t,e,(function(){return i[e]}))}(r);t["default"]=o.a},681:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(647),o={data:function(){return{imgList:[],docId:null,form:{images:[],title:""}}},onLoad:function(e){this.docId=e.docId},methods:{contentInput:function(e){this.form.title=e.detail.value},chooseImage:function(t){var n=this;e.chooseImage({count:4,sizeType:["original","compressed"],sourceType:["album","camera"],success:function(t){e.uploadFile({url:e.getStorageSync("requestPath")+"/app/common/uploadOSS",filePath:t.tempFilePaths[0],name:"file",success:function(e){n.imgList.push(JSON.parse(e.data).url)}})}})},previewImage:function(t){e.previewImage({urls:this.imgList,current:this.imgList[t]})},delImg:function(t){var n=this;e.showModal({title:"提示",content:"确定要删除这张图片吗？",cancelText:"取消",confirmText:"确定",success:function(e){e.confirm&&n.imgList.splice(t,1)}})},submit:function(){if(""!=this.form.title){e.showLoading({title:"正在处理中"});var t={docId:this.docId,title:this.form.title,images:this.imgList.toString()};(0,i.addDocRecord)(t).then((function(t){200==t.code?(e.hideLoading(),e.showToast({icon:"success",title:t.msg}),e.$emit("refreshDocRecord"),setTimeout((function(){e.navigateBack({delta:1})}),200)):e.showToast({icon:"none",title:t.msg})}),(function(e){}))}else e.showToast({icon:"none",title:"请输入健康记录内容"})}}};t.default=o}).call(this,n(2)["default"])},682:function(e,t,n){"use strict";n.r(t);var i=n(683),o=n.n(i);for(var r in i)["default"].indexOf(r)<0&&function(e){n.d(t,e,(function(){return i[e]}))}(r);t["default"]=o.a},683:function(e,t,n){}},[[676,"common/runtime","common/vendor","pages_user/common/vendor"]]]);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages_user/user/addDocRecord.js.map