(self["webpackChunkuniapp"]=self["webpackChunkuniapp"]||[]).push([[492],{5047:function(t,e,i){var n=i(2862);n.__esModule&&(n=n.default),"string"===typeof n&&(n=[[t.id,n,""]]),n.locals&&(t.exports=n.locals);var s=i(5472).Z;s("39145137",n,!0,{sourceMap:!1,shadowMode:!1})},7995:function(t,e,i){var n=i(6620);n.__esModule&&(n=n.default),"string"===typeof n&&(n=[[t.id,n,""]]),n.locals&&(t.exports=n.locals);var s=i(5472).Z;s("67543b74",n,!0,{sourceMap:!1,shadowMode:!1})},928:function(t,e,i){var n=i(1169);n.__esModule&&(n=n.default),"string"===typeof n&&(n=[[t.id,n,""]]),n.locals&&(t.exports=n.locals);var s=i(5472).Z;s("3dede4f9",n,!0,{sourceMap:!1,shadowMode:!1})},8556:function(t,e,i){"use strict";var n;i.d(e,{Z:function(){return d}});var s,l=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{ref:"u-list-item-"+t.anchor,staticClass:"u-list-item",class:["u-list-item-"+t.anchor],attrs:{anchor:"u-list-item-"+t.anchor}},[t._t("default")],2)},a=[],o={props:{anchor:{type:[String,Number],default:uni.$u.props.listItem.anchor}}},r={name:"u-list-item",mixins:[uni.$u.mpMixin,uni.$u.mixin,o],data(){return{rect:{},index:0,show:!0,sys:uni.$u.sys()}},computed:{},inject:["uList"],watch:{"uList.innerScrollTop"(t){const e=this.uList.preLoadScreen,i=this.sys.windowHeight;t<=i*e?this.parent.updateOffsetFromChild(0):this.rect.top<=t-i*e&&this.parent.updateOffsetFromChild(this.rect.top)}},created(){this.parent={}},mounted(){this.init()},methods:{init(){this.updateParentData(),this.index=this.parent.children.indexOf(this),this.resize()},updateParentData(){this.getParentData("u-list")},resize(){this.queryRect(`u-list-item-${this.anchor}`).then((t=>{const e=this.parent.children[this.index-1];this.rect=t;const i=this.uList.preLoadScreen,n=this.sys.windowHeight;e&&(this.rect.top=e.rect.top+e.rect.height),t.top>=this.uList.innerScrollTop+(1+i)*n&&(this.show=!1)}))},queryRect(t){return new Promise((e=>{this.$uGetRect(`.${t}`).then((t=>{e(t)}))}))}}},u=r,p=(i(7995),i(1503)),c=(0,p.Z)(u,l,a,!1,null,"1727a615",null,!1,n,s),d=c.exports},4307:function(t,e,i){"use strict";var n;i.d(e,{Z:function(){return d}});var s,l=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-scroll-view",{staticClass:"u-list",style:[t.listStyle],attrs:{"scroll-into-view":t.scrollIntoView,"scroll-y":!0,"scroll-top":Number(t.scrollTop),"lower-threshold":Number(t.lowerThreshold),"upper-threshold":Number(t.upperThreshold),"show-scrollbar":t.showScrollbar,"enable-back-to-top":t.enableBackToTop,"scroll-with-animation":t.scrollWithAnimation},on:{scroll:function(e){arguments[0]=e=t.$handleEvent(e),t.onScroll.apply(void 0,arguments)},scrolltolower:function(e){arguments[0]=e=t.$handleEvent(e),t.scrolltolower.apply(void 0,arguments)},scrolltoupper:function(e){arguments[0]=e=t.$handleEvent(e),t.scrolltoupper.apply(void 0,arguments)}}},[i("v-uni-view",[t._t("default")],2)],1)},a=[],o={props:{showScrollbar:{type:Boolean,default:uni.$u.props.list.showScrollbar},lowerThreshold:{type:[String,Number],default:uni.$u.props.list.lowerThreshold},upperThreshold:{type:[String,Number],default:uni.$u.props.list.upperThreshold},scrollTop:{type:[String,Number],default:uni.$u.props.list.scrollTop},offsetAccuracy:{type:[String,Number],default:uni.$u.props.list.offsetAccuracy},enableFlex:{type:Boolean,default:uni.$u.props.list.enableFlex},pagingEnabled:{type:Boolean,default:uni.$u.props.list.pagingEnabled},scrollable:{type:Boolean,default:uni.$u.props.list.scrollable},scrollIntoView:{type:String,default:uni.$u.props.list.scrollIntoView},scrollWithAnimation:{type:Boolean,default:uni.$u.props.list.scrollWithAnimation},enableBackToTop:{type:Boolean,default:uni.$u.props.list.enableBackToTop},height:{type:[String,Number],default:uni.$u.props.list.height},width:{type:[String,Number],default:uni.$u.props.list.width},preLoadScreen:{type:[String,Number],default:uni.$u.props.list.preLoadScreen}}},r={name:"u-list",mixins:[uni.$u.mpMixin,uni.$u.mixin,o],watch:{scrollIntoView(t){this.scrollIntoViewById(t)}},data(){return{innerScrollTop:0,offset:0,sys:uni.$u.sys()}},computed:{listStyle(){const t={},e=uni.$u.addUnit;return 0!=this.width&&(t.width=e(this.width)),0!=this.height&&(t.height=e(this.height)),t.height||(t.height=e(this.sys.windowHeight,"px")),uni.$u.deepMerge(t,uni.$u.addStyle(this.customStyle))}},provide(){return{uList:this}},created(){this.refs=[],this.children=[],this.anchors=[]},mounted(){},methods:{updateOffsetFromChild(t){this.offset=t},onScroll(t){let e=0;e=t.detail.scrollTop,this.innerScrollTop=e,this.$emit("scroll",Math.abs(e))},scrollIntoViewById(t){},scrolltolower(t){uni.$u.sleep(30).then((()=>{this.$emit("scrolltolower")}))},scrolltoupper(t){uni.$u.sleep(30).then((()=>{this.$emit("scrolltoupper"),this.offset=0}))}}},u=r,p=(i(928),i(1503)),c=(0,p.Z)(u,l,a,!1,null,"390d4fd5",null,!1,n,s),d=c.exports},416:function(t,e,i){"use strict";i.r(e),i.d(e,{default:function(){return c}});var n,s={uList:i(4307).Z,uListItem:i(8556).Z,uCell:i(7981).Z},l=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"page"},[i("v-uni-view",{staticClass:"list"},[i("u-list",{attrs:{height:t.listHeight},on:{scrolltolower:function(e){arguments[0]=e=t.$handleEvent(e),t.reachBottom.apply(void 0,arguments)}}},t._l(t.list,(function(e){return i("u-list-item",{key:e.id},[i("u-cell",{attrs:{size:"large",url:"/pages/record/detail?id="+e.id}},[i("v-uni-view",{staticClass:"title",attrs:{slot:"title"},slot:"title"},[i("v-uni-view",{staticClass:"list-item-title"},[t._v("患者: "+t._s(e.patient?e.patient.name:""))])],1),i("v-uni-view",{staticClass:"label",attrs:{slot:"label"},slot:"label"},[t._v("时间: "+t._s(e.treat_at))])],1)],1)})),1)],1)],1)},a=[],o=(i(6228),{data:function(){return{patient_id:"",patient:{},page:1,perPage:20,list:[],option:{id:"",show:!1,list:[{name:"详细",color:"#4cd964",action:"detail"},{name:"修改",color:"#007aff",action:"edit"},{name:"删除",color:"#dd524d",action:"delete"}],title:""},swipeOption:[{text:"删除",style:{backgroundColor:"#dd524d"}}],listHeight:0}},onLoad:function(t){var e=this;this.patient_id=t.patient,uni.getSystemInfo({success:function(t){e.listHeight=t.safeArea.height-20}}),this.loadData(!0)},onPullDownRefresh:function(){this.loadData(!0)},methods:{loadData:function(t){var e=this;t&&(this.list=[],this.page=1),uni.showLoading();var i={page:this.page,perPage:this.perPage,patient_id:this.patient_id};this.$ajax.get("/api/client/record",{params:i}).then((function(t){uni.stopPullDownRefresh(),0==t.status&&(e.list=e.list.concat(t.data.items),e.total=t.data.total)})).catch((function(t){uni.stopPullDownRefresh()}))},reachBottom:function(){this.list.length