1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- (function (c) {
- config.init();
- calendar.getToday();
- c(".hzApp-list-calendar-master h2.title").html(calendar.Y + "年" + (calendar.M + 1) + "月" + calendar.D + "日");
- c(".hzApp-list-calendar-master .arrowT").bind("tap", function () {
- if (c(this).hasClass("right")) {
- if (c(this).hasClass("month")) {
- calendar.M++
- } else {
- calendar.D++
- }
- } else {
- if (c(this).hasClass("left")) {
- if (c(this).hasClass("month")) {
- calendar.M--
- } else {
- calendar.D--
- }
- }
- }
- if (calendar.M > 11 || calendar.M < 0) {
- calendar.M = 0
- }
- if (calendar.D > calendar.getDaysInMonth(calendar.Y, calendar.M)) {
- calendar.D = 1
- }
- if (calendar.D < 1) {
- calendar.D = calendar.getDaysInMonth(calendar.Y, calendar.M)
- }
- c(".hzApp-list-calendar-master h2.title").html(calendar.Y + "年" + (calendar.M + 1) + "月" + calendar.D + "日");
- b.doing()
- });
- c("#ListCycle").bind("swipeRight", function () {
- c(".hzApp-list-calendar-master .arrowT.day.left").trigger("tap")
- });
- c("#ListCycle").bind("swipeLeft", function () {
- c(".hzApp-list-calendar-master .arrowT.day.right").trigger("tap")
- });
- c(".menu_drug_add").on("tap", function () {
- window.location = "drug_q_plan_add.html?id=" + JSON.parse(c("#familyList .selected a").attr("data")).id
- });
- var d = "";
- c("#ListCycle li a").on("tap", function () {
- var e = {night: "凌晨", morning: "上午", afternoon: "下午", evening: "晚上"};
- d = "服用清单 - " + calendar.Y + "年" + (calendar.M + 1) + "月" + calendar.D + "日 " + e[c(this).parent().attr("id")];
- icoNav.popWinLayer(c(this).attr("vhref"), d)
- });
- c(".hzApp-list-timeline li a").on("tap", function () {
- if (c(this).attr("vhref").length > 0) {
- d = c(this).find("h4").text();
- icoNav.popWinLayer(c(this).attr("vhref"), d)
- }
- });
- var b = {
- doing: function () {
- planPerDay.getAllPlan(calendar.Y + "-" + (calendar.M + 1) + "-" + calendar.D, JSON.parse(c("#familyList .selected a").attr("data")).id)
- }, init: function () {
- fn_call = {
- doing: function () {
- b.doing()
- }
- };
- hzAPI.getData(window.apiUrl+"?c=Index&a=customerFamilyList", {idCk: Fx.getUrlParam("id")}, "#familyList", 0, true, 4, null, null, fn_call)
- }
- };
- window.reload = b;
- b.init();
- var a = {
- idx: [1, 6, 7, 8],
- // count: 4,
- count: 2,
- current: 7};
- icoNavFx.doing(c("#nav_bottom"), a)
- })(Zepto);
|