1 |
- {"version":3,"sources":["uni-app:///main.js","webpack:///G:/item/appBase/pages/index/sign.vue?cff6","webpack:///G:/item/appBase/pages/index/sign.vue?5553","webpack:///G:/item/appBase/pages/index/sign.vue?5437","webpack:///G:/item/appBase/pages/index/sign.vue?ee6c","uni-app:///pages/index/sign.vue","webpack:///G:/item/appBase/pages/index/sign.vue?2ca6","webpack:///G:/item/appBase/pages/index/sign.vue?eb6b"],"names":["createPage","Page"],"mappings":";;;;;;;;;;kDAAA;AACA;AACA,0F;AACAA,UAAU,CAACC,aAAD,CAAV,C;;;;;;;;;;;;;ACHA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAiH;AACjH;AACwD;AACL;AACc;;;AAGjE;AAC2K;AAC3K,gBAAgB,oLAAU;AAC1B,EAAE,0EAAM;AACR,EAAE,+EAAM;AACR,EAAE,wFAAe;AACjB;AACA;AACA;AACA;AACA;AACA,EAAE,mFAAU;AACZ;AACA;;AAEA;AACe,gF;;;;;;;;;;;;ACvBf;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;;;;;;;;;;;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;ACbA;AAAA;AAAA;AAAA;AAA4nB,CAAgB,ipBAAG,EAAC,C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACsBhpB,6E;AACA;AACA;AACA,sBADA,EADA;;AAIA,MAJA,kBAIA;AACA;AACA,eADA,EACA;AACA,cAFA,EAEA;AACA,aAHA,EAGA;AACA,kBAJA,EAIA;AACA,kBALA,EAKA;AACA,gBANA,EAMA;AACA,qBAPA,EAOA;AACA,qBARA;;AAUA,GAfA;AAgBA,QAhBA,oBAgBA;AACA;AACA;AACA;AACA,GApBA;AAqBA;AACA;AACA,WAFA,mBAEA,OAFA,EAEA;AACA;AACA,qCAFA,CAEA;AACA,uCAHA,CAGA;AACA,gCAJA,CAIA;AACA,KAPA;AAQA;AACA,YATA,sBASA;AACA;AACA,wCADA,CACA;AACA,0CAFA,CAEA;AACA,+CAHA,CAGA;AACA,OAJA;AAKA,KAfA;AAgBA;AACA,YAjBA,sBAiBA;AACA;AACA,UADA,CACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uBADA;AAEA,wBAFA;AAGA,yBAHA;;AAKA,OAZA;AAaA,WAbA,CAaA;AACA;AACA,OAfA;AAgBA,KAlCA;AAmCA;AACA,YApCA,sBAoCA;AACA;AACA,6BAFA,CAEA;AACA,wBAHA,CAGA;AACA,mBAJA,CAIA;AACA;AACA,eADA;AAEA,iBAFA;AAGA,UAHA,CAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SARA;AASA;AACA;AACA;AACA;AACA;AACA,OAlBA;AAmBA,KA5DA,EArBA,E;;;;;;;;;;;;;ACvBA;AAAA;AAAA;AAAA;AAAspC,CAAgB,unCAAG,EAAC,C;;;;;;;;;;;ACA1qC;AACA,OAAO,KAAU,EAAE,kBAKd","file":"pages/index/sign.js","sourcesContent":["import 'uni-pages';\nimport Vue from 'vue'\nimport Page from './pages/index/sign.vue'\ncreatePage(Page)","import { render, staticRenderFns, recyclableRender, components } from \"./sign.vue?vue&type=template&id=442ff513&\"\nvar renderjs\nimport script from \"./sign.vue?vue&type=script&lang=js&\"\nexport * from \"./sign.vue?vue&type=script&lang=js&\"\nimport style0 from \"./sign.vue?vue&type=style&index=0&lang=scss&\"\n\n\n/* normalize component */\nimport normalizer from \"!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\runtime\\\\componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null,\n false,\n components,\n renderjs\n)\n\ncomponent.options.__file = \"pages/index/sign.vue\"\nexport default component.exports","export * from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\templateLoader.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--16-0!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\template.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-uni-app-loader\\\\page-meta.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./sign.vue?vue&type=template&id=442ff513&\"","var components\nvar render = function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n if (!_vm._isMounted) {\n _vm.e0 = function($event) {\n _vm.signTrue ? \"\" : _vm.integral()\n }\n }\n}\nvar recyclableRender = false\nvar staticRenderFns = []\nrender._withStripped = true\n\nexport { render, staticRenderFns, recyclableRender, components }","import mod from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\babel-loader\\\\lib\\\\index.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--12-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\script.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./sign.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\babel-loader\\\\lib\\\\index.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--12-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\script.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./sign.vue?vue&type=script&lang=js&\"","<template>\r\n\t<view>\r\n\t\t<view class=\"title-box\">\r\n\t\t\t<view class=\" title-conetnt position-relative\">\r\n\t\t\t\t<view class=\"title-img\"><image src=\"/static/img/img08.png\" mode=\"aspectFit\"></image></view>\r\n\t\t\t\t<view class=\"title-content-box\">\r\n\t\t\t\t\t<view class=\"title-text\">已连续签到</view>\r\n\t\t\t\t\t<view class=\"title-day-text\">\r\n\t\t\t\t\t\t<text class=\"title-day\">{{actionDay}}</text>\r\n\t\t\t\t\t\t<text>天</text>\r\n\t\t\t\t\t</view>\r\n\t\t\t\t\t<view class=\"title-button\" :class=\"{'signAction':signTrue}\" @click=\"signTrue?'':integral()\">{{signTrue?'已签到':'立即签到'}}</view>\r\n\t\t\t\t</view>\r\n\t\t\t</view>\r\n\t\t\t<view class=\"title-tip\"><text>共获得{{sum_integral}}积分,总签到{{allSign}}天</text></view>\r\n\t\t</view>\r\n\t\t<calendar class=\"sign-date-box\" :checks=\"signList\" checksClass=\"\" :checkTextShow=\"true\" checksIcon=\"/static/img/img07.png\"></calendar>\r\n\t</view>\r\n</template>\r\n\r\n<script>\r\nimport calendar from '../../components/ss-calendar/ss-calendar.vue';\r\nimport { signList, integral,signUser } from '@/api/functionalUnit.js';\r\nexport default {\r\n\tcomponents: {\r\n\t\tcalendar\r\n\t},\r\n\tdata() {\r\n\t\treturn {\r\n\t\t\tmoney: '', //保存当前月份\r\n\t\t\tyear: '', //保存当前年份\r\n\t\t\tday: '', //保存当前日期\r\n\t\t\tsignList: [] ,//签到日子列表\r\n\t\t\tactionDay:0,//连续签到天数\r\n\t\t\tallSign:0,//累计签到\r\n\t\t\tsum_integral:0,//累计获得积分\r\n\t\t\tsignTrue:false,\r\n\t\t};\r\n\t},\r\n\tonLoad() {\r\n\t\tthis.signUser();\r\n\t\tthis.getData();\r\n\t\tthis.loadList();\r\n\t},\r\n\tmethods: {\r\n\t\t// 获取当前时间\r\n\t\tgetData(current) {\r\n\t\t\tconst date = current ? new Date(current) : new Date();\r\n\t\t\tthis.year = date.getFullYear();//保存当前年份\r\n\t\t\tthis.month = date.getMonth() + 1;//保存当前月份\r\n\t\t\tthis.day = date.getDate();//保存当前日期\r\n\t\t},\r\n\t\t//获取签到用户信息\r\n\t\tsignUser(){\r\n\t\t\tsignUser({all:1}).then(({data}) => {\r\n\t\t\t\tthis.actionDay = data.sign_num;//连续签到天数\r\n\t\t\t\tthis.allSign = data.sum_sgin_day;//累计签到天数\r\n\t\t\t\tthis.sum_integral = data.sum_integral;//累计总积分\r\n\t\t\t})\r\n\t\t},\r\n\t\t// 签到\r\n\t\tintegral() {\r\n\t\t\tintegral({})\r\n\t\t\t\t.then(e => {\r\n\t\t\t\t\t// 改为已签到\r\n\t\t\t\t\tthis.signTrue = true;\r\n\t\t\t\t\tthis.actionDay++;\r\n\t\t\t\t\t// 保存签到成功\r\n\t\t\t\t\tthis.signList.push(this.day);\r\n\t\t\t\t\tuni.showToast({\r\n\t\t\t\t\t\ttitle: '签到成功',\r\n\t\t\t\t\t\tduration: 2000,\r\n\t\t\t\t\t\tposition: 'top'\r\n\t\t\t\t\t});\r\n\t\t\t\t})\r\n\t\t\t\t.catch(e => {\r\n\t\t\t\t\tconsole.log(e);\r\n\t\t\t\t});\r\n\t\t},\r\n\t\t// 获取签到列表\r\n\t\tloadList() {\r\n\t\t\tlet obj = this;\r\n\t\t\tlet present = this.day; //保存当前天数用于后续计算\r\n\t\t\tlet actionDay = 0; //用于计算活跃天数\r\n\t\t\tlet arr = []; //保存返回数组;\r\n\t\t\tsignList({\r\n\t\t\t\tpage: 1,\r\n\t\t\t\tlimit: 31\r\n\t\t\t}).then(e => {\r\n\t\t\t\tarr = e.data.map((e, ind) => {\r\n\t\t\t\t\tlet time = e.add_time.split('-');\r\n\t\t\t\t\tlet day = parseInt(time[2].replace(/^0/i, ''));\r\n\t\t\t\t\tlet year = time[0];\r\n\t\t\t\t\tlet month = +time[1];\r\n\t\t\t\t\tif (obj.year == year && obj.month == month) {\r\n\t\t\t\t\t\treturn day;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t\t\tthis.signList = arr;\r\n\t\t\t\t// 判断今天是否已经签到\r\n\t\t\t\tif(arr[0]==this.day){\r\n\t\t\t\t\tthis.signTrue = true;\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n};\r\n</script>\r\n\r\n<style lang=\"scss\">\r\npage {\r\n\tbackground: $page-color-base;\r\n}\r\n.sign-date-box {\r\n\tmargin: 25rpx;\r\n\tborder-radius: 15rpx;\r\n\tmargin-top: -70rpx;\r\n}\r\n.title-box {\r\n\tbackground-color: $base-color;\r\n\tpadding-top: 120rpx;\r\n\tcolor: #ffffff;\r\n\theight: 590rpx;\r\n\t.title-conetnt {\r\n\t\theight: 350rpx;\r\n\t\twidth: 350rpx;\r\n\t\tmargin: 0 auto;\r\n\t\ttext-align: center;\r\n\t\t.title-img {\r\n\t\t\tposition: absolute;\r\n\t\t\ttop: 0;\r\n\t\t\tleft: 0;\r\n\t\t\theight: 100%;\r\n\t\t\twidth: 100%;\r\n\t\t\timage {\r\n\t\t\t\theight: 100%;\r\n\t\t\t\twidth: 100%;\r\n\t\t\t}\r\n\t\t}\r\n\t\t.title-content-box {\r\n\t\t\tposition: absolute;\r\n\t\t\twidth: 100%;\r\n\t\t\t.title-day-text {\r\n\t\t\t\tpadding: 20rpx;\r\n\t\t\t\tfont-size: $font-base - 2rpx;\r\n\t\t\t\t.title-day {\r\n\t\t\t\t\tfont-size: 60rpx;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t.title-text {\r\n\t\t\t\tfont-size: 26rpx;\r\n\t\t\t\tpadding-top: 100rpx;\r\n\t\t\t}\r\n\t\t\t.title-button {\r\n\t\t\t\tbackground-color: #fe7e51;\r\n\t\t\t\tborder-radius: 99rpx;\r\n\t\t\t\twidth: 200rpx;\r\n\t\t\t\theight: 64rpx;\r\n\t\t\t\tmargin: 0 auto;\r\n\t\t\t\tline-height: 64rpx;\r\n\t\t\t\ttext-align: center;\r\n\t\t\t\tfont-size: $font-base;\r\n\t\t\t\t&.signAction{\r\n\t\t\t\t\tbackground-color: $font-color-light;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}\r\n.title-tip {\r\n\tcolor: #ffffff;\r\n\tfont-size: $font-base - 2rpx;\r\n\tpadding-top: 20rpx;\r\n\ttext-align: center;\r\n\tmargin-top: -40rpx;\r\n}\r\n</style>\r\n","import mod from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\mini-css-extract-plugin\\\\dist\\\\loader.js??ref--8-oneOf-1-0!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\css-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\stylePostLoader.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-2!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\postcss-loader\\\\src\\\\index.js??ref--8-oneOf-1-3!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\sass-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-4!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-5!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./sign.vue?vue&type=style&index=0&lang=scss&\"; export default mod; export * from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\mini-css-extract-plugin\\\\dist\\\\loader.js??ref--8-oneOf-1-0!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\css-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\stylePostLoader.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-2!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\postcss-loader\\\\src\\\\index.js??ref--8-oneOf-1-3!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\sass-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-4!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-5!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./sign.vue?vue&type=style&index=0&lang=scss&\"","// extracted by mini-css-extract-plugin\n if(module.hot) {\n // 1618025084122\n var cssReload = require(\"D:/work/HBuilderX/plugins/uniapp-cli/node_modules/mini-css-extract-plugin/dist/hmr/hotModuleReplacement.js\")(module.id, {\"hmr\":true,\"publicPath\":\"../../\",\"locals\":false});\n module.hot.dispose(cssReload);\n module.hot.accept(undefined, cssReload);\n }\n "],"sourceRoot":""}
|