Commit 1b039f01 authored by shiyu's avatar shiyu

删除笔记,打开记录设置为无效

parent ceb3ab91
......@@ -5,6 +5,7 @@ import com.wwdz.ch.core.type.PageSearchResult;
import com.wwdz.ch.core.type.Result;
import com.wwdz.ch.db.dao.qiandao.*;
import com.wwdz.ch.db.domain.qiandao.QdUser;
import com.wwdz.ch.db.domain.qiandao.QdUserSignIn;
import com.wwdz.ch.db.domain.qiandao.QdUserSignInNote;
import com.wwdz.ch.db.domain.qiandao.SignInTask;
import com.wwdz.ch.db.dto.request.qiandao.QdUserSignInNoteRequestDto;
......@@ -153,6 +154,14 @@ public class QdUserSignInNoteServiceImpl implements QdUserSignInNoteService {
qdUserSignInNote.setUpdateTime(new Date());
qdUserSignInNote.setIsDeleted(true);
qdUserSignInNoteDao.updateByPrimaryKey(qdUserSignInNote);
//打开记录设置为无效
QdUserSignInNote signInNote = qdUserSignInNoteDao.findByNoteId(dto.getId());
QdUserSignIn qdUserSignIn = new QdUserSignIn();
qdUserSignIn.setId(signInNote.getRecordId());
qdUserSignIn.setIsValid(false);
qdUserSignIn.setUpdateTime(new Date());
qdUserSignInDao.updateByPrimaryKey(qdUserSignIn);
return Result.success();
} catch (Exception e) {
logger.error("删除笔记 error:{}", e);
......
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