(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/packageA/user/sign_in"],{331:function(n,t,e){"use strict";(function(n,t){var o=e(4);e(26);o(e(25));var r=o(e(332));n.__webpack_require_UNI_MP_PLUGIN__=e,t(r.default)}).call(this,e(1)["default"],e(2)["createPage"])},332:function(n,t,e){"use strict";e.r(t);var o=e(333),r=e(335);for(var a in r)["default"].indexOf(a)<0&&function(n){e.d(t,n,(function(){return r[n]}))}(a);var i,c=e(42),u=Object(c["default"])(r["default"],o["render"],o["staticRenderFns"],!1,null,"7cc20b4e",null,!1,o["components"],i);u.options.__file="pages/packageA/user/sign_in.vue",t["default"]=u.exports},333:function(n,t,e){"use strict";e.r(t);var o=e(334);e.d(t,"render",(function(){return o["render"]})),e.d(t,"staticRenderFns",(function(){return o["staticRenderFns"]})),e.d(t,"recyclableRender",(function(){return o["recyclableRender"]})),e.d(t,"components",(function(){return o["components"]}))},334:function(n,t,e){"use strict";var o;e.r(t),e.d(t,"render",(function(){return r})),e.d(t,"staticRenderFns",(function(){return i})),e.d(t,"recyclableRender",(function(){return a})),e.d(t,"components",(function(){return o}));try{o={tnNavBar:function(){return Promise.all([e.e("common/vendor"),e.e("tuniao-ui/components/tn-nav-bar/tn-nav-bar")]).then(e.bind(null,394))},tnTabs:function(){return Promise.all([e.e("common/vendor"),e.e("tuniao-ui/components/tn-tabs/tn-tabs")]).then(e.bind(null,416))},uniCalendar:function(){return Promise.all([e.e("common/vendor"),e.e("uni_modules/uni-calendar/components/uni-calendar/uni-calendar")]).then(e.bind(null,600))},tnButton:function(){return Promise.all([e.e("common/vendor"),e.e("tuniao-ui/components/tn-button/tn-button")]).then(e.bind(null,408))},tnToast:function(){return e.e("tuniao-ui/components/tn-toast/tn-toast").then(e.bind(null,613))}}}catch(c){if(-1===c.message.indexOf("Cannot find module")||-1===c.message.indexOf(".vue"))throw c;console.error(c.message),console.error("1. 排查组件名称拼写是否正确"),console.error("2. 排查组件是否符合 easycom 规范，文档：https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"),console.error("3. 若组件不符合 easycom 规范，需手动引入，并在 components 中注册该组件")}var r=function(){var n=this,t=n.$createElement;n._self._c},a=!1,i=[];r._withStripped=!0},335:function(n,t,e){"use strict";e.r(t);var o=e(336),r=e.n(o);for(var a in o)["default"].indexOf(a)<0&&function(n){e.d(t,n,(function(){return o[n]}))}(a);t["default"]=r.a},336:function(n,t,e){"use strict";(function(n){var o=e(4);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=o(e(13)),a=e(33),i=(o(e(30)),{data:function(){return{selected:[],startDate:"",integral:[]}},onLoad:function(){this.startDate=this.getDate().fullDate,this.getSignInList(),this.getSignInRecords()},methods:{getSignInRecords:function(){var t=this,e=n.getStorageSync("uid");(0,a.signInRecords)({member_id:e}).then((function(n){console.log(n),t.integral=n.data})).catch((function(t){n.showToast({title:t,icon:"none",duration:2e3})}))},getSignInList:function(){var t=this,e=n.getStorageSync("uid");(0,a.pointsSignMonth)({member_id:e}).then((function(n){console.log(n);var e=n.data,o=Object.keys(e).map((function(n){return{date:n,info:e[n]?"已打卡":"未打卡",is:e[n]?"1":"0"}}));t.selected=o})).catch((function(t){n.showToast({title:t,icon:"none",duration:2e3})}))},signIn:function(){var t=this,e=n.getStorageSync("uid");(0,a.pointsSignIn)({member_id:e}).then((function(n){console.log(n),"error"==n.status?t.$refs.toast.show({content:n.message,duration:2e3}):t.$refs.toast.show({content:n.msg,duration:2e3}),t.getSignInList(),t.getSignInRecords()})).catch((function(t){n.showToast({title:t,icon:"none",duration:2e3})}))},getDate:function(n){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;n||(n=new Date),"object"!==(0,r.default)(n)&&(n=n.replace(/-/g,"/"));var e=new Date(n);e.setDate(e.getDate()+t);var o=e.getFullYear(),a=e.getMonth()+1<10?"0"+(e.getMonth()+1):e.getMonth()+1,i=e.getDate()<10?"0"+e.getDate():e.getDate();return{fullDate:o+"-"+a+"-"+i,year:o,month:a,date:i,day:e.getDay()}},tn:function(t){n.navigateTo({url:t})},goBack:function(){getCurrentPages().length>1?n.navigateBack():n.redirectTo({url:"/pages/index/index"})}}});t.default=i}).call(this,e(2)["default"])}},[[331,"common/runtime","common/vendor"]]]);
//# sourceMappingURL=../../../../.sourcemap/mp-weixin/pages/packageA/user/sign_in.js.map