index.js 6.8 KB

12
  1. (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/policy/index"],{50:function(e,t,n){"use strict";(function(e){n(5);r(n(4));var t=r(n(51));function r(e){return e&&e.__esModule?e:{default:e}}wx.__webpack_require_UNI_MP_PLUGIN__=n,e(t.default)}).call(this,n(1)["createPage"])},51:function(e,t,n){"use strict";n.r(t);var r=n(52),i=n(54);for(var o in i)"default"!==o&&function(e){n.d(t,e,(function(){return i[e]}))}(o);n(56);var a,u=n(11),c=Object(u["default"])(i["default"],r["render"],r["staticRenderFns"],!1,null,null,null,!1,r["components"],a);c.options.__file="pages/policy/index.vue",t["default"]=c.exports},52:function(e,t,n){"use strict";n.r(t);var r=n(53);n.d(t,"render",(function(){return r["render"]})),n.d(t,"staticRenderFns",(function(){return r["staticRenderFns"]})),n.d(t,"recyclableRender",(function(){return r["recyclableRender"]})),n.d(t,"components",(function(){return r["components"]}))},53:function(e,t,n){"use strict";var r;n.r(t),n.d(t,"render",(function(){return i})),n.d(t,"staticRenderFns",(function(){return a})),n.d(t,"recyclableRender",(function(){return o})),n.d(t,"components",(function(){return r}));try{r={uniEasyinput:function(){return n.e("uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput").then(n.bind(null,167))},uniList:function(){return n.e("uni_modules/uni-list/components/uni-list/uni-list").then(n.bind(null,131))},uniListItem:function(){return n.e("uni_modules/uni-list/components/uni-list-item/uni-list-item").then(n.bind(null,138))},uniLoadMore:function(){return Promise.all([n.e("common/vendor"),n.e("uni_modules/uni-load-more/components/uni-load-more/uni-load-more")]).then(n.bind(null,156))}}}catch(u){if(-1===u.message.indexOf("Cannot find module")||-1===u.message.indexOf(".vue"))throw u;console.error(u.message),console.error("1. 排查组件名称拼写是否正确"),console.error("2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"),console.error("3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件")}var i=function(){var e=this,t=e.$createElement;e._self._c},o=!1,a=[];i._withStripped=!0},54:function(e,t,n){"use strict";n.r(t);var r=n(55),i=n.n(r);for(var o in r)"default"!==o&&function(e){n.d(t,e,(function(){return r[e]}))}(o);t["default"]=i.a},55:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=o(n(18)),i=o(n(47));function o(e){return e&&e.__esModule?e:{default:e}}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){c(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e){return d(e)||p(e)||f(e)||l()}function l(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function f(e,t){if(e){if("string"===typeof e)return m(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?m(e,t):void 0}}function p(e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}function d(e){if(Array.isArray(e))return m(e)}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function y(e,t,n,r,i,o,a){try{var u=e[o](a),c=u.value}catch(s){return void n(s)}u.done?t(c):Promise.resolve(c).then(r,i)}function h(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var o=e.apply(t,n);function a(e){y(o,r,i,a,u,"next",e)}function u(e){y(o,r,i,a,u,"throw",e)}a(void 0)}))}}var b={data:function(){return{searchVal:"",istab:"all",page:0,size:12,policyItem:null,more:"more",btnList:[{typeName:"全部",typeId:"all"}],dataList:[],typeName:""}},onShow:function(){this.init()},mounted:function(){var e=this;return h(r.default.mark((function t(){var n,o;return r.default.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,i.default.getTypeList({alias:"policy"});case 2:o=t.sent,(n=e.btnList).push.apply(n,s(o.data));case 4:case"end":return t.stop()}}),t)})))()},methods:{init:function(){var t=this;return h(r.default.mark((function n(){return r.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(t.reset(),t.policyItem=e.getStorageSync("policyItem"),!t.policyItem||null===t.policyItem&&""===t.policyItem){n.next=5;break}return t.tabsBtn(u(u({},t.btnList[0]),{},{tagName:t.policyItem})),n.abrupt("return");case 5:t.tabsBtn(u({},t.btnList[0]));case 6:case"end":return n.stop()}}),n)})))()},listItemBtn:function(t){e.navigateTo({url:"/pages/details/index?id=".concat(t.id)})},tabsBtn:function(e){var t=this;return h(r.default.mark((function n(){var i,o,a;return r.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return t.reset(),t.istab=e.typeId,a={},a.typeName=null!==(i=e.alias)&&void 0!==i?i:"policy",e.tagName&&(a.tagName=e.tagName),""!==t.searchVal&&(a.title=t.searchVal),t.typeName=null!==(o=e.alias)&&void 0!==o?o:"policy",n.next=9,t.getPolicyList(u({},a));case 9:case"end":return n.stop()}}),n)})))()},getPolicyList:function(e){var t=this;return h(r.default.mark((function n(){var o,a;return r.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return t.page+=1,t.more="loading",n.next=4,i.default.getArticleList(u({pageNum:t.page,pageSize:t.size},e));case 4:a=n.sent,(o=t.dataList).push.apply(o,s(a.rows)),t.more=t.page>=Math.ceil(a.total/t.size)?"noMore":"more";case 7:case"end":return n.stop()}}),n)})))()},searchBtn:function(){this.searchVal&&""!=this.searchVal&&(this.reset(),this.getPolicyList({title:this.searchVal,typeName:"policy"}))},reset:function(){this.page=0,this.dataList=[],this.istab="all",this.policyItem=null}},onReachBottom:function(){if("noMore"!=this.more){this.more="more";var e={};""!==this.searchVal&&(e.title=this.searchVal),null!==this.policyItem&&""!==this.policyItem&&(e.tagName=this.policyItem),e.typeName=this.typeName,this.getPolicyList(u({},e))}}};t.default=b}).call(this,n(1)["default"])},56:function(e,t,n){"use strict";n.r(t);var r=n(57),i=n.n(r);for(var o in r)"default"!==o&&function(e){n.d(t,e,(function(){return r[e]}))}(o);t["default"]=i.a},57:function(e,t,n){}},[[50,"common/runtime","common/vendor"]]]);
  2. //# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/policy/index.js.map