mirror of
https://github.com/FatttSnake/Pinnacle-OA.git
synced 2026-04-05 23:11:24 +08:00
modify the el-=cascader in page of NoticeCommitForm
This commit is contained in:
@@ -69,7 +69,7 @@ public class NoticeController {
|
||||
@PreAuthorize("hasAuthority('notice:self:get')")
|
||||
public ResponseResult<List<Notice>> selectByUserId(Integer readStatus,String title, String type, String startTime, String endTime) {
|
||||
List<Notice> noticesByUserId = noticeReceiveService.selectByUserId(readStatus, title.trim(), type.trim(), startTime.trim(), endTime.trim());
|
||||
Integer code = noticesByUserId != null ? ResponseCode.DATABASE_SELECT_OK : ResponseCode.DATABASE_SELECT_ERROR;
|
||||
int code = noticesByUserId != null ? ResponseCode.DATABASE_SELECT_OK : ResponseCode.DATABASE_SELECT_ERROR;
|
||||
String msg = noticesByUserId != null ? "" : "数据查询失败,请重试!";
|
||||
return ResponseResult.build(code, msg, noticesByUserId);
|
||||
}
|
||||
|
||||
@@ -84,7 +84,13 @@
|
||||
}}</span>
|
||||
<span v-if="scope.node.level === 2">{{
|
||||
((scope.node.value = scope.data.id),
|
||||
(scope.node.label = scope.data.username))
|
||||
(scope.node.label = scope.data.staff
|
||||
? scope.data.staff.lastName +
|
||||
scope.data.staff.firstName +
|
||||
'(' +
|
||||
scope.data.username +
|
||||
')'
|
||||
: scope.data.username))
|
||||
}}</span>
|
||||
</template>
|
||||
</el-cascader>
|
||||
@@ -140,7 +146,6 @@ export default {
|
||||
content: [{ required: true, message: '请填写公告内容', trigger: 'blur' }],
|
||||
receivers: [
|
||||
{
|
||||
type: 'array',
|
||||
required: true,
|
||||
message: '请选择公告接收者',
|
||||
trigger: 'change'
|
||||
|
||||
@@ -201,8 +201,8 @@ export const useNoticeStore = defineStore('notice', {
|
||||
this.departmentList = response.data.data
|
||||
})
|
||||
},
|
||||
handleAddNotice(addFormData: IAddNoticeData) {
|
||||
void request.post('/notice', addFormData).then((response) => {
|
||||
async handleAddNotice(addFormData: IAddNoticeData) {
|
||||
await request.post('/notice', addFormData).then((response) => {
|
||||
if (response.data.code === DATABASE_SAVE_OK) {
|
||||
this.dialogAddVisible = false
|
||||
ElMessage({
|
||||
@@ -218,8 +218,8 @@ export const useNoticeStore = defineStore('notice', {
|
||||
})
|
||||
this.selectAllNotice(1, 5, '', '', '', '', [])
|
||||
},
|
||||
handleUpdateNotice(updateNotice: IAddNoticeData) {
|
||||
void request.put('/notice', updateNotice).then((response) => {
|
||||
async handleUpdateNotice(updateNotice: IAddNoticeData) {
|
||||
await request.put('/notice', updateNotice).then((response) => {
|
||||
if (response.data.code === DATABASE_UPDATE_OK) {
|
||||
this.dialogEditVisible = false
|
||||
this.editFlag = false
|
||||
|
||||
Reference in New Issue
Block a user