Commit f4bc09a7 by 丁伟

1、通知公告管理增加查询条件;

2、修复用户密码发送邮件失败问题。
parent 781e000a
...@@ -15,11 +15,11 @@ ...@@ -15,11 +15,11 @@
<property name="yearIsDateType" value="false" /> <property name="yearIsDateType" value="false" />
</driver-properties> </driver-properties>
</data-source> </data-source>
<data-source source="LOCAL" name="sfzxWebsite@localhost" uuid="a69ddf70-6cac-49ce-9296-dba84c6eefc0"> <data-source source="LOCAL" name="sfzx_website@localhost" uuid="d6e72dfc-b1e7-4ef9-9cec-6c86bdaf7493">
<driver-ref>mysql.8</driver-ref> <driver-ref>mysql.8</driver-ref>
<synchronize>true</synchronize> <synchronize>true</synchronize>
<jdbc-driver>com.mysql.cj.jdbc.Driver</jdbc-driver> <jdbc-driver>com.mysql.cj.jdbc.Driver</jdbc-driver>
<jdbc-url>jdbc:mysql://localhost:3306/sfzxWebsite</jdbc-url> <jdbc-url>jdbc:mysql://localhost:3306/sfzx_website</jdbc-url>
<driver-properties> <driver-properties>
<property name="autoReconnect" value="true" /> <property name="autoReconnect" value="true" />
</driver-properties> </driver-properties>
......
...@@ -246,7 +246,7 @@ public class OrgController extends BaseController { ...@@ -246,7 +246,7 @@ public class OrgController extends BaseController {
PageRequest pageRequest = this.getPage(request); PageRequest pageRequest = this.getPage(request);
Page<User> users = new Page<User>(pageRequest); Page<User> users = new Page<User>(pageRequest);
boolean flag = false; boolean flag = false;
if(null != orgId){ if(null != orgId ){
OrgInfo org = orgService.getOrgById(Long.valueOf(orgId)); OrgInfo org = orgService.getOrgById(Long.valueOf(orgId));
Set<User> userSet = org.getUsers(); Set<User> userSet = org.getUsers();
List<User> userList = new ArrayList<User>(userSet); List<User> userList = new ArrayList<User>(userSet);
......
...@@ -749,7 +749,7 @@ public class StringUtil { ...@@ -749,7 +749,7 @@ public class StringUtil {
* @since JDK 1.6 * @since JDK 1.6
*/ */
public static String getRandomString(int length) { public static String getRandomString(int length) {
String base = "abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ~!@#$%^&*()<>?"; String base = "abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ~!@#$%^";
Random random = new Random(); Random random = new Random();
StringBuffer sb = new StringBuffer(); StringBuffer sb = new StringBuffer();
for (int i = 0; i < length; i++) { for (int i = 0; i < length; i++) {
......
...@@ -66,8 +66,8 @@ public class NoticeController extends BaseController { ...@@ -66,8 +66,8 @@ public class NoticeController extends BaseController {
public Object queryAllNotice(HttpServletRequest request,Notice Notice) { public Object queryAllNotice(HttpServletRequest request,Notice Notice) {
PageRequest pageRequest = getPage(request); PageRequest pageRequest = getPage(request);
String title = request.getParameter("noticeTitle"); String title = request.getParameter("noticeTitle");
String newsType = request.getParameter("newsType"); String noticeType = request.getParameter("noticeType");
Page<Notice> pageInformation = noticeService.queryNotices(pageRequest, title,newsType); Page<Notice> pageInformation = noticeService.queryNotices(pageRequest, title,noticeType);
// pageInformation.getRows().forEach(Notice -> { // pageInformation.getRows().forEach(Notice -> {
// noticeService.createNoticesIndex(Notice); // noticeService.createNoticesIndex(Notice);
// }); // });
......
...@@ -127,13 +127,13 @@ public class NoticeService { ...@@ -127,13 +127,13 @@ public class NoticeService {
} }
public Page<Notice> queryNotices(PageRequest pageRequest, String noticeTitle, public Page<Notice> queryNotices(PageRequest pageRequest, String noticeTitle,
String newsType) { String noticeType) {
StringBuffer hql = new StringBuffer("from Notice where 1=1"); StringBuffer hql = new StringBuffer("from Notice where 1=1");
if (noticeTitle != null && !"".equals(noticeTitle)) { if (noticeTitle != null && !"".equals(noticeTitle)) {
hql.append(" and noticeTitle like '%" + noticeTitle + "%'"); hql.append(" and noticeTitle like '%" + noticeTitle + "%'");
} }
if (newsType != null && !"".equals(newsType)) { if (noticeType != null && !"".equals(noticeType)) {
hql.append(" and noticeType = " + Integer.parseInt(newsType)); hql.append(" and noticeType = " + Integer.parseInt(noticeType));
} }
hql.append(" order by createTime desc"); hql.append(" order by createTime desc");
return noticeDao.findPage(pageRequest, hql.toString(), null); return noticeDao.findPage(pageRequest, hql.toString(), null);
......
# jdbc.X # jdbc.X
jdbc.driverClassName=com.mysql.jdbc.Driver jdbc.driverClassName=com.mysql.jdbc.Driver
#dev model #dev model
#jdbc.url=jdbc:mysql://localhost:3306/sfzxWebsite?createDatabaseIfNotExist=true&characterEncoding=utf-8 #jdbc.url=jdbc:mysql://localhost:3306/sfzx_website?createDatabaseIfNotExist=true&characterEncoding=utf-8
#jdbc.user=ccpit #jdbc.user=ccpit
#jdbc.pass=ccpit1516 #jdbc.pass=ccpit1516
#server model #server model
...@@ -26,11 +26,11 @@ system.telphone=010-88077376 ...@@ -26,11 +26,11 @@ system.telphone=010-88077376
file.maxSize = 100 file.maxSize = 100
#chinese #chinese
system.name=\u4E2D\u56FD\u8D38\u4FC3\u4F1A\u53F0\u6E2F\u6FB3\u4F01\u4E1A\u670D\u52A1\u4E2D\u5FC3\u5B98\u7F51\u7CFB\u7EDF system.name=\u4E2D\u56FD\u8D38\u4FC3\u4F1A\u539F\u4EA7\u5730\u8BC1\u5B98\u7F51\u7CFB\u7EDF
# dev server address # dev server address
#system.visit_url=http://localhost:86/admin/login #system.visit_url=http://localhost:86/admin/login
# test server address # test server address
system.visit_url= system.visit_url=https://co.ccpit.org
# official server address # official server address
#upload File save path #upload File save path
......
...@@ -19,8 +19,12 @@ ...@@ -19,8 +19,12 @@
<form method="post" id="queryFormId2" name="queryForm"> <form method="post" id="queryFormId2" name="queryForm">
<table class="querytable" align="center" width="100%" border="0"> <table class="querytable" align="center" width="100%" border="0">
<tr> <tr>
<td width="25%" align="right"><span>通知公告标题:</span></td> <td width="15%" align="right"><span>标题:</span></td>
<td width="35%" align="left"><input id="titleId00" name='noticeTitle' title="50字以内" class="easyui-textbox" /> <td width="25%" align="left"><input id="titleId00" name='noticeTitle' title="50字以内" class="easyui-textbox" />
<td width="15%" align="right"><span>类型:</span></td>
<td width="25%" align="left">
<input id="noticeTypeId00" name="noticeType" class="easyui-combobox" >
</td>
<td> <td>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;
<a id="saveButtonId01" href="#" class="easyui-linkbutton" iconCls="icon-search" onclick="queryData()">查询</a> <a id="saveButtonId01" href="#" class="easyui-linkbutton" iconCls="icon-search" onclick="queryData()">查询</a>
......
...@@ -102,12 +102,12 @@ ...@@ -102,12 +102,12 @@
</div> </div>
</security:url> </security:url>
<security:url uri="/org/ccpit/business/noticeManage"> <security:url uri="/org/ccpit/business/noticeManage">
<div title="通知公告管理" data-options="collapsible:true"> <div title="通知公告及政策管理" data-options="collapsible:true">
<ul> <ul>
<li><security:url uri="/business/noticeManage/goinNoticePage"><div> <li><security:url uri="/business/noticeManage/goinNoticePage"><div>
<a href="#" rel="/business/noticeManage/goinNoticePage"> <a href="#" rel="/business/noticeManage/goinNoticePage">
<span class="huiyuanxinxi">&nbsp;</span> <span class="huiyuanxinxi">&nbsp;</span>
<span class="nav">通知公告信息</span> <span class="nav">通知公告及政策信息</span>
</a> </a>
</div></security:url></li> </div></security:url></li>
<li> <li>
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
</div> </div>
</security:url> </security:url>
<security:url uri="/org/ccpit/business/questionManage"> <security:url uri="/org/ccpit/business/questionManage">
<div title="问题管理" data-options="collapsible:true"> <div title="常见问题管理" data-options="collapsible:true">
<ul> <ul>
<li><security:url uri="/business/questionManage/goinQuestionPage"><div> <li><security:url uri="/business/questionManage/goinQuestionPage"><div>
<a href="#" rel="/business/questionManage/goinQuestionPage"> <a href="#" rel="/business/questionManage/goinQuestionPage">
......
...@@ -701,7 +701,7 @@ function sendMail(){ ...@@ -701,7 +701,7 @@ function sendMail(){
"ids":jsonIds},function(result){ "ids":jsonIds},function(result){
if (result.flag){ if (result.flag){
$.messager.alert('提示',result.info,'ok'); $.messager.alert('提示',result.info,'ok');
initUserList(); // initUserList();
closeWindow1(); closeWindow1();
} else { } else {
$.messager.alert('提示',result.info,'error'); $.messager.alert('提示',result.info,'error');
......
...@@ -48,6 +48,19 @@ function initInputWidth(){ ...@@ -48,6 +48,19 @@ function initInputWidth(){
} }
} }
}); });
$("#noticeTypeId00").combobox({
url : '/admin/metadataManage/getMetadatasList?dataType='+encodeURI(encodeURI(dataType_infoStatus)),
width : fixShortWidth(),
panelHeight : 'auto',
panelHeight : 'auto',
valueField : 'id',
textField : 'text',
onLoadSuccess : function() {
$("#noticeTypeId00").combobox("select", "通知公告");
$("#noticeTypeId00").combobox("setValue", 1);
}
});
$("#infotatusId").combobox({ $("#infotatusId").combobox({
url : '/admin/metadataManage/getMetadatasList?dataType='+encodeURI(encodeURI(infoStatus)), url : '/admin/metadataManage/getMetadatasList?dataType='+encodeURI(encodeURI(infoStatus)),
width : fixShortWidth(), width : fixShortWidth(),
...@@ -351,10 +364,12 @@ function arrayTojson(arr) { ...@@ -351,10 +364,12 @@ function arrayTojson(arr) {
//查询 //查询
function queryData() { function queryData() {
var noticeTitle = $("#titleId00").val(); var noticeTitle = $("#titleId00").val();
var noticeType = $("#noticeTypeId00").combobox('getValue');
var queryParams = null; var queryParams = null;
$("#noticeTable").datagrid({ $("#noticeTable").datagrid({
queryParams : { queryParams : {
noticeTitle : noticeTitle noticeTitle: noticeTitle,
noticeType: noticeType
} }
}); });
} }
......
# jdbc.X # jdbc.X
jdbc.driverClassName=com.mysql.jdbc.Driver jdbc.driverClassName=com.mysql.jdbc.Driver
#dev model #dev model
jdbc.url=jdbc:mysql://localhost:3306/sfzxWebsite?createDatabaseIfNotExist=true&characterEncoding=utf-8 #jdbc.url=jdbc:mysql://localhost:3306/sfzx_website?createDatabaseIfNotExist=true&characterEncoding=utf-8
jdbc.user=ccpit #jdbc.user=ccpit
jdbc.pass=ccpit1516 #jdbc.pass=ccpit1516
#server model #server model
#jdbc.url=jdbc:mysql://mysql:3306/sfzx_website?createDatabaseIfNotExist=true&characterEncoding=utf-8 jdbc.url=jdbc:mysql://mysql:3306/sfzx_website?createDatabaseIfNotExist=true&characterEncoding=utf-8
#jdbc.user=root jdbc.user=root
#jdbc.pass=root jdbc.pass=root
# hibernate.X # hibernate.X
hibernate.dialect=org.hibernate.dialect.MySQL5Dialect hibernate.dialect=org.hibernate.dialect.MySQL5Dialect
hibernate.show_sql=false hibernate.show_sql=false
...@@ -26,11 +26,11 @@ system.telphone=010-88077376 ...@@ -26,11 +26,11 @@ system.telphone=010-88077376
file.maxSize = 100 file.maxSize = 100
#chinese #chinese
system.name=\u4E2D\u56FD\u8D38\u4FC3\u4F1A\u53F0\u6E2F\u6FB3\u4F01\u4E1A\u670D\u52A1\u4E2D\u5FC3\u5B98\u7F51\u7CFB\u7EDF system.name=\u4E2D\u56FD\u8D38\u4FC3\u4F1A\u539F\u4EA7\u5730\u8BC1\u5B98\u7F51\u7CFB\u7EDF
# dev server address # dev server address
#system.visit_url=http://localhost:86/admin/login #system.visit_url=http://localhost:86/admin/login
# test server address # test server address
system.visit_url= system.visit_url=https://co.ccpit.org
# official server address # official server address
#upload File save path #upload File save path
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment