diff --git a/Bin/Debug/MyTimeClock/Logs.txt b/Bin/Debug/MyTimeClock/Logs.txt
new file mode 100644
index 0000000..c5a8f00
--- /dev/null
+++ b/Bin/Debug/MyTimeClock/Logs.txt
@@ -0,0 +1,121 @@
+
+2020/9/13 23:18:29 提前一分钟休息提醒
+2020/9/13 23:18:29 提前一分钟休息弹窗提醒
+2020/9/13 23:32:32 提前一分钟休息提醒
+2020/9/13 23:32:32 提前一分钟休息弹窗提醒
+2020/9/14 9:03:24 提前一分钟休息提醒
+2020/9/14 9:03:24 提前一分钟休息弹窗提醒
+2020/9/14 9:11:41 提前一分钟休息提醒
+2020/9/14 9:11:41 提前一分钟休息弹窗提醒
+2020/9/14 11:25:21 提前一分钟休息提醒
+2020/9/14 11:25:21 提前一分钟休息弹窗提醒
+2020/9/14 11:33:21 提前一分钟休息提醒
+2020/9/14 11:33:21 提前一分钟休息弹窗提醒
+2020/9/14 14:28:29 提前一分钟休息提醒
+2020/9/14 14:28:29 提前一分钟休息弹窗提醒
+2020/9/14 15:30:39 提前一分钟休息提醒
+2020/9/14 15:30:39 提前一分钟休息弹窗提醒
+2020/9/14 16:39:46 提前一分钟休息提醒
+2020/9/14 16:39:46 提前一分钟休息弹窗提醒
+2020/9/14 16:48:55 提前一分钟休息提醒
+2020/9/14 16:48:55 提前一分钟休息弹窗提醒
+2020/9/14 16:58:24 提前一分钟休息提醒
+2020/9/14 16:58:24 提前一分钟休息弹窗提醒
+2020/9/14 17:06:24 提前一分钟休息提醒
+2020/9/14 17:06:24 提前一分钟休息弹窗提醒
+2020/9/15 11:10:04 提前一分钟休息提醒
+2020/9/15 11:10:04 提前一分钟休息弹窗提醒
+2020/9/15 16:04:17 提前一分钟休息提醒
+2020/9/15 16:04:17 提前一分钟休息弹窗提醒
+2020/9/15 17:13:39 提前一分钟休息提醒
+2020/9/15 17:13:39 提前一分钟休息弹窗提醒
+2020/9/15 17:21:39 提前一分钟休息提醒
+2020/9/15 17:21:39 提前一分钟休息弹窗提醒
+2020/9/15 17:29:39 提前一分钟休息提醒
+2020/9/15 17:29:39 提前一分钟休息弹窗提醒
+2020/9/16 10:30:29 提前一分钟休息提醒
+2020/9/16 10:30:29 提前一分钟休息弹窗提醒
+2020/9/16 11:44:13 提前一分钟休息提醒
+2020/9/16 11:44:13 提前一分钟休息弹窗提醒
+2020/9/16 14:35:46 提前一分钟休息提醒
+2020/9/16 14:35:46 提前一分钟休息弹窗提醒
+2020/9/16 14:43:46 提前一分钟休息提醒
+2020/9/16 14:43:46 提前一分钟休息弹窗提醒
+2020/9/16 14:51:46 提前一分钟休息提醒
+2020/9/16 14:51:46 提前一分钟休息弹窗提醒
+2020/9/17 9:21:32 提前一分钟休息提醒
+2020/9/17 9:21:32 提前一分钟休息弹窗提醒
+2020/9/17 9:29:33 提前一分钟休息提醒
+2020/9/17 9:29:33 提前一分钟休息弹窗提醒
+2020/9/17 9:47:22 提前一分钟休息提醒
+2020/9/17 9:47:22 提前一分钟休息弹窗提醒
+2020/9/17 9:55:22 提前一分钟休息提醒
+2020/9/17 9:55:22 提前一分钟休息弹窗提醒
+2020/9/17 11:07:35 提前一分钟休息提醒
+2020/9/17 11:07:35 提前一分钟休息弹窗提醒
+2020/9/17 11:15:35 提前一分钟休息提醒
+2020/9/17 11:15:35 提前一分钟休息弹窗提醒
+2020/9/17 11:23:35 提前一分钟休息提醒
+2020/9/17 11:23:35 提前一分钟休息弹窗提醒
+2020/9/17 11:31:35 提前一分钟休息提醒
+2020/9/17 11:31:35 提前一分钟休息弹窗提醒
+2020/9/17 15:25:26 提前一分钟休息提醒
+2020/9/17 15:25:26 提前一分钟休息弹窗提醒
+2020/9/17 15:36:56 提前一分钟休息提醒
+2020/9/17 15:36:56 提前一分钟休息弹窗提醒
+2020/9/17 16:40:32 提前一分钟休息提醒
+2020/9/17 16:40:32 提前一分钟休息弹窗提醒
+2020/9/17 16:48:32 提前一分钟休息提醒
+2020/9/17 16:48:32 提前一分钟休息弹窗提醒
+2020/9/17 16:56:32 提前一分钟休息提醒
+2020/9/17 16:56:32 提前一分钟休息弹窗提醒
+2020/9/17 17:05:39 提前一分钟休息提醒
+2020/9/17 17:05:39 提前一分钟休息弹窗提醒
+2020/9/20 23:31:07 提前一分钟休息提醒
+2020/9/20 23:31:07 提前一分钟休息弹窗提醒
+2020/9/20 23:39:07 提前一分钟休息提醒
+2020/9/20 23:39:07 提前一分钟休息弹窗提醒
+2020/9/20 23:47:07 提前一分钟休息提醒
+2020/9/20 23:47:07 提前一分钟休息弹窗提醒
+2020/9/20 23:55:07 提前一分钟休息提醒
+2020/9/20 23:55:07 提前一分钟休息弹窗提醒
+2020/9/21 9:04:54 提前一分钟休息提醒
+2020/9/21 9:04:54 提前一分钟休息弹窗提醒
+2020/9/22 11:03:41 提前一分钟休息提醒
+2020/9/22 11:03:41 提前一分钟休息弹窗提醒
+2020/9/22 15:40:44 提前一分钟休息提醒
+2020/9/22 15:40:44 提前一分钟休息弹窗提醒
+2020/9/22 15:48:44 提前一分钟休息提醒
+2020/9/22 15:48:44 提前一分钟休息弹窗提醒
+2020/9/22 15:56:44 提前一分钟休息提醒
+2020/9/22 15:56:44 提前一分钟休息弹窗提醒
+2020/9/22 16:04:52 提前一分钟休息提醒
+2020/9/22 16:04:52 提前一分钟休息弹窗提醒
+2020/9/22 23:33:49 提前一分钟休息提醒
+2020/9/22 23:33:49 提前一分钟休息弹窗提醒
+2020/9/22 23:41:49 提前一分钟休息提醒
+2020/9/22 23:41:49 提前一分钟休息弹窗提醒
+2020/9/23 9:04:32 提前一分钟休息提醒
+2020/9/23 9:04:32 提前一分钟休息弹窗提醒
+2020/9/23 9:21:59 提前一分钟休息提醒
+2020/9/23 9:21:59 提前一分钟休息弹窗提醒
+2020/9/23 9:29:59 提前一分钟休息提醒
+2020/9/23 9:29:59 提前一分钟休息弹窗提醒
+2020/9/23 9:37:59 提前一分钟休息提醒
+2020/9/23 9:37:59 提前一分钟休息弹窗提醒
+2020/9/23 10:28:03 提前一分钟休息提醒
+2020/9/23 10:28:03 提前一分钟休息弹窗提醒
+2020/9/23 10:36:03 提前一分钟休息提醒
+2020/9/23 10:36:03 提前一分钟休息弹窗提醒
+2020/9/23 10:44:03 提前一分钟休息提醒
+2020/9/23 10:44:03 提前一分钟休息弹窗提醒
+2020/9/23 10:52:03 提前一分钟休息提醒
+2020/9/23 10:52:03 提前一分钟休息弹窗提醒
+2020/9/23 22:30:33 提前一分钟休息提醒
+2020/9/23 22:30:33 提前一分钟休息弹窗提醒
+2020/9/23 22:38:33 提前一分钟休息提醒
+2020/9/23 22:38:33 提前一分钟休息弹窗提醒
+2020/9/23 22:46:33 提前一分钟休息提醒
+2020/9/23 22:46:33 提前一分钟休息弹窗提醒
+2020/9/23 22:54:33 提前一分钟休息提醒
+2020/9/23 22:54:33 提前一分钟休息弹窗提醒
\ No newline at end of file
diff --git a/Bin/Debug/MyTimeClock/MyDb.dll b/Bin/Debug/MyTimeClock/MyDb.dll
index 836aafd..d3238b1 100644
Binary files a/Bin/Debug/MyTimeClock/MyDb.dll and b/Bin/Debug/MyTimeClock/MyDb.dll differ
diff --git a/Bin/Debug/MyTimeClock/MyDb.xml b/Bin/Debug/MyTimeClock/MyDb.xml
index 6e82313..b727fa4 100644
--- a/Bin/Debug/MyTimeClock/MyDb.xml
+++ b/Bin/Debug/MyTimeClock/MyDb.xml
@@ -91,6 +91,62 @@
Ini操作类
+
+
+ 写入Ini
+
+
+
+
+
+
+
+
+
+ 获取Ini
+
+
+
+
+
+
+
+
+
+
+
+ 声明INI文件的读操作函数 GetPrivateProfileString()
+
+
+
+
+
+
+
+
+
+
+
+ 声明INI文件的读操作函数 GetPrivateProfileString()
+
+
+
+
+
+
+
+
+
+ 声明INI文件的读操作函数 GetPrivateProfileString()
+
+
+
+
+
+
+
+
+
获取所有节点名称(Section)
@@ -100,6 +156,11 @@
Ini文件
内容的实际长度,为0表示没有内容,为nSize-2表示内存大小不够
+
+
+ 编码
+
+
Ini操作类
@@ -958,6 +1019,56 @@
+
+
+ 文件时间
+
+
+
+
+ 创建时间
+
+
+
+
+ 最后修改时间
+
+
+
+
+ 访问时间
+
+
+
+
+ 图片类型
+
+
+
+
+ Bmp图片
+
+
+
+
+ Jpeg图片
+
+
+
+
+ Png图片
+
+
+
+
+ Gif动态图片
+
+
+
+
+ Tiff图片
+
+
对变量的拓展
@@ -1073,6 +1184,13 @@
+
+
+ 将指定类型转换成长整型
+
+
+
+
转换指定类型为Double类型
@@ -1418,10 +1536,9 @@
- 删除单个文件。
+ 永久删除单个文件。
- 删除的文件名
- 指示是将文件放入回收站还是永久删除,true-放入回收站,false-永久删除
+ 永久删除的文件名
操作执行结果标识,删除文件成功返回0,否则,返回错误代码
@@ -1653,6 +1770,16 @@
+
+
+ 添加文件到指定文件夹,会进行自动重命名,并返回重命名后的文件名
+
+ 要添加的文件路径
+ 要添加到的文件夹
+ 是否根据时间进行重命名
+ 返回是否成功执行
+ 成功执行则返回路径,否则返回空
+
获取文件大小字符串
@@ -1686,6 +1813,15 @@
+
+
+
+
+ 保存高质量不失真照片
+
+
+
+
@@ -1693,6 +1829,7 @@
+
@@ -2044,6 +2181,35 @@
+
+
+ 根据日期和时间转换成日期时间
+
+
+
+
+
+
+
+ 将时间转换成当前分钟开始的时间
+
+
+
+
+
+
+ 将时间转换成当前秒钟开始的时间
+
+
+
+
+
+
+ 当前时间在这一天里的秒数
+
+
+
+
窗体操作类
@@ -2304,6 +2470,42 @@
系统函数
+
+
+
+
+
+
+
+ 红
+
+
+
+
+ 绿
+
+
+
+
+ 蓝
+
+
+
+
+ 获取屏幕伽马值
+
+
+
+
+
+
+
+ 设置屏幕伽马值
+
+
+
+
+
获取键盘和鼠标没有操作的时间
@@ -2343,6 +2545,11 @@
+
+
+ 析构
+
+
设置让窗体支持移动
@@ -2358,6 +2565,17 @@
可调节窗体大小的宽度
+
+
+
+
+
+
+
+
+ 给控件增加拖放功能的类
+
+
拖放实例
@@ -2368,12 +2586,54 @@
高级拖放事件
+
+
+
+
+
使支持拖放属性
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
网络操作类
@@ -2421,6 +2681,11 @@
最后一次接收消息的时间,可用来判断服务端是否有响应
+
+
+ 主句柄
+
+
当收到消息时激发
@@ -2454,6 +2719,11 @@
当前客户端ID,会向服务器报告当前ID
客户端
+
+
+
+
+
断开服务端连接
@@ -2529,9 +2799,24 @@
消息事件
-
+
+
+
+ 大小改变事件
+
+
+
+
+
+
+
+ 即将关闭事件
+
+
+
+
当收到消息时激发
@@ -2541,7 +2826,24 @@
消息处理类
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -2564,6 +2866,26 @@
消息类
+
+
+ 是否取消
+
+
+
+
+ 来源句柄
+
+
+
+
+
+
+
+
+
+ 消息文本
+
+
需要回复的内容
@@ -2610,7 +2932,6 @@
服务端ID,需要唯一性,共客户端识别
服务端
- 容器句柄
@@ -2645,7 +2966,7 @@
根据客户端句柄,获取客户端对象
-
+
@@ -3363,6 +3684,41 @@
日期:2019-02-09
作者:http://www.cnblogs.com/zjfree/
+
+
+ 日历类型
+
+
+
+
+ 无效
+
+
+
+
+ Julian 日历
+
+
+
+
+ Gregorian 日历
+
+
+
+
+ 有效
+
+
+
+
+ 公历节日
+
+
+
+
+ 农历节日
+
+
某个月第n个星期几
@@ -3379,7 +3735,9 @@
获取农历
-
+
+
+
@@ -3389,16 +3747,71 @@
+
+
+ 农历搜索方向
+
+
+
+
+ 无效
+
+
+
+
+ 向上
+
+
+
+
+ 向下
+
+
{* 日月食类型, 无, 日食, 月全食, 月偏食 }
+
+
+ 无
+
+
+
+
+ 日食
+
+
+
+
+ 月全食
+
+
+
+
+ 月偏食
+
+
{* 月相, 无, 朔, 望}
+
+
+ 无
+
+
+
+
+ 朔
+
+
+
+
+ 望
+
+
获得某公历年月日的农历日数和该日月相以及日月食类型和时刻
@@ -3455,7 +3868,20 @@
-
+
+
+ 比较两个农历日期(包括闰月信息),1 大于2返回1、1等于2返回0、1小于2返回-1
+
+
+
+
+
+
+
+
+
+
+
获得某农历年月日(加是否闰月)的公历年月日
@@ -3506,7 +3932,9 @@
获取农历月份,范围约0-9999年
-
+
+
+
@@ -3550,7 +3978,9 @@
获取节气,范围约0-9999年
-
+
+
+
@@ -3559,6 +3989,7 @@
+ pd取值真假,分别表示平气和定气
@@ -3617,6 +4048,7 @@
获取公历节日
+
@@ -3762,6 +4194,11 @@
0表示1伏,1表示2伏,2表示3伏
+
+
+ 节气
+
+
节气的时间。
@@ -3777,6 +4214,200 @@
Win32 API
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 获取当前前台窗口句柄
+
+
+
+
+
+ 获得当前活动窗体
+
+
+
+
+
+ 设置活动窗体
+
+
+
+
+
+
+ 获取类名
+
+
+
+
+
+
+
+
+ 获取当前线程对应的进程ID
+
+
+
+
+
+
+
+ 判断指定句柄是否是一个窗口
+
+
+
+
+
+
+ 获取窗口标题
+
+
+
+
+
+
+
+
+ 查找窗口
+
+
+
+
+
+
+
+ 设置父窗口
+
+
+
+
+
+
+
+ 移动窗口
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 结束进程
+
+
+
+
+
+
+
+ 发送消息
+
+
+
+
+
+
+
+
+
+ 发送消息
+
+
+
+
+
+
+
+
+ 获取窗口位置和大小
+
+
+
+
+
+
+
+ 矩形
+
+
+
+
+ 最左坐标
+
+
+
+
+ 最上坐标
+
+
+
+
+ 最右坐标
+
+
+
+
+ 最下坐标
+
+
+
+
+ WM_COPYDATA消息的主要目的是允许在进程间传递只读数据。
+
+
系统通道ID
@@ -3787,6 +4418,44 @@
用户通道ID
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 获取消息
+
+
+
+
+
+
+
+ 发送消息
+
+
+
+
+
+
+
设置父窗口
diff --git a/Bin/Debug/MyTimeClock/MyDb_SQLite.dll b/Bin/Debug/MyTimeClock/MyDb_SQLite.dll
index d86f9ee..819e7a5 100644
Binary files a/Bin/Debug/MyTimeClock/MyDb_SQLite.dll and b/Bin/Debug/MyTimeClock/MyDb_SQLite.dll differ
diff --git a/Bin/Debug/MyTimeClock/MyTimeClock.exe b/Bin/Debug/MyTimeClock/MyTimeClock.exe
index 00d1298..ed48d1b 100644
Binary files a/Bin/Debug/MyTimeClock/MyTimeClock.exe and b/Bin/Debug/MyTimeClock/MyTimeClock.exe differ
diff --git a/Bin/Debug/MyTimeClock/RyLine.exe b/Bin/Debug/MyTimeClock/RyLine.exe
index 16bd546..713f763 100644
Binary files a/Bin/Debug/MyTimeClock/RyLine.exe and b/Bin/Debug/MyTimeClock/RyLine.exe differ
diff --git a/Bin/Debug/MyTimeClock/RyWeb.dll b/Bin/Debug/MyTimeClock/RyWeb.dll
index 1dd4e14..d249949 100644
Binary files a/Bin/Debug/MyTimeClock/RyWeb.dll and b/Bin/Debug/MyTimeClock/RyWeb.dll differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/Holidays.dat b/Bin/Debug/MyTimeClock/SysDb/Holidays.dat
index aab2a81..62ed53c 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/Holidays.dat and b/Bin/Debug/MyTimeClock/SysDb/Holidays.dat differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/信用卡账单到期.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/信用卡账单到期.mp3
new file mode 100644
index 0000000..24ffd8a
Binary files /dev/null and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/信用卡账单到期.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/您有新的提醒.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/您有新的提醒.mp3
index 09cf06b..fe204e1 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound/您有新的提醒.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/您有新的提醒.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/生日快乐.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/生日快乐.mp3
index 52e0658..197ce4a 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound/生日快乐.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/生日快乐.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/答题.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/答题.mp3
index 7998b5c..fd46ade 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound/答题.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/答题.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/红包雨来啦.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/红包雨来啦.mp3
index 8d2578a..d42e471 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound/红包雨来啦.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/红包雨来啦.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/账单到期啦.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/账单到期啦.mp3
index d7fef15..50b83f5 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound/账单到期啦.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/账单到期啦.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound/门票.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound/门票.mp3
index 740f201..11a8859 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound/门票.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound/门票.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/SysDb/animation/sound_tip/before_rest.mp3 b/Bin/Debug/MyTimeClock/SysDb/animation/sound_tip/before_rest.mp3
index a70c075..6b924da 100644
Binary files a/Bin/Debug/MyTimeClock/SysDb/animation/sound_tip/before_rest.mp3 and b/Bin/Debug/MyTimeClock/SysDb/animation/sound_tip/before_rest.mp3 differ
diff --git a/Bin/Debug/MyTimeClock/TimeClock.dll b/Bin/Debug/MyTimeClock/TimeClock.dll
index 467832b..fd42d26 100644
Binary files a/Bin/Debug/MyTimeClock/TimeClock.dll and b/Bin/Debug/MyTimeClock/TimeClock.dll differ
diff --git a/Bin/Debug/MyTimeClock/UserDb/Images/刷新.png b/Bin/Debug/MyTimeClock/UserDb/Images/刷新.png
new file mode 100644
index 0000000..70bff38
Binary files /dev/null and b/Bin/Debug/MyTimeClock/UserDb/Images/刷新.png differ
diff --git a/Bin/Debug/MyTimeClock/UserDb/TimeTip.dat b/Bin/Debug/MyTimeClock/UserDb/TimeTip.dat
index 6e913fb..ab8f152 100644
Binary files a/Bin/Debug/MyTimeClock/UserDb/TimeTip.dat and b/Bin/Debug/MyTimeClock/UserDb/TimeTip.dat differ
diff --git a/Bin/Debug/MyTimeClock/UserDb/Win.dat b/Bin/Debug/MyTimeClock/UserDb/Win.dat
index 7f34bc4..1b29bfd 100644
--- a/Bin/Debug/MyTimeClock/UserDb/Win.dat
+++ b/Bin/Debug/MyTimeClock/UserDb/Win.dat
@@ -1,2 +1,2 @@
-[TimeClock]
-hwnd=3014724
+[TimeClock]
+hwnd=67418
diff --git a/Bin/Debug/MyTimeClock/cUpdate.dat b/Bin/Debug/MyTimeClock/cUpdate.dat
index 8292205..e74012f 100644
--- a/Bin/Debug/MyTimeClock/cUpdate.dat
+++ b/Bin/Debug/MyTimeClock/cUpdate.dat
@@ -1,3 +1,3 @@
-
+
\ No newline at end of file
diff --git a/Bin/Debug/MyTimeClock/ryControls.dll b/Bin/Debug/MyTimeClock/ryControls.dll
index 2ed820b..07b725d 100644
Binary files a/Bin/Debug/MyTimeClock/ryControls.dll and b/Bin/Debug/MyTimeClock/ryControls.dll differ
diff --git a/Bin/Debug/MyTimeClock/ryUpdate.dll b/Bin/Debug/MyTimeClock/ryUpdate.dll
index 389847e..380d7d8 100644
Binary files a/Bin/Debug/MyTimeClock/ryUpdate.dll and b/Bin/Debug/MyTimeClock/ryUpdate.dll differ
diff --git a/CHANGELOG.md b/CHANGELOG.md
new file mode 100644
index 0000000..6c39050
--- /dev/null
+++ b/CHANGELOG.md
@@ -0,0 +1,35 @@
+### 2019-09-30更新
+------
+#### TimeClock V1.0.1909.3001
+*.[新增]新增国庆节节日。
+*.[改进]日历上方月份、年份等变动会自动更新右侧具体信息。
+#### MyTimeClock V2.0.1909.1501
+暂无
+#### RyLine V2.0.1909.0901
+暂无
+### 2019-09-28更新
+------
+#### TimeClock V1.0.1909.1501
+*.[新增]快速提醒支持在主界面直接调用和右下角托盘菜单调用。
+*.[改进]改进快速提醒,支持按指定分钟和指定时间提醒。
+*.[修复]修复改变提醒窗口大小会导致界面显示异常的BUG。
+
+#### MyTimeClock V2.0.1909.1501
+暂无
+
+#### RyLine V2.0.1909.0901
+暂无
+2019-09-10 更新
+------
+#### TimeClock V1.0.1909.0907
+
+*.[新增]便笺新增支持插入图片
+*.[改进]改进便笺切换编辑状态的逻辑,在后台不会切换为编辑状态。
+
+#### MyTimeClock V2.0.1909.0907
+
+暂无
+
+#### RyLine V2.0.1909.0901
+
+暂无
\ No newline at end of file
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..5620869
--- /dev/null
+++ b/README.md
@@ -0,0 +1,8 @@
+# 睿元定时提醒专家
+
+#### 介绍
+睿元定时提醒专家是一款强大的定时提醒、待办管理、桌面便笺工具,可以设置按分钟、小时、天、周、月、年循环提醒,而且支持农历提醒,支持提醒免打扰。同时支持待办管理,管理待办事项。还有桌面便笺功能,可以创建任意数量的桌面便笺,支持便笺自动备份、图片插入、便笺颜色设置。
+
+#### 软件架构
+毕方架构
+
diff --git a/Source/MyTimeClock/.vs/TimeClock/v16/.suo b/Source/MyTimeClock/.vs/TimeClock/v16/.suo
new file mode 100644
index 0000000..79d1368
Binary files /dev/null and b/Source/MyTimeClock/.vs/TimeClock/v16/.suo differ
diff --git a/Source/MyTimeClock/.vs/TimeClock/v16/Server/sqlite3/db.lock b/Source/MyTimeClock/.vs/TimeClock/v16/Server/sqlite3/db.lock
new file mode 100644
index 0000000..e69de29
diff --git a/Source/MyTimeClock/.vs/TimeClock/v16/Server/sqlite3/storage.ide b/Source/MyTimeClock/.vs/TimeClock/v16/Server/sqlite3/storage.ide
new file mode 100644
index 0000000..692d9bb
Binary files /dev/null and b/Source/MyTimeClock/.vs/TimeClock/v16/Server/sqlite3/storage.ide differ
diff --git a/Source/MyTimeClock/MyTimeClock/Frmmain.cs b/Source/MyTimeClock/MyTimeClock/Frmmain.cs
index 601ca18..8931c4f 100644
--- a/Source/MyTimeClock/MyTimeClock/Frmmain.cs
+++ b/Source/MyTimeClock/MyTimeClock/Frmmain.cs
@@ -51,11 +51,12 @@ namespace MyTimeClock
private void Form1_Load(object sender, EventArgs e)
{
TimeClock.Itrycn_Info.SysDbFolder = Application.StartupPath + "\\SysDb";
+ TimeClock.Itrycn_Info.UserDbFolder = Application.StartupPath + "\\UserDb";
TimeClock.DbOp.Custom.WorkQuickTip = false;
TimeClock.DbOp.Custom.AppTitle = "睿元定时提醒专家";
- TimeClock.DbOp.Custom.DonateVisabled = false;
+ TimeClock.DbOp.Custom.DonateVisabled = true;
捐助我们ToolStripMenuItem.Visible = TimeClock.DbOp.Custom.DonateVisabled;
- 节假日设置ToolStripMenuItem.Visible = false;
+ //节假日设置ToolStripMenuItem.Visible = false;
LblVer.Text = "V"+RySoft.VersionStr;
Text = TimeClock.DbOp.Custom.AppTitle;
LblName.Text = TimeClock.DbOp.Custom.AppTitle;
diff --git a/Source/MyTimeClock/MyTimeClock/MyTimeClock.csproj b/Source/MyTimeClock/MyTimeClock/MyTimeClock.csproj
index 933db84..ba178a3 100644
--- a/Source/MyTimeClock/MyTimeClock/MyTimeClock.csproj
+++ b/Source/MyTimeClock/MyTimeClock/MyTimeClock.csproj
@@ -106,6 +106,7 @@
- "e:\documentscenter\my documents\visual studio 2017\Projects\开发辅助工具\开发辅助工具\bin\Debug\开发辅助工具.exe" ver "$(ProjectDir)"
+
+
\ No newline at end of file
diff --git a/Source/MyTimeClock/RyLine/RyCode.cs b/Source/MyTimeClock/RyLine/RyCode.cs
index a286172..91ba7b1 100644
--- a/Source/MyTimeClock/RyLine/RyCode.cs
+++ b/Source/MyTimeClock/RyLine/RyCode.cs
@@ -56,7 +56,8 @@ namespace RyLine
var device = DevEnum.GetDefaultAudioEndpoint(EDataFlow.eRender, ERole.eMultimedia);
device.AudioEndpointVolume.Mute = true;
}
- catch { }
+ catch {
+ }
break;
case "mute_off"://取消静音
try
diff --git a/Source/MyTimeClock/RyLine/RyLine.csproj b/Source/MyTimeClock/RyLine/RyLine.csproj
index adb20f8..4697f22 100644
--- a/Source/MyTimeClock/RyLine/RyLine.csproj
+++ b/Source/MyTimeClock/RyLine/RyLine.csproj
@@ -99,6 +99,7 @@
- "e:\documentscenter\my documents\visual studio 2017\Projects\开发辅助工具\开发辅助工具\bin\Debug\开发辅助工具.exe" ver "$(ProjectDir)"
+
+
\ No newline at end of file
diff --git a/Source/MyTimeClock/RyLine/RyLine.csproj.user b/Source/MyTimeClock/RyLine/RyLine.csproj.user
index d14eb3b..c97fbae 100644
--- a/Source/MyTimeClock/RyLine/RyLine.csproj.user
+++ b/Source/MyTimeClock/RyLine/RyLine.csproj.user
@@ -1,7 +1,6 @@
-
-
+ mute_on
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.Designer.cs
new file mode 100644
index 0000000..5ff8cb6
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.Designer.cs
@@ -0,0 +1,104 @@
+namespace TimeClock.DbOp.CustomShow
+{
+ partial class BirthDayUI
+ {
+ ///
+ /// 必需的设计器变量。
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// 清理所有正在使用的资源。
+ ///
+ /// 如果应释放托管资源,为 true;否则为 false。
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region 组件设计器生成的代码
+
+ ///
+ /// 设计器支持所需的方法 - 不要修改
+ /// 使用代码编辑器修改此方法的内容。
+ ///
+ private void InitializeComponent()
+ {
+ this.LblValue = new System.Windows.Forms.Label();
+ this.label1 = new System.Windows.Forms.Label();
+ this.LblName = new System.Windows.Forms.Label();
+ this.LblDateStr = new System.Windows.Forms.Label();
+ this.SuspendLayout();
+ //
+ // LblValue
+ //
+ this.LblValue.AutoSize = true;
+ this.LblValue.Font = new System.Drawing.Font("宋体", 26.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LblValue.ForeColor = System.Drawing.Color.White;
+ this.LblValue.Location = new System.Drawing.Point(3, 5);
+ this.LblValue.Name = "LblValue";
+ this.LblValue.Size = new System.Drawing.Size(53, 35);
+ this.LblValue.TabIndex = 0;
+ this.LblValue.Text = "31";
+ this.LblValue.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.label1.ForeColor = System.Drawing.Color.White;
+ this.label1.Location = new System.Drawing.Point(60, 22);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(17, 12);
+ this.label1.TabIndex = 1;
+ this.label1.Text = "岁";
+ //
+ // LblName
+ //
+ this.LblName.AutoSize = true;
+ this.LblName.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LblName.ForeColor = System.Drawing.Color.White;
+ this.LblName.Location = new System.Drawing.Point(9, 55);
+ this.LblName.Name = "LblName";
+ this.LblName.Size = new System.Drawing.Size(70, 12);
+ this.LblName.TabIndex = 2;
+ this.LblName.Text = "自定义名称";
+ //
+ // LblDateStr
+ //
+ this.LblDateStr.AutoSize = true;
+ this.LblDateStr.ForeColor = System.Drawing.Color.White;
+ this.LblDateStr.Location = new System.Drawing.Point(9, 77);
+ this.LblDateStr.Name = "LblDateStr";
+ this.LblDateStr.Size = new System.Drawing.Size(65, 12);
+ this.LblDateStr.TabIndex = 3;
+ this.LblDateStr.Text = "自定义日期";
+ //
+ // BirthDayUI
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.BackColor = System.Drawing.Color.SeaGreen;
+ this.Controls.Add(this.LblDateStr);
+ this.Controls.Add(this.LblName);
+ this.Controls.Add(this.label1);
+ this.Controls.Add(this.LblValue);
+ this.Name = "BirthDayUI";
+ this.Size = new System.Drawing.Size(140, 100);
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ #endregion
+
+ private System.Windows.Forms.Label LblValue;
+ private System.Windows.Forms.Label label1;
+ private System.Windows.Forms.Label LblName;
+ private System.Windows.Forms.Label LblDateStr;
+ }
+}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.cs b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.cs
new file mode 100644
index 0000000..2495928
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.cs
@@ -0,0 +1,80 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Data;
+using System.Linq;
+using System.Text;
+using System.Windows.Forms;
+
+namespace TimeClock.DbOp.CustomShow
+{
+ public partial class BirthDayUI : UserControl
+ {
+ public BirthDayUI()
+ {
+ InitializeComponent();
+ }
+ ///
+ /// 标题名称
+ ///
+ [Description("标题名称")]
+ public string Title
+ {
+ get
+ {
+ return LblName.Text;
+ }
+ set
+ {
+ LblName.Text = value;
+ }
+ }
+ ///
+ /// 日期字符串
+ ///
+ [Description("日期字符串")]
+ public string DateStr
+ {
+ get
+ {
+ return LblDateStr.Text;
+ }
+ set
+ {
+ LblDateStr.Text = value;
+ }
+ }
+ ///
+ /// 岁数字符串
+ ///
+ [Description("岁数字符串")]
+ public string Age
+ {
+ get
+ {
+ return LblValue.Text;
+ }
+ set
+ {
+ LblValue.Text = value;
+ label1.Left = LblValue.Left + LblValue.Width;
+ }
+ }
+ ///
+ /// 岁数单位
+ ///
+ [Description("岁数单位")]
+ public string AgeUnit
+ {
+ get
+ {
+ return label1.Text;
+ }
+ set
+ {
+ label1.Text = value;
+ }
+ }
+ }
+}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.resx b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.resx
new file mode 100644
index 0000000..1af7de1
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/BirthDayUI.resx
@@ -0,0 +1,120 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.Designer.cs
new file mode 100644
index 0000000..62dff5f
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.Designer.cs
@@ -0,0 +1,118 @@
+namespace TimeClock.DbOp.CustomShow
+{
+ partial class DJSDayUI
+ {
+ ///
+ /// 必需的设计器变量。
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// 清理所有正在使用的资源。
+ ///
+ /// 如果应释放托管资源,为 true;否则为 false。
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region 组件设计器生成的代码
+
+ ///
+ /// 设计器支持所需的方法 - 不要修改
+ /// 使用代码编辑器修改此方法的内容。
+ ///
+ private void InitializeComponent()
+ {
+ this.LblValue = new System.Windows.Forms.Label();
+ this.label1 = new System.Windows.Forms.Label();
+ this.LblName = new System.Windows.Forms.Label();
+ this.LblDateStr = new System.Windows.Forms.Label();
+ this.label2 = new System.Windows.Forms.Label();
+ this.SuspendLayout();
+ //
+ // LblValue
+ //
+ this.LblValue.AutoSize = true;
+ this.LblValue.Font = new System.Drawing.Font("宋体", 26.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LblValue.ForeColor = System.Drawing.Color.White;
+ this.LblValue.Location = new System.Drawing.Point(38, 5);
+ this.LblValue.Name = "LblValue";
+ this.LblValue.Size = new System.Drawing.Size(53, 35);
+ this.LblValue.TabIndex = 0;
+ this.LblValue.Text = "31";
+ this.LblValue.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.label1.ForeColor = System.Drawing.Color.White;
+ this.label1.Location = new System.Drawing.Point(96, 22);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(17, 12);
+ this.label1.TabIndex = 1;
+ this.label1.Text = "天";
+ //
+ // LblName
+ //
+ this.LblName.AutoSize = true;
+ this.LblName.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LblName.ForeColor = System.Drawing.Color.White;
+ this.LblName.Location = new System.Drawing.Point(9, 55);
+ this.LblName.Name = "LblName";
+ this.LblName.Size = new System.Drawing.Size(70, 12);
+ this.LblName.TabIndex = 2;
+ this.LblName.Text = "自定义名称";
+ //
+ // LblDateStr
+ //
+ this.LblDateStr.AutoSize = true;
+ this.LblDateStr.ForeColor = System.Drawing.Color.White;
+ this.LblDateStr.Location = new System.Drawing.Point(9, 77);
+ this.LblDateStr.Name = "LblDateStr";
+ this.LblDateStr.Size = new System.Drawing.Size(65, 12);
+ this.LblDateStr.TabIndex = 3;
+ this.LblDateStr.Text = "自定义日期";
+ //
+ // label2
+ //
+ this.label2.AutoSize = true;
+ this.label2.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.label2.ForeColor = System.Drawing.Color.White;
+ this.label2.Location = new System.Drawing.Point(9, 22);
+ this.label2.Name = "label2";
+ this.label2.Size = new System.Drawing.Size(29, 12);
+ this.label2.TabIndex = 4;
+ this.label2.Text = "还有";
+ //
+ // JNDayUI
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.BackColor = System.Drawing.Color.Orchid;
+ this.Controls.Add(this.label2);
+ this.Controls.Add(this.LblDateStr);
+ this.Controls.Add(this.LblName);
+ this.Controls.Add(this.label1);
+ this.Controls.Add(this.LblValue);
+ this.Name = "JNDayUI";
+ this.Size = new System.Drawing.Size(140, 100);
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ #endregion
+
+ private System.Windows.Forms.Label LblValue;
+ private System.Windows.Forms.Label label1;
+ private System.Windows.Forms.Label LblName;
+ private System.Windows.Forms.Label LblDateStr;
+ private System.Windows.Forms.Label label2;
+ }
+}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.cs b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.cs
new file mode 100644
index 0000000..b653c38
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.cs
@@ -0,0 +1,81 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Data;
+using System.Linq;
+using System.Text;
+using System.Windows.Forms;
+
+namespace TimeClock.DbOp.CustomShow
+{
+ public partial class DJSDayUI : UserControl
+ {
+ public DJSDayUI()
+ {
+ InitializeComponent();
+ }
+ ///
+ /// 标题名称
+ ///
+ [Description("标题名称")]
+ public string Title
+ {
+ get
+ {
+ return LblName.Text;
+ }
+ set
+ {
+ LblName.Text = value;
+ }
+ }
+ ///
+ /// 日期字符串
+ ///
+ [Description("日期字符串")]
+ public string DateStr
+ {
+ get
+ {
+ return LblDateStr.Text;
+ }
+ set
+ {
+ LblDateStr.Text = value;
+ }
+ }
+ ///
+ /// 天数
+ ///
+ [Description("天数")]
+ public string Day
+ {
+ get
+ {
+ return LblValue.Text;
+ }
+ set
+ {
+ LblValue.Text = value;
+ LblValue.Left = label2.Left + label2.Width;
+ label1.Left = LblValue.Left + LblValue.Width;
+ }
+ }
+ ///
+ /// 天数前面的字符串
+ ///
+ [Description("天数前面的字符串")]
+ public string DayBefore
+ {
+ get
+ {
+ return label2.Text;
+ }
+ set
+ {
+ label2.Text = value;
+ }
+ }
+ }
+}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.resx b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.resx
new file mode 100644
index 0000000..1af7de1
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/DJSDayUI.resx
@@ -0,0 +1,120 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.Designer.cs
new file mode 100644
index 0000000..3d8b0e8
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.Designer.cs
@@ -0,0 +1,222 @@
+namespace TimeClock.DbOp.CustomShow
+{
+ partial class FrmAddBirthDay
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Clean up any resources being used.
+ ///
+ /// true if managed resources should be disposed; otherwise, false.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Windows Form Designer generated code
+
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ this.BtnCancel = new ryControls.ButtonEx();
+ this.BtnOK = new ryControls.ButtonEx();
+ this.CbbLunar = new ryControls.RyComboBox();
+ this.CbbDay_y = new ryControls.RyComboBox();
+ this.CbbMonth_y = new ryControls.RyComboBox();
+ this.label1 = new System.Windows.Forms.Label();
+ this.label2 = new System.Windows.Forms.Label();
+ this.txtName = new ryControls.TextBoxEx2();
+ this.Dt_Year = new ryControls.DateTimePickerEX();
+ this.label3 = new System.Windows.Forms.Label();
+ this.CbbType = new ryControls.RyComboBox();
+ this.SuspendLayout();
+ //
+ // BtnCancel
+ //
+ this.BtnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+ this.BtnCancel.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.BtnCancel.Location = new System.Drawing.Point(349, 113);
+ this.BtnCancel.Name = "BtnCancel";
+ this.BtnCancel.Size = new System.Drawing.Size(65, 27);
+ this.BtnCancel.TabIndex = 7;
+ this.BtnCancel.Text = "取消";
+ this.BtnCancel.UseVisualStyleBackColor = true;
+ this.BtnCancel.Click += new System.EventHandler(this.BtnCancel_Click);
+ //
+ // BtnOK
+ //
+ this.BtnOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+ this.BtnOK.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.BtnOK.Location = new System.Drawing.Point(278, 113);
+ this.BtnOK.Name = "BtnOK";
+ this.BtnOK.Size = new System.Drawing.Size(65, 27);
+ this.BtnOK.TabIndex = 6;
+ this.BtnOK.Text = "确定";
+ this.BtnOK.UseVisualStyleBackColor = true;
+ this.BtnOK.Click += new System.EventHandler(this.BtnOK_Click);
+ //
+ // CbbLunar
+ //
+ this.CbbLunar.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
+ this.CbbLunar.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.CbbLunar.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.CbbLunar.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.CbbLunar.FormattingEnabled = true;
+ this.CbbLunar.Items.AddRange(new object[] {
+ "阳历",
+ "农历"});
+ this.CbbLunar.Location = new System.Drawing.Point(12, 74);
+ this.CbbLunar.Name = "CbbLunar";
+ this.CbbLunar.Size = new System.Drawing.Size(70, 24);
+ this.CbbLunar.TabIndex = 18;
+ this.CbbLunar.SelectedIndexChanged += new System.EventHandler(this.CbbLunar_SelectedIndexChanged);
+ //
+ // CbbDay_y
+ //
+ this.CbbDay_y.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
+ this.CbbDay_y.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.CbbDay_y.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.CbbDay_y.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.CbbDay_y.FormattingEnabled = true;
+ this.CbbDay_y.Location = new System.Drawing.Point(307, 74);
+ this.CbbDay_y.Name = "CbbDay_y";
+ this.CbbDay_y.Size = new System.Drawing.Size(107, 24);
+ this.CbbDay_y.TabIndex = 17;
+ //
+ // CbbMonth_y
+ //
+ this.CbbMonth_y.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
+ this.CbbMonth_y.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.CbbMonth_y.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.CbbMonth_y.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.CbbMonth_y.FormattingEnabled = true;
+ this.CbbMonth_y.Location = new System.Drawing.Point(184, 74);
+ this.CbbMonth_y.Name = "CbbMonth_y";
+ this.CbbMonth_y.Size = new System.Drawing.Size(117, 24);
+ this.CbbMonth_y.TabIndex = 15;
+ //
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Location = new System.Drawing.Point(13, 59);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(29, 12);
+ this.label1.TabIndex = 19;
+ this.label1.Text = "时间";
+ //
+ // label2
+ //
+ this.label2.AutoSize = true;
+ this.label2.Location = new System.Drawing.Point(182, 10);
+ this.label2.Name = "label2";
+ this.label2.Size = new System.Drawing.Size(29, 12);
+ this.label2.TabIndex = 20;
+ this.label2.Text = "名称";
+ //
+ // txtName
+ //
+ this.txtName.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
+ this.txtName.BackColor = System.Drawing.Color.White;
+ this.txtName.EmptyText = "";
+ this.txtName.Location = new System.Drawing.Point(184, 25);
+ this.txtName.MaxLength = 999999999;
+ this.txtName.Multiline = false;
+ this.txtName.Name = "txtName";
+ this.txtName.OnlyNumeric = false;
+ this.txtName.PasswordChar = '\0';
+ this.txtName.ReadOnly = false;
+ this.txtName.SelectedText = "";
+ this.txtName.SelectionLength = 0;
+ this.txtName.SelectionStart = 0;
+ this.txtName.Size = new System.Drawing.Size(230, 25);
+ this.txtName.TabIndex = 21;
+ this.txtName.TextAlign = System.Windows.Forms.HorizontalAlignment.Left;
+ this.txtName.ToolTip = "";
+ this.txtName.WordWrap = true;
+ //
+ // Dt_Year
+ //
+ this.Dt_Year.CustomFormat = "yyyy年";
+ this.Dt_Year.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.Dt_Year.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
+ this.Dt_Year.Location = new System.Drawing.Point(89, 75);
+ this.Dt_Year.Name = "Dt_Year";
+ this.Dt_Year.ShowUpDown = true;
+ this.Dt_Year.Size = new System.Drawing.Size(87, 23);
+ this.Dt_Year.TabIndex = 22;
+ //
+ // label3
+ //
+ this.label3.AutoSize = true;
+ this.label3.Location = new System.Drawing.Point(13, 7);
+ this.label3.Name = "label3";
+ this.label3.Size = new System.Drawing.Size(29, 12);
+ this.label3.TabIndex = 24;
+ this.label3.Text = "类型";
+ //
+ // CbbType
+ //
+ this.CbbType.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
+ this.CbbType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.CbbType.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.CbbType.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.CbbType.FormattingEnabled = true;
+ this.CbbType.Items.AddRange(new object[] {
+ "出生日期",
+ "纪念日",
+ "倒计时"});
+ this.CbbType.Location = new System.Drawing.Point(12, 25);
+ this.CbbType.Name = "CbbType";
+ this.CbbType.Size = new System.Drawing.Size(164, 24);
+ this.CbbType.TabIndex = 23;
+ //
+ // FrmAddBirthDay
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(423, 152);
+ this.Controls.Add(this.label3);
+ this.Controls.Add(this.CbbType);
+ this.Controls.Add(this.Dt_Year);
+ this.Controls.Add(this.txtName);
+ this.Controls.Add(this.label2);
+ this.Controls.Add(this.label1);
+ this.Controls.Add(this.CbbLunar);
+ this.Controls.Add(this.CbbDay_y);
+ this.Controls.Add(this.CbbMonth_y);
+ this.Controls.Add(this.BtnCancel);
+ this.Controls.Add(this.BtnOK);
+ this.Name = "FrmAddBirthDay";
+ this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
+ this.Text = "添加出生日期";
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ #endregion
+
+ private ryControls.ButtonEx BtnCancel;
+ private ryControls.ButtonEx BtnOK;
+ private System.Windows.Forms.Label label1;
+ private System.Windows.Forms.Label label2;
+ public ryControls.TextBoxEx2 txtName;
+ public ryControls.DateTimePickerEX Dt_Year;
+ public ryControls.RyComboBox CbbLunar;
+ public ryControls.RyComboBox CbbDay_y;
+ public ryControls.RyComboBox CbbMonth_y;
+ private System.Windows.Forms.Label label3;
+ public ryControls.RyComboBox CbbType;
+ }
+}
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.cs b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.cs
new file mode 100644
index 0000000..7e15e2a
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.cs
@@ -0,0 +1,120 @@
+using ryCommon;
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Windows.Forms;
+
+namespace TimeClock.DbOp.CustomShow
+{
+ public partial class FrmAddBirthDay : Form
+ {
+ public FrmAddBirthDay()
+ {
+ InitializeComponent();
+ CbbType.SelectedIndex = 0;
+ CbbLunar.SelectedIndex = 0;
+ }
+ public ModalForm mr = null;
+ ///
+ /// 上一次选择的是阳历还是农历,0表示阳历,1表示农历
+ ///
+ int last_lunar_y_value = -1;
+ private void CbbLunar_SelectedIndexChanged(object sender, EventArgs e)
+ {
+ #region 获取当前选择的时间
+ var getdate = DateTime.Now;
+ try
+ {
+ if (last_lunar_y_value == 0)
+ {
+ getdate = new DateTime(Dt_Year.Value.Year, CbbMonth_y.SelectedIndex + 1, CbbDay_y.SelectedIndex + 1);
+ }
+ else if (last_lunar_y_value == 1)
+ {
+ if (ChinaDate.GetDayFromLunar(Dt_Year.Value.Year, CbbMonth_y.SelectedIndex + 1, CbbDay_y.SelectedIndex + 1, false, out int AYear, out int AMonth, out int ADay))
+ {
+ getdate = new DateTime(AYear, AMonth, ADay);
+ }
+ }
+ }
+ catch
+ {
+ }
+ #endregion
+ last_lunar_y_value = CbbLunar.SelectedIndex;
+ if (CbbLunar.SelectedIndex == 0) //阳历
+ {
+ CbbMonth_y.Items.Clear();
+ for (int i = 0; i < 12; i++)
+ {
+ CbbMonth_y.Items.Add((i + 1).ToString() + "月");
+ }
+ CbbMonth_y.SelectedIndex = getdate.Month - 1;
+ }
+ else
+ {
+ CbbMonth_y.Items.Clear();
+ string stext = "正二三四五六七八九十";
+ for (int i = 0; i < 10; i++)
+ {
+ CbbMonth_y.Items.Add(stext[i].ToString() + "月");
+ }
+ CbbMonth_y.Items.Add("十一月"); CbbMonth_y.Items.Add("十二月");
+ ChinaDate.GetLunarFromDay(getdate.Year, getdate.Month, getdate.Day, out int LunarYear, out int LunarMonth, out int LunarDay, out bool IsLeapMonth);
+ CbbMonth_y.SelectedIndex = LunarMonth - 1;
+ }
+ CbbDay_y.Items.Clear();
+ if (CbbLunar.SelectedIndex == 0)
+ {
+ for (int i = 0; i < 31; i++)
+ {
+ CbbDay_y.Items.Add((i + 1).ToString() + "日");
+ }
+ CbbDay_y.SelectedIndex = getdate.Day - 1;
+ }
+ else
+ {
+ for (int i = 0; i < 30; i++)
+ {
+ CbbDay_y.Items.Add(ChinaDate.GetDay(i + 1));
+ }
+ ChinaDate.GetLunarFromDay(getdate.Year, getdate.Month, getdate.Day, out int LunarYear, out int LunarMonth, out int LunarDay, out bool IsLeapMonth);
+ CbbDay_y.SelectedIndex = LunarDay - 1;
+ }
+ }
+
+ private void BtnCancel_Click(object sender, EventArgs e)
+ {
+ ModalForm.SetDialogResult(this, mr, DialogResult.Cancel);
+ }
+
+ private void BtnOK_Click(object sender, EventArgs e)
+ {
+ if(CbbLunar.SelectedIndex==0)
+ {
+ try
+ {
+ var dt = new DateTime(Dt_Year.Value.Year, CbbMonth_y.SelectedIndex + 1, CbbDay_y.SelectedIndex + 1);
+ }
+ catch
+ {
+ MessageBox.Show("当前阳历不是一个合法的日期。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+ return;
+ }
+ }
+ else
+ {
+ if (!ChinaDate.GetDayFromLunar(Dt_Year.Value.Year, CbbMonth_y.SelectedIndex + 1, CbbDay_y.SelectedIndex + 1, false, out int AYear, out int AMonth, out int ADay))
+ {
+ MessageBox.Show("当前农历不是一个合法的日期。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+ return;
+ }
+ }
+ ModalForm.SetDialogResult(this, mr, DialogResult.OK);
+ }
+ }
+}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.resx b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.resx
new file mode 100644
index 0000000..1af7de1
--- /dev/null
+++ b/Source/MyTimeClock/TimeClock/DbOp/CustomShow/FrmAddBirthDay.resx
@@ -0,0 +1,120 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.Designer.cs
index 43f676f..3dc7265 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.Designer.cs
@@ -44,6 +44,7 @@
this.TxtDes = new ryControls.TextBoxEx2();
this.NumSorts = new System.Windows.Forms.NumericUpDown();
this.label7 = new System.Windows.Forms.Label();
+ this.ChkNoShowRL = new System.Windows.Forms.CheckBox();
((System.ComponentModel.ISupportInitialize)(this.NumStartYear)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NumEndYear)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.NumSorts)).BeginInit();
@@ -52,7 +53,7 @@
// btnCancel
//
this.btnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
- this.btnCancel.ForeColor = System.Drawing.Color.White;
+ this.btnCancel.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
this.btnCancel.Location = new System.Drawing.Point(263, 319);
this.btnCancel.Name = "btnCancel";
this.btnCancel.Size = new System.Drawing.Size(65, 27);
@@ -64,7 +65,7 @@
// btnOK
//
this.btnOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
- this.btnOK.ForeColor = System.Drawing.Color.White;
+ this.btnOK.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
this.btnOK.Location = new System.Drawing.Point(192, 319);
this.btnOK.Name = "btnOK";
this.btnOK.Size = new System.Drawing.Size(65, 27);
@@ -100,6 +101,7 @@
this.txtName.TabIndex = 6;
this.txtName.TextAlign = System.Windows.Forms.HorizontalAlignment.Left;
this.txtName.ToolTip = "";
+ this.txtName.WordWrap = true;
//
// CbbSType
//
@@ -205,6 +207,7 @@
this.TxtTime.TabIndex = 15;
this.TxtTime.TextAlign = System.Windows.Forms.HorizontalAlignment.Left;
this.TxtTime.ToolTip = "";
+ this.TxtTime.WordWrap = true;
//
// label6
//
@@ -236,6 +239,7 @@
this.TxtDes.TabIndex = 18;
this.TxtDes.TextAlign = System.Windows.Forms.HorizontalAlignment.Left;
this.TxtDes.ToolTip = "";
+ this.TxtDes.WordWrap = true;
//
// NumSorts
//
@@ -260,11 +264,22 @@
this.label7.TabIndex = 19;
this.label7.Text = "排序";
//
+ // ChkNoShowRL
+ //
+ this.ChkNoShowRL.AutoSize = true;
+ this.ChkNoShowRL.Location = new System.Drawing.Point(10, 325);
+ this.ChkNoShowRL.Name = "ChkNoShowRL";
+ this.ChkNoShowRL.Size = new System.Drawing.Size(108, 16);
+ this.ChkNoShowRL.TabIndex = 21;
+ this.ChkNoShowRL.Text = "不显示在日历里";
+ this.ChkNoShowRL.UseVisualStyleBackColor = true;
+ //
// FrmAddHoliday
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(338, 356);
+ this.Controls.Add(this.ChkNoShowRL);
this.Controls.Add(this.NumSorts);
this.Controls.Add(this.label7);
this.Controls.Add(this.TxtDes);
@@ -310,5 +325,6 @@
private ryControls.TextBoxEx2 TxtDes;
private System.Windows.Forms.NumericUpDown NumSorts;
private System.Windows.Forms.Label label7;
+ private System.Windows.Forms.CheckBox ChkNoShowRL;
}
}
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.cs
index d379587..fa783c3 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmAddHoliday.cs
@@ -42,6 +42,7 @@ namespace TimeClock.DbOp
NumEndYear.Value = reader["endYear"].ToInt();
CbbSType.SelectedIndex= reader["sType"].ToInt();
TxtTime.Text= reader["Holiday_Time"].ToString();
+ ChkNoShowRL.Checked = reader["NoShowRL"].ToBool();
#endregion
}
}
@@ -67,6 +68,7 @@ namespace TimeClock.DbOp
mySQL.AddField("endYear", NumEndYear.Value);
mySQL.AddField("sType", CbbSType.SelectedIndex);
mySQL.AddField("Holiday_Time", TxtTime.Text);
+ mySQL.AddField("NoShowRL",ChkNoShowRL.Checked);
mySQL.AddField("Des", TxtDes.Text);
DataProvider mydb = new DataProvider();
IDbInterface db = Itrycn_Db.CreateDataProvider(Itrycn_Db.dataType);
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.Designer.cs
index 3e81290..022f686 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.Designer.cs
@@ -166,7 +166,6 @@
this.Text = "即将进入休息";
this.TopMost = true;
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.FrmBeforeRestTip_FormClosed);
- this.Load += new System.EventHandler(this.FrmBeforeRestTip_Load);
this.contextMenuStrip1.ResumeLayout(false);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.cs
index 1487af1..c08646f 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmBeforeRestTip.cs
@@ -68,10 +68,6 @@ namespace TimeClock.DbOp
this.Close();
}
}
-
- private void FrmBeforeRestTip_Load(object sender, EventArgs e)
- {
- }
public void StartLoad()
{
timer1.Start();
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.Designer.cs
index c01586b..39612b8 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.Designer.cs
@@ -39,8 +39,9 @@
this.BtnTuichi = new ryControls.ButtonEx();
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components);
this.LblCloseTime = new System.Windows.Forms.Label();
- this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.LblRunTimeStr = new ryControls.LabelTx();
+ this.pictureBox1 = new System.Windows.Forms.PictureBox();
+ this.panel1 = new System.Windows.Forms.Panel();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.SuspendLayout();
//
@@ -93,9 +94,8 @@
// BtnClose
//
this.BtnClose.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
- this.BtnClose.BaseColor = System.Drawing.Color.Gray;
+ this.BtnClose.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
this.BtnClose.Font = new System.Drawing.Font("宋体", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.BtnClose.ForeColor = System.Drawing.Color.White;
this.BtnClose.Location = new System.Drawing.Point(900, 271);
this.BtnClose.Name = "BtnClose";
this.BtnClose.Size = new System.Drawing.Size(124, 80);
@@ -124,8 +124,7 @@
// BtnTuichi
//
this.BtnTuichi.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
- this.BtnTuichi.BaseColor = System.Drawing.Color.Gray;
- this.BtnTuichi.ForeColor = System.Drawing.Color.White;
+ this.BtnTuichi.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
this.BtnTuichi.Location = new System.Drawing.Point(1030, 271);
this.BtnTuichi.Name = "BtnTuichi";
this.BtnTuichi.Size = new System.Drawing.Size(36, 80);
@@ -152,16 +151,6 @@
this.LblCloseTime.TabIndex = 46;
this.LblCloseTime.Text = "未知";
//
- // pictureBox1
- //
- this.pictureBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
- this.pictureBox1.Location = new System.Drawing.Point(810, 383);
- this.pictureBox1.Name = "pictureBox1";
- this.pictureBox1.Size = new System.Drawing.Size(310, 313);
- this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
- this.pictureBox1.TabIndex = 47;
- this.pictureBox1.TabStop = false;
- //
// LblRunTimeStr
//
this.LblRunTimeStr.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
@@ -173,12 +162,32 @@
this.LblRunTimeStr.TabIndex = 48;
this.LblRunTimeStr.Text = "未知时间";
//
+ // pictureBox1
+ //
+ this.pictureBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
+ this.pictureBox1.Location = new System.Drawing.Point(810, 383);
+ this.pictureBox1.Name = "pictureBox1";
+ this.pictureBox1.Size = new System.Drawing.Size(310, 313);
+ this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
+ this.pictureBox1.TabIndex = 47;
+ this.pictureBox1.TabStop = false;
+ //
+ // panel1
+ //
+ this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
+ this.panel1.Location = new System.Drawing.Point(15, 745);
+ this.panel1.Name = "panel1";
+ this.panel1.Size = new System.Drawing.Size(1201, 125);
+ this.panel1.TabIndex = 49;
+ //
// FrmFullScreenTip
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.ClientSize = new System.Drawing.Size(1331, 919);
+ this.Controls.Add(this.panel1);
this.Controls.Add(this.LblRunTimeStr);
this.Controls.Add(this.pictureBox1);
this.Controls.Add(this.LblCloseTime);
@@ -218,5 +227,6 @@
public System.Windows.Forms.Label LblCloseTime;
private System.Windows.Forms.PictureBox pictureBox1;
public ryControls.LabelTx LblRunTimeStr;
+ private System.Windows.Forms.Panel panel1;
}
}
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.cs
index 462eff9..b67146b 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmFullScreenTip.cs
@@ -46,6 +46,151 @@ namespace TimeClock.DbOp
if (!_HaveCloseMinute) { LblCloseTime.Visible = false; }
sound.Volume = Itrycn_Info.MusicVolume / 100f;
}
+ ///
+ /// 自定义显示
+ ///
+ ///
+ public void AddCustomShow(string CustomShowXML,DateTime NextTipTime)
+ {
+ if (CustomShowXML == "") { return; }
+ ryCommon.Storage myCustomShow_XML = new Storage(CustomShowXML);
+ myCustomShow_XML.SelectNodeBySet();
+ var iCount = myCustomShow_XML.GetAttrValue("Count", 0);
+ Color[] color = new Color[] { Color.Magenta,Color.LightCoral,Color.YellowGreen,Color.SeaGreen,
+ Color.DeepSkyBlue,Color.MediumPurple,Color.MediumOrchid,Color.Fuchsia };
+ ListX listx = new ListX(panel1)
+ {
+ MaxColCount = 6,
+ spaceX = 15
+ };
+ for (int m = 0; m < iCount; m++)
+ {
+ CustomShowInfo dt_info = new CustomShowInfo()
+ {
+ Type = myCustomShow_XML.GetAttrValue("CsType" + (m + 1).ToString(), 1),
+ Name = myCustomShow_XML.GetAttrValue("CsName" + (m + 1).ToString(), ""),
+ IsLunar = myCustomShow_XML.GetAttrValue("CsIsLunar" + (m + 1).ToString(), false),
+ Year = myCustomShow_XML.GetAttrValue("CsYear" + (m + 1).ToString(), 1),
+ Month = myCustomShow_XML.GetAttrValue("CsMonth" + (m + 1).ToString(), 1),
+ Day = myCustomShow_XML.GetAttrValue("CsDay" + (m + 1).ToString(), 1)
+ };
+ Random rd = new Random(Guid.NewGuid().GetHashCode());
+ switch(dt_info.Type)
+ {
+ case 0: //出生日期提醒
+ var days = (NextTipTime.Date - DateTime.Now.Date).TotalDays.ToInt();
+ CustomShow.BirthDayUI b_ui = new CustomShow.BirthDayUI();
+ b_ui.Title = dt_info.Name;
+ b_ui.DateStr = dt_info.DateStr;
+ if (days > 0)
+ { b_ui.AgeUnit ="岁("+ days + "天后)"; }
+ else if (days < 0)
+ { b_ui.AgeUnit = "岁(" + days + "天前)"; }
+ #region 计算岁数
+ int age = NextTipTime.Year - dt_info.Year;
+ if (dt_info.IsLunar)
+ {
+ if (ChinaDate.GetDayFromLunar(NextTipTime.Year, dt_info.Month, dt_info.Day, false, out int AYear, out int AMonth, out int ADay))
+ {
+ var getdate = new DateTime(AYear, AMonth, ADay);
+ if (getdate < NextTipTime.Date)
+ {
+ age--;
+ }
+ }
+ }
+ else
+ {
+ var getdate = new DateTime(NextTipTime.Year, dt_info.Month, dt_info.Day);
+ if (getdate < NextTipTime.Date)
+ {
+ age--;
+ }
+ }
+ b_ui.Age = age.ToString();
+ #endregion
+ b_ui.BackColor = color[rd.Next(0, color.Length-1)];
+ listx.Add(b_ui);
+ break;
+ case 1: //纪念日提醒
+ var days2 = (NextTipTime.Date - DateTime.Now.Date).TotalDays.ToInt();
+ CustomShow.BirthDayUI b_ui2 = new CustomShow.BirthDayUI();
+ b_ui2.Title = dt_info.Name;
+ b_ui2.DateStr = dt_info.DateStr;
+ if (days2 > 0)
+ { b_ui2.AgeUnit = "周年(" + days2 + "天后)"; }
+ else if (days2 < 0)
+ { b_ui2.AgeUnit = "周年(" + days2 + "天前)"; }
+ #region 计算周年
+ int age2 = NextTipTime.Year - dt_info.Year;
+ if (dt_info.IsLunar)
+ {
+ if (ChinaDate.GetDayFromLunar(NextTipTime.Year, dt_info.Month, dt_info.Day, false, out int AYear, out int AMonth, out int ADay))
+ {
+ var getdate = new DateTime(AYear, AMonth, ADay);
+ if (getdate < NextTipTime.Date)
+ {
+ age2--;
+ }
+ }
+ }
+ else
+ {
+ var getdate = new DateTime(NextTipTime.Year, dt_info.Month, dt_info.Day);
+ if (getdate < NextTipTime.Date)
+ {
+ age2--;
+ }
+ }
+ b_ui2.Age = age2.ToString();
+ #endregion
+ b_ui2.BackColor = color[rd.Next(0, color.Length - 1)];
+ listx.Add(b_ui2);
+ break;
+ case 2: //倒计时提醒
+ CustomShow.DJSDayUI b_ui3= new CustomShow.DJSDayUI();
+ b_ui3.Title = dt_info.Name;
+ b_ui3.DateStr = dt_info.DateStr;
+ #region 计算周年
+ int dsj_day = -1;
+ bool get_info = true;
+ if (dt_info.IsLunar)
+ {
+ if (ChinaDate.GetDayFromLunar(dt_info.Year, dt_info.Month, dt_info.Day, false, out int AYear, out int AMonth, out int ADay))
+ {
+ var getdate = new DateTime(AYear, AMonth, ADay);
+ dsj_day =(getdate - DateTime.Now.Date).TotalDays.ToString().ToInt();
+ }
+ else { get_info = false; }
+ }
+ else
+ {
+ var getdate = new DateTime(dt_info.Year, dt_info.Month, dt_info.Day);
+ dsj_day = (getdate - DateTime.Now.Date).TotalDays.ToString().ToInt();
+ }
+ if (!get_info)
+ { b_ui3.Day = "未知"; }
+ else
+ {
+ if (dsj_day < 0)
+ {
+ b_ui3.DayBefore = "过期";
+ b_ui3.Day = (-dsj_day).ToString();
+ }
+ else
+ {
+ b_ui3.DayBefore = "还有";
+ b_ui3.Day = dsj_day.ToString();
+ }
+ }
+ #endregion
+ b_ui3.BackColor = color[rd.Next(0, color.Length - 1)];
+ listx.Add(b_ui3);
+ break;
+ }
+ }
+ listx.ReDraw2();
+ }
public void PlaySound(string path)
{
string _path = ryCommon.RyFiles.GetRealPath(path);
@@ -151,7 +296,7 @@ namespace TimeClock.DbOp
private void FrmFullScreenTip_Load(object sender, EventArgs e)
{
- if (gif_path == "")
+ if (gif_path.Length==0)
{
string title = TxtTitle.Text;
string[] rule = RyFiles.ReadAllLines(Itrycn_Info.SysDbFolder + "\\animation\\gif.db");
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.Designer.cs
index 3f62b9b..c0234e3 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.Designer.cs
@@ -29,6 +29,7 @@
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
+ System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmQuickAdd));
this.label2 = new System.Windows.Forms.Label();
this.txtName = new ryControls.TextBoxEx2();
this.label1 = new System.Windows.Forms.Label();
@@ -42,6 +43,23 @@
this.buttonEx7 = new ryControls.ButtonEx();
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);
this.buttonEx8 = new ryControls.ButtonEx();
+ this.buttonEx9 = new ryControls.ButtonEx();
+ this.buttonEx10 = new ryControls.ButtonEx();
+ this.tabControl1 = new System.Windows.Forms.TabControl();
+ this.tabPage1 = new System.Windows.Forms.TabPage();
+ this.tabPage2 = new System.Windows.Forms.TabPage();
+ this.BtnMinuteOK = new ryControls.ButtonEx();
+ this.label3 = new System.Windows.Forms.Label();
+ this.NumMinute = new System.Windows.Forms.NumericUpDown();
+ this.tabPage3 = new System.Windows.Forms.TabPage();
+ this.BtnTimeOK = new ryControls.ButtonEx();
+ this.label4 = new System.Windows.Forms.Label();
+ this.dateTimePicker1 = new System.Windows.Forms.DateTimePicker();
+ this.tabControl1.SuspendLayout();
+ this.tabPage1.SuspendLayout();
+ this.tabPage2.SuspendLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.NumMinute)).BeginInit();
+ this.tabPage3.SuspendLayout();
this.SuspendLayout();
//
// label2
@@ -58,10 +76,12 @@
this.txtName.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.txtName.BackColor = System.Drawing.Color.White;
+ this.txtName.EmptyText = "";
this.txtName.Location = new System.Drawing.Point(12, 27);
this.txtName.MaxLength = 999999999;
this.txtName.Multiline = false;
this.txtName.Name = "txtName";
+ this.txtName.OnlyNumeric = false;
this.txtName.PasswordChar = '\0';
this.txtName.ReadOnly = false;
this.txtName.SelectedText = "";
@@ -70,6 +90,8 @@
this.txtName.Size = new System.Drawing.Size(554, 25);
this.txtName.TabIndex = 10;
this.txtName.TextAlign = System.Windows.Forms.HorizontalAlignment.Left;
+ this.txtName.ToolTip = "";
+ this.txtName.WordWrap = true;
//
// label1
//
@@ -82,27 +104,30 @@
//
// TxtContent
//
- this.TxtContent.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
+ this.TxtContent.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.TxtContent.BackColor = System.Drawing.Color.White;
+ this.TxtContent.EmptyText = "";
this.TxtContent.Location = new System.Drawing.Point(12, 70);
this.TxtContent.MaxLength = 999999999;
this.TxtContent.Multiline = true;
this.TxtContent.Name = "TxtContent";
+ this.TxtContent.OnlyNumeric = false;
this.TxtContent.PasswordChar = '\0';
this.TxtContent.ReadOnly = false;
this.TxtContent.SelectedText = "";
this.TxtContent.SelectionLength = 0;
this.TxtContent.SelectionStart = 0;
- this.TxtContent.Size = new System.Drawing.Size(554, 303);
+ this.TxtContent.Size = new System.Drawing.Size(554, 307);
this.TxtContent.TabIndex = 13;
this.TxtContent.TextAlign = System.Windows.Forms.HorizontalAlignment.Left;
+ this.TxtContent.ToolTip = "";
+ this.TxtContent.WordWrap = true;
//
// buttonEx1
//
- this.buttonEx1.ForeColor = System.Drawing.Color.White;
- this.buttonEx1.Location = new System.Drawing.Point(12, 379);
+ this.buttonEx1.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx1.Location = new System.Drawing.Point(4, 6);
this.buttonEx1.Name = "buttonEx1";
this.buttonEx1.Size = new System.Drawing.Size(103, 28);
this.buttonEx1.TabIndex = 14;
@@ -112,8 +137,8 @@
//
// buttonEx2
//
- this.buttonEx2.ForeColor = System.Drawing.Color.White;
- this.buttonEx2.Location = new System.Drawing.Point(124, 379);
+ this.buttonEx2.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx2.Location = new System.Drawing.Point(116, 6);
this.buttonEx2.Name = "buttonEx2";
this.buttonEx2.Size = new System.Drawing.Size(103, 28);
this.buttonEx2.TabIndex = 15;
@@ -123,8 +148,8 @@
//
// buttonEx3
//
- this.buttonEx3.ForeColor = System.Drawing.Color.White;
- this.buttonEx3.Location = new System.Drawing.Point(236, 379);
+ this.buttonEx3.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx3.Location = new System.Drawing.Point(452, 6);
this.buttonEx3.Name = "buttonEx3";
this.buttonEx3.Size = new System.Drawing.Size(103, 28);
this.buttonEx3.TabIndex = 16;
@@ -134,8 +159,8 @@
//
// buttonEx4
//
- this.buttonEx4.ForeColor = System.Drawing.Color.White;
- this.buttonEx4.Location = new System.Drawing.Point(348, 379);
+ this.buttonEx4.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx4.Location = new System.Drawing.Point(4, 40);
this.buttonEx4.Name = "buttonEx4";
this.buttonEx4.Size = new System.Drawing.Size(103, 28);
this.buttonEx4.TabIndex = 17;
@@ -145,20 +170,20 @@
//
// buttonEx5
//
- this.buttonEx5.ForeColor = System.Drawing.Color.White;
- this.buttonEx5.Location = new System.Drawing.Point(236, 413);
+ this.buttonEx5.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx5.Location = new System.Drawing.Point(452, 40);
this.buttonEx5.Name = "buttonEx5";
this.buttonEx5.Size = new System.Drawing.Size(103, 28);
this.buttonEx5.TabIndex = 18;
- this.buttonEx5.Text = "明早上班后提醒";
- this.toolTip1.SetToolTip(this.buttonEx5, "将在明天早上上班后10分钟进行提醒。");
+ this.buttonEx5.Text = "明早8:40提醒";
+ this.toolTip1.SetToolTip(this.buttonEx5, "将在明天早上8点40分进行提醒。");
this.buttonEx5.UseVisualStyleBackColor = true;
this.buttonEx5.Click += new System.EventHandler(this.ButtonEx5_Click);
//
// buttonEx6
//
- this.buttonEx6.ForeColor = System.Drawing.Color.White;
- this.buttonEx6.Location = new System.Drawing.Point(12, 413);
+ this.buttonEx6.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx6.Location = new System.Drawing.Point(228, 40);
this.buttonEx6.Name = "buttonEx6";
this.buttonEx6.Size = new System.Drawing.Size(103, 28);
this.buttonEx6.TabIndex = 19;
@@ -169,8 +194,8 @@
//
// buttonEx7
//
- this.buttonEx7.ForeColor = System.Drawing.Color.White;
- this.buttonEx7.Location = new System.Drawing.Point(124, 413);
+ this.buttonEx7.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx7.Location = new System.Drawing.Point(340, 40);
this.buttonEx7.Name = "buttonEx7";
this.buttonEx7.Size = new System.Drawing.Size(103, 28);
this.buttonEx7.TabIndex = 20;
@@ -181,8 +206,8 @@
//
// buttonEx8
//
- this.buttonEx8.ForeColor = System.Drawing.Color.White;
- this.buttonEx8.Location = new System.Drawing.Point(460, 379);
+ this.buttonEx8.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx8.Location = new System.Drawing.Point(116, 40);
this.buttonEx8.Name = "buttonEx8";
this.buttonEx8.Size = new System.Drawing.Size(103, 28);
this.buttonEx8.TabIndex = 21;
@@ -190,29 +215,187 @@
this.buttonEx8.UseVisualStyleBackColor = true;
this.buttonEx8.Click += new System.EventHandler(this.ButtonEx8_Click);
//
+ // buttonEx9
+ //
+ this.buttonEx9.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx9.Location = new System.Drawing.Point(228, 6);
+ this.buttonEx9.Name = "buttonEx9";
+ this.buttonEx9.Size = new System.Drawing.Size(103, 28);
+ this.buttonEx9.TabIndex = 22;
+ this.buttonEx9.Text = "15分钟后提醒";
+ this.buttonEx9.UseVisualStyleBackColor = true;
+ this.buttonEx9.Click += new System.EventHandler(this.ButtonEx9_Click);
+ //
+ // buttonEx10
+ //
+ this.buttonEx10.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.buttonEx10.Location = new System.Drawing.Point(340, 6);
+ this.buttonEx10.Name = "buttonEx10";
+ this.buttonEx10.Size = new System.Drawing.Size(103, 28);
+ this.buttonEx10.TabIndex = 23;
+ this.buttonEx10.Text = "20分钟后提醒";
+ this.buttonEx10.UseVisualStyleBackColor = true;
+ this.buttonEx10.Click += new System.EventHandler(this.ButtonEx10_Click);
+ //
+ // tabControl1
+ //
+ this.tabControl1.Controls.Add(this.tabPage1);
+ this.tabControl1.Controls.Add(this.tabPage2);
+ this.tabControl1.Controls.Add(this.tabPage3);
+ this.tabControl1.Location = new System.Drawing.Point(7, 381);
+ this.tabControl1.Name = "tabControl1";
+ this.tabControl1.SelectedIndex = 0;
+ this.tabControl1.Size = new System.Drawing.Size(568, 104);
+ this.tabControl1.TabIndex = 24;
+ this.tabControl1.SelectedIndexChanged += new System.EventHandler(this.TabControl1_SelectedIndexChanged);
+ //
+ // tabPage1
+ //
+ this.tabPage1.Controls.Add(this.buttonEx1);
+ this.tabPage1.Controls.Add(this.buttonEx10);
+ this.tabPage1.Controls.Add(this.buttonEx2);
+ this.tabPage1.Controls.Add(this.buttonEx9);
+ this.tabPage1.Controls.Add(this.buttonEx3);
+ this.tabPage1.Controls.Add(this.buttonEx8);
+ this.tabPage1.Controls.Add(this.buttonEx4);
+ this.tabPage1.Controls.Add(this.buttonEx7);
+ this.tabPage1.Controls.Add(this.buttonEx5);
+ this.tabPage1.Controls.Add(this.buttonEx6);
+ this.tabPage1.Location = new System.Drawing.Point(4, 22);
+ this.tabPage1.Name = "tabPage1";
+ this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
+ this.tabPage1.Size = new System.Drawing.Size(560, 78);
+ this.tabPage1.TabIndex = 0;
+ this.tabPage1.Text = "常用时间";
+ this.tabPage1.UseVisualStyleBackColor = true;
+ //
+ // tabPage2
+ //
+ this.tabPage2.Controls.Add(this.BtnMinuteOK);
+ this.tabPage2.Controls.Add(this.label3);
+ this.tabPage2.Controls.Add(this.NumMinute);
+ this.tabPage2.Location = new System.Drawing.Point(4, 22);
+ this.tabPage2.Name = "tabPage2";
+ this.tabPage2.Padding = new System.Windows.Forms.Padding(3);
+ this.tabPage2.Size = new System.Drawing.Size(560, 78);
+ this.tabPage2.TabIndex = 1;
+ this.tabPage2.Text = "指定分钟";
+ this.tabPage2.UseVisualStyleBackColor = true;
+ //
+ // BtnMinuteOK
+ //
+ this.BtnMinuteOK.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.BtnMinuteOK.Location = new System.Drawing.Point(184, 23);
+ this.BtnMinuteOK.Name = "BtnMinuteOK";
+ this.BtnMinuteOK.Size = new System.Drawing.Size(59, 28);
+ this.BtnMinuteOK.TabIndex = 15;
+ this.BtnMinuteOK.Text = "确认";
+ this.BtnMinuteOK.UseVisualStyleBackColor = true;
+ this.BtnMinuteOK.Click += new System.EventHandler(this.BtnMinuteOK_Click);
+ //
+ // label3
+ //
+ this.label3.AutoSize = true;
+ this.label3.Location = new System.Drawing.Point(113, 31);
+ this.label3.Name = "label3";
+ this.label3.Size = new System.Drawing.Size(65, 12);
+ this.label3.TabIndex = 1;
+ this.label3.Text = "分钟后提醒";
+ //
+ // NumMinute
+ //
+ this.NumMinute.Font = new System.Drawing.Font("宋体", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.NumMinute.Location = new System.Drawing.Point(22, 22);
+ this.NumMinute.Maximum = new decimal(new int[] {
+ 10000,
+ 0,
+ 0,
+ 0});
+ this.NumMinute.Minimum = new decimal(new int[] {
+ 1,
+ 0,
+ 0,
+ 0});
+ this.NumMinute.Name = "NumMinute";
+ this.NumMinute.Size = new System.Drawing.Size(82, 29);
+ this.NumMinute.TabIndex = 0;
+ this.NumMinute.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
+ this.NumMinute.Value = new decimal(new int[] {
+ 5,
+ 0,
+ 0,
+ 0});
+ this.NumMinute.Enter += new System.EventHandler(this.NumericUpDown1_Enter);
+ this.NumMinute.MouseClick += new System.Windows.Forms.MouseEventHandler(this.NumMinute_MouseClick);
+ //
+ // tabPage3
+ //
+ this.tabPage3.Controls.Add(this.BtnTimeOK);
+ this.tabPage3.Controls.Add(this.label4);
+ this.tabPage3.Controls.Add(this.dateTimePicker1);
+ this.tabPage3.Location = new System.Drawing.Point(4, 22);
+ this.tabPage3.Name = "tabPage3";
+ this.tabPage3.Padding = new System.Windows.Forms.Padding(3);
+ this.tabPage3.Size = new System.Drawing.Size(560, 78);
+ this.tabPage3.TabIndex = 2;
+ this.tabPage3.Text = "指定时间";
+ this.tabPage3.UseVisualStyleBackColor = true;
+ //
+ // BtnTimeOK
+ //
+ this.BtnTimeOK.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
+ this.BtnTimeOK.Location = new System.Drawing.Point(178, 22);
+ this.BtnTimeOK.Name = "BtnTimeOK";
+ this.BtnTimeOK.Size = new System.Drawing.Size(59, 28);
+ this.BtnTimeOK.TabIndex = 16;
+ this.BtnTimeOK.Text = "确认";
+ this.BtnTimeOK.UseVisualStyleBackColor = true;
+ this.BtnTimeOK.Click += new System.EventHandler(this.BtnTimeOK_Click);
+ //
+ // label4
+ //
+ this.label4.AutoSize = true;
+ this.label4.Location = new System.Drawing.Point(107, 31);
+ this.label4.Name = "label4";
+ this.label4.Size = new System.Drawing.Size(53, 12);
+ this.label4.TabIndex = 2;
+ this.label4.Text = "进行提醒";
+ //
+ // dateTimePicker1
+ //
+ this.dateTimePicker1.CustomFormat = "HH:mm";
+ this.dateTimePicker1.Font = new System.Drawing.Font("宋体", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.dateTimePicker1.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
+ this.dateTimePicker1.Location = new System.Drawing.Point(22, 22);
+ this.dateTimePicker1.Name = "dateTimePicker1";
+ this.dateTimePicker1.ShowUpDown = true;
+ this.dateTimePicker1.Size = new System.Drawing.Size(79, 29);
+ this.dateTimePicker1.TabIndex = 0;
+ //
// FrmQuickAdd
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(578, 447);
- this.Controls.Add(this.buttonEx8);
- this.Controls.Add(this.buttonEx7);
- this.Controls.Add(this.buttonEx6);
- this.Controls.Add(this.buttonEx5);
- this.Controls.Add(this.buttonEx4);
- this.Controls.Add(this.buttonEx3);
- this.Controls.Add(this.buttonEx2);
- this.Controls.Add(this.buttonEx1);
+ this.ClientSize = new System.Drawing.Size(578, 486);
+ this.Controls.Add(this.tabControl1);
this.Controls.Add(this.TxtContent);
this.Controls.Add(this.label1);
this.Controls.Add(this.label2);
this.Controls.Add(this.txtName);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+ this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.MaximizeBox = false;
this.Name = "FrmQuickAdd";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.Text = "快速提醒";
this.Load += new System.EventHandler(this.FrmQuickAdd_Load);
+ this.tabControl1.ResumeLayout(false);
+ this.tabPage1.ResumeLayout(false);
+ this.tabPage2.ResumeLayout(false);
+ this.tabPage2.PerformLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.NumMinute)).EndInit();
+ this.tabPage3.ResumeLayout(false);
+ this.tabPage3.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
@@ -233,5 +416,17 @@
private ryControls.ButtonEx buttonEx7;
private System.Windows.Forms.ToolTip toolTip1;
private ryControls.ButtonEx buttonEx8;
+ private ryControls.ButtonEx buttonEx9;
+ private ryControls.ButtonEx buttonEx10;
+ private System.Windows.Forms.TabControl tabControl1;
+ private System.Windows.Forms.TabPage tabPage1;
+ private System.Windows.Forms.TabPage tabPage2;
+ private ryControls.ButtonEx BtnMinuteOK;
+ private System.Windows.Forms.Label label3;
+ private System.Windows.Forms.NumericUpDown NumMinute;
+ private System.Windows.Forms.TabPage tabPage3;
+ private ryControls.ButtonEx BtnTimeOK;
+ private System.Windows.Forms.Label label4;
+ private System.Windows.Forms.DateTimePicker dateTimePicker1;
}
}
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.cs
index 8c37807..db758dc 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.cs
@@ -49,18 +49,18 @@ namespace TimeClock.DbOp
private void ButtonEx5_Click(object sender, EventArgs e)
{
- AddTip(DateTime.Now.AddDays(1).Date.AddHours(8).AddMinutes(10));
+ AddTip(DateTime.Now.AddDays(1).Date.AddHours(8).AddMinutes(40));
}
private void ButtonEx6_Click(object sender, EventArgs e)
{
- if(DateTime.Now.Hour>=11)
+ if (DateTime.Now.Hour == 11 && DateTime.Now.Minute > 20)
+ {
+ MessageBox.Show("已经过了提醒时间,不能再添加。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+ return;
+ }
+ if (DateTime.Now.Hour>11)
{
- if(DateTime.Now.Hour==11 && DateTime.Now.Minute>20)
- {
- MessageBox.Show("已经过了提醒时间,不能再添加。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
- return;
- }
MessageBox.Show("已经过了提醒时间,不能再添加。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
return;
}
@@ -108,12 +108,6 @@ namespace TimeClock.DbOp
buttonEx5.Visible = false;
buttonEx6.Visible = false;
buttonEx7.Visible = false;
- buttonEx1.Top = buttonEx5.Top;
- buttonEx2.Top = buttonEx1.Top;
- buttonEx3.Top = buttonEx1.Top;
- buttonEx4.Top = buttonEx1.Top;
- buttonEx8.Top = buttonEx1.Top;
- TxtContent.Height = buttonEx1.Top - TxtContent.Top - 3;
}
if (DateTime.Now > GetAfterNoon_ClosingTime().AddMinutes(-10))
{
@@ -132,5 +126,50 @@ namespace TimeClock.DbOp
{
AddTip(DateTime.Now.AddMinutes(120));
}
+
+ private void ButtonEx9_Click(object sender, EventArgs e)
+ {
+ AddTip(DateTime.Now.AddMinutes(15));
+ }
+
+ private void ButtonEx10_Click(object sender, EventArgs e)
+ {
+ AddTip(DateTime.Now.AddMinutes(20));
+ }
+
+ private void BtnMinuteOK_Click(object sender, EventArgs e)
+ {
+ AddTip(DateTime.Now.AddMinutes(NumMinute.Value.ToInt()));
+ }
+
+ private void NumericUpDown1_Enter(object sender, EventArgs e)
+ {
+ NumMinute.Select(0, NumMinute.Value.ToString().Length);
+ }
+
+ private void NumMinute_MouseClick(object sender, MouseEventArgs e)
+ {
+ NumMinute.Select(0, NumMinute.Value.ToString().Length);
+ }
+
+ private void TabControl1_SelectedIndexChanged(object sender, EventArgs e)
+ {
+ if(tabControl1.SelectedTab==tabPage2)
+ {
+ NumMinute.Focus();
+ }
+ }
+
+ private void BtnTimeOK_Click(object sender, EventArgs e)
+ {
+ if (dateTimePicker1.Value <= DateTime.Now)
+ {
+ AddTip(dateTimePicker1.Value.AddDays(1));
+ }
+ else
+ {
+ AddTip(dateTimePicker1.Value);
+ }
+ }
}
}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.resx b/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.resx
index df8339b..78ea9a0 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.resx
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmQuickAdd.resx
@@ -120,4 +120,81 @@
17, 17
+
+
+
+ AAABAAEAICAAAAEAIACoEAAAFgAAACgAAAAgAAAAQAAAAAEAIAAAAAAAABAAAHQSAAB0EgAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAPOWIQDzliEA85YhAPOWIQDzliEA85YhAPOW
+ IQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEA85YhAPOW
+ IQDzliEA85YhAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADzliEA85YhAPOWIQDzliEA85YhEvOW
+ ITnzliFj85YhgPOWIYbzliGG85YhgvOWIWfzliE985YhFPOWIQDzliEA85YhAPOWIQDzliFD85YhhvOW
+ IYXzliGF85Yhh/OWIUDzliEAAAAAAAAAAAAAAAAAAAAAAAAAAADzliEA85YhAPOWIQDzliEA85YhKvOW
+ IYDzliHL85Yh8vOWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIfPzliHQ85YhiPOWITDzliEC85YhTvOW
+ IeXzliH/85Yh//OWIf/zliH/85Yhh/OWIQAAAAAAAAAAAAAAAAAAAAAA85YhAPOWIQDzliEA85YhFfOW
+ IX7zliHi85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh5fOW
+ IaPzliHj85Yh//OWIf/zliH/85Yh//OWIf/zliGF85YhAAAAAAAAAAAAAAAAAPOWIQDzliEA85YhAPOW
+ ITHzliG985Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OW
+ If/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIYXzliEAAAAAAAAAAADzliEA85YhAPOW
+ IQDzliE985Yh1/OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OW
+ If/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85YhhvOWIQAAAAAAAAAAAPOW
+ IQDzliEA85YhL/OWIdbzliH/85Yh//OWIf/zliH/85Yh//OWIf/zliHx85YhxvOWIZnzliGB85YhgPOW
+ IZbzliHA85Yh7vOWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIeTzliFD85YhAAAA
+ AADzliEA85YhAPOWIRPzliG685Yh//OWIf/zliH/85Yh//OWIf/zliH085YhoPOWIT7zliEO85YhAPOW
+ IQDzliEA85YhAPOWIQvzliE385YhlfOWIe/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliHj85YhTvOW
+ IQDzliEAAAAAAPOWIQDzliEA85YhePOWIf/zliH/85Yh//OWIf/zliH/85Yh4POWIVjzliEF85YhAPOW
+ IQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEC85YhSvOWIdXzliH/85Yh//OWIf/zliH/85Yh//OW
+ IaPzliEB85YhAPOWIQDzliEA85YhAPOWISTzliHd85Yh//OWIf/zliH/85Yh//OWIeHzliFD85YhAPOW
+ IQDzliEA85YhAAAAAAAAAAAAAAAAAAAAAADzliEA85YhAPOWIQDzliEA85YhNPOWIdXzliH/85Yh//OW
+ If/zliH/85Yh5fOWITDzliEA85YhAPOWIQDzliEA85YhdvOWIf/zliH/85Yh//OWIf/zliH285YhXvOW
+ IQDzliEA85YhAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA85YhAPOWIQDzliEA85YhSvOW
+ Ie/zliH/85Yh//OWIf/zliH/85YhiPOWIQDzliEA85YhAPOWIQzzliHB85Yh//OWIf/zliH/85Yh//OW
+ IarzliEH85YhAPOWIQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA85YhAPOW
+ IQDzliEC85YhlfOWIf/zliH/85Yh//OWIf/zliHQ85YhFfOWIQDzliEA85YhLvOWIevzliH/85Yh//OW
+ If/zliH285YhSvOWIQDzliEAAAAAAAAAAAAAAAAA85YhAPOWIQDzliEA85YhAPOWIQDzliEAAAAAAAAA
+ AAAAAAAA85YhAPOWIQDzliE385Yh7vOWIf/zliH/85Yh//OWIfTzliE985YhAPOWIQDzliFV85Yh/POW
+ If/zliH/85Yh//OWIdPzliEV85YhAPOWIQAAAAAAAAAAAPOWIQDzliEA85YhAPOWIQ/zliER85YhAPOW
+ IQDzliEAAAAAAAAAAADzliEA85YhAPOWIQvzliHB85Yh//OWIf/zliH/85Yh//OWIWfzliEA85YhAPOW
+ IXLzliH/85Yh//OWIf/zliH/85YhrfOWIQPzliEAAAAAAAAAAAAAAAAA85YhAPOWIQDzliFF85Yhx/OW
+ Ic3zliFU85YhAPOWIQAAAAAAAAAAAAAAAADzliEA85YhAPOWIZbzliH/85Yh//OWIf/zliH/85YhgvOW
+ IQDzliEA85YhgfOWIf/zliH/85Yh//OWIf/zliGX85YhAPOWIQAAAAAAAAAAAAAAAADzliEA85YhCPOW
+ IbvzliG485YhqfOWIczzliER85YhAPOWIQAAAAAAAAAAAPOWIQDzliEA85YhgPOWIf/zliH/85Yh//OW
+ If/zliGG85YhAPOWIQDzliGB85Yh//OWIf/zliH/85Yh//OWIZjzliEA85YhAAAAAAAAAAAAAAAAAPOW
+ IQDzliEH85YhtPOWIcTzliG385Yh2POWIRfzliEA85YhAPOWIQAAAAAA85YhAPOWIQDzliGB85Yh//OW
+ If/zliH/85Yh//OWIYbzliEA85YhAPOWIXHzliH/85Yh//OWIf/zliH/85YhsPOWIQTzliEAAAAAAAAA
+ AAAAAAAA85YhAPOWIQDzliE385Yhs/OWIcbzliHm85YhhPOWIQfzliEA85YhAPOWIQDzliEA85YhAPOW
+ IZnzliH/85Yh//OWIf/zliH/85YhgPOWIQDzliEA85YhUvOWIfzzliH/85Yh//OWIf/zliHX85YhGfOW
+ IQDzliEAAAAAAAAAAADzliEA85YhAPOWIQDzliEG85YhCvOWIV/zliHo85YhhPOWIQfzliEA85YhAPOW
+ IQDzliEO85YhxvOWIf/zliH/85Yh//OWIf/zliFj85YhAPOWIQDzliEs85Yh6fOWIf/zliH/85Yh//OW
+ IfnzliFT85YhAPOWIQAAAAAAAAAAAAAAAADzliEA85YhAPOWIQDzliEA85YhAPOWIV7zliHo85YhhPOW
+ IQfzliEA85YhAPOWIT/zliHy85Yh//OWIf/zliH/85Yh8fOWITnzliEA85YhAPOWIQrzliG985Yh//OW
+ If/zliH/85Yh//OWIbXzliEL85YhAPOWIQAAAAAAAAAAAAAAAAAAAAAAAAAAAPOWIQDzliEA85YhAPOW
+ IV7zliHo85YhhPOWIQbzliEE85YhovOWIf/zliH/85Yh//OWIf/zliHL85YhEfOWIQDzliEA85YhAPOW
+ IW7zliH/85Yh//OWIf/zliH/85Yh+vOWIW3zliEA85YhAPOWIQAAAAAAAAAAAAAAAAAAAAAAAAAAAPOW
+ IQDzliEA85YhAPOWIV7zliHo85YhhPOWIWXzliH185Yh//OWIf/zliH/85Yh//OWIYDzliEA85YhAPOW
+ IQDzliEA85YhHvOWIdbzliH/85Yh//OWIf/zliH/85Yh6vOWIVPzliEA85YhAPOWIQDzliEAAAAAAAAA
+ AAAAAAAAAAAAAPOWIQDzliEA85YhAPOWIV/zliGu85YhivOWIfjzliH/85Yh//OWIf/zliHi85YhKvOW
+ IQDzliEAAAAAAPOWIQDzliEA85YhbfOWIf3zliH/85Yh//OWIf/zliH/85Yh6vOWIW3zliEM85YhAPOW
+ IQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEH85YhZfOWIaHzliEz85Yhz/OWIf/zliH/85Yh//OW
+ IX7zliEA85YhAPOWIQAAAAAA85YhAPOWIQDzliEO85YhrvOWIf/zliH/85Yh//OWIf/zliH/85Yh+vOW
+ IbXzliFT85YhGfOWIQTzliEA85YhAPOWIQPzliEW85YhS/OWIazzliH385Yh//OWId/zliH285Yh//OW
+ If/zliG985YhFfOWIQDzliEAAAAAAAAAAAAAAAAA85YhAPOWIQDzliEm85YhzPOWIf/zliH/85Yh//OW
+ If/zliH/85Yh//OWIfnzliHX85YhsPOWIZjzliGX85YhrPOWIdPzliH385Yh//OWIf/zliH/85Yh//OW
+ If/zliH/85Yh1/OWITHzliEA85YhAAAAAAAAAAAAAAAAAAAAAADzliEA85YhAPOWIQDzliEy85YhzPOW
+ If/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OW
+ If/zliH/85Yh//OWIdXzliE985YhAPOWIQDzliEAAAAAAAAAAAAAAAAAAAAAAAAAAADzliEA85YhAPOW
+ IQDzliEm85Yhr/OWIf3zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OW
+ If/zliH/85Yh//OWIf/zliG585YhL/OWIQDzliEA85YhAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
+ AADzliEA85YhAPOWIQDzliEO85YhbfOWIdfzliH/85Yh//OWIf/zliH/85Yh//OWIf/zliH/85Yh//OW
+ If/zliH/85Yh//OWIf/zliHc85Yhd/OWIRLzliEA85YhAPOWIQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAADzliEA85YhAPOWIQDzliEA85YhHvOWIW7zliG885Yh6fOWIfvzliH/85Yh//OW
+ If/zliH/85Yh/POWIezzliHC85YhdvOWISTzliEA85YhAPOWIQDzliEAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA85YhAPOWIQDzliEA85YhAPOWIQrzliEr85YhUfOW
+ IXDzliGA85YhgfOWIXLzliFV85YhL/OWIQzzliEA85YhAPOWIQDzliEAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAPOWIQDzliEA85YhAPOW
+ IQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEA85YhAPOWIQDzliEAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAA/wAAAP4AAAD4AAAA8AAAAOAAAADAAAAAwAAAAIAAAACAAAAAAAPAAAAP
+ 8AAAH/gAADgcAAAwDAAAcA4AAHAGAABwAgAAcAAAADAAAAA4AAAAHwAAAA+AAAADwACAAAAAgAAAAcAA
+ AAPAAAAD4AAAB/AAAA/4AAAf/gAAf/+AAf8=
+
+
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmRest.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmRest.Designer.cs
index 7a7e147..40eca12 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmRest.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmRest.Designer.cs
@@ -117,6 +117,7 @@
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FrmRest_FormClosing);
this.Load += new System.EventHandler(this.FrmRest_Load);
this.KeyDown += new System.Windows.Forms.KeyEventHandler(this.FrmRest_KeyDown);
+ this.Resize += new System.EventHandler(this.FrmRest_Resize);
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.ResumeLayout(false);
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmRest.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmRest.cs
index fd506b0..e54afbf 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmRest.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmRest.cs
@@ -142,5 +142,10 @@ namespace TimeClock.DbOp
Itrycn_Info.InitRest();
this.Close();
}
+
+ private void FrmRest_Resize(object sender, EventArgs e)
+ {
+ label1.Left = (Width - label1.Width) / 2;
+ }
}
}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmSetting.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmSetting.cs
index 37068de..1f93302 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmSetting.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmSetting.cs
@@ -56,7 +56,7 @@ namespace TimeClock.DbOp
//Setting.FilePath = Application.StartupPath + "\\UserDb\\Setting.dat";
Setting.SettingXML = Itrycn_Db.GetSetting("Setting", "");
ryCommon.RyRegedit.RegRoot = Microsoft.Win32.RegistryHive.CurrentUser;
- ChkAutoRun.Checked = ryCommon.RyRegedit.IsAutoRun(Custom.AutoRunName, "\"" + Application.ExecutablePath + "\" " + Custom.AutoRunPram);
+ ChkAutoRun.Checked = ryCommon.RyRegedit.IsAutoRun(Custom.AutoRunName, "\"" + Application.ExecutablePath.Replace("/", "\\") + "\" " + Custom.AutoRunPram);
Setting.Add("FullScreenTip", ChkFullScreenTip, true);
Setting.Add("AutoClose", ChkAutoClose, false);
Setting.Add("AutoCloseMinute", NuAutoCloseMinute, 1);
@@ -187,7 +187,7 @@ namespace TimeClock.DbOp
#endregion
Itrycn_Db.SetSetting("Setting", myXML.XMLText);
ryCommon.RyRegedit.RegRoot = Microsoft.Win32.RegistryHive.CurrentUser;
- ryCommon.RyRegedit.SetAutoRun(ChkAutoRun.Checked, Custom.AutoRunName, "\"" + Application.ExecutablePath + "\" "+ Custom.AutoRunPram);
+ ryCommon.RyRegedit.SetAutoRun(ChkAutoRun.Checked, Custom.AutoRunName, "\"" + Application.ExecutablePath.Replace("/","\\") + "\" "+ Custom.AutoRunPram);
if (_RestTip_On != ChkRestTip_On.Checked || _RestInteval != NumRestInteval.Value || _Rest != NumRest.Value) //初始化休息数据
{
Itrycn_Info.ReadSetting();
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmSticky.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmSticky.cs
index a2440bc..d38ce08 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmSticky.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmSticky.cs
@@ -128,28 +128,30 @@ namespace TimeClock.DbOp
}
private void SetFontStyle(FontStyle style, bool IsRemove)
{
+ var font = txtContent.SelectionFont ?? this.Font;
if (IsRemove)
- { txtContent.SelectionFont = new Font(txtContent.SelectionFont, txtContent.SelectionFont.Style ^ style); }
- else { txtContent.SelectionFont = new Font(txtContent.SelectionFont, txtContent.SelectionFont.Style | style); }
+ { txtContent.SelectionFont = new Font(font ?? this.Font, font.Style ^ style); }
+ else { txtContent.SelectionFont = new Font(font, font.Style | style); }
}
private void LblBold_Click(object sender, EventArgs e)
{
- SetFontStyle(FontStyle.Bold, txtContent.SelectionFont.Bold);
+ SetFontStyle(FontStyle.Bold, txtContent.SelectionFont == null ? false : txtContent.SelectionFont.Bold);
}
private void LblItalic_Click(object sender, EventArgs e)
{
- SetFontStyle(FontStyle.Italic, txtContent.SelectionFont.Italic);
+ SetFontStyle(FontStyle.Italic, txtContent.SelectionFont == null?false: txtContent.SelectionFont.Italic) ;
}
private void LblUnderline_Click(object sender, EventArgs e)
{
- SetFontStyle(FontStyle.Underline, txtContent.SelectionFont.Underline);
+ SetFontStyle(FontStyle.Underline, txtContent.SelectionFont == null ? false : txtContent.SelectionFont.Underline);
+
}
private void LblStrikeout_Click(object sender, EventArgs e)
{
- SetFontStyle(FontStyle.Strikeout, txtContent.SelectionFont.Strikeout);
+ SetFontStyle(FontStyle.Strikeout, txtContent.SelectionFont == null ? false : txtContent.SelectionFont.Strikeout);
}
#endregion
#region 菜单设置
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.Designer.cs
index 1410e6e..2553676 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.Designer.cs
@@ -77,6 +77,11 @@
this.ChkW2 = new System.Windows.Forms.CheckBox();
this.ChkW1 = new System.Windows.Forms.CheckBox();
this.PnlMonth = new System.Windows.Forms.Panel();
+ this.ChkWeekTypeByMonth = new System.Windows.Forms.CheckBox();
+ this.CbbWeekByMonth = new ryControls.RyComboBox();
+ this.CbbWeekIndexByMonth = new ryControls.RyComboBox();
+ this.RbWeekByMonth = new System.Windows.Forms.RadioButton();
+ this.RbDayByMonth = new System.Windows.Forms.RadioButton();
this.ChkRevDay = new System.Windows.Forms.CheckBox();
this.CbbDay = new ryControls.RyComboBox();
this.PnlYear = new System.Windows.Forms.Panel();
@@ -109,6 +114,19 @@
this.清空时间段ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.tableModel1 = new XPTable.Models.TableModel();
this.CbbDisturbed = new ryControls.RyComboBox();
+ this.tabPage4 = new System.Windows.Forms.TabPage();
+ this.table_show = new XPTable.Models.Table();
+ this.columnModel_show = new XPTable.Models.ColumnModel();
+ this.ColType = new XPTable.Models.TextColumn();
+ this.ColName = new XPTable.Models.TextColumn();
+ this.ColValue = new XPTable.Models.TextColumn();
+ this.contextMenuStrip_show = new System.Windows.Forms.ContextMenuStrip(this.components);
+ this.添加出生日期ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.添加倒计时ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.添加纪念日ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.toolStripMenuItem3 = new System.Windows.Forms.ToolStripSeparator();
+ this.删除自定义显示ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.tableModel_show = new XPTable.Models.TableModel();
this.ChkEnabled = new System.Windows.Forms.CheckBox();
this.ChkAllowShow = new System.Windows.Forms.CheckBox();
this.txtName = new ryControls.TextBoxEx2();
@@ -159,6 +177,9 @@
this.tabPage3.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.table1)).BeginInit();
this.contextMenuStrip1.SuspendLayout();
+ this.tabPage4.SuspendLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.table_show)).BeginInit();
+ this.contextMenuStrip_show.SuspendLayout();
this.contextMenuStrip2.SuspendLayout();
this.PnlKeys.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
@@ -191,10 +212,11 @@
this.tabControl1.Controls.Add(this.tabPage2);
this.tabControl1.Controls.Add(this.tabPage1);
this.tabControl1.Controls.Add(this.tabPage3);
+ this.tabControl1.Controls.Add(this.tabPage4);
this.tabControl1.Location = new System.Drawing.Point(12, 55);
this.tabControl1.Name = "tabControl1";
this.tabControl1.SelectedIndex = 0;
- this.tabControl1.Size = new System.Drawing.Size(575, 397);
+ this.tabControl1.Size = new System.Drawing.Size(575, 427);
this.tabControl1.TabIndex = 11;
this.tabControl1.SelectedIndexChanged += new System.EventHandler(this.TabControl1_SelectedIndexChanged);
//
@@ -212,7 +234,7 @@
this.tabPage2.Location = new System.Drawing.Point(4, 22);
this.tabPage2.Name = "tabPage2";
this.tabPage2.Padding = new System.Windows.Forms.Padding(3);
- this.tabPage2.Size = new System.Drawing.Size(567, 371);
+ this.tabPage2.Size = new System.Drawing.Size(567, 401);
this.tabPage2.TabIndex = 1;
this.tabPage2.Text = "内容";
this.tabPage2.UseVisualStyleBackColor = true;
@@ -343,7 +365,7 @@
this.tabPage1.Location = new System.Drawing.Point(4, 22);
this.tabPage1.Name = "tabPage1";
this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
- this.tabPage1.Size = new System.Drawing.Size(567, 371);
+ this.tabPage1.Size = new System.Drawing.Size(567, 401);
this.tabPage1.TabIndex = 0;
this.tabPage1.Text = "定时";
this.tabPage1.UseVisualStyleBackColor = true;
@@ -361,7 +383,7 @@
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(131, 3);
this.panel2.Name = "panel2";
- this.panel2.Size = new System.Drawing.Size(433, 365);
+ this.panel2.Size = new System.Drawing.Size(433, 395);
this.panel2.TabIndex = 12;
//
// panel4
@@ -371,7 +393,7 @@
this.panel4.Controls.Add(this.ChkEarlierTime);
this.panel4.Controls.Add(this.CbbEarlierTime);
this.panel4.Dock = System.Windows.Forms.DockStyle.Top;
- this.panel4.Location = new System.Drawing.Point(0, 339);
+ this.panel4.Location = new System.Drawing.Point(0, 364);
this.panel4.Name = "panel4";
this.panel4.Size = new System.Drawing.Size(433, 35);
this.panel4.TabIndex = 16;
@@ -428,7 +450,7 @@
this.panel3.Controls.Add(this.CbbAction);
this.panel3.Controls.Add(this.label5);
this.panel3.Dock = System.Windows.Forms.DockStyle.Top;
- this.panel3.Location = new System.Drawing.Point(0, 235);
+ this.panel3.Location = new System.Drawing.Point(0, 260);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(433, 104);
this.panel3.TabIndex = 13;
@@ -525,7 +547,7 @@
this.PnlStartTime.Controls.Add(this.Dt_StartDate);
this.PnlStartTime.Controls.Add(this.label4);
this.PnlStartTime.Dock = System.Windows.Forms.DockStyle.Top;
- this.PnlStartTime.Location = new System.Drawing.Point(0, 197);
+ this.PnlStartTime.Location = new System.Drawing.Point(0, 222);
this.PnlStartTime.Name = "PnlStartTime";
this.PnlStartTime.Size = new System.Drawing.Size(433, 38);
this.PnlStartTime.TabIndex = 12;
@@ -567,7 +589,7 @@
this.PnlTime.Controls.Add(this.DtDay);
this.PnlTime.Controls.Add(this.label1);
this.PnlTime.Dock = System.Windows.Forms.DockStyle.Top;
- this.PnlTime.Location = new System.Drawing.Point(0, 157);
+ this.PnlTime.Location = new System.Drawing.Point(0, 182);
this.PnlTime.Name = "PnlTime";
this.PnlTime.Size = new System.Drawing.Size(433, 40);
this.PnlTime.TabIndex = 10;
@@ -615,7 +637,7 @@
this.PnlWeek.Controls.Add(this.ChkW2);
this.PnlWeek.Controls.Add(this.ChkW1);
this.PnlWeek.Dock = System.Windows.Forms.DockStyle.Top;
- this.PnlWeek.Location = new System.Drawing.Point(0, 125);
+ this.PnlWeek.Location = new System.Drawing.Point(0, 150);
this.PnlWeek.Name = "PnlWeek";
this.PnlWeek.Size = new System.Drawing.Size(433, 32);
this.PnlWeek.TabIndex = 14;
@@ -692,19 +714,100 @@
//
// PnlMonth
//
+ this.PnlMonth.Controls.Add(this.ChkWeekTypeByMonth);
+ this.PnlMonth.Controls.Add(this.CbbWeekByMonth);
+ this.PnlMonth.Controls.Add(this.CbbWeekIndexByMonth);
+ this.PnlMonth.Controls.Add(this.RbWeekByMonth);
+ this.PnlMonth.Controls.Add(this.RbDayByMonth);
this.PnlMonth.Controls.Add(this.ChkRevDay);
this.PnlMonth.Controls.Add(this.CbbDay);
this.PnlMonth.Dock = System.Windows.Forms.DockStyle.Top;
this.PnlMonth.Location = new System.Drawing.Point(0, 85);
this.PnlMonth.Name = "PnlMonth";
- this.PnlMonth.Size = new System.Drawing.Size(433, 40);
+ this.PnlMonth.Size = new System.Drawing.Size(433, 65);
this.PnlMonth.TabIndex = 15;
this.PnlMonth.Visible = false;
//
+ // ChkWeekTypeByMonth
+ //
+ this.ChkWeekTypeByMonth.AutoSize = true;
+ this.ChkWeekTypeByMonth.Location = new System.Drawing.Point(282, 39);
+ this.ChkWeekTypeByMonth.Name = "ChkWeekTypeByMonth";
+ this.ChkWeekTypeByMonth.Size = new System.Drawing.Size(60, 16);
+ this.ChkWeekTypeByMonth.TabIndex = 17;
+ this.ChkWeekTypeByMonth.Text = "按周来";
+ this.toolTip1.SetToolTip(this.ChkWeekTypeByMonth, "勾选本项之后,就按第几个星期算,可能会出现执行时间\r\n在上一个月或下一个月的情况。\r\n比如2020年4月的最后一个星期的周五,提醒时间就是\r\n2020年5月1日。" +
+ "\r\n如果不勾选本项,则提醒时间只会在当月里进行执行。");
+ this.ChkWeekTypeByMonth.UseVisualStyleBackColor = true;
+ this.ChkWeekTypeByMonth.CheckedChanged += new System.EventHandler(this.ChkWeekTypeByMonth_CheckedChanged);
+ //
+ // CbbWeekByMonth
+ //
+ this.CbbWeekByMonth.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
+ this.CbbWeekByMonth.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.CbbWeekByMonth.Enabled = false;
+ this.CbbWeekByMonth.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.CbbWeekByMonth.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.CbbWeekByMonth.FormattingEnabled = true;
+ this.CbbWeekByMonth.Items.AddRange(new object[] {
+ "周一",
+ "周二",
+ "周三",
+ "周四",
+ "周五",
+ "周六",
+ "周日"});
+ this.CbbWeekByMonth.Location = new System.Drawing.Point(196, 35);
+ this.CbbWeekByMonth.Name = "CbbWeekByMonth";
+ this.CbbWeekByMonth.Size = new System.Drawing.Size(80, 24);
+ this.CbbWeekByMonth.TabIndex = 16;
+ //
+ // CbbWeekIndexByMonth
+ //
+ this.CbbWeekIndexByMonth.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
+ this.CbbWeekIndexByMonth.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.CbbWeekIndexByMonth.Enabled = false;
+ this.CbbWeekIndexByMonth.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.CbbWeekIndexByMonth.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.CbbWeekIndexByMonth.FormattingEnabled = true;
+ this.CbbWeekIndexByMonth.Items.AddRange(new object[] {
+ "第一个",
+ "第二个",
+ "第三个",
+ "第四个",
+ "最后一个"});
+ this.CbbWeekIndexByMonth.Location = new System.Drawing.Point(68, 35);
+ this.CbbWeekIndexByMonth.Name = "CbbWeekIndexByMonth";
+ this.CbbWeekIndexByMonth.Size = new System.Drawing.Size(122, 24);
+ this.CbbWeekIndexByMonth.TabIndex = 15;
+ //
+ // RbWeekByMonth
+ //
+ this.RbWeekByMonth.AutoSize = true;
+ this.RbWeekByMonth.Location = new System.Drawing.Point(13, 39);
+ this.RbWeekByMonth.Name = "RbWeekByMonth";
+ this.RbWeekByMonth.Size = new System.Drawing.Size(35, 16);
+ this.RbWeekByMonth.TabIndex = 14;
+ this.RbWeekByMonth.Text = "周";
+ this.RbWeekByMonth.UseVisualStyleBackColor = true;
+ //
+ // RbDayByMonth
+ //
+ this.RbDayByMonth.AutoSize = true;
+ this.RbDayByMonth.Checked = true;
+ this.RbDayByMonth.Location = new System.Drawing.Point(13, 13);
+ this.RbDayByMonth.Name = "RbDayByMonth";
+ this.RbDayByMonth.Size = new System.Drawing.Size(35, 16);
+ this.RbDayByMonth.TabIndex = 13;
+ this.RbDayByMonth.TabStop = true;
+ this.RbDayByMonth.Text = "天";
+ this.RbDayByMonth.UseVisualStyleBackColor = true;
+ this.RbDayByMonth.CheckedChanged += new System.EventHandler(this.RbDayByMonth_CheckedChanged);
+ //
// ChkRevDay
//
this.ChkRevDay.AutoSize = true;
- this.ChkRevDay.Location = new System.Drawing.Point(16, 10);
+ this.ChkRevDay.Location = new System.Drawing.Point(68, 13);
this.ChkRevDay.Name = "ChkRevDay";
this.ChkRevDay.Size = new System.Drawing.Size(48, 16);
this.ChkRevDay.TabIndex = 12;
@@ -719,7 +822,7 @@
this.CbbDay.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
this.CbbDay.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.CbbDay.FormattingEnabled = true;
- this.CbbDay.Location = new System.Drawing.Point(68, 5);
+ this.CbbDay.Location = new System.Drawing.Point(120, 8);
this.CbbDay.Name = "CbbDay";
this.CbbDay.Size = new System.Drawing.Size(117, 24);
this.CbbDay.TabIndex = 11;
@@ -856,7 +959,7 @@
this.panel1.Dock = System.Windows.Forms.DockStyle.Left;
this.panel1.Location = new System.Drawing.Point(3, 3);
this.panel1.Name = "panel1";
- this.panel1.Size = new System.Drawing.Size(128, 365);
+ this.panel1.Size = new System.Drawing.Size(128, 395);
this.panel1.TabIndex = 0;
//
// RbWinStart
@@ -962,7 +1065,7 @@
this.tabPage3.Location = new System.Drawing.Point(4, 22);
this.tabPage3.Name = "tabPage3";
this.tabPage3.Padding = new System.Windows.Forms.Padding(3);
- this.tabPage3.Size = new System.Drawing.Size(567, 371);
+ this.tabPage3.Size = new System.Drawing.Size(567, 401);
this.tabPage3.TabIndex = 2;
this.tabPage3.Text = "免打扰";
this.tabPage3.UseVisualStyleBackColor = true;
@@ -1041,10 +1144,6 @@
this.清空时间段ToolStripMenuItem.Text = "清空时间段";
this.清空时间段ToolStripMenuItem.Click += new System.EventHandler(this.清空时间段ToolStripMenuItem_Click);
//
- // tableModel1
- //
- this.tableModel1.RowHeight = 25;
- //
// CbbDisturbed
//
this.CbbDisturbed.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawFixed;
@@ -1061,6 +1160,106 @@
this.CbbDisturbed.TabIndex = 43;
this.toolTip1.SetToolTip(this.CbbDisturbed, "【以下时间段不执行本提醒】\r\n在以下列表中的时间段,本提醒都将跳过提醒。\r\n【只支持以下时间段内的本提醒】\r\n只有以下列表中的某个时间段符合要求,就会提醒。\r\n而" +
"不是必须全部匹配。");
+ //
+ // tabPage4
+ //
+ this.tabPage4.Controls.Add(this.table_show);
+ this.tabPage4.Location = new System.Drawing.Point(4, 22);
+ this.tabPage4.Name = "tabPage4";
+ this.tabPage4.Padding = new System.Windows.Forms.Padding(3);
+ this.tabPage4.Size = new System.Drawing.Size(567, 401);
+ this.tabPage4.TabIndex = 3;
+ this.tabPage4.Text = "自定义显示";
+ this.tabPage4.UseVisualStyleBackColor = true;
+ //
+ // table_show
+ //
+ this.table_show.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+ | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
+ this.table_show.ColumnModel = this.columnModel_show;
+ this.table_show.ContextMenuStrip = this.contextMenuStrip_show;
+ this.table_show.EnableToolTips = true;
+ this.table_show.FullRowSelect = true;
+ this.table_show.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable;
+ this.table_show.Location = new System.Drawing.Point(6, 6);
+ this.table_show.Name = "table_show";
+ this.table_show.NoItemsText = "当前列表没有任何项";
+ this.table_show.Size = new System.Drawing.Size(555, 359);
+ this.table_show.TabIndex = 45;
+ this.table_show.TableModel = this.tableModel_show;
+ this.table_show.Text = "table2";
+ //
+ // columnModel_show
+ //
+ this.columnModel_show.Columns.AddRange(new XPTable.Models.Column[] {
+ this.ColType,
+ this.ColName,
+ this.ColValue});
+ //
+ // ColType
+ //
+ this.ColType.Editable = false;
+ this.ColType.Tag = null;
+ this.ColType.Text = "类型";
+ //
+ // ColName
+ //
+ this.ColName.Editable = false;
+ this.ColName.Tag = null;
+ this.ColName.Text = "名称";
+ this.ColName.Width = 150;
+ //
+ // ColValue
+ //
+ this.ColValue.Editable = false;
+ this.ColValue.Tag = null;
+ this.ColValue.Text = "内容";
+ this.ColValue.Width = 300;
+ //
+ // contextMenuStrip_show
+ //
+ this.contextMenuStrip_show.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
+ this.添加出生日期ToolStripMenuItem,
+ this.添加倒计时ToolStripMenuItem,
+ this.添加纪念日ToolStripMenuItem,
+ this.toolStripMenuItem3,
+ this.删除自定义显示ToolStripMenuItem});
+ this.contextMenuStrip_show.Name = "contextMenuStrip_show";
+ this.contextMenuStrip_show.Size = new System.Drawing.Size(161, 98);
+ //
+ // 添加出生日期ToolStripMenuItem
+ //
+ this.添加出生日期ToolStripMenuItem.Name = "添加出生日期ToolStripMenuItem";
+ this.添加出生日期ToolStripMenuItem.Size = new System.Drawing.Size(160, 22);
+ this.添加出生日期ToolStripMenuItem.Text = "添加出生日期";
+ this.添加出生日期ToolStripMenuItem.Click += new System.EventHandler(this.添加出生日期ToolStripMenuItem_Click);
+ //
+ // 添加倒计时ToolStripMenuItem
+ //
+ this.添加倒计时ToolStripMenuItem.Name = "添加倒计时ToolStripMenuItem";
+ this.添加倒计时ToolStripMenuItem.Size = new System.Drawing.Size(160, 22);
+ this.添加倒计时ToolStripMenuItem.Text = "添加倒计时";
+ this.添加倒计时ToolStripMenuItem.Click += new System.EventHandler(this.添加倒计时ToolStripMenuItem_Click);
+ //
+ // 添加纪念日ToolStripMenuItem
+ //
+ this.添加纪念日ToolStripMenuItem.Name = "添加纪念日ToolStripMenuItem";
+ this.添加纪念日ToolStripMenuItem.Size = new System.Drawing.Size(160, 22);
+ this.添加纪念日ToolStripMenuItem.Text = "添加纪念日";
+ this.添加纪念日ToolStripMenuItem.Click += new System.EventHandler(this.添加纪念日ToolStripMenuItem_Click);
+ //
+ // toolStripMenuItem3
+ //
+ this.toolStripMenuItem3.Name = "toolStripMenuItem3";
+ this.toolStripMenuItem3.Size = new System.Drawing.Size(157, 6);
+ //
+ // 删除自定义显示ToolStripMenuItem
+ //
+ this.删除自定义显示ToolStripMenuItem.Name = "删除自定义显示ToolStripMenuItem";
+ this.删除自定义显示ToolStripMenuItem.Size = new System.Drawing.Size(160, 22);
+ this.删除自定义显示ToolStripMenuItem.Text = "删除自定义显示";
+ this.删除自定义显示ToolStripMenuItem.Click += new System.EventHandler(this.删除自定义显示ToolStripMenuItem_Click);
//
// ChkEnabled
//
@@ -1068,7 +1267,7 @@
this.ChkEnabled.AutoSize = true;
this.ChkEnabled.Checked = true;
this.ChkEnabled.CheckState = System.Windows.Forms.CheckState.Checked;
- this.ChkEnabled.Location = new System.Drawing.Point(16, 463);
+ this.ChkEnabled.Location = new System.Drawing.Point(16, 493);
this.ChkEnabled.Name = "ChkEnabled";
this.ChkEnabled.Size = new System.Drawing.Size(48, 16);
this.ChkEnabled.TabIndex = 12;
@@ -1081,7 +1280,7 @@
this.ChkAllowShow.AutoSize = true;
this.ChkAllowShow.Checked = true;
this.ChkAllowShow.CheckState = System.Windows.Forms.CheckState.Checked;
- this.ChkAllowShow.Location = new System.Drawing.Point(94, 463);
+ this.ChkAllowShow.Location = new System.Drawing.Point(94, 493);
this.ChkAllowShow.Name = "ChkAllowShow";
this.ChkAllowShow.Size = new System.Drawing.Size(72, 16);
this.ChkAllowShow.TabIndex = 12;
@@ -1114,7 +1313,7 @@
//
this.btnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.btnCancel.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
- this.btnCancel.Location = new System.Drawing.Point(522, 458);
+ this.btnCancel.Location = new System.Drawing.Point(522, 488);
this.btnCancel.Name = "btnCancel";
this.btnCancel.Size = new System.Drawing.Size(65, 27);
this.btnCancel.TabIndex = 5;
@@ -1126,7 +1325,7 @@
//
this.btnOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.btnOK.BaseColor = System.Drawing.Color.FromArgb(((int)(((byte)(51)))), ((int)(((byte)(76)))), ((int)(((byte)(95)))));
- this.btnOK.Location = new System.Drawing.Point(451, 458);
+ this.btnOK.Location = new System.Drawing.Point(451, 488);
this.btnOK.Name = "btnOK";
this.btnOK.Size = new System.Drawing.Size(65, 27);
this.btnOK.TabIndex = 4;
@@ -1142,7 +1341,7 @@
//
this.ChkNoShowTip.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.ChkNoShowTip.AutoSize = true;
- this.ChkNoShowTip.Location = new System.Drawing.Point(190, 463);
+ this.ChkNoShowTip.Location = new System.Drawing.Point(190, 493);
this.ChkNoShowTip.Name = "ChkNoShowTip";
this.ChkNoShowTip.Size = new System.Drawing.Size(108, 16);
this.ChkNoShowTip.TabIndex = 13;
@@ -1374,7 +1573,7 @@
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(597, 495);
+ this.ClientSize = new System.Drawing.Size(597, 525);
this.Controls.Add(this.tabControl1);
this.Controls.Add(this.PnlKeys);
this.Controls.Add(this.label8);
@@ -1421,6 +1620,9 @@
this.tabPage3.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.table1)).EndInit();
this.contextMenuStrip1.ResumeLayout(false);
+ this.tabPage4.ResumeLayout(false);
+ ((System.ComponentModel.ISupportInitialize)(this.table_show)).EndInit();
+ this.contextMenuStrip_show.ResumeLayout(false);
this.contextMenuStrip2.ResumeLayout(false);
this.PnlKeys.ResumeLayout(false);
this.PnlKeys.PerformLayout();
@@ -1543,5 +1745,23 @@
private XPTable.Models.TableModel tableModel1;
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem2;
private System.Windows.Forms.ToolStripMenuItem 自定义时间ToolStripMenuItem;
+ private System.Windows.Forms.TabPage tabPage4;
+ private XPTable.Models.Table table_show;
+ private XPTable.Models.TableModel tableModel_show;
+ private XPTable.Models.ColumnModel columnModel_show;
+ private XPTable.Models.TextColumn ColType;
+ private XPTable.Models.TextColumn ColName;
+ private XPTable.Models.TextColumn ColValue;
+ private System.Windows.Forms.ContextMenuStrip contextMenuStrip_show;
+ private System.Windows.Forms.ToolStripMenuItem 添加出生日期ToolStripMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem 添加纪念日ToolStripMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem 添加倒计时ToolStripMenuItem;
+ private System.Windows.Forms.ToolStripSeparator toolStripMenuItem3;
+ private System.Windows.Forms.ToolStripMenuItem 删除自定义显示ToolStripMenuItem;
+ private ryControls.RyComboBox CbbWeekByMonth;
+ private ryControls.RyComboBox CbbWeekIndexByMonth;
+ private System.Windows.Forms.RadioButton RbWeekByMonth;
+ private System.Windows.Forms.RadioButton RbDayByMonth;
+ private System.Windows.Forms.CheckBox ChkWeekTypeByMonth;
}
}
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.cs
index c285a81..50bd11b 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.cs
@@ -17,6 +17,7 @@ namespace TimeClock.DbOp
{
public string tableName = "Dingshi";
public ModalForm mr = null;
+ private string ImgPath = "";
public FrmTimeAdd(ImageList imglist)
{
InitializeComponent();
@@ -27,6 +28,8 @@ namespace TimeClock.DbOp
Dt_StartTime.Value = DateTime.Now;
CbbShowPic.Enabled = false;
BtnSelectPic.Enabled = false;
+ CbbWeekIndexByMonth.SelectedIndex = 0;
+ CbbWeekByMonth.SelectedIndex = 0;
CbbAction.Items.AddRange(new ActionInfo[] {
new ActionInfo { Title = "不执行任何动作",Id="NoAction" },
new ActionInfo { Title = "重启电脑", Id = "Reboot" },
@@ -232,6 +235,33 @@ namespace TimeClock.DbOp
}
tabPage3.Text = "免打扰(" + table1.TableModel.Rows.Count + ")";
#endregion
+ #region 自定义显示
+ ryCommon.Storage myCustomShow_XML = new Storage(reader["CustomShow"].ToString());
+ myCustomShow_XML.SelectNodeBySet();
+ iCount = myCustomShow_XML.GetAttrValue("Count", 0);
+ for (int m = 0; m < iCount; m++)
+ {
+ CustomShowInfo dt_info = new CustomShowInfo()
+ {
+ Type = myCustomShow_XML.GetAttrValue("CsType" + (m + 1).ToString(), 1),
+ Name = myCustomShow_XML.GetAttrValue("CsName" + (m + 1).ToString(),""),
+ IsLunar = myCustomShow_XML.GetAttrValue("CsIsLunar" + (m + 1).ToString(),false),
+ Year = myCustomShow_XML.GetAttrValue("CsYear" + (m + 1).ToString(), 1),
+ Month = myCustomShow_XML.GetAttrValue("CsMonth" + (m + 1).ToString(), 1),
+ Day = myCustomShow_XML.GetAttrValue("CsDay" + (m + 1).ToString(), 1)
+ };
+ XPTable.Models.Row itemList = new XPTable.Models.Row()
+ {
+ Tag = dt_info
+ };
+ //需要修改此处
+ itemList.Cells.Add(new XPTable.Models.Cell(dt_info.TypeStr));//示例
+ itemList.Cells.Add(new XPTable.Models.Cell(dt_info.Name));
+ itemList.Cells.Add(new XPTable.Models.Cell(dt_info.DateStr));
+ table_show.TableModel.Rows.Add(itemList);
+ tabPage4.Text = "自定义显示(" + table_show.TableModel.Rows.Count + ")";
+ }
+ #endregion
#endregion
ryCommon.Storage tStor = new Storage(reader["SetXML"].ToString());
tStor.SelectNodeBySet();
@@ -247,7 +277,8 @@ namespace TimeClock.DbOp
CbbSound.Text = sound;
}
ChkShowPic.Checked = tStor.GetAttrValue("showpic_on", false);
- CbbShowPic.Text = tStor.GetAttrValue("showpic", "");
+ ImgPath= tStor.GetAttrValue("showpic", "");
+ CbbShowPic.Text = ImgPath;
ChkNoShowTip.Checked = tStor.GetAttrValue("NoShowTip", false);
string ActionId = tStor.GetAttrValue("ActionId");
string File = tStor.GetAttrValue("File");
@@ -268,11 +299,28 @@ namespace TimeClock.DbOp
}
if (RbMonth.Checked)
{
- ChkRevDay.Checked = tStor.GetAttrValue("revday", false);
- int day = tStor.GetAttrValue("day", -1);
- if (day.IsInRange(0, 29))
+ var month_mode = tStor.GetAttrValue("month_mode", 0);
+ if (month_mode == 0)
{
- CbbDay.SelectedIndex = day;
+ RbDayByMonth.Checked = true;
+ ChkRevDay.Checked = tStor.GetAttrValue("revday", false);
+ int day = tStor.GetAttrValue("day", -1);
+ if (day.IsInRange(0, 29))
+ {
+ CbbDay.SelectedIndex = day;
+ }
+ }
+ else
+ {
+ RbWeekByMonth.Checked = true;
+ var week_m= tStor.GetAttrValue("week_m", 1);
+ if (!week_m.IsInRange(1, 7)) { week_m = 1; }
+ CbbWeekByMonth.SelectedIndex = week_m - 1;
+ var weekindex_m= tStor.GetAttrValue("weekindex_m", 1);
+ if(!weekindex_m.IsInRange(1,4) && weekindex_m != -1) { weekindex_m = 1; }
+ if (weekindex_m > 0) { CbbWeekIndexByMonth.SelectedIndex = weekindex_m - 1; }
+ else { CbbWeekIndexByMonth.SelectedIndex = CbbWeekIndexByMonth.Items.Count - 1; }
+ ChkWeekTypeByMonth.Checked= tStor.GetAttrValue("weektype_m",false);
}
}
if (RbYear.Checked)
@@ -386,7 +434,18 @@ namespace TimeClock.DbOp
else if (RbDay.Checked) { modtype = TipType.tip_day; runtime_str = (interval == 1 ? "每" : "每过" + interval) + "天 " + Dt_StartTime.Value.ToString("HH:mm"); }
else if (RbTheTime.Checked) { modtype = TipType.tip_thetime; runtime_str = DtDay.Value.ToString("yyyy年MM月dd日") + " " + DtTime.Value.ToString("HH:mm"); }
else if (RbWeek.Checked) { modtype = TipType.tip_week; runtime_str = (interval == 1 ? "每" : "每过" + interval) + "周 " + week_title + " " + Dt_StartTime.Value.ToString("HH:mm"); }
- else if (RbMonth.Checked){ modtype = TipType.tip_month; runtime_str = (interval == 1 ? "每" : "每过" + interval) + "个月 " + (ChkRevDay.Checked ? "倒数" : "") + CbbDay.Text + " " + Dt_StartTime.Value.ToString("HH:mm"); }
+ else if (RbMonth.Checked)
+ {
+ modtype = TipType.tip_month;
+ if (RbDayByMonth.Checked)
+ {
+ runtime_str = (interval == 1 ? "每" : "每过" + interval + "个") + "月 " + (ChkRevDay.Checked ? "倒数" : "") + CbbDay.Text + " " + Dt_StartTime.Value.ToString("HH:mm");
+ }
+ else if (RbWeekByMonth.Checked)
+ {
+ runtime_str = (interval == 1 ? "每" : "每过" + interval+"个") + "月 " + CbbWeekIndexByMonth.Text +(ChkWeekTypeByMonth.Checked?"的 ":"")+ CbbWeekByMonth.Text + " " + Dt_StartTime.Value.ToString("HH:mm");
+ }
+ }
else if (RbYear.Checked)
{
modtype = TipType.tip_year;
@@ -410,14 +469,14 @@ namespace TimeClock.DbOp
}
private void BtnOK_Click(object sender, EventArgs e)
{
- if (txtName.Text == "")
+ if (txtName.Text.Length==0)
{
MessageBox.Show("提醒标题不能为空。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
return;
}
if(PnlFile.Visible)
{
- if(CbbFile.Text=="")
+ if(CbbFile.Text.Length==0)
{
MessageBox.Show("必须选择文件或输入网址。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
return;
@@ -445,7 +504,23 @@ namespace TimeClock.DbOp
}
int interval = NumInterval.Value.ToInt();
string runtime_str = GetRunTimeStr(out string week, out int modtype);
- if (runtime_str == "") { return; }
+ if (runtime_str.Length==0) { return; }
+ var pic_path = CbbShowPic.Text;
+ if(pic_path.Length>0 && pic_path.IndexOfEx("<")!=0)
+ {
+ if(System.IO.File.Exists(pic_path))
+ {
+ var toPath= RyFiles.AddFileToFolder(pic_path, Itrycn_Info.UserDbFolder+"\\Images",false,out bool OK);
+ if(OK)
+ {
+ pic_path = toPath.Replace(Itrycn_Info.UserDbFolder + "\\Images","").Replace(Application.StartupPath, "");
+ }
+ }
+ }
+ if (ImgPath.Length > 0 && ImgPath.IndexOfEx("") == 0 && ImgPath != pic_path)
+ {
+ RyFiles.DeleteFile(ImgPath.Replace("", Itrycn_Info.UserDbFolder + "\\Images").Replace("", Application.StartupPath));
+ }
RyQuickSQL mySQL = new RyQuickSQL(tableName);
mySQL.AddField("MsgTitle", txtName.Text);
mySQL.AddField("MsgText", TxtContent.Text);
@@ -483,6 +558,26 @@ namespace TimeClock.DbOp
mySQL.AddField("ExceptXML", myExcept_XML.XMLText);
}
#endregion
+ #region 自定义显示
+ if (table_show.TableModel.Rows.Count == 0) { mySQL.AddField("CustomShow", ""); }
+ else
+ {
+ ryCommon.Storage myCustomShow_XML = new Storage();
+ myCustomShow_XML.SelectNodeBySet();
+ myCustomShow_XML.SetAttrValue("Count", table_show.TableModel.Rows.Count);
+ for (int m = 0; m < table_show.TableModel.Rows.Count; m++)
+ {
+ CustomShowInfo info = (CustomShowInfo)table_show.TableModel.Rows[m].Tag;
+ myCustomShow_XML.SetAttrValue("CsType" + (m + 1).ToString(), info.Type);
+ myCustomShow_XML.SetAttrValue("CsName" + (m + 1).ToString(), info.Name);
+ myCustomShow_XML.SetAttrValue("CsIsLunar" + (m + 1).ToString(), info.IsLunar);
+ myCustomShow_XML.SetAttrValue("CsYear" + (m + 1).ToString(), info.Year);
+ myCustomShow_XML.SetAttrValue("CsMonth" + (m + 1).ToString(), info.Month);
+ myCustomShow_XML.SetAttrValue("CsDay" + (m + 1).ToString(), info.Day);
+ }
+ mySQL.AddField("CustomShow", myCustomShow_XML.XMLText);
+ }
+ #endregion
#region 动作XML
ActionInfo item = (ActionInfo)CbbAction.SelectedItem;
ryCommon.Storage tStor = new Storage();
@@ -492,9 +587,9 @@ namespace TimeClock.DbOp
tStor.SetAttrValue("Pram", CbbPram.Text);
tStor.SetAttrValue("week", week);
tStor.SetAttrValue("sound_on", ChkSound.Checked);
- tStor.SetAttrValue("sound",CbbSound.Text);
+ tStor.SetAttrValue("sound", CbbSound.Text);
tStor.SetAttrValue("showpic_on", ChkShowPic.Checked);
- tStor.SetAttrValue("showpic", CbbShowPic.Text);
+ tStor.SetAttrValue("showpic", pic_path);
tStor.SetAttrValue("NoShowTip", ChkNoShowTip.Checked);
if (RbYear.Checked)
{
@@ -505,8 +600,26 @@ namespace TimeClock.DbOp
}
else
{
- tStor.SetAttrValue("revday", ChkRevDay.Checked);
- tStor.SetAttrValue("day", CbbDay.SelectedIndex);
+ if (RbDayByMonth.Checked)
+ {
+ tStor.SetAttrValue("month_mode", 0);
+ tStor.SetAttrValue("revday", ChkRevDay.Checked);
+ tStor.SetAttrValue("day", CbbDay.SelectedIndex);
+ }
+ else if (RbWeekByMonth.Checked)
+ {
+ tStor.SetAttrValue("month_mode", 1);
+ if (CbbWeekIndexByMonth.SelectedIndex <= 3)
+ {
+ tStor.SetAttrValue("weekindex_m", CbbWeekIndexByMonth.SelectedIndex+1);
+ }
+ else
+ {
+ tStor.SetAttrValue("weekindex_m", -1);
+ }
+ tStor.SetAttrValue("week_m", CbbWeekByMonth.SelectedIndex+1);
+ tStor.SetAttrValue("weektype_m",ChkWeekTypeByMonth.Checked);
+ }
}
#endregion
mySQL.AddField("SetXML", tStor.XMLText);
@@ -714,7 +827,11 @@ namespace TimeClock.DbOp
{
CbbDay.Items.Add((i+1).ToString()+"日");
}
- CbbDay.SelectedIndex = 0;
+ if (DateTime.Now.Day <= 28)
+ {
+ CbbDay.SelectedIndex = DateTime.Now.Day - 1;
+ }
+ else { CbbDay.SelectedIndex =0; }
}
}
@@ -795,20 +912,27 @@ namespace TimeClock.DbOp
private void BtnSelectSound_Click(object sender, EventArgs e)
{
openFileDialog2.Filter = "音频文件(*.mp3;*.wav)|*.mp3;*.wav";
- openFileDialog2.InitialDirectory =System.IO.Path.GetDirectoryName(RyFiles.GetRealPath(CbbSound.Text));
+ if (CbbSound.Text.Length > 0)
+ {
+ openFileDialog2.InitialDirectory = System.IO.Path.GetDirectoryName(Itrycn_Info.GetRealPath(CbbSound.Text));
+ }
if (openFileDialog2.ShowDialog() == DialogResult.OK)
{
- CbbSound.Text =RyFiles.GetRelativePath(openFileDialog2.FileName);
+ CbbSound.Text = Itrycn_Info.GetRelativePath(openFileDialog2.FileName);
}
}
private void BtnSelectPic_Click(object sender, EventArgs e)
{
openFileDialog2.Filter = "图片文件(*.gif;*.jpg;*.png;*.bmp)|*.gif;*.jpg;*.png;*.bmp";
- openFileDialog2.FileName = System.IO.Path.GetDirectoryName(RyFiles.GetRealPath(CbbShowPic.Text));
+ var pic_path =Itrycn_Info.GetRealPath(CbbShowPic.Text);
+ if (pic_path.Length > 0)
+ {
+ openFileDialog2.FileName = System.IO.Path.GetDirectoryName(pic_path);
+ }
if (openFileDialog2.ShowDialog() == DialogResult.OK)
{
- CbbShowPic.Text = RyFiles.GetRelativePath(openFileDialog2.FileName);
+ CbbShowPic.Text = Itrycn_Info.GetRelativePath(openFileDialog2.FileName);
}
}
@@ -841,31 +965,60 @@ namespace TimeClock.DbOp
LblInterval.Text = "年";
PnlStartTime.Visible = true;
Dt_StartTime.Value = DtTime.Value;
- if (CbbDay.Items.Count == 0)
- {
- for (int i = 0; i < 28; i++)
- {
- CbbDay.Items.Add("第" + (i + 1).ToString() + "天");
- }
- CbbDay.SelectedIndex = 0;
- }
+
+ //if (CbbDay.Items.Count == 0)
+ //{
+ // for (int i = 0; i < 28; i++)
+ // {
+ // CbbDay.Items.Add("第" + (i + 1).ToString() + "天");
+ // }
+ // CbbDay.SelectedIndex = 0;
+ //}
}
private void CheckBox1_CheckedChanged(object sender, EventArgs e)
{
}
-
+ ///
+ /// 上一次选择的是阳历还是农历,0表示阳历,1表示农历
+ ///
+ int last_lunar_y_value = -1;
private void CbbLunar_SelectedIndexChanged(object sender, EventArgs e)
{
- if(CbbLunar.SelectedIndex==0) //阳历
+ #region 获取当前选择的时间
+ var getdate = DateTime.Now;
+ try
+ {
+ if (last_lunar_y_value == 0)
+ {
+ if (!ChkRevDay_y.Checked)
+ getdate = new DateTime(Dt_StartDate.Value.Year, CbbMonth_y.SelectedIndex + 1, CbbDay_y.SelectedIndex + 1);
+ }
+ else if (last_lunar_y_value == 1)
+ {
+ if (!ChkRevDay_y.Checked)
+ {
+ if (ChinaDate.GetDayFromLunar(Dt_StartDate.Value.Year, CbbMonth_y.SelectedIndex + 1, CbbDay_y.SelectedIndex + 1, false, out int AYear, out int AMonth, out int ADay))
+ {
+ getdate = new DateTime(AYear, AMonth, ADay);
+ }
+ }
+ }
+ }
+ catch
+ {
+ }
+ #endregion
+ last_lunar_y_value = CbbLunar.SelectedIndex;
+ if (CbbLunar.SelectedIndex==0) //阳历
{
CbbMonth_y.Items.Clear();
for (int i = 0; i < 12; i++)
{
CbbMonth_y.Items.Add((i + 1).ToString() + "月");
}
- CbbMonth_y.SelectedIndex = 0;
+ CbbMonth_y.SelectedIndex = getdate.Month - 1;
}
else
{
@@ -876,7 +1029,8 @@ namespace TimeClock.DbOp
CbbMonth_y.Items.Add(stext[i].ToString() + "月");
}
CbbMonth_y.Items.Add("十一月"); CbbMonth_y.Items.Add("十二月");
- CbbMonth_y.SelectedIndex = 0;
+ ChinaDate.GetLunarFromDay(getdate.Year, getdate.Month, getdate.Day, out int LunarYear, out int LunarMonth, out int LunarDay, out bool IsLeapMonth);
+ CbbMonth_y.SelectedIndex = LunarMonth-1;
}
if (ChkRevDay_y.Checked)
{
@@ -897,6 +1051,7 @@ namespace TimeClock.DbOp
{
CbbDay_y.Items.Add((i + 1).ToString()+"日");
}
+ CbbDay_y.SelectedIndex= getdate.Day-1;
}
else
{
@@ -904,8 +1059,9 @@ namespace TimeClock.DbOp
{
CbbDay_y.Items.Add(ChinaDate.GetDay(i + 1));
}
+ ChinaDate.GetLunarFromDay(getdate.Year, getdate.Month, getdate.Day, out int LunarYear, out int LunarMonth, out int LunarDay, out bool IsLeapMonth);
+ CbbDay_y.SelectedIndex = LunarDay-1;
}
- CbbDay_y.SelectedIndex = 0;
}
}
@@ -1048,6 +1204,87 @@ namespace TimeClock.DbOp
DtTime.Value = dt;
}
}
+ private void AddCustomShow(int type)
+ {
+ if(table_show.TableModel.Rows.Count>=5)
+ {
+ MessageBox.Show("无法再添加,已经到达最大值。", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+ return;
+ }
+ CustomShow.FrmAddBirthDay frm = new CustomShow.FrmAddBirthDay();
+ frm.Icon = Icon;
+ if (type == 0) { frm.Text = "添加出生日期"; }
+ else if (type == 1) { frm.Text = "添加纪念日"; }
+ else if (type == 2) { frm.Text = "添加倒计时"; }
+ frm.CbbType.SelectedIndex = type;
+ frm.mr = new ModalForm(this, frm);
+ frm.mr.OnDialogResult += new ModalForm.DialogResultHandler((object t, DialogResult dg) => {
+ if (dg == DialogResult.OK)
+ {
+ CustomShowInfo dt_info = new CustomShowInfo()
+ {
+ Type = type,
+ Name = frm.txtName.Text,
+ IsLunar = frm.CbbLunar.SelectedIndex == 1,
+ Year = frm.Dt_Year.Value.Year,
+ Month = frm.CbbMonth_y.SelectedIndex + 1,
+ Day = frm.CbbDay_y.SelectedIndex + 1
+ };
+ XPTable.Models.Row itemList = new XPTable.Models.Row()
+ {
+ Tag = dt_info
+ };
+ //需要修改此处
+ itemList.Cells.Add(new XPTable.Models.Cell(dt_info.TypeStr));//示例
+ itemList.Cells.Add(new XPTable.Models.Cell(dt_info.Name));
+ itemList.Cells.Add(new XPTable.Models.Cell(dt_info.DateStr));//示例
+ table_show.TableModel.Rows.Add(itemList);
+ tabPage4.Text = "自定义显示(" + table_show.TableModel.Rows.Count + ")";
+ }
+ });
+ frm.mr.ShowModal();
+ }
+ private void 添加出生日期ToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ AddCustomShow(0);
+ }
+
+ private void 添加纪念日ToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ AddCustomShow(1);
+ }
+
+ private void 添加倒计时ToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ AddCustomShow(2);
+ }
+
+ private void 删除自定义显示ToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ if (table_show.SelectedItems.Length == 0) { return; }
+ table_show.TableModel.Rows.RemoveAt(table_show.SelectedItems[0].Index);
+ }
+
+ private void RbDayByMonth_CheckedChanged(object sender, EventArgs e)
+ {
+ ChkRevDay.Enabled = RbDayByMonth.Checked;
+ CbbDay.Enabled = RbDayByMonth.Checked;
+ CbbWeekByMonth.Enabled = !RbDayByMonth.Checked;
+ CbbWeekIndexByMonth.Enabled = !RbDayByMonth.Checked;
+ ChkWeekTypeByMonth.Enabled = !RbDayByMonth.Checked;
+ }
+
+ private void ChkWeekTypeByMonth_CheckedChanged(object sender, EventArgs e)
+ {
+ for (int i = 0; i < CbbWeekIndexByMonth.Items.Count; i++)
+ {
+ if (ChkWeekTypeByMonth.Checked)
+ {
+ CbbWeekIndexByMonth.Items[i] = CbbWeekIndexByMonth.Items[i].ToString().Replace("星期", "") + "星期";
+ }
+ else { CbbWeekIndexByMonth.Items[i] = CbbWeekIndexByMonth.Items[i].ToString().Replace("星期", ""); }
+ }
+ }
}
public class ActionInfo
{
@@ -1102,4 +1339,76 @@ namespace TimeClock.DbOp
return Title;
}
}
+ public class CustomShowInfo
+ {
+ ///
+ /// 类型
+ ///
+ public int Type;
+ ///
+ /// 类型
+ ///
+ public string TypeStr
+ {
+ get
+ {
+ var str = "";
+ switch(Type)
+ {
+ case 0:
+ str = "出生日期";
+ break;
+ case 1:
+ str = "纪念日";
+ break;
+ case 2:
+ str = "倒计时";
+ break;
+ default:
+ str = "未知";
+ break;
+ }
+ return str;
+ }
+ }
+ ///
+ /// 名称
+ ///
+ public string Name = "";
+ ///
+ /// 是否是农历
+ ///
+ public bool IsLunar =false;
+ ///
+ /// 年份
+ ///
+ public int Year = 2019;
+ ///
+ /// 月份
+ ///
+ public int Month = 1;
+ ///
+ /// 日
+ ///
+ public int Day = 1;
+ ///
+ /// 日期描述
+ ///
+ public string DateStr
+ {
+ get
+ {
+ var date_str = "";
+ if (IsLunar)
+ {
+ date_str = "农历" + Year + "年" + ChinaDate.GetMonth(Month) + ChinaDate.GetDay(Day);
+ }
+ else
+ {
+ date_str = "阳历" + Year + "年" + Month + "月" + Day + "日";
+ }
+ return date_str;
+ }
+ }
+ }
}
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.resx b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.resx
index 2a43d39..7c9281f 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.resx
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeAdd.resx
@@ -129,6 +129,15 @@
909, 19
+
+ 22, 49
+
+
+ 192, 49
+
+
+ 1036, 19
+
17, 17
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.Designer.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.Designer.cs
index ab0010f..deee463 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.Designer.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.Designer.cs
@@ -30,7 +30,7 @@
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FrmTimeView));
- System.Windows.Forms.TreeNode treeNode1 = new System.Windows.Forms.TreeNode("所有提醒");
+ System.Windows.Forms.TreeNode treeNode2 = new System.Windows.Forms.TreeNode("所有提醒");
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components);
this.快速提醒ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripSeparator();
@@ -920,11 +920,11 @@
this.ctlTreeView1.ItemHeight = 18;
this.ctlTreeView1.Location = new System.Drawing.Point(0, 0);
this.ctlTreeView1.Name = "ctlTreeView1";
- treeNode1.ImageIndex = 0;
- treeNode1.Name = "节点0";
- treeNode1.Text = "所有提醒";
+ treeNode2.ImageIndex = 0;
+ treeNode2.Name = "节点0";
+ treeNode2.Text = "所有提醒";
this.ctlTreeView1.Nodes.AddRange(new System.Windows.Forms.TreeNode[] {
- treeNode1});
+ treeNode2});
this.ctlTreeView1.SelectedImageIndex = 0;
this.ctlTreeView1.Size = new System.Drawing.Size(224, 521);
this.ctlTreeView1.T_FirstShowText = "所有提醒";
@@ -1097,6 +1097,9 @@
//
// table_todo
//
+ this.table_todo.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+ | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
this.table_todo.ColumnModel = this.columnModel_todo;
this.table_todo.ContextMenuStrip = this.contextMenuStrip_todo;
this.table_todo.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
@@ -1241,6 +1244,9 @@
//
// table_sticky
//
+ this.table_sticky.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+ | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
this.table_sticky.ColumnModel = this.columnModel_sticky;
this.table_sticky.ContextMenuStrip = this.MenuSticky;
this.table_sticky.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.cs b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.cs
index f13fda0..16cb1f7 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.cs
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.cs
@@ -480,6 +480,18 @@ namespace TimeClock.DbOp
for (int i = table1.SelectedItems.Length - 1; i >= 0; i--)
{
string selectId = ((TipInfo)table1.SelectedItems[i].Tag).Id.ToString();
+ var ds = db.ReadData("select * from " + tableName + " where id=" + selectId);
+ if(mydb.HaveData(ds))
+ {
+ var row = mydb.GetData(ds);
+ ryCommon.Storage tStor = new Storage(row["SetXML"].ToString());
+ tStor.SelectNodeBySet();
+ var ImgPath = tStor.GetAttrValue("showpic", "");
+ if (ImgPath.Length > 0 && ImgPath.IndexOfEx("") == 0)
+ {
+ RyFiles.DeleteFile(ImgPath.Replace(Itrycn_Info.UserDbFolder + "\\Images", "").Replace(Application.StartupPath, ""));
+ }
+ }
db.DelById(tableName, selectId);
table1.TableModel.Rows.RemoveAt(table1.SelectedItems[i].Index);
}
@@ -620,10 +632,7 @@ namespace TimeClock.DbOp
private void BtnQuickAdd_Click(object sender, EventArgs e)
{
- FrmQuickAdd frm = new FrmQuickAdd
- {
- Icon = Icon
- };
+ FrmQuickAdd frm = new FrmQuickAdd();
frm.mr = new ModalForm(this, frm);
frm.mr.OnDialogResult += new ModalForm.DialogResultHandler((object t, DialogResult dg) => {
if (dg == DialogResult.OK)
diff --git a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.resx b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.resx
index 73bf236..854b1f6 100644
--- a/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.resx
+++ b/Source/MyTimeClock/TimeClock/DbOp/FrmTimeView.resx
@@ -129,6 +129,15 @@
814, 21
+
+ 635, 52
+
+
+ 803, 52
+
+
+ 482, 52
+
164, 59
@@ -243,15 +252,6 @@
429, 21
-
- 635, 52
-
-
- 803, 52
-
-
- 482, 52
-
994, 52
diff --git a/Source/MyTimeClock/TimeClock/Itrycn_Info.cs b/Source/MyTimeClock/TimeClock/Itrycn_Info.cs
index b9edf5f..85928cc 100644
--- a/Source/MyTimeClock/TimeClock/Itrycn_Info.cs
+++ b/Source/MyTimeClock/TimeClock/Itrycn_Info.cs
@@ -208,7 +208,7 @@ namespace TimeClock
/// 播放音乐
///
///
- public static void PlaySound(string path)
+ public static void PlaySound(string path)
{
List list = new List
{
@@ -359,11 +359,22 @@ namespace TimeClock
db.Free();
#endregion
}
+ public static string GetRealPath(string path)
+ {
+ return RyFiles.GetRealPath(path).Replace("
", Itrycn_Info.UserDbFolder + "\\Images").Replace("", Itrycn_Info.UserDbFolder + "\\Sound");
+ }
+ public static string GetRelativePath(string path)
+ {
+ return RyFiles.GetRelativePath(path).Replace(Itrycn_Info.UserDbFolder + "\\Images","
").Replace(Itrycn_Info.UserDbFolder + "\\Sound", "");
+ }
///
/// 系统数据文件夹
///
public static string SysDbFolder { get; set; } = Application.StartupPath+"\\SysDb";
-
+ ///
+ /// 用户数据文件夹
+ ///
+ public static string UserDbFolder { get; set; } = Application.StartupPath + "\\UserDb";
///
/// 播放音乐列表
///
@@ -591,6 +602,66 @@ namespace TimeClock
{
return GetNextTipTime(reader,DateTime.Now);
}
+ ///
+ /// 获取该月的第几个星期几
+ ///
+ /// 该月第一天日期
+ /// 为false表示第几个周几,为true表示第几个星期的周几
+ /// 第几个周几或第几个星期的周几,范围为1-4或-1
+ /// 周几,范围为1-7,表示周一到周日
+ /// 表示是否返回成功,成功则返回true,否则为false
+ /// 返回具体日期
+ private static DateTime GetWeekIndexTime(DateTime month_start,bool weektype, int weekindex,int week,out bool OK)
+ {
+ OK = false;
+ DateTime dt;
+ var month_start_week = RyDate.GetWeek_index(month_start);
+ if (!weektype)
+ {
+ #region 方式1,第几个星期几
+ if (weekindex > 0)
+ {
+ if (month_start_week <= week)
+ {
+ dt = month_start.AddDays((weekindex - 1) * 7 + week - month_start_week);
+ }
+ else { dt = month_start.AddDays(weekindex * 7 + week - month_start_week); }
+ }
+ else //最后一个星期几
+ {
+ var month_end = month_start.AddMonths(1).AddDays(-1);
+ var month_end_week = RyDate.GetWeek_index(month_end);
+ if (month_end_week >= week)
+ {
+ dt = month_end.AddDays(week - month_end_week);
+ }
+ else
+ {
+ dt = month_end.AddDays(week - month_end_week - 7);
+ }
+ }
+ //如果算出的结果在同一个月,则表示计算正确
+ if (RyDate.InSameMonth(dt, month_start)) { OK = true; }
+ #endregion
+ }
+ else
+ {
+ #region 方式2,第几个星期的周几
+ if (weekindex > 0)
+ {
+ var month_start_weekstart = RyDate.GetWeekInfo(month_start).startDate;
+ dt = month_start_weekstart.AddDays(week - 1 + (weekindex - 1) * 7);
+ }
+ else
+ {
+ var month_end = RyDate.GetWeekInfo(month_start.AddMonths(1).AddDays(-1)).startDate;
+ dt = month_end.AddDays(week - 1);
+ }
+ OK = true;
+ #endregion
+ }
+ return dt.Date.AddHours(month_start.Hour).AddMinutes(month_start.Minute) ;
+ }
public static DateTime GetNextTipTime(DataRow reader,DateTime dt_Now)
{
DateTime StartTime = reader["StartTime"].ToDateTime();
@@ -686,34 +757,70 @@ namespace TimeClock
#region 每隔月
ryCommon.Storage tStor2 = new Storage(reader["SetXML"].ToString());
tStor2.SelectNodeBySet();
- int day = tStor2.GetAttrValue("day", 0);
- bool revday = tStor2.GetAttrValue("revday", false);//是否倒数
+ var month_mode = tStor2.GetAttrValue("month_mode", 0);
value = ryCommon.RyDate.GetMonthCount(StartTime, dt_Now);
if (value < 0) { value = 0; }
dt = RyDate.GetMonthStart(StartTime).AddMonths(value - (value % interval)).AddHours(StartTime.Hour).AddMinutes(StartTime.Minute);
- if (revday)
- { dt = dt.AddMonths(1).AddDays(-day - 1); }
- else
- {
- dt = dt.AddDays(day);
- }
- if (dt <= dt_Now)
+ if (month_mode == 0) //按日
{
+ #region 每月几号的提醒
+ int day = tStor2.GetAttrValue("day", 0);
+ bool revday = tStor2.GetAttrValue("revday", false);//是否倒数
if (revday)
+ { dt = dt.AddMonths(1).AddDays(-day - 1); }
+ else
{
- dt = RyDate.GetMonthStart(dt).AddMonths(interval).AddHours(StartTime.Hour).AddMinutes(StartTime.Minute);
- return dt.AddMonths(1).AddDays(-day - 1);
+ dt = dt.AddDays(day);
+ }
+ if (dt <= dt_Now)
+ {
+ if (revday)
+ {
+ dt = RyDate.GetMonthStart(dt).AddMonths(interval).AddHours(StartTime.Hour).AddMinutes(StartTime.Minute);
+ return dt.AddMonths(1).AddDays(-day - 1);
+ }
+ else
+ {
+ return dt.AddMonths(interval);
+ }
}
else
{
- return dt.AddMonths(interval);
- }
+ if (dt < StartTime)
+ {
+ return dt.AddMonths(interval);
+ }
+ return dt;
+ }
+ #endregion
}
- else
+ else //按周
{
- if (dt < StartTime)
+ var week_m = tStor2.GetAttrValue("week_m", 1); //表示星期,值为1-7,表示周一到周日
+ if (!week_m.IsInRange(1, 7)) { week_m = 1; }
+ var weekindex_m = tStor2.GetAttrValue("weekindex_m", 1);//第几个星期,值为1-4或-1,表示第1-4个星期,或最后一个星期
+ if (!weekindex_m.IsInRange(1, 4) && weekindex_m != -1) { weekindex_m = 1; }
+ var weektype_m = tStor2.GetAttrValue("weektype_m", false);
+ var month_start = RyDate.GetMonthStart(dt).AddHours(StartTime.Hour).AddMinutes(StartTime.Minute);
+ dt= GetWeekIndexTime(month_start, weektype_m, weekindex_m, week_m,out bool OK);
+ if(OK)
{
- return dt.AddMonths(interval);
+ if (dt <= dt_Now)
+ {
+ dt= GetWeekIndexTime(month_start.AddMonths(interval), weektype_m, weekindex_m, week_m, out _);
+ }
+ else
+ {
+ if (dt < StartTime)
+ {
+ dt= GetWeekIndexTime(month_start.AddMonths(interval), weektype_m, weekindex_m, week_m, out _);
+ }
+ return dt;
+ }
+ }
+ else
+ {
+ dt = GetWeekIndexTime(month_start.AddMonths(interval), weektype_m, weekindex_m, week_m, out OK);
}
return dt;
}
@@ -879,7 +986,7 @@ namespace TimeClock
return reader["RunTime"].ToDateTime();
case TipType.tip_winstart:
DateTime dt_3= Itrycn_Info.soft_startTime.AddMinutes(interval);
- dt_3 = dt_3.Date.AddHours(dt_3.Hour).AddMinutes(dt_3.Minute);
+ dt_3 = dt_3.Date.AddHours(dt_3.Hour).AddMinutes(dt_3.Minute+1);
return dt_3;
default:
return StartTime;
@@ -1014,6 +1121,7 @@ namespace TimeClock
mySQL.AddField("TipClose", 0);//该提醒是否已经结束,结束的提醒将不会提醒
mySQL.AddField("StartTime", DateTime.Now);
mySQL.AddField("ExceptXML", "");//例外
+ mySQL.AddField("CustomShow", "");//自定义显示
mySQL.AddField("SetXML", "");
mySQL.AddField("addTime", DateTime.Now);
db.CreateDb(mySQL);
@@ -1116,6 +1224,7 @@ namespace TimeClock
mySQL.AddField("Holiday_Time","");//节日时间
mySQL.AddField("Des","");//节日描述
mySQL.AddField("Sorts", 0);//数值越高,排名越靠前
+ mySQL.AddField("NoShowRL", 0);//是否不显示在日历选项中
mySQL.AddField("addTime", DateTime.Now);
db.CreateDb(mySQL);
#endregion
diff --git a/Source/MyTimeClock/TimeClock/Properties/AssemblyInfo.cs b/Source/MyTimeClock/TimeClock/Properties/AssemblyInfo.cs
index 626d122..b162fb8 100644
--- a/Source/MyTimeClock/TimeClock/Properties/AssemblyInfo.cs
+++ b/Source/MyTimeClock/TimeClock/Properties/AssemblyInfo.cs
@@ -10,7 +10,7 @@ using System.Runtime.InteropServices;
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("TimeClock")]
-[assembly: AssemblyCopyright("Copyright © 2017")]
+[assembly: AssemblyCopyright("Copyright © 2019")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
// 方法是按如下所示使用“*”: :
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("1.0.1909.1501")]
-[assembly: AssemblyFileVersion("1.0.1909.1501")]
\ No newline at end of file
+[assembly: AssemblyVersion("1.0.2009.2401")]
+[assembly: AssemblyFileVersion("1.0.2009.2401")]
\ No newline at end of file
diff --git a/Source/MyTimeClock/TimeClock/RyTimeClock.cs b/Source/MyTimeClock/TimeClock/RyTimeClock.cs
index aafcc00..1ddd6aa 100644
--- a/Source/MyTimeClock/TimeClock/RyTimeClock.cs
+++ b/Source/MyTimeClock/TimeClock/RyTimeClock.cs
@@ -86,6 +86,21 @@ namespace TimeClock
form.WindowState = FormWindowState.Normal;
}
///
+ /// 添加快速提醒。
+ ///
+ public void ShowQuickAddTip()
+ {
+ DbOp.FrmQuickAdd frm = new DbOp.FrmQuickAdd();
+ frm.mr = new ModalForm(null, frm);
+ frm.mr.OnDialogResult += new ModalForm.DialogResultHandler((object t, DialogResult dg) => {
+ if (dg == DialogResult.OK)
+ {
+ TipChanged();
+ }
+ });
+ frm.mr.ShowModal();
+ }
+ ///
/// 显示提醒管理窗口中的日历页
///
public void ShowCalendarManage()
@@ -263,7 +278,7 @@ namespace TimeClock
mySQL2.AddField("NextTipTime", dt);
mySQL2.AddField("EarlierTipTime", dt.AddMinutes(-reader["EarlierMinute"].ToInt()));
mySQL2.AddField("Clac_Time", DateTime.Now);
- if (reader["modtype"].ToInt() == 3)//指定时间
+ if (reader["modtype"].ToInt() == TipType.tip_thetime)//指定时间
{ mySQL2.AddField("TipClose", 1); }
db.ExecuteNonQuery(mySQL2.GetUpdateSQL() + " where id=" + reader["id"].ToString(), mySQL2);
}
@@ -301,7 +316,7 @@ namespace TimeClock
mySQL2.AddField("NextTipTime", dt);
mySQL2.AddField("EarlierTipTime", dt.AddMinutes(-reader["EarlierMinute"].ToInt()));
mySQL2.AddField("Clac_Time", DateTime.Now);
- if (reader["modtype"].ToInt() == 3)//指定时间
+ if (reader["modtype"].ToInt() == TipType.tip_thetime)//指定时间
{ mySQL2.AddField("TipClose", 1); }
db.ExecuteNonQuery(mySQL2.GetUpdateSQL() + " where id=" + reader["id"].ToString(), mySQL2);
}
@@ -501,6 +516,8 @@ namespace TimeClock
#region 提前一分钟提醒
if (Itrycn_Info.TipBeforeRest)
{
+ //System.IO.File.AppendAllText(Application.StartupPath + "\\Logs.txt",
+ // "\r\n" + DateTime.Now + "\t提前一分钟休息提醒");
bool is_form_show = false;
try
{
@@ -513,11 +530,15 @@ namespace TimeClock
}
}
}
- catch{}
+ catch{
+
+ }
if (!is_form_show)
{
+ //System.IO.File.AppendAllText(Application.StartupPath + "\\Logs.txt",
+ //"\r\n" + DateTime.Now + "\t提前一分钟休息弹窗提醒");
DbOp.FrmBeforeRestTip frm = new DbOp.FrmBeforeRestTip();
- RyForm.ShowNoActiveWindow(frm);
+ frm.Show();
frm.StartLoad();
}
}
@@ -590,14 +611,15 @@ namespace TimeClock
#region 遍历需要提醒的项目
ryCommon.Storage tStor = new Storage(reader["SetXML"].ToString());
tStor.SelectNodeBySet();
+ var NextTipTime = reader["NextTipTime"].ToDateTime();
string ActionId = tStor.GetAttrValue("ActionId");
string File = RyFiles.GetRealPath(tStor.GetAttrValue("File"));
string Pram = tStor.GetAttrValue("Pram");
bool sound_on = tStor.GetAttrValue("sound_on", true);
string sound_path = tStor.GetAttrValue("sound", @"\animation\sound\tip.wav");
- sound_path = RyFiles.GetRealPath(sound_path);
+ sound_path = Itrycn_Info.GetRealPath(sound_path);
bool gif_on = tStor.GetAttrValue("showpic_on", false);
- string gif_path = RyFiles.GetRealPath(tStor.GetAttrValue("showpic", ""));
+ string gif_path = Itrycn_Info.GetRealPath(tStor.GetAttrValue("showpic", ""));
string _run_file = "";
string _run_param = "";
#region 执行动作
@@ -680,6 +702,7 @@ namespace TimeClock
{
frm.gif_path = gif_path;
}
+ frm.AddCustomShow(reader["CustomShow"].ToString(), NextTipTime);
if (ti.isTemp == 1)
{
frm.Text = "【" + reader["RunTimeStr"].ToString() + "】推迟的提醒";
diff --git a/Source/MyTimeClock/TimeClock/TimeClock.csproj b/Source/MyTimeClock/TimeClock/TimeClock.csproj
index 355f0c1..b059f81 100644
--- a/Source/MyTimeClock/TimeClock/TimeClock.csproj
+++ b/Source/MyTimeClock/TimeClock/TimeClock.csproj
@@ -74,6 +74,24 @@
+
+ UserControl
+
+
+ DJSDayUI.cs
+
+
+ UserControl
+
+
+ BirthDayUI.cs
+
+
+ Form
+
+
+ FrmAddBirthDay.cs
+
Form
@@ -185,6 +203,15 @@
RyTimeClock.cs
+
+ DJSDayUI.cs
+
+
+ BirthDayUI.cs
+
+
+ FrmAddBirthDay.cs
+
FrmAddTodo.cs
@@ -286,6 +313,7 @@
- "e:\documentscenter\my documents\visual studio 2017\Projects\开发辅助工具\开发辅助工具\bin\Debug\开发辅助工具.exe" ver "$(ProjectDir)"
+
+
\ No newline at end of file
diff --git a/Source/README.md b/Source/README.md
deleted file mode 100644
index b7eb166..0000000
--- a/Source/README.md
+++ /dev/null
@@ -1,37 +0,0 @@
-# 睿元定时提醒专家
-
-#### 介绍
-睿元定时提醒专家是一款强大的定时提醒、待办管理、桌面便笺工具,可以设置按分钟、小时、天、周、月、年循环提醒,而且支持农历提醒,支持提醒免打扰。同时支持待办管理,管理待办事项。还有桌面便笺功能,可以创建任意数量的桌面便笺,支持便笺自动备份、图片插入、便笺颜色设置。
-
-#### 软件架构
-软件架构说明
-
-
-#### 安装教程
-
-1. xxxx
-2. xxxx
-3. xxxx
-
-#### 使用说明
-
-1. xxxx
-2. xxxx
-3. xxxx
-
-#### 参与贡献
-
-1. Fork 本仓库
-2. 新建 Feat_xxx 分支
-3. 提交代码
-4. 新建 Pull Request
-
-
-#### 码云特技
-
-1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md
-2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com)
-3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目
-4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目
-5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
-6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
\ No newline at end of file
diff --git a/更新日志.md b/更新日志.md
deleted file mode 100644
index c47ee04..0000000
--- a/更新日志.md
+++ /dev/null
@@ -1,19 +0,0 @@
-2019-09-10 更新
-------
-#### RyLine V2.0.1909.0901
-
-暂无
-
-#### TimeClock V1.0.1909.0907
-
-*.[新增]便笺新增支持插入图片
-
-*.[改进]改进便笺切换编辑状态的逻辑,在后台不会切换为编辑状态。
-
-#### MyTimeClock V2.0.1909.0907
-
-暂无
-
-#### RyLine V2.0.1909.0901
-
-暂无
\ No newline at end of file