征求意见-(代码修改)
This commit is contained in:
+1
-1
@@ -83,7 +83,7 @@ public class SarPublicIdeaController extends BaseController<SarPublicIdea> {
|
||||
//
|
||||
Calendar c2 = Calendar.getInstance();
|
||||
c2.setTime(sarPublicIdea.getEndTime());
|
||||
c2.add(Calendar.DAY_OF_MONTH, 0);// 今天+1天
|
||||
c2.add(Calendar.DAY_OF_MONTH, +1);// 今天+1天
|
||||
sarPublicIdea.setEndTime(c2.getTime());
|
||||
|
||||
sarPublicIdeaService.save(sarPublicIdea);
|
||||
|
||||
-13
@@ -52,19 +52,6 @@ public class SarPublicIdeaServiceImpl extends ServiceImpl<SarPublicIdeaDao, SarP
|
||||
String date1 = (new SimpleDateFormat("yyyy-MM-dd")).format(start);
|
||||
String date2 = (new SimpleDateFormat("yyyy-MM-dd")).format(end);
|
||||
|
||||
// Date classDate = null;
|
||||
// try {
|
||||
// classDate = new SimpleDateFormat("yyyy-MM-dd").parse(date3);
|
||||
// Calendar calendar = Calendar.getInstance(); //使用Calendar日历类对日期进行加减
|
||||
// calendar.setTime(classDate);
|
||||
// calendar.add(Calendar.DAY_OF_MONTH, - 1);
|
||||
// classDate = calendar.getTime();//获取加减以后的Date类型日期
|
||||
//
|
||||
// } catch (ParseException e) {
|
||||
// e.printStackTrace();
|
||||
// }
|
||||
// ;//把字符串转化成指定格式的日期
|
||||
// String date2 =(new SimpleDateFormat("yyyy-MM-dd")).format(classDate);
|
||||
|
||||
list.like(StringUtils.isNotEmpty(category), "category", category)
|
||||
.like(StringUtils.isNotEmpty(cname), "cid", cname)
|
||||
|
||||
@@ -116,7 +116,7 @@ public class DateUtil {
|
||||
Calendar theCa = Calendar.getInstance();
|
||||
theCa.setTime(today);
|
||||
theCa.add(Calendar.MONTH, 0);
|
||||
theCa.set(Calendar.DAY_OF_MONTH, 1);
|
||||
theCa.set(Calendar.DAY_OF_MONTH, +1);
|
||||
Date start = theCa.getTime();
|
||||
startDate = sdf.format(start);
|
||||
} catch (ParseException e) {
|
||||
|
||||
Reference in New Issue
Block a user