Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
bieyuan
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
hookehuyr
2023-09-04 16:09:24 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
77924420c1e1fa4088e6cf954c570529445b5022
77924420
1 parent
999adba0
fix 日历选择后需要保存值优化
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
src/views/preview.vue
src/views/preview.vue
View file @
7792442
...
...
@@ -167,10 +167,13 @@ const formatter = computed(() => { // 格式化日历文字显示
const onConfirm = async (dates) => { // 日历点击确认回调
show.value = false;
selectedDates.value = [];
defaultDate.value = [];
dates.forEach((date) => {
selectedDates.value.push(dayjs(date).format('YYYY-MM-DD'))
defaultDate.value.push(dayjs(date).toDate())
});
// 缓存修改日期
localStorage.setItem('save_selected_dates', JSON.stringify(selectedDates.value));
// 后台请求数据更新日期列表
const { data } = await orderRestCountAPI({ dates: selectedDates.value.join(',') });
shortcut.value = data;
...
...
Please
register
or
login
to post a comment