frame2.html 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
  6. <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
  7. <title>工作台</title>
  8. <link rel="stylesheet" type="text/css" href="../../css/api.css" />
  9. <link rel="stylesheet" href="../../css/animate.css">
  10. <link rel="stylesheet" href="../../css/style.css">
  11. <style>
  12. body,
  13. html {
  14. background: rgba(243, 243, 243, 1)
  15. }
  16. .banner img {
  17. width: 100%;
  18. }
  19. /*天气*/
  20. /*.weather-wrap{
  21. padding: 21px 0;
  22. }*/
  23. /*nav*/
  24. .nav-itme {
  25. padding: 15px 20px 15px 15px;
  26. background: #fff;
  27. margin-bottom: 2px;
  28. position: relative;
  29. }
  30. .nav-itme:active {
  31. background: rgba(243, 243, 243, .9);
  32. }
  33. .nav-itme:last-child {
  34. margin-bottom: 0;
  35. }
  36. .title-wrap {
  37. color: #232627;
  38. font-size: 14px;
  39. }
  40. .title-wrap p {
  41. color: #7D7C7C;
  42. font-size: 12px;
  43. }
  44. /*.header-ico {
  45. width: 39px;
  46. height: 39px;
  47. display: block;
  48. background: url("../../icon/tzgg.png") center no-repeat;
  49. background-size: contain;
  50. margin-right: 15px;
  51. }*/
  52. .header-ico {
  53. width: 39px;
  54. height: 39px;
  55. display: block;
  56. margin-right: 15px;
  57. }
  58. /*.nav-itme:nth-child(2) .header-ico {
  59. background: url("../../icon/dbgz.png") center no-repeat;
  60. background-size: contain;
  61. }
  62. .nav-itme:nth-child(3) .header-ico {
  63. background: url("../../icon/zbxx.png") center no-repeat;
  64. background-size: contain;
  65. }
  66. .nav-itme:nth-child(4) .header-ico {
  67. background: url("../../icon/hyap.png") center no-repeat;
  68. background-size: contain;
  69. }
  70. .nav-itme:nth-child(5) .header-ico {
  71. background: url("../../icon/txl.png") center no-repeat;
  72. background-size: contain;
  73. }*/
  74. .more {
  75. width: 16px;
  76. height: 16px;
  77. display: block;
  78. background: url("../../image/more.png") center no-repeat;
  79. background-size: contain;
  80. }
  81. /*矿区服务*/
  82. .mine-service {
  83. margin: 5px 0;
  84. background: rgba(243, 243, 243, 1)
  85. }
  86. .mine-title {
  87. font-size: 16px;
  88. }
  89. .mine-titleIco {
  90. width: 25px;
  91. height: 25px;
  92. display: block;
  93. margin-right: 10px;
  94. }
  95. .mine-items {
  96. margin-top: 10px;
  97. flex-wrap: wrap;
  98. }
  99. .mine-item {
  100. width: 50%;
  101. margin: 12px 0;
  102. box-sizing: border-box;
  103. }
  104. .mine-item:nth-child(even) {
  105. padding-left: 20px;
  106. position: relative;
  107. }
  108. .mine-item:nth-child(even):after {
  109. content: '';
  110. position: absolute;
  111. top: 0;
  112. left: 0;
  113. width: 1px;
  114. height: 100%;
  115. background: #E8E8E8;
  116. }
  117. /*生活服务*/
  118. .life-service {
  119. margin: 0;
  120. margin-bottom: 20px;
  121. }
  122. /*工资密码*/
  123. .wages-layout {
  124. width: 100%;
  125. height: 100%;
  126. position: fixed;
  127. top: 0;
  128. left: 0;
  129. background: rgba(0, 0, 0, 0.5);
  130. }
  131. .wages {
  132. position: absolute;
  133. top: 0;
  134. left: 0;
  135. right: 0;
  136. bottom: 0;
  137. width: 300px;
  138. height: 200px;
  139. margin: auto;
  140. background: #fff;
  141. border-radius: 5px;
  142. padding: 10px;
  143. }
  144. .wages-title {
  145. text-align: center;
  146. font-size: 18px;
  147. }
  148. .wages-wrap {
  149. padding: 15px 10px 0 10px;
  150. box-sizing: border-box;
  151. }
  152. .wages-wrap input {
  153. width: 100%;
  154. height: 35px;
  155. border: 1px solid #E8E8E8;
  156. border-radius: 5px;
  157. padding-left: 10px;
  158. box-sizing: border-box;
  159. }
  160. .btn-term {
  161. text-align: center;
  162. margin-top: 20px;
  163. position: absolute;
  164. bottom: 10px;
  165. left: 0;
  166. width: 100%;
  167. padding: 0 10px;
  168. box-sizing: border-box;
  169. }
  170. .btn-term button {
  171. width: 49%;
  172. padding: 10px 0;
  173. text-align: center;
  174. border-radius: 3px;
  175. }
  176. .btn-close {
  177. border: 1px solid #E8E8E8;
  178. }
  179. .btn-close:active {
  180. background: #E8E8E8;
  181. }
  182. .btn-confirm:active {
  183. background: rgba(0, 159, 232, .7);
  184. border: 1px solid rgba(0, 159, 232, .7);
  185. }
  186. .btn-confirm {
  187. margin-top: 10px;
  188. border: 1px solid #009fe8;
  189. background: #009fe8;
  190. color: #fff;
  191. }
  192. .Tips {
  193. color: #6C6F74;
  194. font-size: 12px;
  195. padding: 0 10px;
  196. margin-top: 20px;
  197. }
  198. </style>
  199. </head>
  200. <body>
  201. <div class="api_layout">
  202. <!--banner-->
  203. <!-- <div class="banner">
  204. <img src="../../icon/workBanner.jpeg" alt="">
  205. </div> -->
  206. <div id="worderbenList"></div>
  207. <div id="worderbenListNav"></div>
  208. <!-- 天气-->
  209. <div class="weather-wrap">
  210. </div>
  211. </div>
  212. <!-- 工资密码-->
  213. <div class="wages-layout" id="wages-layout" style="display: none;">
  214. <div class="wages">
  215. <h3 class="wages-title">工资权限验证</h3>
  216. <div class="wages-wrap">
  217. <input type="password" placeholder="请输入登陆密码" class="password">
  218. <p class="Tips-p" style="color:red;font-size:12px;margin-top:5px;"></p>
  219. </div>
  220. <div class="Tips">
  221. <span>友情提示:该密码为用户登陆密码。</span>
  222. </div>
  223. <div class="btn-term">
  224. <button type="button" name="button" class="btn-close" onclick="closeWages()">取消</button>
  225. <button type="button" name="button" class="btn-confirm" onclick="wagesJurisdiction()">确认</button>
  226. </div>
  227. </div>
  228. </div>
  229. </body>
  230. </html>
  231. <script type="text/javascript" src="../../script/api.js"></script>
  232. <script type="text/javascript" src="../../script/zepto.js"></script>
  233. <script src="../../script/config.js" charset="utf-8"></script>
  234. <script src="../../script/doT.min.js" charset="utf-8"></script>
  235. <script type="text/template" id="templateWorkbench">
  236. <div class="banner">
  237. <img src="{{=it.header}}" alt="">
  238. </div>
  239. <div class="nav-wrap">
  240. <ul class="nav-itmes">
  241. {{ for(var i = 0; i < it.nav.length; i++ ) { }}
  242. <li class="flex-space nav-itme" onclick="openNewsList('{{=it.nav[i].title}}')">
  243. <div class="flex-start">
  244. <!-- <span class="header-ico"></span> -->
  245. <img class="header-ico" src="{{=it.nav[i].icon}}" alt="">
  246. <div class="title-wrap">
  247. <label>{{=it.nav[i].title}}</label>
  248. <p>{{=it.nav[i].sub_title}}</p>
  249. </div>
  250. </div>
  251. <i class="more"></i>
  252. </li>
  253. {{ } }}
  254. </ul>
  255. </div>
  256. <div class="mine-service life-service">
  257. {{ for(var k = 0; k < it.module.length; k++ ) { }}
  258. <div style="background: #fff; margin-top: 5px;padding: 10px 15px 0 15px">
  259. <div class="mine-title flex-start">
  260. <img class="mine-titleIco" src="{{=it.module[k].icon}}" alt="">
  261. <label>{{=it.module[k].title}}</label>
  262. </div>
  263. <ul class="flex-space mine-items">
  264. {{ for(var j = 0; j < it.module[k].children.length; j++ ) { }}
  265. <li class="mine-item life-item" onclick="openmineServiceItem('{{=it.module[k].children[j].title}}')">
  266. <div class="flex-start">
  267. <img class="header-ico" src="{{=it.module[k].children[j].icon}}" alt="">
  268. <div class="title-wrap">
  269. <label>{{=it.module[k].children[j].title}}</label>
  270. <p>{{=it.module[k].children[j].sub_title}}</p>
  271. </div>
  272. </div>
  273. </li>
  274. {{ } }}
  275. </ul>
  276. </div>
  277. {{ } }}
  278. </div>
  279. </script>
  280. <script type="text/javascript">
  281. var jobID = "";
  282. apiready = function() {
  283. var info = $api.getStorage('data');
  284. jobID = JSON.parse(info).data.user.staff_num;
  285. getWorkbenchList()
  286. }
  287. // 工资密码
  288. function openWages() {
  289. $('.password').val('');
  290. $('.Tips-p').html('');
  291. $('.wages-layout').show();
  292. $('.wages').addClass('animated bounceInDown');
  293. setTimeout(function() {
  294. $('.wages').removeClass('animated bounceInDown')
  295. }, 1000);
  296. }
  297. window.onclick = function(event) {
  298. if (event.target == document.getElementById('wages-layout')) {
  299. $('.wages-layout').hide();
  300. }
  301. }
  302. function closeWages() {
  303. $('.wages-layout').hide();
  304. };
  305. // 工资权限验证
  306. function wagesJurisdiction() {
  307. var param = {
  308. staff_num: jobID,
  309. password: $('.password').val()
  310. }
  311. $http.fnReuestDataNologing(UrlRouter.getPassword, '', 'post', param, function(ret, err) {
  312. if (ret.code === 0) {
  313. $('.wages-layout').hide();
  314. $('.Tips-p').html('');
  315. wages('工资查询');
  316. } else if (ret.code === 1) {
  317. $('.Tips-p').html(ret.message)
  318. }
  319. })
  320. }
  321. function getWorkbenchList() {
  322. $http.fnReuestDataNologing(UrlRouter.getWorkbenchList, '', 'get', '', function(ret, err) {
  323. $apis.html(worderbenList, '#templateWorkbench', ret.data);
  324. })
  325. }
  326. // 第三方链接跳转
  327. function Jump(url, title) {
  328. $event.openWin('jumpURL', '../workBench/jumpURL', {
  329. url: url,
  330. title: title
  331. }, '');
  332. }
  333. //发票
  334. function Invaice(title) {
  335. $event.openTabLayout('invoice', '../workBench/invoice', title, '');
  336. }
  337. //值班
  338. function Duty(title) {
  339. $event.openWin('getDuty', '../workBench/getDuty', '', '');
  340. }
  341. //通讯录
  342. function organization(title) {
  343. $event.openWin('organization', '../mail/organization', '', '');
  344. }
  345. //工资
  346. function wages(title) {
  347. $event.openTabLayout('wages', '../workBench/wages', title, '');
  348. }
  349. // //消息列表
  350. function openNewsList(value) {
  351. if(value == '通知公告') {
  352. $event.openWin('newsList', '../news/news_win', '', '');
  353. } else if (value == '待办工作' || value == '通知公告' || value =='会议安排') {
  354. api.alert({
  355. title: '提示',
  356. msg: '此功能暂未上线,敬请期待',
  357. });
  358. } else if (value =='值班信息') {
  359. $event.openWin('getDuty', '../workBench/getDuty', '', '');
  360. }
  361. }
  362. function openmineServiceItem(value) {
  363. if(value == '工资查询') {
  364. $('.password').val('');
  365. $('.Tips-p').html('');
  366. $('.wages-layout').show();
  367. $('.wages').addClass('animated bounceInDown');
  368. setTimeout(function() {
  369. $('.wages').removeClass('animated bounceInDown')
  370. }, 1000);
  371. } else if (value == '发票助手') {
  372. $event.openTabLayout('invoice', '../workBench/invoice', '发票助手', '');
  373. } else if (value == '劳保发放' || value == '生活圈' || value == '小助手') {
  374. api.alert({
  375. title: '提示',
  376. msg: '此功能暂未上线,敬请期待',
  377. });
  378. } else if(value == '公积金查询'){
  379. Jump('http://gjj.yinchuan.gov.cn/list_gjjcx.jsp?urltype=tree.TreeTempUrl&wbtreeid=1044','公积金查询')
  380. } else if (value == '飞机火车票') {
  381. Jump('http://m.ctrip.com/html5/?sid=155952&allianceid=4897&ouid=index','飞机火车票')
  382. } else if (value == '美团外卖') {
  383. Jump('https://h5.waimai.meituan.com/waimai/mindex/home','美团外卖')
  384. } else if (value == '周边服务') {
  385. Jump('http://i.meituan.com/?city=yinchuan','周边服务')
  386. }
  387. }
  388. </script>