(global["webpackJsonp"] = global["webpackJsonp"] || []).push([ ["pages/index/index"], { "0b56": function(t, e, n) { "use strict"; (function(t, a) { var i = n("4ea4"); Object.defineProperty(e, "__esModule", { value: !0 }), e.default = void 0; var s, o = i(n("9523")), r = n("0c59"), u = n("fef2"), c = n("db68"), d = n("eec6"), f = n("76dd"), h = n("dc92"), l = n("f785"), m = { mixins: [u.pageJumps, u.statisticalPageJumps], components: { uniTabbar: function() { n.e("components/tabbar/tabbar").then(function() { return resolve(n("c4bc")) }.bind(null, n)).catch(n.oe) }, screenPop: function() { n.e("pages/index/screen").then(function() { return resolve(n("5aad")) }.bind(null, n)).catch(n.oe) } }, data: function() { return { topHeight: 0, paddingHeight: 0, searchWidth: 470, BASE_IMG_URL: r.BASE_IMG_URL, tipNumber: null, typeList: ["本人及下属", "仅本人", "仅下属"], typeIndex: 0, dataTime: "", startTime: "", endTime: "", text: "本月", info: {}, target_money: 0, complete_money: 0, percentage: 0, shows: !1, approvelNum: 0, oneChart: {}, chartData: {}, achieveArr: [{ id: 1, name: "合同" }, { id: 2, name: "回款" }], achieveIndex: 0 } }, onLaunch: function() {}, onLoad: function() { var e = this; t.getSystemInfo({ success: function(t) { var n, i = a.getMenuButtonBoundingClientRect(); n = i.height + 2 * (i.top - t.statusBarHeight) + t.statusBarHeight + 5, e.topHeight = n, e.paddingHeight = i.top, e.searchWidth = 470 } }), this.getTime() }, onShow: function() { this.roleType = t.getStorageSync("roleType"), this.rules = t.getStorageSync("rules"), this.dataTime = (0, d.getNowData)().substr(0, 7), t.getStorageSync("isAuth") ? this.getTip() : this.tipNumber = 0 }, methods: (s = { changeAchieve: function(t) { this.achieveIndex = t.detail.value, this.getTarget() }, getTime: function() { var t = this; (0, h.netTime)({ times: "thismonth" }).then((function(e) { e = e.data, t.startTime = e.times[0], t.endTime = e.times[1] })) }, getOpenid: function() { (0, l.netMapKey)().then((function(e) { t.setStorageSync("mapKey", e.data.map_key), t.setStorageSync("appid", e.data.appid) })) }, getTip: function() { var e = this; (0, c.netAgentList)().then((function(n) { t.setStorageSync("token", n.data.userinfo.token), t.setStorageSync("roleType", n.data.userinfo.role_type), t.setStorageSync("rules", n.data.userinfo.rules), e.tipNumber = n.data.total, e.approvelNum = n.data.examine.count, e.getData(), e.getTarget(), e.getOpenid() })) }, getData: function() { var t = this, e = { times: this.startTime + "," + this.endTime, type: this.typeIndex }; (0, f.netGetBriefdata)(e).then((function(e) { t.info = e.data })) }, getTarget: function() { var t = this, e = { times: this.startTime + "," + this.endTime, type: this.typeIndex, status: this.achieveArr[this.achieveIndex].id }; (0, h.netGetData)(e).then((function(e) { t.complete_money = e.data.contract_moneys, t.target_money = e.data.achievement; var n = e.data.ratio >= 100 ? 100 : e.data.ratio, a = { series: [{ name: "已完成", color: "#2979ff", data: n }] }, i = { title: { name: e.data.ratio + "%", fontSize: 18, color: "#2979ff" }, subtitle: { name: "完成率", fontSize: 15, color: "#666666" }, extra: { arcbar: { type: "circle", width: 12, backgroundColor: "#E9E9E9", startAngle: 1.5, endAngle: .25, gap: 2 } } }; t.oneChart = i, t.chartData = a })) }, changeType: function(t) { this.typeIndex = t.detail.value, this.getData(), this.getTarget() }, changeDataTime: function(t) { this.$refs.screenChild.init() }, sureTime: function(t) { console.log(t, "===="), t.text && t.start_time && t.end_time && (this.text = t.text, this.startTime = t.start_time, this.endTime = t.end_time, this.getData(), this.getTarget()) }, toProductList: function() { t.navigateTo({ url: "/pagesA/product/index" }) }, toPayment: function() { t.navigateTo({ url: "/pagesA/payment/index" }) }, toCostList: function() { t.navigateTo({ url: "/pagesA/cost/index" }) }, toBillList: function() { t.navigateTo({ url: "/pagesA/bills/index" }) } }, (0, o.default)(s, "toPayment", (function() { t.navigateTo({ url: "/pagesA/payment/index" }) })), (0, o.default)(s, "toPayPlan", (function() { t.navigateTo({ url: "/pagesA/payplan/index" }) })), (0, o.default)(s, "achieveStatis", (function() { t.navigateTo({ url: "/pagesA/crm/statisticalFrom/achieveStatis" }) })), (0, o.default)(s, "toClock", (function() { t.navigateTo({ url: "/pagesA/punchclock/index" }) })), (0, o.default)(s, "toBusiness", (function() { t.navigateTo({ url: "/pagesA/business/index" }) })), (0, o.default)(s, "toCheckBusiness", (function() { t.navigateTo({ url: "/pagesA/business/index?type=" + this.typeIndex + "&stime=" + this.startTime + "&etime=" + this.endTime }) })), (0, o.default)(s, "toCus", (function(e) { t.navigateTo({ url: "/pagesA/crm/customerManagement/customerManagement?cusStatus=" + e + "&stime=" + this.startTime + "&etime=" + this.endTime }) })), (0, o.default)(s, "toBus", (function(e) { t.navigateTo({ url: "/pagesA/business/index?busStatus=" + e + "&stime=" + this.startTime + "&etime=" + this.endTime }) })), s) }; e.default = m }).call(this, n("543d")["default"], n("bc2e")["default"]) }, "52bc": function(t, e, n) {}, "84f4": function(t, e, n) { "use strict"; var a = n("52bc"), i = n.n(a); i.a }, "88d5": function(t, e, n) { "use strict"; n.d(e, "b", (function() { return i })), n.d(e, "c", (function() { return s })), n.d(e, "a", (function() { return a })); var a = { qiunDataCharts: function() { return Promise.all([n.e("common/vendor"), n.e("uni_modules/qiun-data-charts/components/qiun-data-charts/qiun-data-charts")]).then(n.bind(null, "2e67")) } }, i = function() { var t = this.$createElement; this._self._c }, s = [] }, c365: function(t, e, n) { "use strict"; n.r(e); var a = n("0b56"), i = n.n(a); for (var s in a)["default"].indexOf(s) < 0 && function(t) { n.d(e, t, (function() { return a[t] })) }(s); e["default"] = i.a }, c489: function(t, e, n) { "use strict"; n.r(e); var a = n("88d5"), i = n("c365"); for (var s in i)["default"].indexOf(s) < 0 && function(t) { n.d(e, t, (function() { return i[t] })) }(s); n("84f4"); var o = n("f0c5"), r = Object(o["a"])(i["default"], a["b"], a["c"], !1, null, "0cd52b3f", null, !1, a["a"], void 0); e["default"] = r.exports }, e177: function(t, e, n) { "use strict"; (function(t, e) { var a = n("4ea4"); n("8886"); a(n("66fd")); var i = a(n("c489")); t.__webpack_require_UNI_MP_PLUGIN__ = n, e(i.default) }).call(this, n("bc2e")["default"], n("543d")["createPage"]) } }, [ ["e177", "common/runtime", "common/vendor"] ] ]);