| @@ -60,7 +60,7 @@ | |||
| </div> | |||
| <div class="search"> | |||
| <input type="search" placeholder="搜索您需要的讯息" > | |||
| <input type="search" placeholder="搜索您需要的讯息" id="searchInput" oninput="searchChange()" > | |||
| </div> | |||
| <div class="new"> | |||
| @@ -81,7 +81,7 @@ | |||
| <div class="new_list"> | |||
| <div class="new_list_tit"> | |||
| <p>今日资讯</p> | |||
| <p>2023.03.15</p> | |||
| <p id="nowDateNYR">2023.03.15</p> | |||
| </div> | |||
| <div class="new_list_ul" id="newListContent"> | |||
| @@ -152,7 +152,7 @@ | |||
| border-radius: 15px; | |||
| padding: 3vh; | |||
| display: flex; | |||
| align-items: center; | |||
| /*align-items: center;*/ | |||
| } | |||
| .personalTit-banner { | |||
| @@ -165,6 +165,7 @@ | |||
| .new_list{ | |||
| margin-left: 2%; | |||
| width: 53%; | |||
| padding: 1vh 0; | |||
| } | |||
| .new_list_tit{ | |||
| @@ -14,7 +14,11 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| treeselectSecond:[{ | |||
| value:100, | |||
| label:'全部' | |||
| }] | |||
| }], | |||
| useType:[{ | |||
| dictValue:'', | |||
| dictLabel:'全部' | |||
| }], | |||
| }, | |||
| }; | |||
| var tools = new Tools(); | |||
| @@ -39,7 +43,10 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| module.webDeptType = function (data) { | |||
| if (data.code == 200) { | |||
| var content = data.data; | |||
| module.data.useType = content; | |||
| content.map(res=>{ | |||
| module.data.useType.push(res) | |||
| }) | |||
| // module.data.useType = content; | |||
| var useTypeData = template('useTypeData', module.data); | |||
| $("#useTypeContent").html(useTypeData); | |||
| } | |||
| @@ -131,7 +138,14 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| selectChange = function(){ | |||
| // tools.doGet(treeselectSecond+$('#treeselectContent').val(), {}, module.selectSecondChange , true); | |||
| module.data.treeselectSecond = module.data.treeselect.filter(function (e) { return e.value == $('#treeselectContent').val(); })[0].children; | |||
| if ($('#treeselectContent').val() == 100){ | |||
| module.data.treeselectSecond = [{ | |||
| value:100, | |||
| label:'全部' | |||
| }] | |||
| }else{ | |||
| module.data.treeselectSecond = module.data.treeselect.filter(function (e) { return e.value == $('#treeselectContent').val(); })[0].children; | |||
| } | |||
| var treeselectSecondData = template('treeselectSecondData', module.data); | |||
| $("#treeselectSecondContent").html(treeselectSecondData); | |||
| @@ -24,6 +24,9 @@ define(['jquery', "template", "Tools", 'swiper'], function ($, template, Tools, | |||
| autoplay : 2000, | |||
| loop:true | |||
| }) | |||
| $("#nowDateNYR").html(new Date().getFullYear()+'-'+(new Date().getMonth()+1)+'-'+new Date().getDate()); | |||
| }; | |||
| module.newsList = function (data) { | |||
| @@ -46,5 +49,9 @@ define(['jquery', "template", "Tools", 'swiper'], function ($, template, Tools, | |||
| } | |||
| } | |||
| searchChange = function () { | |||
| tools.doGet(newsList, {pageNum:1,pageSize:8,infoName:$("#searchInput").val()}, module.newsList , true); | |||
| } | |||
| return module; | |||
| }); | |||
| @@ -13,7 +13,11 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| treeselectSecond:[{ | |||
| value:100, | |||
| label:'全部' | |||
| }] | |||
| }], | |||
| useType:[{ | |||
| dictValue:'', | |||
| dictLabel:'全部' | |||
| }], | |||
| }, | |||
| }; | |||
| var tools = new Tools(); | |||
| @@ -41,7 +45,9 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| module.webDeptType = function (data) { | |||
| if (data.code == 200) { | |||
| var content = data.data; | |||
| module.data.useType = content; | |||
| content.map(res=>{ | |||
| module.data.useType.push(res) | |||
| }) | |||
| var useTypeData = template('useTypeData', module.data); | |||
| $("#useTypeContent").html(useTypeData); | |||
| } | |||
| @@ -133,10 +139,15 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| selectChange = function(){ | |||
| // tools.doGet(treeselectSecond+$('#treeselectContent').val(), {}, module.selectSecondChange , true); | |||
| if ($('#treeselectContent').val() == ''){ | |||
| console.log($('#treeselectContent').val()) | |||
| if ($('#treeselectContent').val() == 100){ | |||
| module.data.treeselectSecond = [{ | |||
| value:100, | |||
| label:'全部' | |||
| }] | |||
| }else{ | |||
| module.data.treeselectSecond = module.data.treeselect.filter(function (e) { return e.value == $('#treeselectContent').val(); })[0].children; | |||
| } | |||
| module.data.treeselectSecond = module.data.treeselect.filter(function (e) { return e.value == $('#treeselectContent').val(); })[0].children; | |||
| var treeselectSecondData = template('treeselectSecondData', module.data); | |||
| $("#treeselectSecondContent").html(treeselectSecondData); | |||
| @@ -13,7 +13,11 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| treeselectSecond:[{ | |||
| value:100, | |||
| label:'全部' | |||
| }] | |||
| }], | |||
| useType:[{ | |||
| dictValue:'', | |||
| dictLabel:'全部' | |||
| }], | |||
| }, | |||
| }; | |||
| var tools = new Tools(); | |||
| @@ -37,7 +41,10 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| module.webDeptType = function (data) { | |||
| if (data.code == 200) { | |||
| var content = data.data; | |||
| module.data.useType = content; | |||
| content.map(res=>{ | |||
| module.data.useType.push(res) | |||
| }) | |||
| // module.data.useType = content; | |||
| var useTypeData = template('useTypeData', module.data); | |||
| $("#useTypeContent").html(useTypeData); | |||
| } | |||
| @@ -129,7 +136,14 @@ define(['jquery', "template", "Tools", "paging", 'dateTime', 'swiper'], function | |||
| selectChange = function(){ | |||
| // tools.doGet(treeselectSecond+$('#treeselectContent').val(), {}, module.selectSecondChange , true); | |||
| module.data.treeselectSecond = module.data.treeselect.filter(function (e) { return e.value == $('#treeselectContent').val(); })[0].children; | |||
| if ($('#treeselectContent').val() == 100){ | |||
| module.data.treeselectSecond = [{ | |||
| value:100, | |||
| label:'全部' | |||
| }] | |||
| }else{ | |||
| module.data.treeselectSecond = module.data.treeselect.filter(function (e) { return e.value == $('#treeselectContent').val(); })[0].children; | |||
| } | |||
| var treeselectSecondData = template('treeselectSecondData', module.data); | |||
| $("#treeselectSecondContent").html(treeselectSecondData); | |||