1.增加了重力感应,也就是横屏响应式布局。
2.修改了沉浸式布局。 3.修改了添加日程和编辑日程页面,增加了重复、提醒等功能。 4.修改了权限问题,如果日历本是只读,则有删除线做标识。同时,对于只读的日程,点击后将不再进入编辑页面,而是展示详情。 5.系统日历的处理。给用户两个选择,第一个选择就是只显示系统日历。第二种选择,用户可以选择一个caldav账户中的某一个日历本,把系统日历中的日程,包括日历日程和应用创建的日程,都读取出来,然后加入到这个日历本下,最后同步到caldav的服务器上,这样的好处是,手机丢失了,或者换了手机品牌型号,手机上的日程仍然在自己的caldav服务器上有一个备份。当然,系统日历中的caldav日历,就不会再读取了。
This commit is contained in:
@@ -26,6 +26,8 @@ export class DavAccount {
|
||||
calendarNames: string[] = [];
|
||||
/** 服务器端定义的日历本颜色(calendar-color),与 calendarHrefs 一一对应,空串表示未定义 */
|
||||
calendarColors: string[] = [];
|
||||
/** 各日历本写权限('1'=可写 '0'=只读),与 calendarHrefs 一一对应;空数组表示未知(按可写处理) */
|
||||
calendarWritable: string[] = [];
|
||||
itemCount: number = 0;
|
||||
lastSyncTime: string = '';
|
||||
}
|
||||
@@ -37,6 +39,7 @@ export class CalSource {
|
||||
color: string = '#007DFF';
|
||||
source: string = 'dav'; // 'dav' | 'system' | 'local'
|
||||
visible: boolean = true;
|
||||
writable: boolean = true; // 只读日历本中的日程只能查看详情,不能编辑
|
||||
}
|
||||
|
||||
/** 与 UI 无关的调色板 */
|
||||
@@ -81,7 +84,8 @@ export class AccountStore {
|
||||
acc.calendarHrefs.join(';'),
|
||||
acc.calendarNames.join(';'),
|
||||
acc.calendarColors.join(';'),
|
||||
safe(acc.id)
|
||||
safe(acc.id),
|
||||
acc.calendarWritable.join(';')
|
||||
];
|
||||
return parts.join('|');
|
||||
}
|
||||
@@ -109,6 +113,9 @@ export class AccountStore {
|
||||
if (parts.length >= 11) {
|
||||
acc.id = parts[10];
|
||||
}
|
||||
if (parts.length >= 12) {
|
||||
acc.calendarWritable = parts[11] === '' ? [] : parts[11].split(';');
|
||||
}
|
||||
return acc;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user