作者 sgj

合并分支 'lihongjuan' 到 'master'

Lihongjuan

健康数据的血糖血压

查看合并请求 !3
body, html {
height: 100%;
-webkit-tap-highlight-color: transparent;
}
.demos-title {
text-align: center;
font-size: 34px;
color: #3cc51f;
font-weight: 400;
margin: 0 15%;
}
.demos-sub-title {
text-align: center;
color: #888;
font-size: 14px;
}
.demos-header {
padding: 35px 0;
}
.demos-content-padded {
padding: 15px;
}
.demos-second-title {
text-align: center;
font-size: 24px;
color: #3cc51f;
font-weight: 400;
margin: 0 15%;
}
footer {
text-align: center;
font-size: 14px;
padding: 20px;
}
footer a {
color: #999;
text-decoration: none;
}
... ...
html,body{min-height:100%;}
html{-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;}
body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin: 0;padding: 0;border: 0;outline: 0;-webkit-tap-highlight-color:transparent;}
article,aside,header,footer,nav,section,figure,figcaption,hgroup,progress,canvas{display:block}
blockquote:before,blockquote:after,q:before,q:after{content:'';content:none}
body{font-size:14px;font-family:'PingFangSC-Light','PingFang SC','Segoe UI','Lucida Grande','NotoSansHans-Light','Microsoft YaHei', '\5FAE\8F6F\96C5\9ED1', STHeiti, 'WenQuanYi Micro Hei', SimSun, sans-serif;text-rendering:geometricPrecision;color:#333333;background:#FFFFFF;}
a:active,a:hover{outline:0}
img{display:inline-block;border:0}
li{list-style:none}
table{border-collapse:collapse;border-spacing:0}
h1,h2,h3{font-size:14px;font-weight:400}
h4,h5,h6{font-size:100%;font-weight:400}
button,input,optgroup,option,select,textarea{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;outline:0;margin: 0px;padding: 0px;}
pre{white-space:pre-wrap;white-space:-moz-pre-wrap;white-space:-pre-wrap;white-space:-o-pre-wrap;word-wrap:break-word}
hr{height:1px;margin:10px 0;border:0;background-color:#e2e2e2;clear:both}
a{color:#333;text-decoration:none}
a:hover{color:#777}
.gray{background-color: #f2f2f2;}
.icons{background-image: url("jedate.png"); background-repeat:no-repeat; }
.jequote{max-width: 1200px;margin-bottom: 10px;padding: 15px;line-height: 22px;border: 4px solid #00A080;border-radius: 4px;background-color: #f5f5f5;font-size: 15px;}
.jebody{max-width: 1200px;margin: 40px auto 100px auto;position: relative;}
.jewarp{width:100%;margin: 15px 0; }
.jewarp h3{position: relative;left: 0;height: 40px;line-height:40px;padding-left:10px;white-space: nowrap;border-radius: 4px 4px 0 0;font-size: 16px;color:#00A080;text-align: left;border: 1px solid #ededed;border-bottom: none;}
.jewarp .content{border: 1px solid #ededed;border-radius:0 0 4px 4px;padding: 25px 10px 10px 10px;overflow: hidden;}
.jeitem{width:33.33%;margin:0 0px 15px 0;position: relative;float: left;}
.jelabel{width: 120px;float: left;display: block;padding: 9px 10px;font-weight: 400;text-align: right; color:#555;}
.jeinpbox{width: 230px;margin-right: 10px;float: left;vertical-align: middle;position: relative;}
.jeinput{display: block;width: 100%;padding-left: 10px; height: 36px;line-height: 34px\9;border: 1px solid #e6e6e6;background-color: #fff;border-radius: 3px;background-color: #fcfcfc;}
.jeindiv{display: block;width: 100%;padding-left: 10px; height: 36px;line-height: 36px;border-bottom: 1px solid #e6e6e6;background-color: #fff;background-color: #fcfcfc;}
.jebtns{width: 35px;margin-left: 10px; height: 36px;line-height: 36px\9;border: 1px solid #e6e6e6;background-color: #fff;border-radius: 3px;background-position:right center;float: left;cursor: pointer;position: absolute;top:0;right:-12px;}
.jefixeitem{width:25%;margin:0 0px 15px 0;position: relative;float: left; text-align: center;}
... ...
/**
@Name : jeDate V6.5.0 日期控件
@Author: chen guojun
@QQ群:516754269
@官网:http://www.jemui.com/ 或 https://github.com/singod/jeDate
*/
@font-face {font-family: "jedatefont";
src: url('jedatefont.eot?t=1510763148800'); /* IE9*/
src: url('jedatefont.eot?t=1510763148800#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('jedatefont.woff?t=1510763148800') format('woff'),
url('jedatefont.ttf?t=1510763148800') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('jedatefont.svg?t=1510763148800#jedatefont') format('svg'); /* iOS 4.1- */
}
.jedatefont {font-family:"jedatefont" !important;font-style:normal;-webkit-font-smoothing: antialiased;-moz-osx-font-smoothing: grayscale;}
.jedate{height:auto; font-family:'PingFangSC-Light','PingFang SC','Segoe UI','Lucida Grande','NotoSansHans-Light','Microsoft YaHei', '\5FAE\8F6F\96C5\9ED1', STHeiti, 'WenQuanYi Micro Hei', SimSun, sans-serif;font-size:12px; cursor:default;margin: 0;padding: 0;overflow: hidden;position: relative;border-radius:4px;display: inline-block;border: 1px solid #e2e2e2;box-shadow: 0 1px 6px rgba(0,0,0,.15);background-color:#fff;}
.jedate *{margin: 0;padding: 0;list-style-type:none;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;font-style:normal;font-family:'PingFangSC-Light','PingFang SC','Segoe UI','Lucida Grande','NotoSansHans-Light','Microsoft YaHei', '\5FAE\8F6F\96C5\9ED1', STHeiti, 'WenQuanYi Micro Hei', SimSun, sans-serif;}
.jedate table thead,.jedate table td{border: 1px #fff solid;}
.jedate ul,.jedate ol,.jedate li,.jedate dl{list-style-type:none;font-style:normal;font-weight: 300;}
.jedate .yearprev{left:0;font-size: 14px;}
.jedate .monthprev{left:25px;font-size: 14px;}
.jedate .yearnext{right:0;font-size: 14px;}
.jedate .monthnext{right:25px;font-size: 14px;}
.jedate .jedate-tips{position: absolute; top: 40%; left: 50%;z-index: 800; width: 200px; margin-left: -100px; line-height: 20px; padding: 15px; text-align: center; font-size: 12px; color: #ff0000;background-color: #FFFEF4;border: 1px rgb(247, 206, 57) solid;display: none;}
.jedate .timecontent ul::-webkit-scrollbar,.jedate-menu::-webkit-scrollbar{height:6px;width:6px;margin-right:5px;background-color: #f5f5f5;transition:all 0.3s ease-in-out;border-radius:0px}
.jedate .timecontent ul::-webkit-scrollbar-track,.jedate-menu::-webkit-scrollbar-track { -webkit-border-radius: 0px;border-radius: 0px;}
.jedate .timecontent ul::-webkit-scrollbar-thumb,.jedate-menu::-webkit-scrollbar-thumb{-webkit-border-radius: 0px;border-radius: 0px;background: rgba(0,0,0,0.5); }
.jedate .timecontent ul::-webkit-scrollbar-thumb:hover,.jedate-menu::-webkit-scrollbar-thumb:hover{background:rgba(0,0,0,0.6)}
.jedate .timecontent ul::-webkit-scrollbar-thumb:active,.jedate-menu::-webkit-scrollbar-thumb:active{background:rgba(0,0,0,0.8)}
.jedate .timecontent ul::-webkit-scrollbar-thumb:window-inactive,.jedate-menu::-webkit-scrollbar-thumb:window-inactive {background: rgba(0,0,0,0.4);}
.jedate .jedate-hmsmask{width:100%;display: block;background-color: rgba(0,0,0,.7);background-color:#fff;position: absolute;top: 0;left:0;right:0;bottom: 36px;z-index: 100;}
.jedatetipscon{color:#333; float:left; overflow:hidden;background-color: #FFFEF4; line-height:22px;padding:6px;border: 1px rgb(247, 206, 57) solid;font-style:normal;font-family: Arial, "\5b8b\4f53", 'sans-serif';font-size:12px;font-weight: 300;}
.jedatetipscon p{padding: 0;margin: 0;font-size:12px;}
.jedatetipscon p.red{color: #ff0000;}
.jedate.leftmenu{padding-left: 90px;}
.jedate .jedate-menu{width:90px;position: absolute;top: 0;left:0;bottom: 0;z-index: 10;background: #f2f2f2;border-right: 1px solid #efefef;border-radius: 4px 0 0 4px;overflow:auto;display: block;padding:4px 0;}
.jedate .jedate-menu p{height: 30px;line-height: 30px;padding-left: 8px;overflow:hidden;font-size: 12px;cursor: pointer;}
.jedate .jedate-menu p:hover{background-color: #00A680;color:#FFFFFF;}
.jedate .jedate-wrap{width:7rem;background: #fff;overflow: hidden;}
.jedate .jedate-pane{width: 7rem;float: left;overflow: hidden;}
.jedate .jedate-header{width:100%;height:36px;line-height: 36px;float: left;background-color: #f2f2f2;text-align: center;font-size: 14px;padding: 0 50px;position: relative;}
.jedate .jedate-header em{width:25px;height:36px;line-height: 36px;position:absolute;color: #666;top:0;background-repeat: no-repeat;background-position: center center;cursor: pointer;}
.jedate .jedate-header .ymbtn{padding: 8px;border-radius: 4px;cursor:pointer;font-size: 14px;}
/* .jedate .jedate-header em:hover,.jedate .jedate-header .ymbtn:hover{color: #00A680;} */
.jedate .jedate-content{width:100%;height: 220px;float: left;padding: 5px;overflow: hidden;}
.jedate .jedate-content.bordge{border-left: 1px #e9e9e9 solid;}
.jedate .jedate-content .yeartable,.jedate .jedate-content .monthtable{width: 100%;border-collapse: collapse;border-spacing: 0;border: 1px solid #fff;}
.jedate .jedate-content .yeartable td,.jedate .jedate-content .monthtable td{width:73px;height: 51px;line-height: 51px;text-align:center; position:relative; overflow:hidden;font-size: 14px;}
.jedate .jedate-content .yeartable td span,.jedate .jedate-content .monthtable td span{padding: 8px 10px;border: 1px solid #fff;}
.jedate .jedate-content .yeartable td.action span,.jedate .jedate-content .monthtable td.action span,
.jedate .jedate-content .yeartable td.action span:hover,.jedate .jedate-content .monthtable td.action span:hover{background-color:#00A680;border:1px #00A680 solid;color:#fff;}
.jedate .jedate-content .yeartable td span:hover,.jedate .jedate-content .monthtable td span:hover{background-color:#f2f2f2;border: 1px #f2f2f2 solid;}
.jedate .jedate-content .yeartable td.disabled span,.jedate .jedate-content .monthtable td.disabled span,
.jedate .jedate-content .yeartable td.disabled span:hover,.jedate .jedate-content .monthtable td.disabled span:hover{color:#bbb;background-color:#fff;border: 1px solid #fff;}
.jedate .jedate-content .yeartable td.contain span,.jedate .jedate-content .monthtable td.contain span,
.jedate .jedate-content .yeartable td.contain span:hover,.jedate .jedate-content .monthtable td.contain span:hover{background-color: #D0F0E3;border:1px #D0F0E3 solid;}
.jedate.grid .daystable thead,.jedate.grid .daystable td{border: 1px #f2f2f2 solid;}
.jedate .jedate-content .daystable{width: 100%;border-collapse: collapse;border-spacing: 0;border: 1px solid #fff;}
.jedate .jedate-content .daystable thead{background-color:#fff;}
.jedate .jedate-content .daystable th{width:48px;height:27px; text-align:center; position:relative; overflow:hidden;font-size: 12px;font-weight: 400;}
.jedate .jedate-content .daystable td{width:31px;height:30px; text-align:center; position:relative; overflow:hidden;font-size: 14px;font-family: Arial, "\5b8b\4f53", 'sans-serif';}
.jedate .jedate-content .daystable td .nolunar{line-height:29px;font-size: 14px;font-family: Arial, "\5b8b\4f53", 'sans-serif';}
.jedate .jedate-content .daystable td .solar{height:14px;line-height:14px;font-size: 14px;padding-top: 2px;display: block;font-family: Arial, "\5b8b\4f53", 'sans-serif';}
.jedate .jedate-content .daystable td .lunar{height:15px;line-height:15px;font-size: 12px;overflow:hidden;display: block;font-family: Arial, "\5b8b\4f53", 'sans-serif';color: #888;transform: scale(.95);}
.jedate .jedate-content .daystable td.action,.jedate .jedate-content .daystable td.action:hover,
.jedate .jedate-content .daystable td.action .lunar{background-color: #00A680;color:#fff;}
.jedate .jedate-content .daystable td.other,.jedate .jedate-content .daystable td.other .nolunar,.jedate .jedate-content .daystable td.other .lunar{color:#00DDAA;}
.jedate .jedate-content .daystable td.disabled,.jedate .jedate-content .daystable td.disabled .nolunar,.jedate .jedate-content .daystable td.disabled .lunar{ color:#bbb;}
.jedate .jedate-content .daystable td.contain,.jedate .jedate-content .daystable td.contain:hover{background-color: #00DDAA;color:#fff;}
.jedate .jedate-content .daystable td.disabled:hover{background-color:#fff;}
.jedate .jedate-content .daystable td:hover{background-color:#f2f2f2;}
.jedate .jedate-content .daystable td.red{ color:#ff0000;}
.jedate .jedate-content .daystable td .marks{ width:5px; height:5px; background-color:#ff0000; -webkit-border-radius:50%;border-radius:50%; position:absolute; right:2px; top:4px;}
.jedate .jedate-content .daystable td.action .marks{ width:5px; height:5px; background-color:#fff; -webkit-border-radius:50%;border-radius:50%; position:absolute; right:2px; top:4px;}
.jedate .jedate-time{overflow: hidden;padding-bottom: 4px; background-color:#fff;position: absolute;top:0;right: 0;z-index: 150;}
.jedate .jedate-time .timepane{width:230px;float:left;}
.jedate .jedate-time .timeheader{width: 100%;float:left;height: 36px;line-height: 36px;background-color: #f2f2f2;text-align: center;font-size: 14px;position: relative;}
.jedate .jedate-time .timecontent{width: 100%;float:left;}
.jedate .jedate-time .hmstitle{width: 211px;margin: 0 auto;overflow: hidden;padding-top: 4px;text-align: center;}
.jedate .jedate-time .hmstitle p{width: 33.33%;float:left;height: 30px;line-height: 30px;font-size: 13px;}
.jedate .jedate-time .hmslist{width: 211px;margin: 0 auto 6px auto;border: 1px solid #ddd;border-right: none;overflow: hidden;}
.jedate .jedate-time .hmslist .hmsauto{height: 100%;margin: 0;text-align: center;}
.jedate .jedate-time .hmslist ul {width: 70px;height: 174px;float: left;border-right: 1px solid #ddd;overflow: hidden;}
.jedate .jedate-time .hmslist .hmsauto:hover ul {overflow-y: auto}
.jedate .jedate-time .hmslist ul li {width: 130%;padding-left:26px;text-align: left;height: 25px;line-height: 25px;font-size: 14px;font-family: Arial, "\5b8b\4f53", 'sans-serif';}
.jedate .jedate-time .hmslist ul li:hover{background-color: #F2F2F2;}
.jedate .jedate-time .hmslist ul li.action,.jedate-time .hmslist ul li.action:hover{background-color: #00A680;color:#fff;}
.jedate .jedate-time .hmslist ul li.disabled{ background-color: #fbfbfb;color:#ccc;}
.jedate .jedate-time .hmslist ul li.disabled.action{ background-color: #00A680;color:#FFFFFF;filter:Alpha(opacity=30);opacity:.3; }
.jedate .jedate-footbtn{height: 36px;padding: 0 6px;border-top: 1px #e9e9e9 solid;overflow: hidden;}
.jedate .jedate-footbtn .timecon{line-height:28px;padding:0 5px;background-color:#00A680;color:#fff;display:block;float: left;font-size: 12px;margin-top:4px;border-radius:4px;overflow: hidden;}
.jedate .jedate-footbtn .btnscon{line-height:28px;margin-top:4px;display:block;float: right;font-size: 12px;border-radius:4px;overflow: hidden;}
.jedate .jedate-footbtn .btnscon span{float:left; padding:0 5px;border-right: 1px #fff solid;background-color:#00A680;color:#fff;display:block;height:28px;line-height:28px;text-align:center;overflow:hidden;}
.jedate .jedate-footbtn .btnscon span:last-child{border-right:none;}
... ...
/**
* jQuery WeUI V1.2.1
* By 言川
* http://lihongxun945.github.io/jquery-weui/
*/
.preloader {
width: 20px;
height: 20px;
-webkit-transform-origin: 50%;
transform-origin: 50%;
-webkit-animation: preloader-spin 1s steps(12, end) infinite;
animation: preloader-spin 1s steps(12, end) infinite;
}
.preloader:after {
display: block;
width: 100%;
height: 100%;
content: "";
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20viewBox%3D'0%200%20120%20120'%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20xmlns%3Axlink%3D'http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink'%3E%3Cdefs%3E%3Cline%20id%3D'l'%20x1%3D'60'%20x2%3D'60'%20y1%3D'7'%20y2%3D'27'%20stroke%3D'%236c6c6c'%20stroke-width%3D'11'%20stroke-linecap%3D'round'%2F%3E%3C%2Fdefs%3E%3Cg%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(30%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(60%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(90%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(120%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(150%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.37'%20transform%3D'rotate(180%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.46'%20transform%3D'rotate(210%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.56'%20transform%3D'rotate(240%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.66'%20transform%3D'rotate(270%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.75'%20transform%3D'rotate(300%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.85'%20transform%3D'rotate(330%2060%2C60)'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
background-repeat: no-repeat;
background-position: 50%;
background-size: 100%;
}
@-webkit-keyframes preloader-spin {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes preloader-spin {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
/*
.hairline(@position, @color) when (@position = top) {
border-top: 1px solid @color;
}
.hairline(@position, @color) when (@position = left) {
border-left: 1px solid @color;
}
.hairline(@position, @color) when (@position = bottom) {
border-bottom: 1px solid @color;
}
.hairline(@position, @color) when (@position = right) {
border-right: 1px solid @color;
}
// For right and bottom
.hairline-remove(@position) when not (@position = left) and not (@position = top) {
border-left: 0;
border-bottom: 0;
}
// For left and top
.hairline-remove(@position) when not (@position = right) and not (@position = bottom) {
border-right: 0;
border-top: 0;
}
// For right and bottom
.hairline-color(@position, @color) when not (@position = left) and not (@position = top) {
border-right-color: @color;
border-bottom-color: @color;
}
// For left and top
.hairline-color(@position, @color) when not (@position = right) and not (@position = bottom) {
border-left-color: @color;
border-top-color: @color;
}
*/
label > * {
pointer-events: none;
}
html {
font-size: 20px;
}
body {
font-size: 16px;
}
@media only screen and (min-width: 400px) {
html {
font-size: 21.33333333px !important;
}
}
@media only screen and (min-width: 414px) {
html {
font-size: 22.08px !important;
}
}
@media only screen and (min-width: 480px) {
html {
font-size: 25.6px !important;
}
}
.weui_navbar {
z-index: 10;
}
.weui-popup-overlay,
.weui-popup-container {
z-index: 1000;
}
.weui-mask {
z-index: 1000;
}
/* === Grid === */
.weui-row {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
justify-content: space-between;
-webkit-box-lines: multiple;
-moz-box-lines: multiple;
-ms-flex-wrap: wrap;
flex-wrap: wrap;
-webkit-box-align: start;
-ms-flex-align: start;
align-items: flex-start;
}
.weui-row > [class*="col-"] {
box-sizing: border-box;
}
.weui-row .col-auto {
width: 100%;
}
.weui-row .weui-col-100 {
width: 100%;
width: calc((100% - 15px*0) / 1);
}
.weui-row.weui-no-gutter .weui-col-100 {
width: 100%;
}
.weui-row .weui-col-95 {
width: 95%;
width: calc((100% - 15px*0.05263157894736836) / 1.0526315789473684);
}
.weui-row.weui-no-gutter .weui-col-95 {
width: 95%;
}
.weui-row .weui-col-90 {
width: 90%;
width: calc((100% - 15px*0.11111111111111116) / 1.1111111111111112);
}
.weui-row.weui-no-gutter .weui-col-90 {
width: 90%;
}
.weui-row .weui-col-85 {
width: 85%;
width: calc((100% - 15px*0.17647058823529416) / 1.1764705882352942);
}
.weui-row.weui-no-gutter .weui-col-85 {
width: 85%;
}
.weui-row .weui-col-80 {
width: 80%;
width: calc((100% - 15px*0.25) / 1.25);
}
.weui-row.weui-no-gutter .weui-col-80 {
width: 80%;
}
.weui-row .weui-col-75 {
width: 75%;
width: calc((100% - 15px*0.33333333333333326) / 1.3333333333333333);
}
.weui-row.weui-no-gutter .weui-col-75 {
width: 75%;
}
.weui-row .weui-col-66 {
width: 66.66666666666666%;
width: calc((100% - 15px*0.5000000000000002) / 1.5000000000000002);
}
.weui-row.weui-no-gutter .weui-col-66 {
width: 66.66666666666666%;
}
.weui-row .weui-col-60 {
width: 60%;
width: calc((100% - 15px*0.6666666666666667) / 1.6666666666666667);
}
.weui-row.weui-no-gutter .weui-col-60 {
width: 60%;
}
.weui-row .weui-col-50 {
width: 50%;
width: calc((100% - 15px*1) / 2);
}
.weui-row.weui-no-gutter .weui-col-50 {
width: 50%;
}
.weui-row .weui-col-40 {
width: 40%;
width: calc((100% - 15px*1.5) / 2.5);
}
.weui-row.weui-no-gutter .weui-col-40 {
width: 40%;
}
.weui-row .weui-col-33 {
width: 33.333333333333336%;
width: calc((100% - 15px*2) / 3);
}
.weui-row.weui-no-gutter .weui-col-33 {
width: 33.333333333333336%;
}
.weui-row .weui-col-25 {
width: 25%;
width: calc((100% - 15px*3) / 4);
}
.weui-row.weui-no-gutter .weui-col-25 {
width: 25%;
}
.weui-row .weui-col-20 {
width: 20%;
width: calc((100% - 15px*4) / 5);
}
.weui-row.weui-no-gutter .weui-col-20 {
width: 20%;
}
.weui-row .weui-col-15 {
width: 15%;
width: calc((100% - 15px*5.666666666666667) / 6.666666666666667);
}
.weui-row.weui-no-gutter .weui-col-15 {
width: 15%;
}
.weui-row .weui-col-10 {
width: 10%;
width: calc((100% - 15px*9) / 10);
}
.weui-row.weui-no-gutter .weui-col-10 {
width: 10%;
}
.weui-row .weui-col-5 {
width: 5%;
width: calc((100% - 15px*19) / 20);
}
.weui-row.weui-no-gutter .weui-col-5 {
width: 5%;
}
.weui-row .weui-col-auto:nth-last-child(1),
.weui-row .weui-col-auto:nth-last-child(1) ~ .weui-col-auto {
width: 100%;
width: calc((100% - 15px*0) / 1);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(1),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(1) ~ .weui-col-auto {
width: 100%;
}
.weui-row .weui-col-auto:nth-last-child(2),
.weui-row .weui-col-auto:nth-last-child(2) ~ .weui-col-auto {
width: 50%;
width: calc((100% - 15px*1) / 2);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(2),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(2) ~ .weui-col-auto {
width: 50%;
}
.weui-row .weui-col-auto:nth-last-child(3),
.weui-row .weui-col-auto:nth-last-child(3) ~ .weui-col-auto {
width: 33.33333333%;
width: calc((100% - 15px*2) / 3);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(3),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(3) ~ .weui-col-auto {
width: 33.33333333%;
}
.weui-row .weui-col-auto:nth-last-child(4),
.weui-row .weui-col-auto:nth-last-child(4) ~ .weui-col-auto {
width: 25%;
width: calc((100% - 15px*3) / 4);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(4),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(4) ~ .weui-col-auto {
width: 25%;
}
.weui-row .weui-col-auto:nth-last-child(5),
.weui-row .weui-col-auto:nth-last-child(5) ~ .weui-col-auto {
width: 20%;
width: calc((100% - 15px*4) / 5);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(5),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(5) ~ .weui-col-auto {
width: 20%;
}
.weui-row .weui-col-auto:nth-last-child(6),
.weui-row .weui-col-auto:nth-last-child(6) ~ .weui-col-auto {
width: 16.66666667%;
width: calc((100% - 15px*5) / 6);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(6),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(6) ~ .weui-col-auto {
width: 16.66666667%;
}
.weui-row .weui-col-auto:nth-last-child(7),
.weui-row .weui-col-auto:nth-last-child(7) ~ .weui-col-auto {
width: 14.28571429%;
width: calc((100% - 15px*6) / 7);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(7),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(7) ~ .weui-col-auto {
width: 14.28571429%;
}
.weui-row .weui-col-auto:nth-last-child(8),
.weui-row .weui-col-auto:nth-last-child(8) ~ .weui-col-auto {
width: 12.5%;
width: calc((100% - 15px*7) / 8);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(8),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(8) ~ .weui-col-auto {
width: 12.5%;
}
.weui-row .weui-col-auto:nth-last-child(9),
.weui-row .weui-col-auto:nth-last-child(9) ~ .weui-col-auto {
width: 11.11111111%;
width: calc((100% - 15px*8) / 9);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(9),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(9) ~ .weui-col-auto {
width: 11.11111111%;
}
.weui-row .weui-col-auto:nth-last-child(10),
.weui-row .weui-col-auto:nth-last-child(10) ~ .weui-col-auto {
width: 10%;
width: calc((100% - 15px*9) / 10);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(10),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(10) ~ .weui-col-auto {
width: 10%;
}
.weui-row .weui-col-auto:nth-last-child(11),
.weui-row .weui-col-auto:nth-last-child(11) ~ .weui-col-auto {
width: 9.09090909%;
width: calc((100% - 15px*10) / 11);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(11),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(11) ~ .weui-col-auto {
width: 9.09090909%;
}
.weui-row .weui-col-auto:nth-last-child(12),
.weui-row .weui-col-auto:nth-last-child(12) ~ .weui-col-auto {
width: 8.33333333%;
width: calc((100% - 15px*11) / 12);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(12),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(12) ~ .weui-col-auto {
width: 8.33333333%;
}
.weui-row .weui-col-auto:nth-last-child(13),
.weui-row .weui-col-auto:nth-last-child(13) ~ .weui-col-auto {
width: 7.69230769%;
width: calc((100% - 15px*12) / 13);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(13),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(13) ~ .weui-col-auto {
width: 7.69230769%;
}
.weui-row .weui-col-auto:nth-last-child(14),
.weui-row .weui-col-auto:nth-last-child(14) ~ .weui-col-auto {
width: 7.14285714%;
width: calc((100% - 15px*13) / 14);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(14),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(14) ~ .weui-col-auto {
width: 7.14285714%;
}
.weui-row .weui-col-auto:nth-last-child(15),
.weui-row .weui-col-auto:nth-last-child(15) ~ .weui-col-auto {
width: 6.66666667%;
width: calc((100% - 15px*14) / 15);
}
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(15),
.weui-row.weui-no-gutter .weui-col-auto:nth-last-child(15) ~ .weui-col-auto {
width: 6.66666667%;
}
@media all and (min-width: 768px) {
.row .tablet-100 {
width: 100%;
width: calc((100% - 15px*0) / 1);
}
.row.no-gutter .tablet-100 {
width: 100%;
}
.row .tablet-95 {
width: 95%;
width: calc((100% - 15px*0.05263157894736836) / 1.0526315789473684);
}
.row.no-gutter .tablet-95 {
width: 95%;
}
.row .tablet-90 {
width: 90%;
width: calc((100% - 15px*0.11111111111111116) / 1.1111111111111112);
}
.row.no-gutter .tablet-90 {
width: 90%;
}
.row .tablet-85 {
width: 85%;
width: calc((100% - 15px*0.17647058823529416) / 1.1764705882352942);
}
.row.no-gutter .tablet-85 {
width: 85%;
}
.row .tablet-80 {
width: 80%;
width: calc((100% - 15px*0.25) / 1.25);
}
.row.no-gutter .tablet-80 {
width: 80%;
}
.row .tablet-75 {
width: 75%;
width: calc((100% - 15px*0.33333333333333326) / 1.3333333333333333);
}
.row.no-gutter .tablet-75 {
width: 75%;
}
.row .tablet-66 {
width: 66.66666666666666%;
width: calc((100% - 15px*0.5000000000000002) / 1.5000000000000002);
}
.row.no-gutter .tablet-66 {
width: 66.66666666666666%;
}
.row .tablet-60 {
width: 60%;
width: calc((100% - 15px*0.6666666666666667) / 1.6666666666666667);
}
.row.no-gutter .tablet-60 {
width: 60%;
}
.row .tablet-50 {
width: 50%;
width: calc((100% - 15px*1) / 2);
}
.row.no-gutter .tablet-50 {
width: 50%;
}
.row .tablet-40 {
width: 40%;
width: calc((100% - 15px*1.5) / 2.5);
}
.row.no-gutter .tablet-40 {
width: 40%;
}
.row .tablet-33 {
width: 33.333333333333336%;
width: calc((100% - 15px*2) / 3);
}
.row.no-gutter .tablet-33 {
width: 33.333333333333336%;
}
.row .tablet-25 {
width: 25%;
width: calc((100% - 15px*3) / 4);
}
.row.no-gutter .tablet-25 {
width: 25%;
}
.row .tablet-20 {
width: 20%;
width: calc((100% - 15px*4) / 5);
}
.row.no-gutter .tablet-20 {
width: 20%;
}
.row .tablet-15 {
width: 15%;
width: calc((100% - 15px*5.666666666666667) / 6.666666666666667);
}
.row.no-gutter .tablet-15 {
width: 15%;
}
.row .tablet-10 {
width: 10%;
width: calc((100% - 15px*9) / 10);
}
.row.no-gutter .tablet-10 {
width: 10%;
}
.row .tablet-5 {
width: 5%;
width: calc((100% - 15px*19) / 20);
}
.row.no-gutter .tablet-5 {
width: 5%;
}
.row .tablet-auto:nth-last-child(1),
.row .tablet-auto:nth-last-child(1) ~ .col-auto {
width: 100%;
width: calc((100% - 15px*0) / 1);
}
.row.no-gutter .tablet-auto:nth-last-child(1),
.row.no-gutter .tablet-auto:nth-last-child(1) ~ .tablet-auto {
width: 100%;
}
.row .tablet-auto:nth-last-child(2),
.row .tablet-auto:nth-last-child(2) ~ .col-auto {
width: 50%;
width: calc((100% - 15px*1) / 2);
}
.row.no-gutter .tablet-auto:nth-last-child(2),
.row.no-gutter .tablet-auto:nth-last-child(2) ~ .tablet-auto {
width: 50%;
}
.row .tablet-auto:nth-last-child(3),
.row .tablet-auto:nth-last-child(3) ~ .col-auto {
width: 33.33333333%;
width: calc((100% - 15px*2) / 3);
}
.row.no-gutter .tablet-auto:nth-last-child(3),
.row.no-gutter .tablet-auto:nth-last-child(3) ~ .tablet-auto {
width: 33.33333333%;
}
.row .tablet-auto:nth-last-child(4),
.row .tablet-auto:nth-last-child(4) ~ .col-auto {
width: 25%;
width: calc((100% - 15px*3) / 4);
}
.row.no-gutter .tablet-auto:nth-last-child(4),
.row.no-gutter .tablet-auto:nth-last-child(4) ~ .tablet-auto {
width: 25%;
}
.row .tablet-auto:nth-last-child(5),
.row .tablet-auto:nth-last-child(5) ~ .col-auto {
width: 20%;
width: calc((100% - 15px*4) / 5);
}
.row.no-gutter .tablet-auto:nth-last-child(5),
.row.no-gutter .tablet-auto:nth-last-child(5) ~ .tablet-auto {
width: 20%;
}
.row .tablet-auto:nth-last-child(6),
.row .tablet-auto:nth-last-child(6) ~ .col-auto {
width: 16.66666667%;
width: calc((100% - 15px*5) / 6);
}
.row.no-gutter .tablet-auto:nth-last-child(6),
.row.no-gutter .tablet-auto:nth-last-child(6) ~ .tablet-auto {
width: 16.66666667%;
}
.row .tablet-auto:nth-last-child(7),
.row .tablet-auto:nth-last-child(7) ~ .col-auto {
width: 14.28571429%;
width: calc((100% - 15px*6) / 7);
}
.row.no-gutter .tablet-auto:nth-last-child(7),
.row.no-gutter .tablet-auto:nth-last-child(7) ~ .tablet-auto {
width: 14.28571429%;
}
.row .tablet-auto:nth-last-child(8),
.row .tablet-auto:nth-last-child(8) ~ .col-auto {
width: 12.5%;
width: calc((100% - 15px*7) / 8);
}
.row.no-gutter .tablet-auto:nth-last-child(8),
.row.no-gutter .tablet-auto:nth-last-child(8) ~ .tablet-auto {
width: 12.5%;
}
.row .tablet-auto:nth-last-child(9),
.row .tablet-auto:nth-last-child(9) ~ .col-auto {
width: 11.11111111%;
width: calc((100% - 15px*8) / 9);
}
.row.no-gutter .tablet-auto:nth-last-child(9),
.row.no-gutter .tablet-auto:nth-last-child(9) ~ .tablet-auto {
width: 11.11111111%;
}
.row .tablet-auto:nth-last-child(10),
.row .tablet-auto:nth-last-child(10) ~ .col-auto {
width: 10%;
width: calc((100% - 15px*9) / 10);
}
.row.no-gutter .tablet-auto:nth-last-child(10),
.row.no-gutter .tablet-auto:nth-last-child(10) ~ .tablet-auto {
width: 10%;
}
.row .tablet-auto:nth-last-child(11),
.row .tablet-auto:nth-last-child(11) ~ .col-auto {
width: 9.09090909%;
width: calc((100% - 15px*10) / 11);
}
.row.no-gutter .tablet-auto:nth-last-child(11),
.row.no-gutter .tablet-auto:nth-last-child(11) ~ .tablet-auto {
width: 9.09090909%;
}
.row .tablet-auto:nth-last-child(12),
.row .tablet-auto:nth-last-child(12) ~ .col-auto {
width: 8.33333333%;
width: calc((100% - 15px*11) / 12);
}
.row.no-gutter .tablet-auto:nth-last-child(12),
.row.no-gutter .tablet-auto:nth-last-child(12) ~ .tablet-auto {
width: 8.33333333%;
}
.row .tablet-auto:nth-last-child(13),
.row .tablet-auto:nth-last-child(13) ~ .col-auto {
width: 7.69230769%;
width: calc((100% - 15px*12) / 13);
}
.row.no-gutter .tablet-auto:nth-last-child(13),
.row.no-gutter .tablet-auto:nth-last-child(13) ~ .tablet-auto {
width: 7.69230769%;
}
.row .tablet-auto:nth-last-child(14),
.row .tablet-auto:nth-last-child(14) ~ .col-auto {
width: 7.14285714%;
width: calc((100% - 15px*13) / 14);
}
.row.no-gutter .tablet-auto:nth-last-child(14),
.row.no-gutter .tablet-auto:nth-last-child(14) ~ .tablet-auto {
width: 7.14285714%;
}
.row .tablet-auto:nth-last-child(15),
.row .tablet-auto:nth-last-child(15) ~ .col-auto {
width: 6.66666667%;
width: calc((100% - 15px*14) / 15);
}
.row.no-gutter .tablet-auto:nth-last-child(15),
.row.no-gutter .tablet-auto:nth-last-child(15) ~ .tablet-auto {
width: 6.66666667%;
}
}
.weui-cell__hd img {
display: block;
margin-right: 5px;
}
.weui-cell_swiped .weui-cell__bd {
-webkit-transition: -webkit-transform .3s;
transition: -webkit-transform .3s;
transition: transform .3s;
transition: transform .3s, -webkit-transform .3s;
}
.swipeout-touching .weui-cell__bd {
-webkit-transition: none;
transition: none;
}
.weui-dialog,
.weui-toast {
-webkit-transition-duration: .2s;
transition-duration: .2s;
opacity: 0;
-webkit-transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
visibility: hidden;
margin: 0;
top: 45%;
z-index: 2000;
}
.weui-dialog .weui-dialog__btn.default,
.weui-toast .weui-dialog__btn.default {
color: #5f646e;
}
.weui-dialog .weui-dialog__btn + .weui-dialog__btn,
.weui-toast .weui-dialog__btn + .weui-dialog__btn {
position: relative;
}
.weui-dialog .weui-dialog__btn + .weui-dialog__btn:after,
.weui-toast .weui-dialog__btn + .weui-dialog__btn:after {
content: " ";
position: absolute;
left: 0;
top: 0;
width: 1px;
height: 100%;
border-left: 1px solid #D5D5D6;
color: #D5D5D6;
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
-webkit-transform: scaleX(0.5);
transform: scaleX(0.5);
}
.weui-dialog.weui-dialog--visible,
.weui-toast.weui-dialog--visible,
.weui-dialog.weui-toast--visible,
.weui-toast.weui-toast--visible {
opacity: 1;
visibility: visible;
}
.weui-toast_forbidden {
color: #F76260;
}
.weui-toast_cancel .weui-icon-toast:before {
content: "\EA0D";
}
.weui-toast_forbidden .weui-icon-toast:before {
content: "\EA0B";
color: #F76260;
}
.weui-toast_text {
min-height: 1em;
width: auto;
height: 45px;
border-radius: 25px;
margin-left: 0;
-webkit-transform: scale(0.9) translate3d(-50%, 0, 0);
transform: scale(0.9) translate3d(-50%, 0, 0);
-webkit-transform-origin: left;
transform-origin: left;
}
.weui-toast_text.weui-toast--visible {
-webkit-transform: scale(1) translate3d(-50%, 0, 0);
transform: scale(1) translate3d(-50%, 0, 0);
}
.weui-toast_text .weui-icon-toast {
display: none;
}
.weui-toast_text .weui-toast_content {
margin: 10px 15px;
}
.weui-mask {
opacity: 0;
-webkit-transition-duration: .3s;
transition-duration: .3s;
visibility: hidden;
}
.weui-mask.weui-mask--visible {
opacity: 1;
visibility: visible;
}
.weui-prompt-input {
padding: 4px 6px;
border: 1px solid #ccc;
box-sizing: border-box;
height: 2em;
width: 80%;
margin-top: 10px;
}
.weui-pull-to-refresh {
margin-top: -50px;
-webkit-transition: -webkit-transform .4s;
transition: -webkit-transform .4s;
transition: transform .4s;
transition: transform .4s, -webkit-transform .4s;
}
.weui-pull-to-refresh.refreshing {
-webkit-transform: translate3d(0, 50px, 0);
transform: translate3d(0, 50px, 0);
}
.weui-pull-to-refresh.touching {
-webkit-transition-duration: 0s;
transition-duration: 0s;
}
.weui-pull-to-refresh__layer {
height: 30px;
line-height: 30px;
padding: 10px;
text-align: center;
}
.weui-pull-to-refresh__layer .down {
display: inline-block;
}
.weui-pull-to-refresh__layer .up,
.weui-pull-to-refresh__layer .refresh {
display: none;
}
.weui-pull-to-refresh__layer .weui-pull-to-refresh__arrow {
display: inline-block;
z-index: 10;
width: 20px;
height: 20px;
margin-right: 4px;
vertical-align: -4px;
background: no-repeat center;
background-size: 13px 20px;
-webkit-transition-duration: 300ms;
transition-duration: 300ms;
-webkit-transform: rotate(0deg) translate3d(0, 0, 0);
transform: rotate(0deg) translate3d(0, 0, 0);
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2026%2040'%3E%3Cpolygon%20points%3D'9%2C22%209%2C0%2017%2C0%2017%2C22%2026%2C22%2013.5%2C40%200%2C22'%20fill%3D'%238c8c8c'%2F%3E%3C%2Fsvg%3E");
}
.weui-pull-to-refresh__layer .weui-pull-to-refresh__preloader {
display: none;
vertical-align: -4px;
margin-right: 4px;
width: 20px;
height: 20px;
-webkit-transform-origin: 50%;
transform-origin: 50%;
-webkit-animation: preloader-spin 1s steps(12, end) infinite;
animation: preloader-spin 1s steps(12, end) infinite;
}
.weui-pull-to-refresh__layer .weui-pull-to-refresh__preloader:after {
display: block;
width: 100%;
height: 100%;
content: "";
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20viewBox%3D'0%200%20120%20120'%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20xmlns%3Axlink%3D'http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink'%3E%3Cdefs%3E%3Cline%20id%3D'l'%20x1%3D'60'%20x2%3D'60'%20y1%3D'7'%20y2%3D'27'%20stroke%3D'%236c6c6c'%20stroke-width%3D'11'%20stroke-linecap%3D'round'%2F%3E%3C%2Fdefs%3E%3Cg%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(30%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(60%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(90%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(120%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(150%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.37'%20transform%3D'rotate(180%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.46'%20transform%3D'rotate(210%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.56'%20transform%3D'rotate(240%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.66'%20transform%3D'rotate(270%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.75'%20transform%3D'rotate(300%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.85'%20transform%3D'rotate(330%2060%2C60)'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
background-repeat: no-repeat;
background-position: 50%;
background-size: 100%;
}
.pull-up .weui-pull-to-refresh__layer .down,
.refreshing .weui-pull-to-refresh__layer .down {
display: none;
}
.pull-up .weui-pull-to-refresh__layer .weui-pull-to-refresh__arrow {
display: inline-block;
-webkit-transform: rotate(180deg) translate3d(0, 0, 0);
transform: rotate(180deg) translate3d(0, 0, 0);
}
.pull-up .weui-pull-to-refresh__layer .up {
display: inline-block;
}
.pull-down .weui-pull-to-refresh__layer .weui-pull-to-refresh__arrow {
display: inline-block;
}
.pull-down .weui-pull-to-refresh__layer .down {
display: inline-block;
}
.refreshing .weui-pull-to-refresh__layer .weui-pull-to-refresh__arrow {
display: none;
}
.refreshing .weui-pull-to-refresh__layer .weui-pull-to-refresh__preloader {
display: inline-block;
}
.refreshing .weui-pull-to-refresh__layer .refresh {
display: inline-block;
}
@keyframes preloader-spin {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
.weui-tab__bd-item.weui-pull-to-refresh {
position: absolute;
top: 50px;
}
.weui-tabbar__item {
position: relative;
}
.weui-tabbar__item.weui-bar__item--on .weui-tabbar__label {
color: #04BE02;
}
.weui-navbar__item {
color: #888;
}
.weui-navbar__item.weui-bar__item--on {
color: #666;
background-color: #f1f1f1;
}
.weui-tab__bd {
box-sizing: border-box;
height: 100%;
}
.weui-tab__bd .weui-tab__bd-item {
display: none;
height: 100%;
overflow: auto;
}
.weui-tab__bd .weui-tab__bd-item.weui-tab__bd-item--active {
display: block;
}
.weui-navbar + .weui-tab__bd {
padding-top: 50px;
}
.toolbar {
position: relative;
width: 100%;
font-size: .85rem;
line-height: 1.5;
color: #3d4145;
background: #f7f7f8;
}
.toolbar:before {
content: '';
position: absolute;
left: 0;
top: 0;
bottom: auto;
right: auto;
height: 1px;
width: 100%;
background-color: #d9d9d9;
display: block;
z-index: 15;
-webkit-transform-origin: 50% 0%;
transform-origin: 50% 0%;
}
@media only screen and (-webkit-min-device-pixel-ratio: 2) {
.toolbar:before {
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
}
}
@media only screen and (-webkit-min-device-pixel-ratio: 3) {
.toolbar:before {
-webkit-transform: scaleY(0.33);
transform: scaleY(0.33);
}
}
.toolbar .toolbar-inner {
height: 2.2rem;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
text-align: center;
}
.toolbar .title {
position: absolute;
display: block;
width: 100%;
padding: 0;
font-size: .85rem;
font-weight: normal;
line-height: 2.2rem;
color: #3d4145;
text-align: center;
white-space: nowrap;
}
.toolbar .picker-button {
position: absolute;
right: 0;
box-sizing: border-box;
height: 2.2rem;
line-height: 2.2rem;
color: #04BE02;
z-index: 1;
padding: 0 .5rem;
}
/* === Columns Picker === */
.weui-picker-modal {
width: 100%;
position: absolute;
bottom: 0;
text-align: center;
border-radius: 0;
opacity: 0.6;
color: #3d4145;
-webkit-transition-duration: .3s;
transition-duration: .3s;
height: 13rem;
background: #EFEFF4;
-webkit-transform: translate3d(0, 100%, 0);
transform: translate3d(0, 100%, 0);
-webkit-transition-property: opacity, -webkit-transform;
transition-property: opacity, -webkit-transform;
transition-property: transform, opacity;
transition-property: transform, opacity, -webkit-transform;
}
.weui-picker-modal.picker-modal-inline {
height: 10.8rem;
opacity: 1;
position: static;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
.weui-picker-modal.picker-modal-inline .toolbar {
display: none;
}
.weui-picker-modal.picker-columns-single .picker-items-col {
width: 100%;
}
.weui-picker-modal.weui-picker-modal-visible {
opacity: 1;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
.weui-picker-modal .picker-modal-inner {
position: relative;
height: 10.8rem;
}
.weui-picker-modal .picker-columns {
width: 100%;
height: 13rem;
z-index: 11500;
}
.weui-picker-modal .picker-columns.picker-modal-inline,
.popover .weui-picker-modal .picker-columns {
height: 10rem;
}
@media (orientation: landscape) and (max-height: 415px) {
.weui-picker-modal .picker-columns:not(.picker-modal-inline) {
height: 10rem;
}
}
.weui-picker-modal .popover.popover-picker-columns {
width: 14rem;
}
.weui-picker-modal .picker-items {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
width: 100%;
padding: 0;
text-align: right;
font-size: 1rem;
font-weight: normal;
-webkit-mask-box-image: -webkit-linear-gradient(bottom, transparent, transparent 5%, white 20%, white 80%, transparent 95%, transparent);
-webkit-mask-box-image: linear-gradient(to top, transparent, transparent 5%, white 20%, white 80%, transparent 95%, transparent);
}
.weui-picker-modal .bar + .picker-items {
height: 10.8rem;
}
.weui-picker-modal .picker-items-col {
overflow: hidden;
position: relative;
max-height: 100%;
}
.weui-picker-modal .picker-items-col.picker-items-col-left {
text-align: left;
}
.weui-picker-modal .picker-items-col.picker-items-col-center {
text-align: center;
}
.weui-picker-modal .picker-items-col.picker-items-col-right {
text-align: right;
}
.weui-picker-modal .picker-items-col.picker-items-col-divider {
color: #3d4145;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
}
.weui-picker-modal .picker-items-col-wrapper {
-webkit-transition: 300ms;
transition: 300ms;
-webkit-transition-timing-function: ease-out;
transition-timing-function: ease-out;
}
.weui-picker-modal .picker-item {
height: 32px;
line-height: 32px;
padding: 0 10px;
white-space: nowrap;
position: relative;
overflow: hidden;
text-overflow: ellipsis;
color: #9b9b9b;
left: 0;
top: 0;
width: 100%;
box-sizing: border-box;
-webkit-transition: 300ms;
transition: 300ms;
}
.picker-items-col-absolute .weui-picker-modal .picker-item {
position: absolute;
}
.weui-picker-modal .picker-item.picker-item-far {
pointer-events: none;
}
.weui-picker-modal .picker-item.picker-selected {
color: #3d4145;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
-webkit-transform: rotateX(0deg);
transform: rotateX(0deg);
}
.weui-picker-modal .picker-center-highlight {
height: 32px;
box-sizing: border-box;
position: absolute;
left: 0;
width: 100%;
top: 50%;
margin-top: -16px;
pointer-events: none;
}
.weui-picker-modal .picker-center-highlight:before {
content: '';
position: absolute;
left: 0;
top: 0;
bottom: auto;
right: auto;
height: 1px;
width: 100%;
background-color: #D9D9D9;
display: block;
z-index: 15;
-webkit-transform-origin: 50% 0%;
transform-origin: 50% 0%;
}
@media only screen and (-webkit-min-device-pixel-ratio: 2) {
.weui-picker-modal .picker-center-highlight:before {
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
}
}
@media only screen and (-webkit-min-device-pixel-ratio: 3) {
.weui-picker-modal .picker-center-highlight:before {
-webkit-transform: scaleY(0.33);
transform: scaleY(0.33);
}
}
.weui-picker-modal .picker-center-highlight:after {
content: '';
position: absolute;
left: 0;
bottom: 0;
right: auto;
top: auto;
height: 1px;
width: 100%;
background-color: #D9D9D9;
display: block;
z-index: 15;
-webkit-transform-origin: 50% 100%;
transform-origin: 50% 100%;
}
@media only screen and (-webkit-min-device-pixel-ratio: 2) {
.weui-picker-modal .picker-center-highlight:after {
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
}
}
@media only screen and (-webkit-min-device-pixel-ratio: 3) {
.weui-picker-modal .picker-center-highlight:after {
-webkit-transform: scaleY(0.33);
transform: scaleY(0.33);
}
}
.weui-picker-modal .picker-3d .picker-items {
overflow: hidden;
-webkit-perspective: 1200px;
perspective: 1200px;
}
.weui-picker-modal .picker-3d .picker-items-col,
.weui-picker-modal .picker-3d .picker-items-col-wrapper,
.weui-picker-modal .picker-3d .picker-item {
-webkit-transform-style: preserve-3d;
transform-style: preserve-3d;
}
.weui-picker-modal .picker-3d .picker-items-col {
overflow: visible;
}
.weui-picker-modal .picker-3d .picker-item {
-webkit-transform-origin: center center -110px;
transform-origin: center center -110px;
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
-webkit-transition-timing-function: ease-out;
transition-timing-function: ease-out;
}
.weui-picker-overlay,
.weui-picker-container {
position: fixed;
bottom: 0;
left: 0;
right: 0;
height: 0;
width: 100%;
z-index: 1000;
}
.city-picker .picker-items-col {
-webkit-box-flex: 1;
-ms-flex: 1;
flex: 1;
max-width: 7rem;
}
.weui-picker-container .weui-cells {
margin: 0;
text-align: left;
}
.datetime-picker .picker-item {
text-overflow: initial;
}
.weui-select-modal {
height: auto;
}
.weui-select-modal .weui-cells {
margin: 0;
text-align: left;
overflow-y: auto;
overflow-x: hidden;
max-height: 16rem;
}
.weui-select-modal .weui-cells:after {
display: none;
}
/* === Calendar === */
.weui-picker-calendar {
background: #fff;
height: 15rem;
width: 100%;
overflow: hidden;
}
.weui-picker-calendar .picker-modal-inner {
overflow: hidden;
height: 12.8rem;
}
.picker-calendar-week-days {
height: .9rem;
background: #f7f7f8;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
font-size: 11px;
box-sizing: border-box;
position: relative;
}
.picker-calendar-week-days:after {
content: '';
position: absolute;
left: 0;
bottom: 0;
right: auto;
top: auto;
height: 1px;
width: 100%;
background-color: #c4c4c4;
display: block;
z-index: 15;
-webkit-transform-origin: 50% 100%;
transform-origin: 50% 100%;
}
@media only screen and (-webkit-min-device-pixel-ratio: 2) {
.picker-calendar-week-days:after {
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
}
}
@media only screen and (-webkit-min-device-pixel-ratio: 3) {
.picker-calendar-week-days:after {
-webkit-transform: scaleY(0.33);
transform: scaleY(0.33);
}
}
.picker-calendar-week-days .picker-calendar-week-day {
-webkit-flex-shrink: 1;
-ms-flex: 0 1 auto;
-ms-flex-negative: 1;
flex-shrink: 1;
width: 14.28571429%;
width: calc(100% / 7);
line-height: 17px;
text-align: center;
}
.picker-calendar-week-days + .picker-calendar-months {
height: 11.9rem;
}
.picker-calendar-months {
width: 100%;
height: 100%;
overflow: hidden;
position: relative;
}
.picker-calendar-months-wrapper {
position: relative;
width: 100%;
height: 100%;
-webkit-transition: 300ms;
transition: 300ms;
}
.picker-calendar-month {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-orient: vertical;
-ms-flex-direction: column;
flex-direction: column;
width: 100%;
height: 100%;
position: absolute;
left: 0;
top: 0;
}
.picker-calendar-row {
height: 16.66666667%;
height: calc(100% / 6);
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-flex-shrink: 1;
-ms-flex: 0 1 auto;
-ms-flex-negative: 1;
flex-shrink: 1;
width: 100%;
position: relative;
}
.picker-calendar-row:after {
content: '';
position: absolute;
left: 0;
bottom: 0;
right: auto;
top: auto;
height: 1px;
width: 100%;
background-color: #ccc;
display: block;
z-index: 15;
-webkit-transform-origin: 50% 100%;
transform-origin: 50% 100%;
}
@media only screen and (-webkit-min-device-pixel-ratio: 2) {
.picker-calendar-row:after {
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
}
}
@media only screen and (-webkit-min-device-pixel-ratio: 3) {
.picker-calendar-row:after {
-webkit-transform: scaleY(0.33);
transform: scaleY(0.33);
}
}
.weui-picker-modal .picker-calendar-row:last-child:after {
display: none;
}
.picker-calendar-day {
-webkit-flex-shrink: 1;
-ms-flex: 0 1 auto;
-ms-flex-negative: 1;
flex-shrink: 1;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
box-sizing: border-box;
width: 14.28571429%;
width: calc(100% / 7);
text-align: center;
color: #3d4145;
font-size: 15px;
cursor: pointer;
}
.picker-calendar-day.picker-calendar-day-prev,
.picker-calendar-day.picker-calendar-day-next {
color: #ccc;
}
.picker-calendar-day.picker-calendar-day-disabled {
color: #d4d4d4;
cursor: auto;
}
.picker-calendar-day.picker-calendar-day-today span {
background: #e3e3e3;
}
.picker-calendar-day.picker-calendar-day-selected span {
background: #04BE02;
color: #fff;
}
.picker-calendar-day span {
display: inline-block;
border-radius: 100%;
width: 30px;
height: 30px;
line-height: 30px;
}
.picker-calendar-month-picker,
.picker-calendar-year-picker {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
justify-content: space-between;
width: 50%;
max-width: 200px;
-webkit-flex-shrink: 10;
-ms-flex: 0 10 auto;
-ms-flex-negative: 10;
flex-shrink: 10;
}
.picker-calendar-month-picker a.icon-only,
.picker-calendar-year-picker a.icon-only {
min-width: 36px;
}
.picker-calendar-month-picker span,
.picker-calendar-year-picker span {
-webkit-flex-shrink: 1;
-ms-flex: 0 1 auto;
-ms-flex-negative: 1;
flex-shrink: 1;
position: relative;
overflow: hidden;
text-overflow: ellipsis;
}
.popover .picker-calendar .picker-calendar-week-days,
.picker-calendar.picker-modal-inline .picker-calendar-week-days {
background: none;
}
.popover .picker-calendar .toolbar:before,
.picker-calendar.picker-modal-inline .toolbar:before,
.popover .picker-calendar .picker-calendar-week-days:before,
.picker-calendar.picker-modal-inline .picker-calendar-week-days:before {
display: none;
}
.popover .picker-calendar .toolbar:after,
.picker-calendar.picker-modal-inline .toolbar:after,
.popover .picker-calendar .picker-calendar-week-days:after,
.picker-calendar.picker-modal-inline .picker-calendar-week-days:after {
display: none;
}
.popover .picker-calendar .toolbar ~ .picker-modal-inner .picker-calendar-months:before,
.picker-calendar.picker-modal-inline .toolbar ~ .picker-modal-inner .picker-calendar-months:before,
.popover .picker-calendar .picker-calendar-week-days ~ .picker-calendar-months:before,
.picker-calendar.picker-modal-inline .picker-calendar-week-days ~ .picker-calendar-months:before {
content: '';
position: absolute;
left: 0;
top: 0;
bottom: auto;
right: auto;
height: 1px;
width: 100%;
background-color: #c4c4c4;
display: block;
z-index: 15;
-webkit-transform-origin: 50% 0%;
transform-origin: 50% 0%;
}
@media only screen and (-webkit-min-device-pixel-ratio: 2) {
.popover .picker-calendar .toolbar ~ .picker-modal-inner .picker-calendar-months:before,
.picker-calendar.picker-modal-inline .toolbar ~ .picker-modal-inner .picker-calendar-months:before,
.popover .picker-calendar .picker-calendar-week-days ~ .picker-calendar-months:before,
.picker-calendar.picker-modal-inline .picker-calendar-week-days ~ .picker-calendar-months:before {
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
}
}
@media only screen and (-webkit-min-device-pixel-ratio: 3) {
.popover .picker-calendar .toolbar ~ .picker-modal-inner .picker-calendar-months:before,
.picker-calendar.picker-modal-inline .toolbar ~ .picker-modal-inner .picker-calendar-months:before,
.popover .picker-calendar .picker-calendar-week-days ~ .picker-calendar-months:before,
.picker-calendar.picker-modal-inline .picker-calendar-week-days ~ .picker-calendar-months:before {
-webkit-transform: scaleY(0.33);
transform: scaleY(0.33);
}
}
.picker-calendar-month-picker,
.picker-calendar-year-picker {
display: block;
line-height: 2.2rem;
-webkit-box-flex: 1;
-ms-flex: 1;
flex: 1;
}
.picker-calendar-month-picker a.icon-only,
.picker-calendar-year-picker a.icon-only {
float: left;
width: 25%;
height: 2.2rem;
line-height: 2rem;
}
.picker-calendar-month-picker .current-month-value,
.picker-calendar-year-picker .current-month-value,
.picker-calendar-month-picker .current-year-value,
.picker-calendar-year-picker .current-year-value {
float: left;
width: 50%;
height: 2.2rem;
}
i.icon {
display: inline-block;
vertical-align: middle;
background-size: 100% auto;
background-position: center;
background-repeat: no-repeat;
font-style: normal;
position: relative;
}
i.icon.icon-next,
i.icon.icon-prev {
width: 0.75rem;
height: 0.75rem;
}
i.icon.icon-next {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2015%2015'%3E%3Cg%3E%3Cpath%20fill%3D'%2304BE02'%20d%3D'M1%2C1.6l11.8%2C5.8L1%2C13.4V1.6%20M0%2C0v15l15-7.6L0%2C0L0%2C0z'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
}
i.icon.icon-prev {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2015%2015'%3E%3Cg%3E%3Cpath%20fill%3D'%2304BE02'%20d%3D'M14%2C1.6v11.8L2.2%2C7.6L14%2C1.6%20M15%2C0L0%2C7.6L15%2C15V0L15%2C0z'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
}
/**
* Swiper 3.3.1
* Most modern mobile touch slider and framework with hardware accelerated transitions
*
* http://www.idangero.us/swiper/
*
* Copyright 2016, Vladimir Kharlampidi
* The iDangero.us
* http://www.idangero.us/
*
* Licensed under MIT
*
* Released on: February 7, 2016
*/
.swiper-container {
margin: 0 auto;
position: relative;
overflow: hidden;
/* Fix of Webkit flickering */
z-index: 1;
}
.swiper-container-no-flexbox .swiper-slide {
float: left;
}
.swiper-container-vertical > .swiper-wrapper {
-webkit-box-orient: vertical;
-ms-flex-direction: column;
flex-direction: column;
}
.swiper-wrapper {
position: relative;
width: 100%;
height: 100%;
z-index: 1;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-transition-property: -webkit-transform;
transition-property: -webkit-transform;
transition-property: transform;
transition-property: transform, -webkit-transform;
box-sizing: content-box;
}
.swiper-container-android .swiper-slide,
.swiper-wrapper {
-webkit-transform: translate3d(0px, 0, 0);
transform: translate3d(0px, 0, 0);
}
.swiper-container-multirow > .swiper-wrapper {
-webkit-box-lines: multiple;
-moz-box-lines: multiple;
-ms-flex-wrap: wrap;
flex-wrap: wrap;
}
.swiper-container-free-mode > .swiper-wrapper {
-webkit-transition-timing-function: ease-out;
transition-timing-function: ease-out;
margin: 0 auto;
}
.swiper-slide {
-webkit-flex-shrink: 0;
-ms-flex: 0 0 auto;
-ms-flex-negative: 0;
flex-shrink: 0;
width: 100%;
height: 100%;
position: relative;
}
/* Auto Height */
.swiper-container-autoheight,
.swiper-container-autoheight .swiper-slide {
height: auto;
}
.swiper-container-autoheight .swiper-wrapper {
-webkit-box-align: start;
-ms-flex-align: start;
align-items: flex-start;
-webkit-transition-property: -webkit-transform, height;
-webkit-transition-property: height, -webkit-transform;
transition-property: height, -webkit-transform;
transition-property: transform, height;
transition-property: transform, height, -webkit-transform;
}
/* a11y */
.swiper-container .swiper-notification {
position: absolute;
left: 0;
top: 0;
pointer-events: none;
opacity: 0;
z-index: -1000;
}
/* IE10 Windows Phone 8 Fixes */
.swiper-wp8-horizontal {
-ms-touch-action: pan-y;
touch-action: pan-y;
}
.swiper-wp8-vertical {
-ms-touch-action: pan-x;
touch-action: pan-x;
}
/* Arrows */
.swiper-button-prev,
.swiper-button-next {
position: absolute;
top: 50%;
width: 27px;
height: 44px;
margin-top: -22px;
z-index: 10;
cursor: pointer;
background-size: 27px 44px;
background-position: center;
background-repeat: no-repeat;
}
.swiper-button-prev.swiper-button-disabled,
.swiper-button-next.swiper-button-disabled {
opacity: 0.35;
cursor: auto;
pointer-events: none;
}
.swiper-button-prev,
.swiper-container-rtl .swiper-button-next {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M0%2C22L22%2C0l2.1%2C2.1L4.2%2C22l19.9%2C19.9L22%2C44L0%2C22L0%2C22L0%2C22z'%20fill%3D'%23007aff'%2F%3E%3C%2Fsvg%3E");
left: 10px;
right: auto;
}
.swiper-button-prev.swiper-button-black,
.swiper-container-rtl .swiper-button-next.swiper-button-black {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M0%2C22L22%2C0l2.1%2C2.1L4.2%2C22l19.9%2C19.9L22%2C44L0%2C22L0%2C22L0%2C22z'%20fill%3D'%23000000'%2F%3E%3C%2Fsvg%3E");
}
.swiper-button-prev.swiper-button-white,
.swiper-container-rtl .swiper-button-next.swiper-button-white {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M0%2C22L22%2C0l2.1%2C2.1L4.2%2C22l19.9%2C19.9L22%2C44L0%2C22L0%2C22L0%2C22z'%20fill%3D'%23ffffff'%2F%3E%3C%2Fsvg%3E");
}
.swiper-button-next,
.swiper-container-rtl .swiper-button-prev {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M27%2C22L27%2C22L5%2C44l-2.1-2.1L22.8%2C22L2.9%2C2.1L5%2C0L27%2C22L27%2C22z'%20fill%3D'%23007aff'%2F%3E%3C%2Fsvg%3E");
right: 10px;
left: auto;
}
.swiper-button-next.swiper-button-black,
.swiper-container-rtl .swiper-button-prev.swiper-button-black {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M27%2C22L27%2C22L5%2C44l-2.1-2.1L22.8%2C22L2.9%2C2.1L5%2C0L27%2C22L27%2C22z'%20fill%3D'%23000000'%2F%3E%3C%2Fsvg%3E");
}
.swiper-button-next.swiper-button-white,
.swiper-container-rtl .swiper-button-prev.swiper-button-white {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M27%2C22L27%2C22L5%2C44l-2.1-2.1L22.8%2C22L2.9%2C2.1L5%2C0L27%2C22L27%2C22z'%20fill%3D'%23ffffff'%2F%3E%3C%2Fsvg%3E");
}
/* Pagination Styles */
.swiper-pagination {
position: absolute;
text-align: center;
-webkit-transition: 300ms;
transition: 300ms;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
z-index: 10;
}
.swiper-pagination.swiper-pagination-hidden {
opacity: 0;
}
/* Common Styles */
.swiper-pagination-fraction,
.swiper-pagination-custom,
.swiper-container-horizontal > .swiper-pagination-bullets {
bottom: 10px;
left: 0;
width: 100%;
}
/* Bullets */
.swiper-pagination-bullet {
width: 8px;
height: 8px;
display: inline-block;
border-radius: 100%;
background: #000;
opacity: 0.2;
}
button.swiper-pagination-bullet {
border: none;
margin: 0;
padding: 0;
box-shadow: none;
-moz-appearance: none;
-ms-appearance: none;
-webkit-appearance: none;
appearance: none;
}
.swiper-pagination-clickable .swiper-pagination-bullet {
cursor: pointer;
}
.swiper-pagination-white .swiper-pagination-bullet {
background: #fff;
}
.swiper-pagination-bullet-active {
opacity: 1;
background: #04BE02;
}
.swiper-pagination-white .swiper-pagination-bullet-active {
background: #fff;
}
.swiper-pagination-black .swiper-pagination-bullet-active {
background: #000;
}
.swiper-container-vertical > .swiper-pagination-bullets {
right: 10px;
top: 50%;
-webkit-transform: translate3d(0px, -50%, 0);
transform: translate3d(0px, -50%, 0);
}
.swiper-container-vertical > .swiper-pagination-bullets .swiper-pagination-bullet {
margin: 5px 0;
display: block;
}
.swiper-container-horizontal > .swiper-pagination-bullets .swiper-pagination-bullet {
margin: 0 5px;
}
/* Progress */
.swiper-pagination-progress {
background: rgba(0, 0, 0, 0.25);
position: absolute;
}
.swiper-pagination-progress .swiper-pagination-progressbar {
background: #007aff;
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 100%;
-webkit-transform: scale(0);
transform: scale(0);
-webkit-transform-origin: left top;
transform-origin: left top;
}
.swiper-container-rtl .swiper-pagination-progress .swiper-pagination-progressbar {
-webkit-transform-origin: right top;
transform-origin: right top;
}
.swiper-container-horizontal > .swiper-pagination-progress {
width: 100%;
height: 4px;
left: 0;
top: 0;
}
.swiper-container-vertical > .swiper-pagination-progress {
width: 4px;
height: 100%;
left: 0;
top: 0;
}
.swiper-pagination-progress.swiper-pagination-white {
background: rgba(255, 255, 255, 0.5);
}
.swiper-pagination-progress.swiper-pagination-white .swiper-pagination-progressbar {
background: #fff;
}
.swiper-pagination-progress.swiper-pagination-black .swiper-pagination-progressbar {
background: #000;
}
/* 3D Container */
.swiper-container-3d {
-webkit-perspective: 1200px;
-o-perspective: 1200px;
perspective: 1200px;
}
.swiper-container-3d .swiper-wrapper,
.swiper-container-3d .swiper-slide,
.swiper-container-3d .swiper-slide-shadow-left,
.swiper-container-3d .swiper-slide-shadow-right,
.swiper-container-3d .swiper-slide-shadow-top,
.swiper-container-3d .swiper-slide-shadow-bottom,
.swiper-container-3d .swiper-cube-shadow {
-webkit-transform-style: preserve-3d;
transform-style: preserve-3d;
}
.swiper-container-3d .swiper-slide-shadow-left,
.swiper-container-3d .swiper-slide-shadow-right,
.swiper-container-3d .swiper-slide-shadow-top,
.swiper-container-3d .swiper-slide-shadow-bottom {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 100%;
pointer-events: none;
z-index: 10;
}
.swiper-container-3d .swiper-slide-shadow-left {
background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0)));
/* Safari 4+, Chrome */
background-image: -webkit-linear-gradient(right, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Chrome 10+, Safari 5.1+, iOS 5+ */
/* Firefox 3.6-15 */
/* Opera 11.10-12.00 */
background-image: linear-gradient(to left, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Firefox 16+, IE10, Opera 12.50+ */
}
.swiper-container-3d .swiper-slide-shadow-right {
background-image: -webkit-gradient(linear, right top, left top, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0)));
/* Safari 4+, Chrome */
background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Chrome 10+, Safari 5.1+, iOS 5+ */
/* Firefox 3.6-15 */
/* Opera 11.10-12.00 */
background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Firefox 16+, IE10, Opera 12.50+ */
}
.swiper-container-3d .swiper-slide-shadow-top {
background-image: -webkit-gradient(linear, left top, left bottom, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0)));
/* Safari 4+, Chrome */
background-image: -webkit-linear-gradient(bottom, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Chrome 10+, Safari 5.1+, iOS 5+ */
/* Firefox 3.6-15 */
/* Opera 11.10-12.00 */
background-image: linear-gradient(to top, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Firefox 16+, IE10, Opera 12.50+ */
}
.swiper-container-3d .swiper-slide-shadow-bottom {
background-image: -webkit-gradient(linear, left bottom, left top, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0)));
/* Safari 4+, Chrome */
background-image: -webkit-linear-gradient(top, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Chrome 10+, Safari 5.1+, iOS 5+ */
/* Firefox 3.6-15 */
/* Opera 11.10-12.00 */
background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
/* Firefox 16+, IE10, Opera 12.50+ */
}
/* Coverflow */
.swiper-container-coverflow .swiper-wrapper,
.swiper-container-flip .swiper-wrapper {
/* Windows 8 IE 10 fix */
-ms-perspective: 1200px;
}
/* Cube + Flip */
.swiper-container-cube,
.swiper-container-flip {
overflow: visible;
}
.swiper-container-cube .swiper-slide,
.swiper-container-flip .swiper-slide {
pointer-events: none;
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
z-index: 1;
}
.swiper-container-cube .swiper-slide .swiper-slide,
.swiper-container-flip .swiper-slide .swiper-slide {
pointer-events: none;
}
.swiper-container-cube .swiper-slide-active,
.swiper-container-flip .swiper-slide-active,
.swiper-container-cube .swiper-slide-active .swiper-slide-active,
.swiper-container-flip .swiper-slide-active .swiper-slide-active {
pointer-events: auto;
}
.swiper-container-cube .swiper-slide-shadow-top,
.swiper-container-flip .swiper-slide-shadow-top,
.swiper-container-cube .swiper-slide-shadow-bottom,
.swiper-container-flip .swiper-slide-shadow-bottom,
.swiper-container-cube .swiper-slide-shadow-left,
.swiper-container-flip .swiper-slide-shadow-left,
.swiper-container-cube .swiper-slide-shadow-right,
.swiper-container-flip .swiper-slide-shadow-right {
z-index: 0;
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
/* Cube */
.swiper-container-cube .swiper-slide {
visibility: hidden;
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
width: 100%;
height: 100%;
}
.swiper-container-cube.swiper-container-rtl .swiper-slide {
-webkit-transform-origin: 100% 0;
transform-origin: 100% 0;
}
.swiper-container-cube .swiper-slide-active,
.swiper-container-cube .swiper-slide-next,
.swiper-container-cube .swiper-slide-prev,
.swiper-container-cube .swiper-slide-next + .swiper-slide {
pointer-events: auto;
visibility: visible;
}
.swiper-container-cube .swiper-cube-shadow {
position: absolute;
left: 0;
bottom: 0px;
width: 100%;
height: 100%;
background: #000;
opacity: 0.6;
-webkit-filter: blur(50px);
filter: blur(50px);
z-index: 0;
}
/* Fade */
.swiper-container-fade.swiper-container-free-mode .swiper-slide {
-webkit-transition-timing-function: ease-out;
transition-timing-function: ease-out;
}
.swiper-container-fade .swiper-slide {
pointer-events: none;
-webkit-transition-property: opacity;
transition-property: opacity;
}
.swiper-container-fade .swiper-slide .swiper-slide {
pointer-events: none;
}
.swiper-container-fade .swiper-slide-active,
.swiper-container-fade .swiper-slide-active .swiper-slide-active {
pointer-events: auto;
}
/* Scrollbar */
.swiper-scrollbar {
border-radius: 10px;
position: relative;
-ms-touch-action: none;
background: rgba(0, 0, 0, 0.1);
}
.swiper-container-horizontal > .swiper-scrollbar {
position: absolute;
left: 1%;
bottom: 3px;
z-index: 50;
height: 5px;
width: 98%;
}
.swiper-container-vertical > .swiper-scrollbar {
position: absolute;
right: 3px;
top: 1%;
z-index: 50;
width: 5px;
height: 98%;
}
.swiper-scrollbar-drag {
height: 100%;
width: 100%;
position: relative;
background: rgba(0, 0, 0, 0.5);
border-radius: 10px;
left: 0;
top: 0;
}
.swiper-scrollbar-cursor-drag {
cursor: move;
}
/* Preloader */
.swiper-lazy-preloader {
width: 42px;
height: 42px;
position: absolute;
left: 50%;
top: 50%;
margin-left: -21px;
margin-top: -21px;
z-index: 10;
-webkit-transform-origin: 50%;
transform-origin: 50%;
-webkit-animation: swiper-preloader-spin 1s steps(12, end) infinite;
animation: swiper-preloader-spin 1s steps(12, end) infinite;
}
.swiper-lazy-preloader:after {
display: block;
content: "";
width: 100%;
height: 100%;
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20viewBox%3D'0%200%20120%20120'%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20xmlns%3Axlink%3D'http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink'%3E%3Cdefs%3E%3Cline%20id%3D'l'%20x1%3D'60'%20x2%3D'60'%20y1%3D'7'%20y2%3D'27'%20stroke%3D'%236c6c6c'%20stroke-width%3D'11'%20stroke-linecap%3D'round'%2F%3E%3C%2Fdefs%3E%3Cg%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(30%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(60%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(90%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(120%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(150%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.37'%20transform%3D'rotate(180%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.46'%20transform%3D'rotate(210%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.56'%20transform%3D'rotate(240%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.66'%20transform%3D'rotate(270%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.75'%20transform%3D'rotate(300%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.85'%20transform%3D'rotate(330%2060%2C60)'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
background-position: 50%;
background-size: 100%;
background-repeat: no-repeat;
}
.swiper-lazy-preloader-white:after {
background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20viewBox%3D'0%200%20120%20120'%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20xmlns%3Axlink%3D'http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink'%3E%3Cdefs%3E%3Cline%20id%3D'l'%20x1%3D'60'%20x2%3D'60'%20y1%3D'7'%20y2%3D'27'%20stroke%3D'%23fff'%20stroke-width%3D'11'%20stroke-linecap%3D'round'%2F%3E%3C%2Fdefs%3E%3Cg%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(30%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(60%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(90%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(120%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(150%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.37'%20transform%3D'rotate(180%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.46'%20transform%3D'rotate(210%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.56'%20transform%3D'rotate(240%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.66'%20transform%3D'rotate(270%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.75'%20transform%3D'rotate(300%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.85'%20transform%3D'rotate(330%2060%2C60)'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
}
@-webkit-keyframes swiper-preloader-spin {
100% {
-webkit-transform: rotate(360deg);
}
}
@keyframes swiper-preloader-spin {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
.weui-actionsheet {
z-index: 10000;
}
.weui-popup__overlay,
.weui-popup__container {
position: fixed;
bottom: 0;
left: 0;
right: 0;
height: 0;
width: 100%;
height: 100%;
z-index: 10;
}
.weui-popup__overlay {
background-color: rgba(0, 0, 0, 0.6);
opacity: 0;
-webkit-transition: opacity .3s;
transition: opacity .3s;
}
.weui-popup__container {
display: none;
}
.weui-popup__container.weui-popup__container--visible {
display: block;
}
.weui-popup__container .weui-cells {
margin: 0;
text-align: left;
}
.weui-popup__modal {
width: 100%;
position: absolute;
z-index: 100;
bottom: 0;
border-radius: 0;
opacity: 0.6;
color: #3d4145;
-webkit-transition-duration: .3s;
transition-duration: .3s;
height: 100%;
background: #EFEFF4;
-webkit-transform: translate3d(0, 100%, 0);
transform: translate3d(0, 100%, 0);
-webkit-transition-property: opacity, -webkit-transform;
transition-property: opacity, -webkit-transform;
transition-property: transform, opacity;
transition-property: transform, opacity, -webkit-transform;
overflow-x: hidden;
overflow-y: auto;
}
.popup-bottom .weui-popup__modal {
height: auto;
}
.weui-popup__modal .toolbar {
position: absolute;
left: 0;
top: 0;
right: 0;
z-index: 1;
}
.weui-popup__modal .modal-content {
height: 100%;
padding-top: 2.2rem;
overflow: auto;
box-sizing: border-box;
}
.weui-popup__container--visible .weui-popup__overlay {
opacity: 1;
}
.weui-popup__container--visible .weui-popup__modal {
opacity: 1;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
.weui-notification {
position: fixed;
width: 100%;
min-height: 3.4rem;
top: -2rem;
padding-top: 2rem;
left: 0;
right: 0;
z-index: 9999;
background-color: rgba(0, 0, 0, 0.85);
color: white;
font-size: .65rem;
-webkit-transform: translate3d(0, -100%, 0);
transform: translate3d(0, -100%, 0);
-webkit-transition: .4s;
transition: .4s;
}
.weui-notification.weui-notification--in {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
.weui-notification.weui-notification--touching {
-webkit-transition-duration: 0s;
transition-duration: 0s;
}
.weui-notification .weui-notification__inner {
padding: .4rem .6rem 1rem .6rem;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: start;
-ms-flex-align: start;
align-items: flex-start;
}
.weui-notification .weui-notification__content {
width: 100%;
margin: 0rem .4rem;
}
.weui-notification .weui-notification__title {
font-weight: bold;
}
.weui-notification .weui-notification__text {
line-height: 1;
}
.weui-notification .weui-notification__media {
height: 1rem;
width: 1rem;
}
.weui-notification .weui-notification__media img {
width: 100%;
}
.weui-notification .weui-notification__handle-bar {
position: absolute;
bottom: .2rem;
left: 50%;
-webkit-transform: translate3d(-50%, 0, 0);
transform: translate3d(-50%, 0, 0);
width: 2rem;
height: .3rem;
border-radius: .15rem;
background: white;
opacity: .5;
}
.weui-photo-browser-modal {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: black;
display: none;
opacity: 0;
-webkit-transition: opacity .3s;
transition: opacity .3s;
}
.weui-photo-browser-modal.weui-photo-browser-modal-visible {
opacity: 1;
}
.weui-photo-browser-modal .swiper-container {
height: 100%;
-webkit-transform: scale(0.2);
transform: scale(0.2);
-webkit-transition: -webkit-transform .5s;
transition: -webkit-transform .5s;
transition: transform .5s;
transition: transform .5s, -webkit-transform .5s;
}
.weui-photo-browser-modal .swiper-container .swiper-pagination-bullet {
background: white;
visibility: hidden;
}
.weui-photo-browser-modal .swiper-container.swiper-container-visible {
-webkit-transform: scale(1);
transform: scale(1);
}
.weui-photo-browser-modal .swiper-container.swiper-container-visible .swiper-pagination-bullet {
visibility: visible;
-webkit-transition-property: visibility;
transition-property: visibility;
-webkit-transition-delay: .5s;
transition-delay: .5s;
}
.weui-photo-browser-modal .swiper-container .swiper-pagination {
bottom: 10px;
left: 0;
width: 100%;
}
.weui-photo-browser-modal .photo-container {
height: 100%;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
overflow: hidden;
}
.weui-photo-browser-modal .photo-container img {
max-width: 100%;
margin-top: -30px;
}
.weui-photo-browser-modal .caption {
position: absolute;
bottom: 40px;
left: 0;
right: 0;
color: white;
text-align: center;
padding: 0 12px;
min-height: 3rem;
font-size: 14px;
z-index: 10;
-webkit-transition: opacity .3s;
transition: opacity .3s;
-webkit-transition-delay: .5s;
transition-delay: .5s;
opacity: 0;
}
.weui-photo-browser-modal .caption .caption-item {
display: none;
opacity: 0;
-webkit-transition: opacity .15s;
transition: opacity .15s;
}
.weui-photo-browser-modal .caption .caption-item.active {
display: block;
opacity: 1;
}
.weui-photo-browser-modal .swiper-container-visible .caption {
opacity: 1;
}
.color-primary {
color: #04BE02;
}
.color-danger,
.color-error {
color: #f6383a;
}
.color-warning {
color: #f60;
}
.color-success {
color: #4cd964;
}
.bg-primary,
.bg-success,
.bg-danger,
.bg-error,
.bg-warning {
color: white;
}
.bg-primary {
background-color: #04BE02;
}
.bg-danger,
.bg-error {
background-color: #f6383a;
}
.bg-warning {
background-color: #f60;
}
.bg-success {
background-color: #4cd964;
}
.weui-toptips {
z-index: 100;
opacity: 0;
-webkit-transition: opacity .3s;
transition: opacity .3s;
}
.weui-toptips.weui-toptips_visible {
opacity: 1;
}
.weui-icon_toast {
font-size: 55px;
color: white;
margin-bottom: 6px;
}
.weui-toast--forbidden .weui-icon_toast {
color: #f6383a;
}
.weui-toast--text {
min-height: initial;
font-size: 18px;
padding: 8px 16px;
width: auto;
top: 40%;
}
.weui-toast--text .weui-icon_toast {
display: none;
}
.weui-count {
display: inline-block;
height: 25px;
line-height: 25px;
}
.weui-count .weui-count__btn {
height: 21px;
width: 21px;
line-height: 21px;
display: inline-block;
position: relative;
border: 1px solid #04BE02;
border-radius: 50%;
vertical-align: -6px;
}
.weui-count .weui-count__btn:after,
.weui-count .weui-count__btn:before {
content: " ";
position: absolute;
height: 1px;
width: 11px;
background-color: #04BE02;
left: 50%;
top: 50%;
margin-left: -5.5px;
}
.weui-count .weui-count__btn:after {
height: 11px;
width: 1px;
margin-top: -5.5px;
margin-left: -1px;
}
.weui-count .weui-count__decrease:after {
display: none;
}
.weui-count .weui-count__increase {
background-color: #04BE02;
}
.weui-count .weui-count__increase:after,
.weui-count .weui-count__increase:before {
background-color: white;
}
.weui-count .weui-count__number {
background-color: transparent;
font-size: .8rem;
border: 0;
width: 1.3rem;
text-align: center;
color: #5f646e;
}
.weui-panel .weui-media-box__title-after {
color: #9b9b9b;
font-size: .65rem;
float: right;
}
... ...
/**
* jeDate 演示
*/
var enLang = {
name : "en",
month : ["01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12"],
weeks : [ "SUN","MON","TUR","WED","THU","FRI","SAT" ],
times : ["Hour","Minute","Second"],
timetxt: ["Time","Start Time","End Time"],
backtxt:"Back",
clear : "Clear",
today : "Now",
yes : "Confirm",
close : "Close"
}
//常规选择
// jeDate("#test01",{
// //festival:true,
// //multiPane:false,
// format: "YYYY"
// });
//
// jeDate("#test02",{
// format: "YYYY-MM"
// });
//
// jeDate("#test03",{
// //onClose:false,
//
// format: "MM-DD-YYYY"
// });
jeDate("#test04",{
festival:true,
minDate:"1900-01-01", //最小日期
maxDate:"2099-12-31", //最大日期
method:{
choose:function (params) {
}
},
format: "YYYY-MM-DD hh:mm:ss"
});
// var jds = jeDate("#test05",{
// minDate:"01:02:08", //最小日期
// maxDate:"15:25:35", //最大日期
// format: "hh:mm:ss"
// });
console.log(jds)
//英文语言
// jeDate("#enYMD",{
// language:enLang,
// format: "YYYY-MM-DD"
// });
// jeDate("#enYMDhms",{
// language:enLang,
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#enhms",{
// language:enLang,
// format: "hh:mm:ss"
// });
//自定义主题色
// jeDate("#testblue",{
// theme:{bgcolor:"#00A1CB",pnColor:"#00CCFF"},
// multiPane:false,
// range:" ~ ",
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#testgray",{
// theme:{bgcolor:"#00A680",pnColor:"#00DDAA"},
// multiPane:false,
// range:" ~ ",
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#testred",{
// theme:{bgcolor:"#D91600",pnColor:"#FF6653"},
// multiPane:false,
// range:" ~ ",
// format: "YYYY-MM-DD hh:mm:ss"
// });
//
// //区域范围选择
// jeDate("#test06",{
// format: "YYYY",
// range:" ~ "
// });
// jeDate("#test07",{
// format: "YYYY-MM",
// range:" To "
// });
// jeDate("#test08",{
// format: "YYYY-MM-DD",
// range:" 至 "
// });
//区域范围双面板选择
// var jd = jeDate("#test09",{
// format: "YYYY",
// multiPane:false,
// range:" ~ "
// });
// jeDate("#test10",{
// format: "YYYY-MM",
// multiPane:false,
// range:" To "
// });
// jeDate("#test11",{
// format: "YYYY-MM-DD",
// multiPane:false,
// range:" 至 "
// });
// jeDate("#test11A",{
// format: "YYYY-MM-DD hh:mm:ss",
// multiPane:false,
// range:" 至 "
// });
// jeDate("#test11B",{
// minDate:"03:02:04", //最小日期
// maxDate:"14:30:45",
// format: "hh:mm:ss",
// multiPane:false,
// range:" 至 "
// });
// jeDate("#test11C",{
// format: "hh:mm",
// multiPane:false,
// range:" 至 "
// });
//自定义格式选择
// jeDate("#test12",{
// format: "YYYY年MM月DD日"
// });
// jeDate("#test13",{
// format: "MM-DD-YYYY"
// });
// jeDate("#test14",{
// format: "DD/MM/YYYY"
// });
//一次绑定多个选择
// var jel = document.querySelectorAll(".moredate");
// for(var j=0;j<jel.length;j++){
// var mat = jel[j].getAttribute("placeholder");
// jeDate(jel[j],{
// format: mat
// });
// }
//
// //一次绑定多个选择DIV类型
// var divel = document.querySelectorAll(".divmore");
// for(var j=0;j<divel.length;j++){
// var divmat = divel[j].getAttribute("placeholder");
// jeDate(divel[j],{
// format: divmat
// });
// }
//
// //左边多类选择
// jeDate("#short",{
// format:"YYYY-MM-DD",
// shortcut:[
// {name:"一周",val:{DD:7}},
// {name:"一个月",val:{DD:30}},
// {name:"二个月",val:{MM:2}},
// {name:"三个月",val:{MM:3}},
// {name:"一年",val:{DD:365}}
// ],
// donefun:function (obj) {
// //alert(jeDate.getLunar(obj.date[0]).cW);
// }
// });
// jeDate("#shortboth",{
// format:"YYYY-MM-DD",
// isinitVal: true,
// range:" TO ",
// multiPane:false,
// shortcut:[
// {name:"一周",val:{DD:7}},
// {name:"一个月",val:{DD:30}},
// {name:"二个月",val:{MM:2}},
// {name:"三个月",val:{MM:3}},
// {name:"一年",val:{DD:365}}
// ],
// donefun:function (obj) {
// //var bs = {yy:123,dd:789}
// console.log(jeDate.extend({yy:123,dd:789},{yy:"you",aa:456}))
// //alert(jeDate.getLunar(obj.date[0]).cW);
// }
// });
//
// //YYYYMMDD格式
// jeDate("#dateymd",{
// format: "YYYYMMDD"
// });
// jeDate("#dateymdboth",{
// format: "YYYYMMDD",
// multiPane:false,
// range:" 至 "
// });
//
//
// //其它功能展示选择
// jeDate("#test15",{
// format: "YYYY-MM-DD",
// isinitVal: true
// });
// jeDate("#test16",{
// format: "YYYY-MM-DD",
// donefun:function (obj) {
// alert('你选择的日期是:' + obj.val)
// }
// });
// jeDate("#test17",{
// format: "YYYY-MM-DD",
// toggle:function (obj) {
// alert('你选择的日期是:' + obj.val + '\n\n获得的对象是' + JSON.stringify(obj.date));
// }
// });
// jeDate("#test18",{
// trigger:"dblclick",
// format: "YYYY-MM-DD"
// });
// var custom = jeDate("#test19",{
// format: "YYYY-MM-DD"
// }).setValue("2018-09-01");
// //或者 custom.setValue("2018-09-01");
//
// //有效、无效日期限制
// jeDate("#test20",{
// valiDate:["0[4-7]$,1[1-5]$,2[58]$",true],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test21",{
// valiDate:["0[4-7]$,1[1-5]$,2[58]$",false],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test22",{
// valiDate:["1$,3$,6$,9$",true],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test23",{
// valiDate:["1$,3$,6$,9$",false],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test24",{
// valiDate:["%1,%3,%6,%9,%12,%15,%25",true],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test25",{
// valiDate:["%1,%3,%6,%9,%12,%15,%25",false],
// format: "YYYY年MM月DD日"
// });
//
// //直接展示日历
// jeDate("#show01",{
// isShow:false,
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#show02",{
// isShow:false,
// format: "YYYY-MM"
// });
// jeDate("#show03",{
// isShow:false,
// format: "YYYY"
// });
// jeDate("#show04",{
// isShow:false,
// format: "hh:mm:ss"
// });
... ...
/**
* jeDate 演示
*/
var enLang = {
name : "en",
month : ["01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12"],
weeks : [ "SUN","MON","TUR","WED","THU","FRI","SAT" ],
times : ["Hour","Minute","Second"],
timetxt: ["Time","Start Time","End Time"],
backtxt:"Back",
clear : "Clear",
today : "Now",
yes : "Confirm",
close : "Close"
}
//常规选择
// jeDate("#test01",{
// //festival:true,
// //multiPane:false,
// format: "YYYY"
// });
//
// jeDate("#test02",{
// format: "YYYY-MM"
// });
//
// jeDate("#test03",{
// //onClose:false,
//
// format: "MM-DD-YYYY"
// });
jeDate("#test04",{
festival:true,
minDate:"1900-01-01", //最小日期
maxDate:"2099-12-31", //最大日期
method:{
choose:function (params) {
}
},
format: "YYYY-MM-DD hh:mm:ss"
});
// var jds = jeDate("#test05",{
// minDate:"01:02:08", //最小日期
// maxDate:"15:25:35", //最大日期
// format: "hh:mm:ss"
// });
console.log(jds)
//英文语言
// jeDate("#enYMD",{
// language:enLang,
// format: "YYYY-MM-DD"
// });
// jeDate("#enYMDhms",{
// language:enLang,
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#enhms",{
// language:enLang,
// format: "hh:mm:ss"
// });
//自定义主题色
// jeDate("#testblue",{
// theme:{bgcolor:"#00A1CB",pnColor:"#00CCFF"},
// multiPane:false,
// range:" ~ ",
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#testgray",{
// theme:{bgcolor:"#00A680",pnColor:"#00DDAA"},
// multiPane:false,
// range:" ~ ",
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#testred",{
// theme:{bgcolor:"#D91600",pnColor:"#FF6653"},
// multiPane:false,
// range:" ~ ",
// format: "YYYY-MM-DD hh:mm:ss"
// });
//
// //区域范围选择
// jeDate("#test06",{
// format: "YYYY",
// range:" ~ "
// });
// jeDate("#test07",{
// format: "YYYY-MM",
// range:" To "
// });
// jeDate("#test08",{
// format: "YYYY-MM-DD",
// range:" 至 "
// });
//区域范围双面板选择
// var jd = jeDate("#test09",{
// format: "YYYY",
// multiPane:false,
// range:" ~ "
// });
// jeDate("#test10",{
// format: "YYYY-MM",
// multiPane:false,
// range:" To "
// });
// jeDate("#test11",{
// format: "YYYY-MM-DD",
// multiPane:false,
// range:" 至 "
// });
// jeDate("#test11A",{
// format: "YYYY-MM-DD hh:mm:ss",
// multiPane:false,
// range:" 至 "
// });
// jeDate("#test11B",{
// minDate:"03:02:04", //最小日期
// maxDate:"14:30:45",
// format: "hh:mm:ss",
// multiPane:false,
// range:" 至 "
// });
// jeDate("#test11C",{
// format: "hh:mm",
// multiPane:false,
// range:" 至 "
// });
//自定义格式选择
// jeDate("#test12",{
// format: "YYYY年MM月DD日"
// });
// jeDate("#test13",{
// format: "MM-DD-YYYY"
// });
// jeDate("#test14",{
// format: "DD/MM/YYYY"
// });
//一次绑定多个选择
// var jel = document.querySelectorAll(".moredate");
// for(var j=0;j<jel.length;j++){
// var mat = jel[j].getAttribute("placeholder");
// jeDate(jel[j],{
// format: mat
// });
// }
//
// //一次绑定多个选择DIV类型
// var divel = document.querySelectorAll(".divmore");
// for(var j=0;j<divel.length;j++){
// var divmat = divel[j].getAttribute("placeholder");
// jeDate(divel[j],{
// format: divmat
// });
// }
//
// //左边多类选择
// jeDate("#short",{
// format:"YYYY-MM-DD",
// shortcut:[
// {name:"一周",val:{DD:7}},
// {name:"一个月",val:{DD:30}},
// {name:"二个月",val:{MM:2}},
// {name:"三个月",val:{MM:3}},
// {name:"一年",val:{DD:365}}
// ],
// donefun:function (obj) {
// //alert(jeDate.getLunar(obj.date[0]).cW);
// }
// });
// jeDate("#shortboth",{
// format:"YYYY-MM-DD",
// isinitVal: true,
// range:" TO ",
// multiPane:false,
// shortcut:[
// {name:"一周",val:{DD:7}},
// {name:"一个月",val:{DD:30}},
// {name:"二个月",val:{MM:2}},
// {name:"三个月",val:{MM:3}},
// {name:"一年",val:{DD:365}}
// ],
// donefun:function (obj) {
// //var bs = {yy:123,dd:789}
// console.log(jeDate.extend({yy:123,dd:789},{yy:"you",aa:456}))
// //alert(jeDate.getLunar(obj.date[0]).cW);
// }
// });
//
// //YYYYMMDD格式
// jeDate("#dateymd",{
// format: "YYYYMMDD"
// });
// jeDate("#dateymdboth",{
// format: "YYYYMMDD",
// multiPane:false,
// range:" 至 "
// });
//
//
// //其它功能展示选择
// jeDate("#test15",{
// format: "YYYY-MM-DD",
// isinitVal: true
// });
// jeDate("#test16",{
// format: "YYYY-MM-DD",
// donefun:function (obj) {
// alert('你选择的日期是:' + obj.val)
// }
// });
// jeDate("#test17",{
// format: "YYYY-MM-DD",
// toggle:function (obj) {
// alert('你选择的日期是:' + obj.val + '\n\n获得的对象是' + JSON.stringify(obj.date));
// }
// });
// jeDate("#test18",{
// trigger:"dblclick",
// format: "YYYY-MM-DD"
// });
// var custom = jeDate("#test19",{
// format: "YYYY-MM-DD"
// }).setValue("2018-09-01");
// //或者 custom.setValue("2018-09-01");
//
// //有效、无效日期限制
// jeDate("#test20",{
// valiDate:["0[4-7]$,1[1-5]$,2[58]$",true],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test21",{
// valiDate:["0[4-7]$,1[1-5]$,2[58]$",false],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test22",{
// valiDate:["1$,3$,6$,9$",true],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test23",{
// valiDate:["1$,3$,6$,9$",false],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test24",{
// valiDate:["%1,%3,%6,%9,%12,%15,%25",true],
// format: "YYYY年MM月DD日"
// });
// jeDate("#test25",{
// valiDate:["%1,%3,%6,%9,%12,%15,%25",false],
// format: "YYYY年MM月DD日"
// });
//
// //直接展示日历
// jeDate("#show01",{
// isShow:false,
// format: "YYYY-MM-DD hh:mm:ss"
// });
// jeDate("#show02",{
// isShow:false,
// format: "YYYY-MM"
// });
// jeDate("#show03",{
// isShow:false,
// format: "YYYY"
// });
// jeDate("#show04",{
// isShow:false,
// format: "hh:mm:ss"
// });
... ...
/**
@Name : jeDate v6.5.0 日期控件
@Author: chen guojun
@Date: 2018-04-30
@QQ群:516754269
@官网:http://www.jemui.com/ 或 https://github.com/singod/jeDate
*/
;(function(window, factory) {
//amd
if (typeof define === 'function' && define.amd) {
define(factory);
} else if (typeof exports === 'object') { //umd
module.exports = factory();
} else {
window.jeDate = factory();
}
})(this, function() {
var doc = document, win = window;
var jet = {}, doc = document, regymdzz = "YYYY|MM|DD|hh|mm|ss|zz", gr = /\-/g,
regymd = "YYYY|MM|DD|hh|mm|ss|zz".replace("|zz",""), parseInt = function (n) { return window.parseInt(n, 10);};
var $Q = function (selector,content) {
content = content || document;
return selector.nodeType ? selector : content.querySelector(selector);
};
var jeDate = function(elem,options){
var opts = typeof (options) === "function" ? options() : options;
return new jeDatePick(elem,opts);
};
//日期控件版本
jeDate.dateVer = "V6.5.0";
//用一个或多个其他对象来扩展一个对象,返回被扩展的对象
jeDate.extend = jet.extend = function () {
var options, name, src, copy,deep = false, target = arguments[0], i = 1, length = arguments.length;
if (typeof (target) === "boolean") deep = target, target = arguments[1] || {}, i = 2;
if (typeof (target) !== "object" && typeof (target) !== "function") target = {};
if (length === i) target = this, --i;
for (; i < length; i++) {
if ((options = arguments[i]) != null) {
for (name in options) {
src = target[name], copy = options[name];
if (target === copy) continue;
if (copy !== undefined) target[name] = copy;
}
}
}
return target;
};
//返回指定日期
jeDate.nowDate = function (val,format) {
format = format || 'YYYY-MM-DD hh:mm:ss';
if (!isNaN(val)) val = {DD: val};
return jet.parse(jet.getDateTime(val),format);
};
//日期转换
jeDate.convert = function (obj) {
obj.format = obj.format || 'YYYY-MM-DD hh:mm:ss';
obj.addval = obj.addval || [];
var mats = jet.reMatch(obj.format),objVal = {};
jet.each(jet.reMatch(obj.val),function (i,cval) {
objVal[mats[i]] = parseInt(cval);
});
var result = new DateTime(obj.addval,objVal), redate = {
YYYY:result.GetYear(), MM:result.GetMonth(), DD:result.GetDate(),
hh:result.GetHours(), mm:result.GetMinutes(), ss:result.GetSeconds()
};
return redate;
};
jeDate.valText = function (elem,value) {
return jet.valText(elem,value);
}
//日期时间戳相互转换
jeDate.timeStampDate = function (date,format) {
format = format || 'YYYY-MM-DD hh:mm:ss';
var dateTest = (/^(-)?\d{1,10}$/.test(date) || /^(-)?\d{1,13}$/.test(date));
if(/^[1-9]*[1-9][0-9]*$/.test(date) && dateTest){
var vdate = parseInt(date);
if (/^(-)?\d{1,10}$/.test(vdate)) {
vdate = vdate * 1000;
} else if (/^(-)?\d{1,13}$/.test(vdate)) {
vdate = vdate * 1000;
} else if (/^(-)?\d{1,14}$/.test(vdate)) {
vdate = vdate * 100;
} else {
alert("时间戳格式不正确");
return;
}
var setdate = new Date(vdate);
return jet.parse({
YYYY:setdate.getFullYear(), MM:jet.digit(setdate.getMonth()+1), DD:jet.digit(setdate.getDate()) ,
hh:jet.digit(setdate.getHours()), mm:jet.digit(setdate.getMinutes()), ss:jet.digit(setdate.getSeconds())
}, format);
}else {
//将日期转换成时间戳
var arrs = jet.reMatch(date),
newdate = new Date(arrs[0],arrs[1]-1,arrs[2],arrs[3]||0,arrs[4]||0,arrs[5]||0),
timeStr = Math.round(newdate.getTime() / 1000);
return timeStr;
}
};
//获取年月日星期
jeDate.getLunar = function(obj){
//如果为数字类型的日期对获取到日期的进行替换
var lunars = jeLunar(obj.YYYY, parseInt(obj.MM) - 1, obj.DD);
return{
nM: lunars.lnongMonth, //农历月
nD: lunars.lnongDate, //农历日
cY: parseInt(lunars.solarYear), //阳历年
cM: parseInt(lunars.solarMonth), //阳历月
cD: parseInt(lunars.solarDate), //阳历日
cW: lunars.inWeekDays, //汉字星期几
nW: lunars.solarWeekDay //数字星期几
};
};
//转换日期格式
jeDate.parse = jet.parse = function(ymdhms, format) {
return format.replace(new RegExp(regymdzz,"g"), function(str, index) {
return str == "zz" ? "00":jet.digit(ymdhms[str]);
});
}
//返回日期
function DateTime(arr,valObj) {
var that = this,newdate = new Date(), narr = ["FullYear","Month","Date","Hours","Minutes","Seconds"];
var vb = jet.extend({YYYY:null,MM:null,DD:null,hh:newdate.getHours(),mm:newdate.getMinutes(),ss:newdate.getSeconds()},valObj);
var ND = valObj == undefined ? newdate : new Date(vb.YYYY,vb.MM,vb.DD,vb.hh,vb.mm,vb.ss);
if((arr||[]).length>0) jet.each(arr,function (i,par) {
ND["set"+narr[i]](narr[i] == "Month" ? parseInt(par)-1:parseInt(par));
});
//返回一个数值相同的新DateTime对象
that.reDate = function () {
return new DateTime();
};
//返回此实例的Date值
that.GetValue = function () {
return ND;
};
//获取此实例所表示日期的年份部分。
that.GetYear = function () {
return ND.getFullYear();
};
//获取此实例所表示日期的月份部分。
that.GetMonth = function () {
return ND.getMonth() + 1;
};
//获取此实例所表示的日期为该月中的第几天。
that.GetDate = function () {
return ND.getDate();
};
//获取此实例所表示日期的小时部分。
that.GetHours = function () {
return ND.getHours();
};
//获取此实例所表示日期的分钟部分。
that.GetMinutes = function () {
return ND.getMinutes();
};
//获取此实例所表示日期的秒部分。
that.GetSeconds = function () {
return ND.getSeconds();
};
};
jet.extend(jet,{
isType : function (obj,type) {
var firstUper = function (str) {
str = str.toLowerCase();
return str.replace(/\b(\w)|\s(\w)/g, function (m) {
return m.toUpperCase();
});
}
return Object.prototype.toString.call(obj) == "[object " + firstUper(type) + "]";
},
each : function (obj, callback, args) {
var name, i = 0, length = obj.length, iselem = (length === undefined || obj === "function");
if (iselem) {
for (name in obj) { if (callback.call(obj[name], name, obj[name]) === false) { break } }
} else {
for (; i < length;) { if (callback.call(obj[i], i, obj[i++]) === false) { break } }
}
return obj;
},
on : function (elm, type, fn) {
if (elm.addEventListener) {
elm.addEventListener(type, fn, false);//DOM2.0
return true;
}else if (elm.attachEvent) {
return elm.attachEvent("on" + type, fn);//IE5+
}else {
elm["on" + type] = fn;//DOM 0
}
},
isObj : function (obj){
for(var i in obj){return true;}
return false;
},
trim : function (str){ return str.replace(/(^\s*)|(\s*$)/g, ""); },
reMatch : function (str) {
var smarr = [],maStr = "", parti = /(^\w{4}|\w{2}\B)/g;
if(jet.isNum(str)){
maStr = str.replace(parti,"$1-");
}else{
maStr = /^[A-Za-z]+$/.test(str) ? str.replace(parti,"$1-") : str;
}
jet.each(maStr.match(/\w+|d+/g),function (i,val) {
smarr.push(jet.isNum(val) ? parseInt(val):val);
});
return smarr;
},
equals : function (arrA,arrB) {
if (!arrB) return false;
if (arrA.length != arrB.length) return false;
for (var i = 0, l = arrA.length; i < l; i++) {
if (arrA[i] instanceof Array && arrB[i] instanceof Array) {
if (!arrA[i].equals(arrB[i])) return false;
} else if (arrA[i] != arrB[i]) {
return false;
}
}
return true;
},
docScroll : function(type) {
type = type ? "scrollLeft" :"scrollTop";
return document.body[type] | document.documentElement[type];
},
docArea : function(type) {
return document.documentElement[type ? "clientWidth" :"clientHeight"];
},
//补齐数位
digit : function(num) {
return num < 10 ? "0" + (num | 0) :num;
},
//判断是否为数字
isNum : function(value){
return /^[+-]?\d*\.?\d*$/.test(value) ? true : false;
},
//获取本月的总天数
getDaysNum : function(y, m) {
var num = 31,isLeap = (y % 100 !== 0 && y % 4 === 0) || (y % 400 === 0);
switch (parseInt(m)) {
case 2: num = isLeap ? 29 : 28; break;
case 4: case 6: case 9: case 11: num = 30; break;
}
return num;
},
//获取月与年
getYM : function(y, m, n) {
var nd = new Date(y, m - 1);
nd.setMonth(m - 1 + n);
return {
y: nd.getFullYear(),
m: nd.getMonth() + 1
};
},
//获取上个月
prevMonth : function(y, m, n) {
return jet.getYM(y, m, 0 - (n || 1));
},
//获取下个月
nextMonth : function(y, m, n) {
return jet.getYM(y, m, n || 1);
},
setCss:function(elem,obj) {
for (var x in obj) elem.style[x] = obj[x];
},
html : function (elem,html) {
return typeof html === "undefined" ? elem && elem.nodeType === 1 ? elem.innerHTML :undefined :typeof html !== "undefined" && html == true ? elem && elem.nodeType === 1 ? elem.outerHTML :undefined : elem.innerHTML = html;
},
// 读取设置节点文本内容
text : function(elem,value) {
var innText = document.all ? "innerText" :"textContent";
return typeof value === "undefined" ? elem && elem.nodeType === 1 ? elem[innText] :undefined : elem[innText] = value;
},
//设置值
val : function (elem,value) {
if (typeof value === "undefined") {
return elem && elem.nodeType === 1 && typeof elem.value !== "undefined" ? elem.value :undefined;
}
// 将value转化为string
value = value == null ? "" :value + "";
elem.value = value;
},
attr : function(elem,value){
return elem.getAttribute(value);
},
hasClass : function (obj, cls) {
return obj.className.match(new RegExp('(\\s|^)' + cls + '(\\s|$)'));
},
stopPropagation : function (ev) {
(ev && ev.stopPropagation) ? ev.stopPropagation() : window.event.cancelBubble = true;
},
template : function (str, data) {
var strCell = !/[^\w\-\.:]/.test(str) ? document.getElementById(str).innerHTML : str;
var keys = function (obj){
var arr = [];
for(arr[arr.length] in obj);
return arr ;
}, dataVar = function (obj) {
var vars = '';
for (var key in obj) {
vars += 'var ' + key + '= $D["' + key + '"];';
}
return vars;
}, compile = function (source,data) {
var code = "var $out='" + source.replace(/[\r\n]/g, '').replace(/^(.+?)\{\%|\%\}(.+?)\{\%|\%\}(.+?)$/g, function (val) {
return val.replace(/(['"])/g, '\\\$1');
}).replace(/\{\%\s*=\s*(.+?)\%\}/g, "';$out+=$1;$out+='").replace(/\{\%(.+?)\%\}/g, "';$1;$out+='") + "';return new String($out);";
var vars = dataVar(data), Render = new Function('$D',vars + code);
return new Render(data) + '';
};
return compile(strCell,data);
},
//判断元素类型
isValDiv : function(elem) {
return /textarea|input/.test(elem.tagName.toLocaleLowerCase());
},
valText : function (elem,value) {
var cell = $Q(elem) ,type = jet.isValDiv(cell) ? "val" : "text";
if(value != undefined){
jet[type](cell,value);
}else{
return jet[type](cell);
}
},
isBool : function(obj){ return (obj == undefined || obj == true ? true : false); },
//获取返回的日期
getDateTime : function (obj) {
var result = new DateTime(), objVal = jet.extend({YYYY:null,MM:null,DD:null,hh:0,mm:0,ss:0},obj),
matArr = {YYYY:"FullYear",MM:"Month",DD:"Date",hh:"Hours",mm:"Minutes",ss:"Seconds"};
jet.each(["ss","mm","hh","DD","MM","YYYY"],function (i,mat) {
if (!jet.isNum(parseInt(objVal[mat]))) return null;
var reVal = result.GetValue();
if (parseInt(objVal[mat]) || parseInt(objVal[mat]) == 0){
reVal["set"+matArr[mat]](result["Get"+matArr[mat]]() + (mat == "MM" ? -1 : 0) + parseInt(objVal[mat]));
}
});
//获取格式化后的日期
var redate = {
YYYY:result.GetYear(), MM:result.GetMonth(), DD:result.GetDate(),
hh:result.GetHours(), mm:result.GetMinutes(), ss:result.GetSeconds()
};
return redate;
}
});
function jeDatePick(elem, options){
var config = {
language:{
name : "cn",
month : ["01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12"],
weeks : [ "日", "一", "二", "三", "四", "五", "六" ],
times : ["小时","分钟","秒数"],
timetxt: ["时间选择","开始时间","结束时间"],
backtxt:"返回日期",
clear : "清空",
today : "现在",
yes : "确定"
},
format:"YYYY-MM-DD hh:mm:ss", //日期格式
minDate:"1900-01-01 00:00:00", //最小日期
maxDate:"2099-12-31 23:59:59", //最大日期
isShow:true, //是否显示为固定日历,为false的时候固定显示
multiPane:true, //是否为双面板,为false是展示双面板
onClose:true, //是否为选中日期后关闭弹层,为false时选中日期后关闭弹层
range:false, //如果不为空且不为false,则会进行区域选择,例如 " 至 "," ~ "," To "
trigger:"click", //是否为内部触发事件,默认为内部触发事件
position:[], //自定义日期弹层的偏移位置,长度为0,弹层自动查找位置
valiDate:[], //有效日期与非有效日期,例如 ["0[4-7]$,1[1-5]$,2[58]$",true]
isinitVal:false, //是否初始化时间,默认不初始化时间
initDate:{}, //初始化时间,加减 天 时 分
isTime:true, //是否开启时间选择
isClear:true, //是否显示清空按钮
isToday:true, //是否显示今天或本月按钮
isYes:true, //是否显示确定按钮
festival:false, //是否显示农历节日
fixed:true, //是否静止定位,为true时定位在输入框,为false时居中定位
zIndex:2099, //弹出层的层级高度
method:{}, //自定义方法
theme:{}, //自定义主题色
shortcut:[], //日期选择的快捷方式
donefun:null, //选中日期完成的回调
before:null, //在界面加载之前执行
succeed:null //在界面加载之后执行
};
this.$opts = jet.extend(config,options||{});
this.valCell = $Q(elem);
this.format = this.$opts.format;
this.valCell != null ? this.init() : alert(elem+" ID\u6216\u7C7B\u540D\u4E0D\u5B58\u5728!");
jet.extend(this,this.$opts.method);
delete this.$opts.method;
}
var searandom = function (){
var str = "",arr = [1,2,3,4,5,6,7,8,9,0];
for(var i=0; i<8; i++) str += arr[Math.round(Math.random() * (arr.length-1))];
return str;
};
var jefix = "jefixed",ymdzArr = jet.reMatch(regymdzz),elx = "#jedate";
jet.extend(jeDatePick.prototype,{
init : function () {
var that = this, opts = that.$opts, newDate = new Date(), shortArr = [],
trigges = opts.trigger,ndate = opts.initDate || [], inVal, range = opts.range,
zIndex = opts.zIndex == undefined ? 10000 : opts.zIndex,isShow = jet.isBool(opts.isShow),
isinitVal = (opts.isinitVal == undefined || opts.isinitVal == false) ? false : true;
that.setDatas();
opts.before && opts.before(that.valCell);
//为开启初始化的时间设置值
if (isinitVal && trigges && isShow) {
if (ndate[1]){
var addval = jet.getDateTime(ndate[0]);
inVal = [{
YYYY:addval.YYYY, MM:jet.digit(addval.MM), DD:jet.digit(addval.DD) ,
hh:jet.digit(addval.hh), mm:jet.digit(addval.mm), ss:jet.digit(addval.ss)
}];
}else {
inVal = that.getValue(jet.isObj(ndate[0]) ? ndate[0] : {});
}
if(!range) that.setValue([inVal[0]],opts.format,true);
}
var getCurrValue = function () {
var mats = jet.reMatch(that.format), isEmpty = that.getValue() != "",curVal = [],
parmat = that.dlen == 7 ? "hh:mm:ss" : "YYYY-MM"+ (that.dlen <= 2 ? "":"-DD");
that.selectValue = [jet.parse(jet.getDateTime({}), parmat)];
if(isEmpty && isShow){
var getVal = that.getValue().split(range);
jet.each(new Array(range ? 2 : 1),function (a) {
curVal[a] = {};
jet.each(jet.reMatch(getVal[a]),function (i,val) {
curVal[a][mats[i]] = parseInt(val);
});
});
if(range) that.selectValue = getVal;
}else{
var parr = that.getValue({})[0], nmVal = jet.nextMonth(parr.YYYY,parr.MM||jet.getDateTime({}).MM),
narr = (that.dlen>2 && that.dlen <=6) ? {YYYY:nmVal.y,MM:nmVal.m} : {};
curVal = [parr];
}
that.selectDate = curVal;
return curVal;
},ymarr = [];
that.minDate = ""; that.maxDate = "";
if(!isShow || !trigges) ymarr = getCurrValue();
if(!isShow || !trigges){
that.minDate = jet.isType(opts.minDate,"function") ? opts.minDate(that) : opts.minDate;
that.maxDate = jet.isType(opts.maxDate,"function") ? opts.maxDate(that) : opts.maxDate;
that.storeData(ymarr[0],ymarr[1]);
that.renderDate();
opts.succeed && opts.succeed(that.dateCell);
}else{
if (trigges) {
jet.on(that.valCell,trigges,function(){
if (document.querySelectorAll(elx).length > 0) return;
var gvarr = getCurrValue();
that.minDate = jet.isType(opts.minDate,"function") ? opts.minDate(that) : opts.minDate;
that.maxDate = jet.isType(opts.maxDate,"function") ? opts.maxDate(that) : opts.maxDate;
that.storeData(gvarr[0],gvarr[1]);
that.renderDate();
});
}
}
},
setDatas : function(){
var that = this, opts = that.$opts,range = opts.range,shortArr = [],isShow = jet.isBool(opts.isShow),multi = opts.multiPane;
that.$data = jet.extend({year:false,month:false,day:true,time:false,timebtn:false},{
shortcut:[],lang:opts.language,yaerlist:[],monthlist:[[],[]],ymlist:[[],[]], daylist:[[],[]],
clear:opts.isClear,today:range ? false:opts.isToday,yes:opts.isYes,pane:multi ? 1:2
});
if(opts.shortcut.length>0){
jet.each(opts.shortcut,function (i,short) {
var tarr = [], shval = jet.isType(short.val,"function") ? short.val() : short.val;
if(jet.isType(shval,"object")){
for (var s in shval) tarr.push(s + ':' + shval[s]);
shortArr.push(jet.extend({},{name:short.name,val:"{" + tarr.join('#') + "}"}));
}
});
that.$data.shortcut = shortArr;
}
that.dlen = (function () {
var mats = jet.reMatch(that.format),marr = [];
jet.each(ymdzArr,function(i,val){
jet.each(mats,function(m,mval){
if(val == mval) marr.push(mval);
});
});
var matlen = marr.length, lens = (marr[0] == "hh")&&matlen<=3 ? 7 : matlen;
return lens;
})();
that.$data.dlen = that.dlen;
that.timeInspect = false;
if(that.dlen == 1){
jet.extend(that.$data,{year:true,day:false});
}else if(that.dlen == 2){
jet.extend(that.$data,{month:true,day:false});
}else if(that.dlen>3 && that.dlen <=6){
that.$data.timebtn = true;
}else if(that.dlen == 7){
jet.extend(that.$data,{day:false,time:true});
}
if(!isShow){
that.$data.clear = false;
that.$data.yes = false;
}
},
renderDate : function () {
var that= this, opts = that.$opts,isShow = jet.isBool(opts.isShow),
elxID = !isShow ? elx+searandom() : elx, setzin = {"zIndex": (opts.zIndex == undefined ? 10000 : opts.zIndex)};
if(that.dateCell == undefined){
that.dateCell = document.createElement("div");
that.dateCell.id = elxID.replace(/\#/g,"");
that.dateCell.className = elx.replace(/\#/g,"")+" "+(opts.shortcut.length>0?" leftmenu":"");
that.dateCell.setAttribute("author","chen guojun");
}
jet.html(that.dateCell,jet.template(that.dateTemplate(),that.$data));
//自定义主题色
if(jet.isObj(opts.theme)){
var styleDiv = document.createElement("style"),stCell = ".jedate"+searandom(), t = opts.theme,
BG = "background-color:"+t.bgcolor, WC = "color:"+(t.color == undefined ? "#FFFFFF":t.color),
OTH = (t.pnColor == undefined ? "":"color:"+t.pnColor+";");
that.dateCell.className = that.dateCell.className+" "+stCell.replace(/^./g,""); styleDiv.setAttribute("type","text/css");
styleDiv.innerHTML = stCell+" .jedate-menu p:hover{"+BG+";"+WC+";}"+stCell+" .jedate-header em{"+WC+";}"+
stCell+" .jedate-content .yeartable td.action span,"+stCell+" .jedate-content .monthtable td.action span,"+
stCell+" .jedate-content .yeartable td.action span:hover,"+stCell+" .jedate-content .monthtable td.action span:hover{"+BG+";border:1px "+t.bgcolor+" solid;"+WC+";}"+stCell+" .jedate-content .daystable td.action,"+stCell+" .jedate-content .daystable td.action:hover,"+
stCell+" .jedate-content .daystable td.action .lunar,"+stCell+" .jedate-header,"+stCell+" .jedate-time .timeheader,"+
stCell+" .jedate-time .hmslist ul li.action,"+stCell+" .jedate-time .hmslist ul li.action:hover,"+
stCell+" .jedate-time .hmslist ul li.disabled.action,"+stCell+" .jedate-footbtn .timecon,"+stCell+" .jedate-footbtn .btnscon span{"+BG+";"+WC+";}"+
stCell+" .jedate-content .daystable td.other,"+stCell+" .jedate-content .daystable td.other .nolunar,"+stCell+" .jedate-content .daystable td.other .lunar{"+OTH+"}"+stCell+" .jedate-content .daystable td.contain,"+stCell+" .jedate-content .daystable td.contain:hover{background-"+OTH+"}";
that.dateCell.appendChild(styleDiv);
}
that.compileBindNode(that.dateCell);
if (document.querySelectorAll(elxID).length > 0) document.body.removeChild($Q(elxID));
!isShow ? that.valCell.appendChild(that.dateCell) : document.body.appendChild(that.dateCell);
jet.setCss(that.dateCell,jet.extend({position:(!isShow ? "relative" : (opts.fixed == true ? "absolute" :"fixed"))},isShow ? setzin:{}));
that.methodEventBind();
if(that.dlen == 7 || (that.dlen>3 && that.dlen <=6)) that.locateScroll();
if(opts.festival && opts.language.name == "cn") that.showFestival();
if(isShow){
that.dateOrien(that.dateCell,that.valCell);
that.blankArea();
}
},
//设置日期值
setValue : function (fnStr,matStr,bool) {
var that = this, valCell = that.valCell,strVal;
matStr = matStr || that.format;
if((typeof fnStr=='string')&&fnStr!=''){
var sprange = fnStr.split(that.$opts.range), inArr=[];
jet.each(sprange,function (i,sval) {
var reVal = jet.reMatch(sval), inObj={};
jet.each(jet.reMatch(matStr),function (r,val) {
inObj[val] = reVal[r];
});
inArr.push(inObj);
});
strVal = inArr;
}else {
strVal = fnStr;
}
var vals = that.parseValue(strVal,matStr);
if (bool != false) jet.valText(valCell,vals);
return vals;
},
//获取日期值
getValue : function (valobj) {
var that = this, valCell = that.valCell,
opts = that.$opts, reObj, result = new DateTime().reDate(),
dateY = result.GetYear(),dateM = result.GetMonth(),dateD = result.GetDate(),
timeh = result.GetHours(),timem = result.GetMinutes(),times = result.GetSeconds();
if (valobj == undefined && jet.isBool(opts.isShow)){
reObj = jet.valText(valCell);
}else {
var isValShow = jet.isBool(opts.isShow) ? (jet.valText(valCell) == "") : !jet.isBool(opts.isShow),
objarr = jet.extend({YYYY:null,MM:null,DD:null},valobj||{}),
ranMat = [],newArr = new Array(2),unObj = function (obj) {
return [(objarr[obj] == undefined || objarr[obj] == null),objarr[obj]];
}, defObj = [{ YYYY:dateY,MM:dateM,DD:dateD, hh:timeh,mm:timem,ss:times,zz:00},
{ YYYY:dateY,MM:dateM,DD:dateD, hh:timeh,mm:timem,ss:times,zz:00}];
if (isValShow) {
//目标为空值则获取当前日期时间
jet.each(newArr,function (i) {
var inObj = {};
jet.each(ymdzArr, function (r, val) {
inObj[val] = parseInt(unObj(val)[0] ? defObj[i][val] : unObj(val)[1]);
});
ranMat.push(jet.extend(defObj[i], inObj));
});
} else {
var isunRange = opts.range != false, initVal = that.getValue(),
spVal = initVal.split(opts.range), reMat = jet.reMatch(that.format);
jet.each(newArr,function (i) {
var inObj = {}, reVal = isunRange ? jet.reMatch(spVal[i]) : jet.reMatch(initVal);
jet.each(reMat,function (r,val) {
inObj[val] = reVal[r];
});
var exVal = jet.extend(inObj,valobj||{});
ranMat.push(jet.extend(defObj[i],exVal));
});
}
reObj = ranMat;
}
return reObj;
},
storeData:function (curr,next) {
next = next || {};
var that = this, opts = that.$opts,multi = opts.multiPane,valCell = that.valCell,
days = new Date().getDate(), DTS = that.$data,isnext = jet.isObj(next),
RES = {yearlist:[],monthlist:[[],[]],daylist:[],daytit:[],timelist:[]},seltime,
cday = curr.DD == null ? days : curr.DD, nday = next.DD == null ? days : next.DD,
timeA = {hh:curr.hh,mm:curr.mm,ss:curr.ss}, timeB = {hh:next.hh||0,mm:next.mm||0,ss:next.ss||0};
//设置年的数据
RES.yearlist.push(that.eachYear(parseInt(curr.YYYY),1));
if(multi == false){
var yearNext = isnext ? next.YYYY : curr.YYYY;
RES.yearlist.push(that.eachYear(parseInt(yearNext),2));
}
//设置月的数据
RES.monthlist[0] = that.eachMonth(curr.YYYY,0);
if(multi == false){
var monthNext = isnext ? next.YYYY : curr.YYYY+1;
RES.monthlist[1] = that.eachMonth(curr.YYYY+1,1);
}
//设置天的数据
RES.daylist.push(that.eachDays(curr.YYYY,curr.MM,cday,0));
RES.daytit.push({YYYY:curr.YYYY,MM:curr.MM});
if(multi == false){
var dayNext = jet.nextMonth(curr.YYYY,curr.MM);
RES.daylist.push(that.eachDays(dayNext.y,dayNext.m,nday,1));
RES.daytit.push({YYYY:dayNext.y,MM:dayNext.m});
}
//设置时间数据
that.selectTime = [timeA,timeB];
RES.timelist.push(that.eachTime(timeA,1));
if(multi == false){
seltime = that.dlen == 7 && opts.range && !isnext ? timeA : timeB;
if(that.dlen == 7 && opts.range && jet.valText(valCell) == ""){
that.selectTime[1] = jet.extend(timeB,timeA);
}
RES.timelist.push(that.eachTime(seltime,2));
}
//最后将数据合并于总数据中
jet.extend(that.$data,RES);
},
dateTemplate : function() {
var that = this, opts = that.$opts, multi = opts.multiPane,YMDStr = "",hmsStr = "",lang = opts.language,
ytxt = lang.name == "cn" ? "年":"", mtxt = lang.name == "cn" ? "月":"";
var ymvals = multi ? '{%=ymlist[0].YYYY%}-{%=ymlist[0].MM%}':'{%=ymlist[0].YYYY%}-{%=ymlist[0].MM%}#{%=ymlist[ynidx].YYYY%}-{%=ymlist[ynidx].MM%}';
var aowArr = (function () {
var butArr = [], ismu = multi ? "11":"23";
if(that.dlen == 1){
butArr = ['{%=yearlist[i][0].y-'+ismu+'%}','{%=yearlist[i][yearlist[i].length-1].y%}'];
}else if(that.dlen == 2){
butArr = multi ? ['{%=yearlist[0][0].y-1%}','{%=yearlist[0][0].y+1%}']:['{%=yearlist[i][0].y-'+ismu+'%}','{%=yearlist[i][yearlist[i].length-1].y%}'];
}else if(that.dlen>2 && that.dlen <=6){
butArr = ['{%=yearlist[0][0].y-1%}','{%=yearlist[0][0].y+1%}'];
}
return butArr;
})();
var lyPrev = '<em class="yearprev yprev jedatefont" @on="yearBtn(lprev,'+aowArr[0]+')">&#xed6c2;</em>',
lyNext = '<em class="yearnext ynext jedatefont" on="yearBtn(lnext,'+aowArr[2]+')">&#xed6c5;</em>',
ryPrev = '<em class="yearprev yprev jedatefont" on="yearBtn(rprev,'+aowArr[3]+')">&#xed6c2;</em>',
ryNext = '<em class="yearnext ynext jedatefont" @on="yearBtn(rnext,'+aowArr[1]+')">&#xed6c5;</em>',
mPrev = '{% if(dlen>2){ %}<em class="monthprev mprev jedatefont" @on="monthBtn(mprev,{%=daytit[i].YYYY%}-{%=daytit[i].MM%})">&#xed602;</em>{% } %}',
mNext = '{% if(dlen>2){ %}<em class="monthnext mnext jedatefont" @on="monthBtn(mnext,{%=daytit[i].YYYY%}-{%=daytit[i].MM%})">&#xed605;</em>{% } %}';
//循环年的模板
var yaerHtml = '<table class="yeartable year{%= i==0 ? "left":"right"%}" style="display:{%=year ? "block":"none"%};"><tbody><tr>'+
'{% for(var y=0;y<=11;y++){ %}<td class="{%=yearlist[i][y].style%}" @on="yearClick({%=yearlist[i][y].y%})"><span>{%=yearlist[i][y].y%}'+ytxt+'</span></td>{% if((y+1)%3==0){ %} </tr>{% } %} {% } %} </tbody></table>';
//循环月的模板
var monthHtml = '<table class="monthtable month{%= i==0 ? "left":"right"%}" style="display:{%=month ? "block":"none"%};"><tbody><tr>'+
'{% for(var m=0;m<=11;m++){ %}<td class="{%=monthlist[i][m].style%}" ym="{%=monthlist[i][m].y%}-{%=monthlist[i][m].m%}" @on="monthClick({%=monthlist[i][m].y%}-{%=monthlist[i][m].m%})"><span>{%=monthlist[i][m].m%}'+mtxt+'</span></td>{% if((m+1)%3==0){ %} </tr>{% } %} {% } %} </tbody></table>';
//循环天的模板
var daysHtml = '<table class="daystable days{%= i==0 ? "left":"right"%}" style="display:{%=day ? "block":"none"%};"><thead><tr>'+
'{% for(var w=0;w<lang.weeks.length;w++){ %} <th>{%=lang.weeks[w]%}</th> {% } %}</tr></thead><tbody>'+
'<tr>{% for(var d=0;d<=41;d++){ %}<td class="{%=daylist[i][d].style%}" ymd="{%=daylist[i][d].ymd%}" @on="daysClick({%=daylist[i][d].ymd%})">{%=daylist[i][d].day%}</td>{% if((d+1)%7==0){ %} </tr>{% } %} {% } %} </tbody></table>';
//循环时间模板
var hmsHtml = '<div class="jedate-time">{% for(var h=0;h<timelist.length;h++){ %}<div class="timepane"><div class="timeheader">{%= timelist.length == 1 ? lang.timetxt[0]:lang.timetxt[h+1]%}</div><div class="timecontent">'+
'<div class="hmstitle"><p>{%=lang.times[0]%}</p><p>{%=lang.times[1]%}</p><p>{%=lang.times[2]%}</p></div>'+
'<div class="hmslist">{% for(var t=0;t<3;t++){ %}<div class="hmsauto"><ul>{% for(var s=0;s<timelist[h][t].length;s++){ %}<li class="{%=timelist[h][t][s].style%}" @on="hmsClick({%= h %},{%= h>0?3+t:t %})">{%= timelist[h][t][s].hms < 10 ? "0" + timelist[h][t][s].hms :timelist[h][t][s].hms %}</li>{% } %}</ul></div>{% } %}</div></div>'+'</div>{% } %}</div>';
//左边选择模板
var shortHtml = opts.shortcut.length > 0 ? "{% for(var s=0;s<shortcut.length;s++){ %}<p @on=shortClick({%= shortcut[s].val %})>{%=shortcut[s].name%}</p>{% } %}":'';
var ymtitHtml = (function () {
var ymtitStr = "";
if(that.dlen == 1){
ymtitStr = '<span class="ymbtn">{%=yearlist[i][0].y%}'+ytxt+' ~ {%=yearlist[i][yearlist[i].length-1].y%}'+ytxt+'</span>';
}else if(that.dlen == 2){
ymtitStr = '<span class="ymbtn" @on="yearShow({%=yearlist[0][i].y%})">{%=yearlist[0][i].y%}'+ytxt+'</span>';
}else if(that.dlen>2 && that.dlen <=6){
ymtitStr = '<span class="ymbtn" @on="monthShow({%=daytit[i].MM%})">{%=daytit[i].MM%}'+mtxt+'</span>'+
'<span class="ymbtn" @on="yearShow({%=daytit[i].YYYY%})">{%=daytit[i].YYYY%}'+ytxt+'</span>';
}
return ymtitStr;
})();
var ymButton = (function () {
var titStrBut = "";
if(that.dlen==1){
titStrBut = multi ? [lyPrev+ryNext]:[lyPrev,ryNext];
}else if(that.dlen==2){
titStrBut = multi ? [lyPrev+ryNext] : [lyPrev,ryNext];
}else if(that.dlen>2 && that.dlen <=6){
titStrBut = multi ? [lyPrev+mPrev+mNext+ryNext] : [lyPrev+mPrev,mNext+ryNext];
}else if(that.dlen==7){
titStrBut = "";
}
return titStrBut;
})();
if(that.dlen == 1){
YMDStr = yaerHtml;
}else if(that.dlen == 2){
YMDStr = yaerHtml + monthHtml;
}else if(that.dlen == 3){
YMDStr = yaerHtml + monthHtml + daysHtml;
}else if(that.dlen > 3 && that.dlen <= 6){
YMDStr = yaerHtml + monthHtml + daysHtml;
hmsStr = hmsHtml;
}else if(that.dlen == 7){
hmsStr = hmsHtml;
}
var paneHtml = '{% for(var i=0;i<pane;i++){ %}<div class="jedate-pane">'+
'<div class="jedate-header">{% if(i==0){ %}'+ymButton[0]+'{% }else{ %}'+ymButton[1]+'{% } %}'+ymtitHtml+'</div>'+
'<div class="jedate-content{%= i==1?" bordge":"" %}">'+YMDStr+'</div>'+
'</div>{% } %}';
var btnStr = '{% if(timebtn){%}<div class="timecon" style="cursor: pointer;" @on="timeBtn">{%=lang.timetxt[0]%}</div>{% } %}<div class="btnscon">{% if(clear){ %}<span class="clear" @on="clearBtn">{%=lang.clear%}</span>{% } %}{% if(today){ %}<span class="today" @on="nowBtn">{%=lang.today%}</span>{% } %}{% if(yes){ %}<span class="setok" @on="sureBtn">{%=lang.yes%}</span>{% } %}</div>';
return '<div class="jedate-menu" style="display:{%=shortcut.length>0 ? "block":"none"%};">'+shortHtml+'</div><div class="jedate-wrap">'+paneHtml+'</div>'+hmsStr+'<div class="jedate-footbtn">'+btnStr+'</div><div class="jedate-tips"></div>';
},
//递归绑定事件
compileBindNode : function (dom) {
var self = this, aton = "@on";
var acquireAttr = function (atVal){
var args=/\(.*\)/.exec(atVal);
if(args) { //如果函数带参数,将参数字符串转换为参数数组
args = args[0];
atVal = atVal.replace(args,"");
args = args.replace(/[\(\)\'\"]/g,'').split(",");
}else args = [];
return [atVal,args];
};
jet.each(dom.childNodes,function (i,node) {
if (node.nodeType === 1) {
if(!self.$opts.festival) node.removeAttribute("ymd");
self.compileBindNode(node);
var geton = node.getAttribute(aton);
if(geton != null){
var onarr = acquireAttr(geton);
jet.on(node,"click",function () {
self[onarr[0]] && self[onarr[0]].apply(node,onarr[1]);
});
node.removeAttribute(aton);
}
}
});
},
methodEventBind : function() {
var that = this, opts = that.$opts, multi = opts.multiPane, DTS = that.$data,
result = new DateTime().reDate(),dateY = result.GetYear(),dateM = result.GetMonth(),dateD = result.GetDate(),
range = opts.range,elCell = that.dateCell;
jet.extend(that,{
yearBtn:function (type,val) {
var yarr = val.split("#"), pval = jet.reMatch(yarr[0]), tmval = that.selectTime;
exarr = [jet.extend({YYYY:parseInt(val),MM:dateM,DD:dateD},tmval[0]),{}];
var dateVal = that.parseValue([exarr[0]],that.format);
that.storeData(exarr[0],exarr[1]);
that.renderDate();
opts.toggle && opts.toggle({elem:that.valCell,val:dateVal,date:exarr[0]});
},
yearShow:function (val) {
DTS.year = DTS.year ? false : true;
DTS.month = that.dlen < 3 ? true : false;
if(that.dlen > 2 && that.dlen <= 6){
var dayCell = $Q(".daystable",elCell);
DTS.day = dayCell.style.display == "none" ? true : false;
}
that.renderDate();
},
monthBtn:function (type,val) {
var ymarr = jet.reMatch(val),tmval = that.selectTime, exarr=[], PrevYM , NextYM,
year = parseInt(ymarr[0]),month = parseInt(ymarr[1]);
if(range){
if(type == "mprev"){
PrevYM = jet.prevMonth(year, month);
NextYM = jet.nextMonth(PrevYM.y, PrevYM.m);
}else{
NextYM = jet.nextMonth(year, month);
PrevYM = jet.prevMonth(NextYM.y, NextYM.m);
}
exarr = [jet.extend({YYYY:PrevYM.y,MM:PrevYM.m,DD:dateD},tmval[0]),{YYYY:NextYM.y,MM:NextYM.m,DD:dateD}];
}else{
var PNYM = (type == "mprev") ? jet.prevMonth(year, month) : jet.nextMonth(year, month);
exarr = [jet.extend({YYYY:PNYM.y,MM:PNYM.m,DD:dateD},tmval[0]),{}];
}
var dateVal = that.parseValue([exarr[0]],that.format);
that.storeData(exarr[0],exarr[1]);
that.renderDate();
opts.toggle && opts.toggle({elem:that.valCell,val:dateVal,date:exarr[0]});
},
monthShow:function (val) {
DTS.year = false;
DTS.month = DTS.month ? false : true;
if(that.dlen > 2 && that.dlen <= 6){
var dayCell = $Q(".daystable",elCell);
DTS.day = dayCell.style.display == "none" ? true : false;
}
that.renderDate();
},
shortClick:function (val) {
var reval = val.replace(/\#/g,','),evobj = eval("("+reval+")"),
gval = jet.getDateTime(evobj),tmval = that.selectTime;
that.selectValue = [jet.parse(gval,"YYYY-MM-DD")];
that.selectDate = [{YYYY:gval.YYYY,MM:gval.MM,DD:gval.DD}];
if(opts.onClose){
var nYM = jet.nextMonth(gval.YYYY,gval.MM),
ymarr = [{YYYY:gval.YYYY,MM:gval.MM,DD:gval.DD},{YYYY:nYM.y,MM:nYM.m,DD:null}];
that.storeData(jet.extend(ymarr[0],tmval[0]),jet.extend(ymarr[1],tmval[1]));
that.renderDate();
}else{
that.setValue(gval,that.format);
that.closeDate();
}
},
yearClick:function (val) {
if(jet.hasClass(this,"disabled")) return;
var yearVal = "",lens = that.dlen;
if(range && lens == 1){
var ylen = that.selectValue.length;
that.selectDate = (ylen == 2) ? [{YYYY:parseInt(val),MM:dateM}] :
[{YYYY:that.selectDate[0].YYYY,MM:that.selectDate[0].MM},{YYYY:parseInt(val),MM:dateM}];
that.selectValue = (ylen == 2) ? [val+"-"+jet.digit(dateM)] : [that.selectValue[0],val+"-"+jet.digit(dateM)];
if(that.selectValue.length == 2){
var svalarr = [that.selectValue[0],that.selectValue[1]],newArr = [{},{}];
svalarr.sort(function(a, b){ return a > b ? 1 : -1; });
that.selectValue = svalarr;
jet.each(svalarr,function(i,strval) {
jet.each(jet.reMatch(strval),function(s,dval) {
newArr[i][ymdzArr[s]] = dval;
});
});
that.selectDate = newArr;
}
}else if(lens>1 && lens <=6){
yearVal = parseInt(val);
}else{
that.selectValue = [val+"-"+jet.digit(dateM)];
that.selectDate = [{YYYY:parseInt(val),MM:dateM}];
}
DTS.year = (lens == 1) ? true : false;
DTS.month = (lens < 3) ? true : false;
DTS.day = (lens > 2 && lens <= 6) ? true : false;
var electVal = (lens>1 && lens <=6) ? yearVal : parseInt(that.selectDate[0].YYYY);
that.storeData(jet.extend({YYYY:electVal,MM:dateM,DD:dateD},that.selectTime[0]),{});
that.renderDate();
},
monthClick:function (val) {
if(jet.hasClass(this,"disabled")) return;
var ymval = jet.reMatch(val),newArr = [{},{}],mlen = that.selectValue.length ;
if(range){
that.selectDate = (mlen == 2) ? [{YYYY:ymval[0],MM:ymval[1]}] :
[{YYYY:that.selectDate[0].YYYY,MM:that.selectDate[0].MM},{YYYY:parseInt(val),MM:ymval[1]}];
that.selectValue = (mlen == 2) ? [val] : [that.selectValue[0],val];
if(that.selectValue.length == 2){
var svalarr = [that.selectValue[0],that.selectValue[1]];
svalarr.sort(function(a, b){ return a > b ? 1 : -1; });
that.selectValue = svalarr;
jet.each(svalarr,function(i,strval) {
jet.each(jet.reMatch(strval),function(s,dval) {
newArr[i][ymdzArr[s]] = dval;
});
});
that.selectDate = newArr;
}
}else{
that.selectValue = [val];
that.selectDate = [{YYYY:ymval[0],MM:ymval[1]}];
}
if(that.dlen > 2){
DTS.year = false;
DTS.month = false;
}
DTS.day = (that.dlen > 2 && that.dlen <= 6) ? true : false;
that.storeData(jet.extend({
YYYY:parseInt(that.selectDate[0].YYYY),
MM:parseInt(that.selectDate[0].MM),
DD:dateD
},that.selectTime[0]),{});
that.renderDate();
},
daysClick:function (val) {
if(jet.hasClass(this,"disabled")) return;
var tmval = that.selectTime, matVal = jet.reMatch(val),
slen = that.selectValue.length,dateVal = "",
newArr = [{},{}],sday,nYM,ymarr;
if(range){
if(slen == 1){
var svalarr = [that.selectValue[0],val];
svalarr.sort(function(a, b){ return a > b ? 1 : -1; });
that.selectValue = svalarr;
jet.each(svalarr,function(i,strval) {
jet.each(jet.reMatch(strval),function(s,dval) {
newArr[i][ymdzArr[s]] = dval;
});
});
that.selectDate = newArr;
}else{
that.selectValue = [val];
newArr = [{YYYY:matVal[0],MM:matVal[1],DD:matVal[2]}];
that.selectDate = [{YYYY:matVal[0],MM:matVal[1],DD:matVal[2]},{}];
}
nYM = jet.nextMonth(newArr[0].YYYY,newArr[0].MM);
ymarr = [{YYYY:newArr[0].YYYY,MM:newArr[0].MM,DD:newArr[0].DD},{YYYY:nYM.y,MM:nYM.m,DD:null}];
that.storeData(jet.extend(ymarr[0],tmval[0]),jet.extend(ymarr[1],tmval[1]));
that.renderDate();
}else{
that.selectValue = [val];
that.selectDate = [{YYYY:matVal[0],MM:matVal[1],DD:matVal[2]},{YYYY:matVal[0],MM:matVal[1],DD:matVal[2]}];
jet.each(new Array(range == false ? 1 : 2),function (a) {
jet.each(matVal,function (i,val) {
newArr[a][ymdzArr[i]] = val;
});
jet.extend(newArr[a],tmval[a]);
});
if(opts.onClose){
that.storeData(jet.extend(newArr[0],tmval[0]),jet.extend(newArr[1],tmval[1]));
that.renderDate();
}else{
dateVal = that.setValue(newArr,that.format);
that.closeDate();
opts.donefun && opts.donefun.call(that,{elem:that.valCell,val:dateVal,date:newArr});
}
}
},
hmsClick:function(idx,num) {
var pidx = parseInt(num), vals = parseInt(jet.text(this)),
paridx = parseInt(idx), act = "action",mhms = ["hh","mm","ss"],
ulCell = $Q(".jedate-time",that.dateCell).querySelectorAll("ul")[pidx],
tlen = that.$data.timelist[0].length;
if(jet.hasClass(this,"disabled")) return;
jet.each(ulCell.childNodes,function (i,node) {
var reg = new RegExp("(^|\\s+)" + act + "(\\s+|$)", "g");
node.className = reg.test(node.className) ? node.className.replace(reg, '') : node.className;
});
that.selectTime[paridx][paridx == 1 ? mhms[pidx-tlen]:mhms[pidx]] = vals;
this.className = this.className + act;
var hmsCls = ulCell.querySelector("."+act);
ulCell.scrollTop = hmsCls ? (hmsCls.offsetTop-145):0;
if(that.dlen == 7 && idx == 0 && range && !multi){
var nVal = that.getValue({}), nYM = jet.nextMonth(nVal[0].YYYY,nVal[0].MM),st = that.selectTime;
that.storeData(
{YYYY:nVal[0].YYYY,MM:nVal[0].MM,DD:null,hh:st[0].hh,mm:st[0].mm,ss:st[0].ss},
{YYYY:nYM.y,MM:nYM.m,DD:null,hh:st[1].hh,mm:st[1].mm,ss:st[1].ss}
);
that.renderDate();
}
},
timeBtn:function() {
var timeCell = $Q(".jedate-time",elCell), disNo = timeCell.style.display == "none";
jet.text(this,disNo ? opts.language.backtxt:opts.language.timetxt[0]);
jet.setCss(timeCell,{display: disNo ? "block":"none"});
},
//清空按钮函数
clearBtn:function () {
jet.valText(that.valCell,"");
that.selectDate = [jet.parse(jet.getDateTime({}),"YYYY-MM-DD hh:mm:ss")];
that.closeDate();
},
//现在按钮函数
nowBtn:function () {
var newArr = jet.getDateTime({}), nYM = jet.nextMonth(newArr.YYYY,newArr.MM), dateVal;
that.selectDate = [newArr];
dateVal = opts.isShow ? that.setValue([newArr],that.format,true) : jet.parse(newArr,that.format);
if(opts.onClose && range || !opts.isShow){
that.storeData(newArr,{YYYY:nYM.y,MM:nYM.m,DD:null,hh:0,mm:0,ss:0});
that.renderDate();
}else{
that.closeDate();
}
opts.donefun && opts.donefun.call(that,{elem:that.valCell,val:dateVal,date:newArr});
},
//确认按钮函数
sureBtn:function () {
var newArr = that.selectValue.length > 1 ? [{},{}]: [{}], dateVal = "", tmval = that.selectTime;
var equal = function (o) {
var h = o.hh == undefined ? 0:o.hh, m = o.mm == undefined ? 0:o.mm, s = o.ss == undefined ? 0:o.ss;
return parseInt(jet.digit(h)+""+jet.digit(m)+""+jet.digit(s));
};
if(range){
if(that.selectValue.length > 1){
var sortarr = that.selectValue;
sortarr.sort(function(a, b){ return a > b ? 1 : -1; });
jet.each(sortarr,function (i,arr) {
jet.each(jet.reMatch(arr),function (a,val) {
newArr[i][ymdzArr[a]] = val;
});
jet.extend(newArr[i],tmval[i]);
});
}else if(that.dlen == 7 && tmval.length>1){
newArr = tmval;
}
var sameTime = equal(tmval[0]) >= equal(tmval[1]),selVal = that.selectValue, sameDate = "";
if(selVal[1] != undefined) sameDate = selVal[0].replace(/\-/g,"") == selVal[1].replace(/\-/g,"");
if(selVal.length == 1 && that.dlen < 7){
that.tips(opts.language.name == "cn" ? "未选结束日期" : "Please select the end date"); return;
}else if((that.dlen == 7 && sameTime) || (sameDate && sameTime)){
that.tips(opts.language.name == "cn" ? "结束时间必须大于开始时间" : "The end time must be greater than the start time"); return;
}
}else{
jet.each(new Array(range == false ? 1 : 2),function (i) {
if(that.dlen != 7) jet.each(jet.reMatch(that.selectValue[0]),function (a,val) {
newArr[i][ymdzArr[a]] = val;
});
jet.extend(newArr[i],tmval[i]);
});
}
dateVal = that.setValue(newArr,that.format,opts.isShow ? true:false);
opts.isShow && that.closeDate();
opts.donefun && opts.donefun.call(that,{elem:that.valCell,val:dateVal,date:newArr});
},
blankArea:function () {
jet.on(document,"mouseup",function (ev) {
jet.stopPropagation(ev);
that.closeDate();
});
jet.on($Q(elx),"mouseup", function(ev) {
jet.stopPropagation(ev);
});
}
});
},
//循环生成年数据
eachYear : function (val,type) {
var that = this,opts = that.$opts, yNum = parseInt(val),yarr = [],seCls='', selYear = that.selectDate,i,
mins = jet.reMatch(that.minDate), maxs = jet.reMatch(that.maxDate);
i = type == 1 ? yNum : that.yindex;
that.yindex = type == 1 ? 12+yNum : 12+that.yindex;
var endDate = selYear[1] == undefined ? "":selYear[1].YYYY;
for(; i < that.yindex; i++){
if(i == selYear[0].YYYY || i == endDate){
seCls = "action";
}else if(i>selYear[0].YYYY && i<endDate){
seCls = "contain";
}else if(i < mins[0] || i > maxs[0]){
seCls = "disabled";
}else{
seCls = "";
}
yarr.push({style:seCls,y:i});
}
return yarr;
},
//循环生成月数据
eachMonth : function (val,type) {
var that = this,opts = that.$opts, range = opts.range, marr = [],
selMonth = that.selectDate, seCls='',monthArr = opts.language.month ,
mins = jet.reMatch(that.minDate), maxs = jet.reMatch(that.maxDate),
minym = parseInt(mins[0]+""+jet.digit(mins[1])),
maxym = parseInt(maxs[0]+""+jet.digit(maxs[1])),
currStart = parseInt(selMonth[0].YYYY+""+jet.digit(selMonth[0].MM)),
currEnd = selMonth[1] ? parseInt(selMonth[1].YYYY+""+jet.digit(selMonth[1].MM)) : 0;
jet.each(monthArr,function (i,months) {
var ival = parseInt(val+""+jet.digit(months));
if(ival == currStart || ival == currEnd){
seCls = "action";
}else if(ival > currStart && ival < currEnd){
seCls = "contain";
}else if(ival < minym || ival > maxym){
seCls = "disabled";
}else{
seCls = "";
}
marr.push({style:seCls ,y:val ,m:months});
});
return marr;
},
//循环生成天数据
eachDays : function (yd,md,ds,idx) {
var that = this, count = 0, daysArr = [],opts = that.$opts, multiPane = jet.isBool(opts.multiPane),
firstWeek = new Date(yd, md - 1, 1).getDay() || 7,valrange = opts.range != false,
daysNum = jet.getDaysNum(yd, md), didx = 0, sDate = that.selectDate,
prevM = jet.prevMonth(yd, md),isShow = jet.isBool(opts.isShow),
prevDaysNum = jet.getDaysNum(yd, prevM.m),nextM = jet.nextMonth(yd, md), objCell = that.valCell,
lang = opts.language, endval = opts.valiDate||[],
minArr = jet.reMatch(that.minDate), minNum = parseInt(minArr[0]+""+jet.digit(minArr[1])+""+jet.digit(minArr[2])),
maxArr = jet.reMatch(that.maxDate), maxNum = parseInt(maxArr[0]+""+jet.digit(maxArr[1])+""+jet.digit(maxArr[2]));
var startDate = sDate[0] ? parseInt(sDate[0].YYYY+""+jet.digit(sDate[0].MM)+""+jet.digit(sDate[0].DD)) : "";
var endDate = sDate[1] ? parseInt(sDate[1].YYYY+""+jet.digit(sDate[1].MM)+""+jet.digit(sDate[1].DD)) : "";
//设置时间标注
var setMark = function (my, mm, md) {
var Marks = opts.marks, contains = function(arr, obj) {
var clen = arr.length;
while (clen--) { if (arr[clen] === obj) return true; }
return false;
},isArr = jet.isType(Marks,"array");
return isArr && Marks.length > 0 && contains(Marks, my + "-" + jet.digit(mm) + "-" + jet.digit(md)) ? '<i class="marks"></i>' :"";
};
//是否显示节日
var isfestival = function(y, m ,d) {
var festivalStr = '';
if(opts.festival == true && lang.name == "cn"){
var lunar = jeLunar(y, m - 1, d), feslunar = (lunar.solarFestival || lunar.lunarFestival),
lunartext = (feslunar && lunar.jieqi) != "" ? feslunar : (lunar.jieqi || lunar.showInLunar);
festivalStr = '<p><span class="solar">' + d + '</span><span class="lunar">' + lunartext + '</span></p>';
}else{
festivalStr = '<p class="nolunar">' + d + '</p>';
}
return festivalStr;
};
//判断是否在限制的日期之中
var dateLimit = function(Y, M, D, isMonth){
var thatNum = parseInt(Y + "" + jet.digit(M) + "" + jet.digit(D));
if(isMonth){
if (thatNum >= minNum && thatNum <= maxNum) return true;
}else {
if (minNum > thatNum || maxNum < thatNum) return true;
}
};
var regExpDate = function (date,cls) {
var inArray = function (search,array){
for(var i in array) if(array[i]==search) return true;
return false;
};
if(endval.length > 0 && endval[0]!=""){
if(/\%/g.test(endval[0])){
var reval = endval[0].replace(/\%/g,"").split(","), enArr = [];
jet.each(reval,function (r,rel) {
enArr.push(jet.digit(parseInt(rel)));
});
var isfind = inArray(jet.digit(date), enArr) == false;
cls = jet.isBool(endval[1]) ? (isfind ? " disabled" :cls) : (isfind ? cls :" disabled");
}else {
var valreg = that.dateRegExp(endval[0]), regday = valreg.test(jet.digit(date));
cls = jet.isBool(endval[1]) ? (regday ? " disabled" : cls) : (regday ? cls : " disabled");
}
}
return cls;
};
//var ymds = ymdarr[1]
//上一月剩余天数
for (var p = prevDaysNum - firstWeek + 1; p <= prevDaysNum; p++, count++) {
var pmark = setMark(prevM.y,prevM.m,p), pcls = dateLimit(prevM.y, prevM.m, p, false) ? "disabled" : "other";
pcls = regExpDate(p,pcls);
daysArr.push({style:pcls,ymd:prevM.y+'-'+jet.digit(prevM.m)+'-'+jet.digit(p),day:(isfestival(prevM.y,prevM.m,p) + pmark)});
}
//本月的天数
for(var b = 1; b <= daysNum; b++, count++){
var bmark = setMark(yd,md,b), bcls = "";
var dateval = parseInt(yd+""+jet.digit(md)+""+jet.digit(b)),
parsdate = dateval > startDate, rangdate = dateval < endDate;
if(dateLimit(yd, md, b, true)){
if(dateval == startDate || dateval == endDate){
bcls = " action";
}else if(parsdate&&rangdate){
bcls = " contain";
}else {
bcls = "";
}
}else {
bcls = " disabled";
}
bcls = regExpDate(b,bcls);
daysArr.push({style:"normal"+bcls,ymd:yd+'-'+jet.digit(md)+'-'+jet.digit(b),day:(isfestival(yd,md,b) + bmark)});
}
//下一月开始天数
for(var n = 1, nlen = 42 - count; n <= nlen; n++){
var nmark = setMark(nextM.y,nextM.m,n);
var ncls = dateLimit(nextM.y, nextM.m, n, false) ? "disabled" : "other";
ncls = regExpDate(n,ncls);
daysArr.push({style:ncls,ymd:nextM.y+'-'+jet.digit(nextM.m)+'-'+jet.digit(n),day:(isfestival(nextM.y,nextM.m,n) + nmark)});
}
//将星期与日期拼接起来
return daysArr;
},
eachTime : function (hmsArr,type) {
var that = this,opts = that.$opts, range = opts.range,multi = opts.multiPane, minVal = [], maxVal = [],
mhms = ["hh","mm","ss"], timeArr = [],hmsCls = '',format = that.format,
ntVal = jet.trim(that.minDate).replace(/\s+/g," "),
xtVal = jet.trim(that.maxDate).replace(/\s+/g," "),
nVal = ntVal.split(" "), xVal = xtVal.split(" ");
if(that.dlen>3 && /\:/.test(nVal) && /\:/.test(xVal)){
minVal = jet.reMatch(/\s/.test(ntVal)&&that.dlen>3 ? nVal[1] : ntVal);
maxVal = jet.reMatch(/\s/.test(xtVal)&&that.dlen>3 ? xVal[1] : xtVal);
}
jet.each([24,60,60],function (s,lens) {
timeArr[s] = [];
var unhmsVal = minVal[s] == undefined || minVal[s] == 0 ? hmsArr[mhms[s]] : minVal[s],
currVal = that.getValue() == "" ? unhmsVal : hmsArr[mhms[s]];
if(that.dlen>3 && /\:/.test(nVal) && type==1){
that.selectTime[0][mhms[s]] = currVal;
}
for (var h = 0; h < lens; h++) {
var exists = new RegExp(mhms[s],"g").test(format);
if(h == currVal){
hmsCls = exists ? "action" : "disabled";
}else if(!exists || !range && multi &&(h<minVal[s] ||h>maxVal[s])){
hmsCls = "disabled";
}else if(!multi){
hmsCls = type == 1&&h<minVal[s] || type == 2&&h>maxVal[s] ? "disabled" : "";
}else{
hmsCls = "";
}
timeArr[s].push({style:hmsCls,hms:h});
}
});
return timeArr;
},
//关闭日期控件
closeDate : function () {
var elem = $Q(elx), tipelem = $Q("#jedatetipscon");
elem && document.body.removeChild(elem);
tipelem && document.body.removeChild(tipelem);
//再次初始化值
this.setDatas();
},
//转换日期值
parseValue : function (fnObj,matStr) {
var that = this, valArr=[],opts = that.$opts, range = opts.range;
jet.each(fnObj,function (i,val) {
valArr.push(jet.parse(val, matStr));
});
return range == false ? valArr[0] : valArr.join(range);
},
//初始验证正则
dateRegExp : function(valArr) {
var enval = valArr.split(",")||[], regs = "";
var doExp = function (val) {
var arr, tmpEval, regs = /#?\{(.*?)\}/;
val = val + "";
while ((arr = regs.exec(val)) != null) {
arr.lastIndex = arr.index + arr[1].length + arr[0].length - arr[1].length - 1;
tmpEval = parseInt(eval(arr[1]));
if (tmpEval < 0) tmpEval = "9700" + -tmpEval;
val = val.substring(0, arr.index) + tmpEval + val.substring(arr.lastIndex + 1);
}
return val;
};
if (enval && enval.length > 0) {
for (var i = 0; i < enval.length; i++) {
regs += doExp(enval[i]);
if (i != enval.length - 1) regs += "|";
}
regs = regs ? new RegExp("(?:" + regs + ")") : null;
} else {
regs = null;
}
//re = new RegExp((re + "").replace(/^\/\(\?:(.*)\)\/.*/, "$1"));
return regs;
},
//显示农历节日
showFestival:function () {
var that = this, opts = that.$opts;
jet.each(that.dateCell.querySelectorAll(".daystable td"),function (i,node) {
var tval = jet.reMatch(jet.attr(node,"ymd")),tipDiv = document.createElement("div");
node.removeAttribute("ymd");
//鼠标进入提示框出现
jet.on(node,"mouseover",function () {
var lunar = new jeLunar(tval[0], tval[1] - 1, tval[2]);
if($Q("#jedatetipscon")) return;
tipDiv.id = tipDiv.className = "jedatetipscon";
var tiphtml = '<p>' + lunar.solarYear + '\u5E74' + lunar.solarMonth + '\u6708' + lunar.solarDate + '\u65E5 ' + lunar.inWeekDays + '</p><p class="red">\u519C\u5386:' + lunar.shengxiao + '\u5E74 ' + lunar.lnongMonth + '\u6708' + lunar.lnongDate + '</p><p>' + lunar.ganzhiYear + '\u5E74 ' + lunar.ganzhiMonth + '\u6708 ' + lunar.ganzhiDate + '\u65E5</p>';
var Fesjieri = (lunar.solarFestival || lunar.lunarFestival) != "" ? '<p class="red">' + ("\u8282\u65E5:"+lunar.solarFestival + lunar.lunarFestival) + '</p>' : "";
var Fesjieqi = lunar.jieqi != "" ? '<p class="red">'+(lunar.jieqi != "" ? "\u8282\u6C14:"+lunar.jieqi : "") + '</p>': "";
var tiptext = (lunar.solarFestival || lunar.lunarFestival || lunar.jieqi) != "" ? (Fesjieri + Fesjieqi) : "";
jet.html(tipDiv,tiphtml + tiptext);
document.body.appendChild(tipDiv);
//获取并设置农历提示框出现的位置
var tipPos = that.lunarOrien(tipDiv, this);
jet.setCss(tipDiv,{"zIndex": (opts.zIndex == undefined ? 10000 + 5 : opts.zIndex + 5),top:tipPos.top,left:tipPos.left,position:"absolute",display:"block"});
});
//鼠标移除提示框消失
jet.on(node,"mouseout",function () {
document.body.removeChild($Q("#jedatetipscon"));
});
});
if (that.dateCell.nodeType === 1 && !jet.hasClass(that.dateCell,"grid")) that.dateCell.className = that.dateCell.className + " grid";
},
//农历方位辨别
lunarOrien : function(obj, self, pos) {
var tops, leris, ortop, orleri, rect =self.getBoundingClientRect(), boxW = obj.offsetWidth, boxH = obj.offsetHeight;
leris = rect.right + boxW / 1.5 >= jet.docArea(true) ? rect.right - boxW : rect.left + (pos ? 0 : jet.docScroll(true));
tops = rect.bottom + boxH / 1 <= jet.docArea() ? rect.bottom - 1 : rect.top > boxH / 1.5 ? rect.top - boxH - 1 : jet.docArea() - boxH;
if(leris + boxW > jet.docArea(true)) leris = rect.left - (boxW - rect.width);
ortop = Math.max(tops + (pos ? 0 :jet.docScroll()) + 1, 1) + "px", orleri = leris + "px";
return {top: ortop, left: orleri }
},
//辨别控件的方位
dateOrien : function(elbox, valCls, pos) {
var that = this, tops, leris, ortop, orleri,
rect = that.$opts.fixed ? valCls.getBoundingClientRect() : elbox.getBoundingClientRect(),
leris = rect.left, tops = rect.bottom;
if(that.$opts.fixed) {
var boxW = elbox.offsetWidth, boxH = elbox.offsetHeight;
//如果右侧超出边界
if(leris + boxW > jet.docArea(true)){
leris = leris - (boxW - rect.width);
}
//如果底部超出边界
if(tops + boxH > jet.docArea()){
tops = rect.top > boxH ? rect.top - boxH -2 : jet.docArea() - boxH -1;
}
//根据目标元素计算弹层位置
ortop = Math.max(tops + (pos ? 0 :jet.docScroll())+1, 1) + "px"; orleri = leris + "px";
}else{
//弹层位置位于页面上下左右居中
ortop = "50%"; orleri = "50%";
elbox.style.cssText = "marginTop:"+-(rect.height / 2)+";marginLeft:"+-(rect.width / 2);
}
jet.setCss(elbox,{top:ortop,left:orleri});
},
tips : function (text, time) {
var that = this, tipCls = $Q(".jedate-tips",that.dateCell),tipTime;
jet.html(tipCls,text||""); jet.setCss(tipCls,{display:"block"});
clearTimeout(tipTime);
tipTime = setTimeout(function(){
jet.html(tipCls,""); jet.setCss(tipCls,{display:"none"});
}, (time||2.5)*1000);
},
locateScroll : function () {
var that = this, ulCell = $Q(".jedate-time",that.dateCell).querySelectorAll("ul");
jet.each(ulCell, function(i,cell) {
var hmsCls = cell.querySelector(".action");
cell.scrollTop = hmsCls ? (hmsCls.offsetTop-145):0;
});
if(that.dlen != 7) jet.setCss($Q(".jedate-time",that.dateCell),{display:'none'});
}
});
//农历数据
function jeLunar(ly,lm,ld) {
var lunarInfo=[19416,19168,42352,21717,53856,55632,91476,22176,39632,21970,19168,42422,42192,53840,119381,46400,54944,44450,38320,84343,18800,42160,46261,27216,27968,109396,11104,38256,21234,18800,25958,54432,59984,28309,23248,11104,100067,37600,116951,51536,54432,120998,46416,22176,107956,9680,37584,53938,43344,46423,27808,46416,86869,19872,42448,83315,21200,43432,59728,27296,44710,43856,19296,43748,42352,21088,62051,55632,23383,22176,38608,19925,19152,42192,54484,53840,54616,46400,46496,103846,38320,18864,43380,42160,45690,27216,27968,44870,43872,38256,19189,18800,25776,29859,59984,27480,21952,43872,38613,37600,51552,55636,54432,55888,30034,22176,43959,9680,37584,51893,43344,46240,47780,44368,21977,19360,42416,86390,21168,43312,31060,27296,44368,23378,19296,42726,42208,53856,60005,54576,23200,30371,38608,19415,19152,42192,118966,53840,54560,56645,46496,22224,21938,18864,42359,42160,43600,111189,27936,44448],
sTermInfo = [ 0, 21208, 43467, 63836, 85337, 107014, 128867, 150921, 173149, 195551, 218072, 240693, 263343, 285989, 308563, 331033, 353350, 375494, 397447, 419210, 440795, 462224, 483532, 504758 ];
var Gan = "甲乙丙丁戊己庚辛壬癸", Zhi = "子丑寅卯辰巳午未申酉戌亥", Animals = "鼠牛虎兔龙蛇马羊猴鸡狗猪";
var solarTerm = [ "小寒", "大寒", "立春", "雨水", "惊蛰", "春分", "清明", "谷雨", "立夏", "小满",
"芒种", "夏至", "小暑", "大暑", "立秋", "处暑", "白露", "秋分", "寒露", "霜降", "立冬", "小雪", "大雪", "冬至" ];
var nStr1 = "日一二三四五六七八九十", nStr2 = "初十廿卅", nStr3 = [ "正", "二", "三", "四", "五", "六", "七", "八", "九", "十", "十一", "腊"],
sFtv1 = {
"0101" : "*1元旦节", "0202" : "湿地日",
"0214" : "情人节", "0308" : "妇女节",
"0312" : "植树节", "0315" : "消费者权益日",
"0401" : "愚人节", "0422" : "地球日",
"0501" : "*1劳动节", "0504" : "青年节",
"0512" : "护士节", "0518" : "博物馆日",
"0520" : "母亲节", "0601" : "儿童节",
"0623" : "奥林匹克日", "0630" : "父亲节",
"0701" : "建党节", "0801" : "建军节",
"0903" : "抗战胜利日", "0910" : "教师节",
"1001" : "*3国庆节", "1201" : "艾滋病日",
"1224" : "平安夜", "1225" : "圣诞节"
},
sFtv2 = {
"0100" : "除夕", "0101" : "*2春节",
"0115" : "元宵节", "0505" : "*1端午节",
"0707" : "七夕节", "0715" : "中元节",
"0815" : "*1中秋节", "0909" : "*1重阳节",
"1015" : "下元节", "1208" : "腊八节",
"1223" : "小年"
};
function flunar(Y) {
var sTerm = function (j, i) {
var h = new Date((31556925974.7 * (j - 1900) + sTermInfo[i] * 60000) + Date.UTC(1900, 0, 6, 2, 5));
return (h.getUTCDate());
},
d = function (k) {
var h, j = 348;
for (h = 32768; h > 8; h >>= 1) j += (lunarInfo[k - 1900] & h) ? 1 : 0;
return (j + b(k));
},
ymdCyl = function (h) {
return (Gan.charAt(h % 10) + Zhi.charAt(h % 12));
},
b = function (h) {
var islp = (g(h)) ? ((lunarInfo[h - 1900] & 65536) ? 30 : 29) : (0);
return islp;
},
g = function (h) {
return (lunarInfo[h - 1900] & 15)
},
e = function (i, h) {
return ((lunarInfo[i - 1900] & (65536 >> h)) ? 30 : 29);
},
newymd = function (m) {
var k, j = 0, h = 0, l = new Date(1900, 0, 31), n = (m - l) / 86400000;
this.dayCyl = n + 40;
this.monCyl = 14;
for (k = 1900; k < 2050 && n > 0; k++) {
h = d(k); n -= h;
this.monCyl += 12;
}
if (n < 0) {
n += h; k--;
this.monCyl -= 12;
}
this.year = k;
this.yearCyl = k - 1864;
j = g(k);
this.isLeap = false;
for (k = 1; k < 13 && n > 0; k++) {
if (j > 0 && k == (j + 1) && this.isLeap == false) {
--k;
this.isLeap = true;
h = b(this.year);
} else {
h = e(this.year, k);
}
if (this.isLeap == true && k == (j + 1)) {
this.isLeap = false;
}
n -= h;
if (this.isLeap == false) this.monCyl++;
}
if (n == 0 && j > 0 && k == j + 1) {
if (this.isLeap) {
this.isLeap = false;
} else {
this.isLeap = true;
--k;
--this.monCyl;
}
}
if (n < 0) {
n += h; --k;
--this.monCyl;
}
this.month = k;
this.day = n + 1;
},
digit = function (num) {
return num < 10 ? "0" + (num | 0) : num;
},
reymd = function (i, j) {
var h = i;
return j.replace(/dd?d?d?|MM?M?M?|yy?y?y?/g, function (k) {
switch (k) {
case "yyyy":
var l = "000" + h.getFullYear();
return l.substring(l.length - 4);
case "dd": return digit(h.getDate());
case "d": return h.getDate().toString();
case "MM": return digit((h.getMonth() + 1));
case "M": return h.getMonth() + 1;
}
});
},
lunarMD = function (i, h) {
var j;
switch (i, h) {
case 10: j = "初十"; break;
case 20: j = "二十"; break;
case 30: j = "三十"; break;
default:
j = nStr2.charAt(Math.floor(h / 10));
j += nStr1.charAt(h % 10);
}
return j;
};
this.isToday = false;
this.isRestDay = false;
this.solarYear = reymd(Y, "yyyy");
this.solarMonth = reymd(Y, "M");
this.solarDate = reymd(Y, "d");
this.solarWeekDay = Y.getDay();
this.inWeekDays = "星期" + nStr1.charAt(this.solarWeekDay);
var X = new newymd(Y);
this.lunarYear = X.year;
this.shengxiao = Animals.charAt((this.lunarYear - 4) % 12);
this.lunarMonth = X.month;
this.lunarIsLeapMonth = X.isLeap;
this.lnongMonth = this.lunarIsLeapMonth ? "闰" + nStr3[X.month - 1] : nStr3[X.month - 1];
this.lunarDate = X.day;
this.showInLunar = this.lnongDate = lunarMD(this.lunarMonth, this.lunarDate);
if (this.lunarDate == 1) {
this.showInLunar = this.lnongMonth + "月";
}
this.ganzhiYear = ymdCyl(X.yearCyl);
this.ganzhiMonth = ymdCyl(X.monCyl);
this.ganzhiDate = ymdCyl(X.dayCyl++);
this.jieqi = "";
this.restDays = 0;
if (sTerm(this.solarYear, (this.solarMonth - 1) * 2) == reymd(Y, "d")) {
this.showInLunar = this.jieqi = solarTerm[(this.solarMonth - 1) * 2];
}
if (sTerm(this.solarYear, (this.solarMonth - 1) * 2 + 1) == reymd(Y, "d")) {
this.showInLunar = this.jieqi = solarTerm[(this.solarMonth - 1) * 2 + 1];
}
if (this.showInLunar == "清明") {
this.showInLunar = "清明节";
this.restDays = 1;
}
this.solarFestival = sFtv1[reymd(Y, "MM") + reymd(Y, "dd")];
if (typeof this.solarFestival == "undefined") {
this.solarFestival = "";
} else {
if (/\*(\d)/.test(this.solarFestival)) {
this.restDays = parseInt(RegExp.$1);
this.solarFestival = this.solarFestival.replace(/\*\d/, "");
}
}
this.showInLunar = (this.solarFestival == "") ? this.showInLunar : this.solarFestival;
this.lunarFestival = sFtv2[this.lunarIsLeapMonth ? "00" : digit(this.lunarMonth) + digit(this.lunarDate)];
if (typeof this.lunarFestival == "undefined") {
this.lunarFestival = "";
} else {
if (/\*(\d)/.test(this.lunarFestival)) {
this.restDays = (this.restDays > parseInt(RegExp.$1)) ? this.restDays : parseInt(RegExp.$1);
this.lunarFestival = this.lunarFestival.replace(/\*\d/, "");
}
}
if (this.lunarMonth == 12 && this.lunarDate == e(this.lunarYear, 12)) {
this.lunarFestival = sFtv2["0100"];
this.restDays = 1;
}
this.showInLunar = (this.lunarFestival == "") ? this.showInLunar : this.lunarFestival;
}
return new flunar(new Date(ly, lm, ld));
}
return jeDate;
});
... ...
此 diff 太大无法显示。
此 diff 太大无法显示。
... ... @@ -264,8 +264,7 @@
},
// 重新获取当前定位信息
choose_now: function() {
toastMsg('正在重新定位')
toastMsg('正在重新定位');
app.get_city()
setTimeout(function() {
// api.hideProgress();
... ...
... ... @@ -276,6 +276,7 @@
},
// 切换底部导航
changeTab: function (res) {
setTimeout(function () {
app.index = res;
api.setFrameGroupIndex({
... ...
... ... @@ -17,7 +17,6 @@
/*background-color: #efefef;*/
height: 100%;
}
.banner_box {
display: flex;
align-items: center;
... ...
... ... @@ -93,8 +93,8 @@
'XX-Device-Type': getDevice()
}
getRequest('POST', 'home/index/loginBySMS', post, header).then(function (res) {
console.log(res)
toastMsg(res.data.msg)
console.log(res);
toastMsg(res.data.msg);
if (!app.timer) {
app.count = TIME_COUNT;
app.show = false;
... ...
... ... @@ -7,6 +7,7 @@
<meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
<title></title>
<script src="../../assets/js/fontsize.js"></script>
<link rel="stylesheet" href="../../assets/css/weui.min.css">
<link rel="stylesheet" href="../../assets/css/api.css"/>
<link rel="stylesheet" href="../../assets/css/index.css">
<link rel="stylesheet" href="../../assets/icon/iconfont.css">
... ... @@ -89,6 +90,7 @@
</div>
</body>
</html>
<script type="text/javascript" src="../../assets/js/weui.min.js"></script>
<script type="text/javascript" src="../../assets/js/api.js"></script>
<script type="text/javascript" src="../../assets/js/public.js"></script>
<script type="text/javascript" src="../../assets/js/fastclick.js"></script>
... ... @@ -138,6 +140,7 @@
'XX-Token': getToken()
};
getRequest('post', 'user/index/typeInfo', post, header).then(function (res) {
console.log(res)
if (res.data.code == 1) {
app.status1 = res.data.data[0].status;
app.status2 = res.data.data[1].status;
... ... @@ -148,15 +151,20 @@
app.one_qid = res.data.data[0].answer[0].qid;
app.two_qid = res.data.data[1].answer[0].qid;
app.thr_qid = res.data.data[2].answer[0].qid;
for (var i in res.data.data[0].answer[0].answer) {
app.answer_one.push(res.data.data[0].answer[0].answer[i])
}
for (var j in res.data.data[1].answer[0].answer) {
app.answer_two.push(res.data.data[1].answer[0].answer[j])
}
for (var k in res.data.data[2].answer[0].answer) {
app.answer_thr.push(res.data.data[2].answer[0].answer[k])
}
app.answer_one=res.data.data[0].answer[0].answer;
app.answer_two=res.data.data[1].answer[0].answer;
app.answer_thr=res.data.data[2].answer[0].answer;
// for (var i in res.data.data[0].answer[0].answer) {
// app.answer_one.push(res.data.data[0].answer[0].answer[i])
// }
// for (var j in res.data.data[1].answer[0].answer) {
// app.answer_two.push(res.data.data[1].answer[0].answer[j])
// }
// for (var k in res.data.data[2].answer[0].answer) {
// app.answer_thr.push(res.data.data[2].answer[0].answer[k])
// }
}
loadEnd();
})
... ... @@ -216,11 +224,15 @@
,
// 保存选择结果
save_info: function () {
api.showProgress({
title: '保存中',
text: '正在保存……',
modal: false
});
toastMsg('正在保存')
// api.showProgress({
// title: '保存中',
// text: '正在保存……',
// modal: false
// });
var header = {
"XX-Device-Type": getDevice(),
'XX-Token': getToken()
... ... @@ -260,4 +272,4 @@
}
},
})
</script>
\ No newline at end of file
</script>
... ...
... ... @@ -7,6 +7,7 @@
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
<script src="../../assets/js/fontsize.js"></script>
<link rel="stylesheet" href="../../assets/css/weui.min.css">
<link rel="stylesheet" href="../../assets/css/api.css"/>
<link rel="stylesheet" href="../../assets/css/my_f.css"/>
<link rel="stylesheet" href="http://at.alicdn.com/t/font_641470_jg64l6ijsg4lsor.css">
... ... @@ -395,7 +396,7 @@
</body>
</html>
<script type="text/javascript" src="../../assets/js/weui.min.js"></script>
<script type="text/javascript" src="../../assets/js/api.js"></script>
<script type="text/javascript" src="../../assets/js/public.js"></script>
<script type="text/javascript" src="../../assets/js/fastclick.js"></script>
... ... @@ -587,4 +588,4 @@
}
}
})
</script>
\ No newline at end of file
</script>
... ...
... ... @@ -7,11 +7,15 @@
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
<script src="../../assets/js/fontsize.js"></script>
<link rel="stylesheet" href="../../assets/css/demos.css">
<link rel="stylesheet" href="../../assets/css/weui.min.css">
<link rel="stylesheet" href="../../assets/css/jeDate-test.css">
<link rel="stylesheet" href="../../assets/css/jedate.css">
<link rel="stylesheet" href="../../assets/css/api.css"/>
<link rel="stylesheet" href="../../assets/css/my_f.css"/>
<link rel="stylesheet" href="../../assets/css/style.css">
<link rel="stylesheet" href="../../assets/icon/iconfont.css">
<title></title>
<style>
body, html {
... ... @@ -60,8 +64,11 @@
<div id="app">
<div class="data_box">
<div class="data_item" @click="dateSelect"><span>测量时间</span>
<div class="data_item_right"><span>{{date_info?date_info:default_date}}</span><span
class="iconfont icon-xiangyou"></span>
<!--<div class="data_item_right"><span>{{date_info?date_info:default_date}}</span>-->
<!--&lt;!&ndash;<span class="iconfont icon-xiangyou"></span>&ndash;&gt;-->
<!--</div>-->
<div class="data_item_right">
<input type="datetime-local" placeholder="请选择时间">
</div>
</div>
<div class="data_item" @click="choose_high">
... ... @@ -86,9 +93,11 @@
</div>
</body>
</html>
<script type="text/javascript" src="../../assets/js/jquery-2.1.4.js"></script>
<script type="text/javascript" src="../../assets/js/fastclick.js"></script>
<script type="text/javascript" src="../../assets/js/jquery-weui.js"></script>
<script type="text/javascript" src="../../assets/js/api.js"></script>
<script type="text/javascript" src="../../assets/js/index.js"></script>
<script type="text/javascript" src="../../assets/js/public.js"></script>
<script type="text/javascript" src="../../assets/js/fastclick.js"></script>
<script>
... ... @@ -98,6 +107,8 @@
<script type="text/javascript" src="../../assets/js/weui.min.js"></script>
<script type="text/javascript" src="../../assets/js/axios.min.js"></script>
<script type="text/javascript" src="../../assets/icon/iconfont.js"></script>
<script type="text/javascript" src="../../assets/js/index.js"></script>
<script type="text/javascript" src="../../assets/js/datePicker.js"></script>
<script>
var app = new Vue({
el: '#app',
... ... @@ -132,63 +143,63 @@
methods: {
// 日期选择
dateSelect: function () {
if (api.systemType == 'ios') {
api.openPicker({
type: 'date_time',
date: new Date(),
maxDate: getTimeDetil(0),
title: '测量时间'
}, function (ret, err) {
if (ret) {
app.year = ret.year;
app.month = ret.month;
app.day = ret.day;
app.hour = ret.hour;
app.minute = ret.minute;
app.date_info = app.year + '-' + add0(app.month) + '-' + add0(app.day) + ' ' + add0(app.hour) + ':' + add0(app.minute);
if (checkDate(app.date_info, 2)) {
return app.date_info
} else {
toastMsg('请选择正确的测量时间');
return app.date_info = ''
}
} else {
console.log(err)
}
});
}
else {
api.openPicker({
type: 'date',
title: '测量时间',
}, function (ret, err) {
if (ret) {
app.year = ret.year;
app.month = ret.month;
app.day = ret.day;
api.openPicker({
type: 'time',
title: '测量时间'
}, function (rets, errs) {
if (rets) {
app.hour = rets.hour;
app.minute = rets.minute;
app.date_info = app.year + '-' + add0(app.month) + '-' + add0(app.day) + ' ' + add0(app.hour) + ':' + add0(app.minute);
if (checkDate(app.date_info, 2)) {
return app.date_info
} else {
toastMsg('请选择正确的测量时间');
return app.date_info = ''
}
} else {
console.log(errs)
}
});
} else {
console.log(err)
}
});
}
// if (api.systemType == 'ios') {
// api.openPicker({
// type: 'date_time',
// date: new Date(),
// maxDate: getTimeDetil(0),
// title: '测量时间'
// }, function (ret, err) {
// if (ret) {
// app.year = ret.year;
// app.month = ret.month;
// app.day = ret.day;
// app.hour = ret.hour;
// app.minute = ret.minute;
// app.date_info = app.year + '-' + add0(app.month) + '-' + add0(app.day) + ' ' + add0(app.hour) + ':' + add0(app.minute);
// if (checkDate(app.date_info, 2)) {
// return app.date_info
// } else {
// toastMsg('请选择正确的测量时间');
// return app.date_info = ''
// }
// } else {
// console.log(err)
// }
// });
// }
// else {
// api.openPicker({
// type: 'date',
// title: '测量时间',
// }, function (ret, err) {
// if (ret) {
// app.year = ret.year;
// app.month = ret.month;
// app.day = ret.day;
// api.openPicker({
// type: 'time',
// title: '测量时间'
// }, function (rets, errs) {
// if (rets) {
// app.hour = rets.hour;
// app.minute = rets.minute;
// app.date_info = app.year + '-' + add0(app.month) + '-' + add0(app.day) + ' ' + add0(app.hour) + ':' + add0(app.minute);
// if (checkDate(app.date_info, 2)) {
// return app.date_info
// } else {
// toastMsg('请选择正确的测量时间');
// return app.date_info = ''
// }
// } else {
// console.log(errs)
// }
// });
// } else {
// console.log(err)
// }
// });
// }
},
// 选择高压
choose_high: function () {
... ...
... ... @@ -3,10 +3,14 @@
<head>
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<link rel="stylesheet" href="../../assets/css/weui.min.css">
<link rel="stylesheet" href="../../assets/css/jeDate-test.css">
<link rel="stylesheet" href="../../assets/css/jedate.css">
<link rel="stylesheet" href="../../assets/css/base.css">
<link rel="stylesheet" href="../../assets/css/style1.css">
<link rel="stylesheet" href="../../assets/css/common1.css">
<link rel="stylesheet" href="../../assets/icon/iconfont.css">
<title></title>
<style type="text/css">
body {
... ... @@ -48,12 +52,16 @@
}
.date_box {
position:relative;
width:7.5rem;
display: flex;
align-items: center;
justify-content: space-between;
padding: 10px 13px;
margin: 20px 0 0 0;
background-color: #fff;
/*overflow: hidden;*/
}
.date_item {
... ... @@ -63,6 +71,10 @@
.date_box .iconfont {
color: #c0c0c0;
position:absolute;
right:0.9rem;
top:0.4rem;
}
.save_btn {
... ... @@ -93,7 +105,7 @@
</style>
</head>
<body>
<body class="jebody">
<div id="loadStart"></div>
<div class="perpart1 center">
<div style="position: relative;color: #fff;top: 2.5rem;">mmol/L</div>
... ... @@ -113,13 +125,25 @@
<span data-id="7">睡前</span>
<span data-id="8">凌晨</span>
</div>
<div class="date_box">
<div class="date_item">请选择测量时间</div>
<div class="iconfont icon-xiangyou"></div>
</div>
<!--<div class="date_box">-->
<!--<div class="date_item">请选择测量时间</div>-->
<!--<div class="iconfont icon-xiangyou"></div>-->
<!--</div>-->
<div class="jeitem ">
<div class="jelabel ">请选择测量时间</div>
<div class="date_box">
<div class="jeinpbox" style="width:95%"><input type="text" class="jeinput" id="test04" placeholder="请选择测量时间" style="width:96%"></div>
<!--<div class="iconfont icon-xiangyou" ></div>-->
</div>
</div>
<div class="save_btn">保存</div>
</body>
</html>
<script type="text/javascript" src="../../assets/js/api.js"></script>
<script type="text/javascript" src="../../assets/js/public.js"></script>
<script type="text/javascript" src="../../assets/js/fastclick.js"></script>
... ... @@ -130,10 +154,15 @@
<script src="../../assets/js/jquery.knob.js" type="text/javascript"></script>
<script type="text/javascript" src="../../assets/js/axios.min.js"></script>
<script type="text/javascript" src="../../assets/icon/iconfont.js"></script>
<script type="text/javascript" src="../../assets/js/jedate.js"></script>
<script type="text/javascript" src="../../assets/js/demo.js"></script>
<script type="text/javascript" src="../../assets/js/weui.min.js"></script>
<script type="text/javascript">
$(function () {
apiready = function () {
$(document).ready(function () {
var type=1
$(".knob").knob();
loadEnd();
... ... @@ -168,74 +197,85 @@
}
});
$('.date_box').click(function () {
if (api.systemType == 'ios') {
api.openPicker({
type: 'date_time',
date: new Date(),
maxDate: getTimeDetil(0),
title: '测量时间'
}, function (ret, err) {
if (ret) {
var year = ret.year;
var month = ret.month;
var day = ret.day;
var hour = ret.hour;
var minute = ret.minute;
var date_info = year + '-' + add0(month) + '-' + add0(day) + ' ' + add0(hour) + ':' + add0(minute);
if (checkDate(date_info, 2)) {
$('.date_item').html(date_info)
} else {
toastMsg('选择日期不能大于当前时间');
$('.date_item').html('请选择测量时间')
}
} else {
console.log(err)
}
});
}
else {
api.openPicker({
type: 'date',
title: '服务日期',
}, function (ret, err) {
if (ret) {
var year = ret.year;
var month = ret.month;
var day = ret.day;
api.openPicker({
type: 'time',
title: '服务时间'
}, function (rets, errs) {
if (rets) {
var hour = rets.hour;
var minute = rets.minute;
var date_info = year + '-' + add0(month) + '-' + add0(day) + ' ' + add0(hour) + ':' + add0(minute);
if (checkDate(date_info, 2)) {
$('.date_item').html(date_info)
} else {
toastMsg('选择日期不能大于当前时间');
$('.date_item').html('请选择测量时间')
}
} else {
console.log(errs)
}
});
} else {
console.log(err)
}
});
}
});
// if (api.systemType == 'ios') {
// api.openPicker({
// type: 'date_time',
// date: new Date(),
// maxDate: getTimeDetil(0),
// title: '测量时间'
// }, function (ret, err) {
// console.log(ret)
// if (ret) {
// var year = ret.year;
// var month = ret.month;
// var day = ret.day;
// var hour = ret.hour;
// var minute = ret.minute;
// var date_info = year + '-' + add0(month) + '-' + add0(day) + ' ' + add0(hour) + ':' + add0(minute);
// if (checkDate(date_info, 2)) {
// $('.date_item').html(date_info)
// } else {
// toastMsg('选择日期不能大于当前时间');
// $('.date_item').html('请选择测量时间')
// }
// } else {
// console.log(err)
// }
// });
// }
// else {
// api.openPicker({
// type: 'date',
// title: '服务日期',
// }, function (ret, err) {
// if (ret) {
// var year = ret.year;
// var month = ret.month;
// var day = ret.day;
// api.openPicker({
// type: 'time',
// title: '服务时间'
// }, function (rets, errs) {
// if (rets) {
// var hour = rets.hour;
// var minute = rets.minute;
// var date_info = year + '-' + add0(month) + '-' + add0(day) + ' ' + add0(hour) + ':' + add0(minute);
// if (checkDate(date_info, 2)) {
// $('.date_item').html(date_info);
// } else {
// toastMsg('选择日期不能大于当前时间');
// $('.date_item').html('请选择测量时间')
// }
// } else {
// console.log(errs)
// }
// });
// } else {
// console.log(err)
// }
// });
// }
});
$('.save_btn').click(function () {
var value = $('.knob').val();
var date = $('.date_item').text();
var type = $('.sugar_type').attr('data-type');
var date = $('#test04').val();
// type = $('.sugar_type').attr('data-type');
type = $('.spanactive').attr('data-id')
console.log(type)
var post = {
rid: api.pageParam.rid,
time_type: type,
time: date,
data: value,
type: 1
type: type
};
var header = {
"XX-Device-Type": getDevice(),
... ... @@ -246,7 +286,7 @@
} else if (type == '') {
toastMsg('请选择具体测试时间')
}
else if (date == '请选择测量时间') {
else if (date == '') {
toastMsg('请选择测量时间')
} else {
getRequest('post', 'user/index/setBoolData', post, header).then(function (res) {
... ... @@ -270,4 +310,4 @@
})
}
});
</script>
\ No newline at end of file
</script>
... ...