-
Notifications
You must be signed in to change notification settings - Fork 26
/
config.php
835 lines (835 loc) · 17.8 KB
/
config.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
<?php
/**
* 时间格式:
* array(
* Time =>时间,
* Name =>中文名称,
* EnglishName =>英文名称,
* IsNotWork =>是否不工作(是否放假,有些节日不放假),
* Start =>放假开始时间(-1则提前一天放假),
* End =>放假结束时间(+1则延后一天放假)
* )
* 总放假天数:|Start|+|End|+1
*
* @author zhusaidong [[email protected]]
* @version 0.2.0.0
*/
const NotWork = 1;
const Work = 0;
//阳历
$GregorianCalendarHoliday = array(
array(
"Time" => "1月1日",
"Name" => "中国元旦",
"EnglishName" => "New Year's Day",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "2月2日",
"Name" => "世界湿地日",
"EnglishName" => "World Wetlands Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "2月14日",
"Name" => "情人节",
"EnglishName" => "Valentine's Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月3日",
"Name" => "全国爱耳日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月5日",
"Name" => "青年志愿者服务日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月8日",
"Name" => "国际妇女节",
"EnglishName" => "International Women' Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月9日",
"Name" => "保护母亲河日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月12日",
"Name" => "中国植树节",
"EnglishName" => "China Arbor Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月14日",
"Name" => "白色情人节",
"EnglishName" => "White Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月14日",
"Name" => "国际警察日",
"EnglishName" => "International Policemen' Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月15日",
"Name" => "世界消费者权益日",
"EnglishName" => "World Consumer Right Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月21日",
"Name" => "世界森林日",
"EnglishName" => "World Forest Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月21日",
"Name" => "世界睡眠日",
"EnglishName" => "World Sleep Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月22日",
"Name" => "世界水日",
"EnglishName" => "World Water Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月23日",
"Name" => "世界气象日",
"EnglishName" => "World Meteorological Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月24日",
"Name" => "世界防治结核病日",
"EnglishName" => "World Tuberculosis Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "4月1日",
"Name" => "愚人节",
"EnglishName" => "April Fools' Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "4月5日",
"Name" => "清明节",
"EnglishName" => "Tomb",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "4月7日",
"Name" => "世界卫生日",
"EnglishName" => "World Health Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "4月22日",
"Name" => "世界地球日",
"EnglishName" => "World Earth Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "4月26日",
"Name" => "世界知识产权日",
"EnglishName" => "World Intellectual Property Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月1日",
"Name" => "国际劳动节",
"EnglishName" => "International Labour Day",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月3日",
"Name" => "世界哮喘日",
"EnglishName" => "World Asthma Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月4日",
"Name" => "中国青年节",
"EnglishName" => "Chinese Youth Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月8日",
"Name" => "世界红十字日",
"EnglishName" => "World Red",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月12日",
"Name" => "国际护士节",
"EnglishName" => "International Nurse Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月15日",
"Name" => "国际家庭日",
"EnglishName" => "International Family Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月17日",
"Name" => "世界电信日",
"EnglishName" => "World Telecommunications Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月20日",
"Name" => "全国学生营养日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月23日",
"Name" => "国际牛奶日",
"EnglishName" => "International Milk Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月31日",
"Name" => "世界无烟日",
"EnglishName" => "World No",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月1日",
"Name" => "国际儿童节",
"EnglishName" => "International Children's Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月5日",
"Name" => "世界环境日",
"EnglishName" => "International Environment Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月6日",
"Name" => "全国爱眼日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月17日",
"Name" => "世界防治荒漠化和干旱日",
"EnglishName" => "World Day to combat desertification",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月23日",
"Name" => "国际奥林匹克日",
"EnglishName" => "International Olympic Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月25日",
"Name" => "全国土地日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月26日",
"Name" => "国际禁毒日",
"EnglishName" => "International Day Against Drug Abuse and Illicit Trafficking",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "7月1日",
"Name" => "建党节",
"EnglishName" => "Anniversary of the Founding of the Chinese Communist Party",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "7月1日",
"Name" => "国际建筑日",
"EnglishName" => "International Architecture Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "7月7日",
"Name" => "中国人民抗日战争纪念日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "7月11日",
"Name" => "世界人口日",
"EnglishName" => "World Population Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "8月1日",
"Name" => "建军节",
"EnglishName" => "Army Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "8月12日",
"Name" => "国际青年节",
"EnglishName" => "International Youth Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月8日",
"Name" => "国际扫盲日",
"EnglishName" => "International Anti",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月10日",
"Name" => "中国教师节",
"EnglishName" => "Teacher's Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月16日",
"Name" => "中国脑健康日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月16日",
"Name" => "国际臭氧层保护日",
"EnglishName" => "International Day for the Preservation of the Ozone Layer",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月20日",
"Name" => "全国爱牙日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月21日",
"Name" => "世界停火日",
"EnglishName" => "World Cease",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月27日",
"Name" => "世界旅游日",
"EnglishName" => "World Tourism Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月1日",
"Name" => "国庆节",
"EnglishName" => "National Day",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 6,
),
array(
"Time" => "10月1日",
"Name" => "国际音乐日",
"EnglishName" => "International Music Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月1日",
"Name" => "国际老年人日",
"EnglishName" => "International Day of Older Persons",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月4日",
"Name" => "世界动物日",
"EnglishName" => "World Animal Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月5日",
"Name" => "世界教师日",
"EnglishName" => "World Teachers' Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月8日",
"Name" => "全国高血压日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月9日",
"Name" => "世界邮政日",
"EnglishName" => "World Post Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月10日",
"Name" => "世界精神卫生日",
"EnglishName" => "World Mental Health Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月14日",
"Name" => "世界标准日",
"EnglishName" => "World Standards Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月15日",
"Name" => "国际盲人节",
"EnglishName" => "International Day of the Blind",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月15日",
"Name" => "世界农村妇女日",
"EnglishName" => "World Rural Women's Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月16日",
"Name" => "世界粮食日",
"EnglishName" => "World Food Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月17日",
"Name" => "国际消除贫困日",
"EnglishName" => "International Day for the Eradication of Poverty",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月24日",
"Name" => "联合国日",
"EnglishName" => "United Nations Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月24日",
"Name" => "世界发展新闻日",
"EnglishName" => "World Development Information Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月28日",
"Name" => "中国男性健康日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月29日",
"Name" => "国际生物多样性日",
"EnglishName" => "International Biodiversity Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月31日",
"Name" => "万圣节",
"EnglishName" => "Halloween",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "11月8日",
"Name" => "中国记者节",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "11月9日",
"Name" => "消防宣传日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "11月14日",
"Name" => "世界糖尿病日",
"EnglishName" => "World Diabetes Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "11月17日",
"Name" => "国际大学生节",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "11月25日",
"Name" => "国际消除对妇女的暴力日",
"EnglishName" => "International Day For the elimination of Violence against Women",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "12月1日",
"Name" => "世界爱滋病日",
"EnglishName" => "World AIDS Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "12月3日",
"Name" => "世界残疾人日",
"EnglishName" => "World Disabled Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "12月4日",
"Name" => "全国法制宣传日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "12月9日",
"Name" => "世界足球日",
"EnglishName" => "World Football Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "12月25日",
"Name" => "圣诞节",
"EnglishName" => "Christmas Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "12月29日",
"Name" => "国际生物多样性日",
"EnglishName" => "International Biological Diversity Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
);
//特殊阳历
$SpecialHoliday = array(
array(
"Time" => "1月最后一个星期日",
"Name" => "国际麻风节",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "3月最后一个完整周的星期一",
"Name" => "中小学生安全教育日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月第二个星期日",
"Name" => "母亲节",
"EnglishName" => "Mother's Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "5月第三个星期日",
"Name" => "全国助残日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "6月第三个星期日",
"Name" => "父亲节",
"EnglishName" => "Father's Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月第三个星期二",
"Name" => "国际和平日",
"EnglishName" => "International Peace Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月第三个星期六",
"Name" => "全国国防教育日",
"EnglishName" => "",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "9月第四个星期日",
"Name" => "国际聋人节",
"EnglishName" => "International Day of the Deaf",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月第一个星期一",
"Name" => "世界住房日",
"EnglishName" => "World Habitat Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月第二个星斯一",
"Name" => "加拿大感恩节",
"EnglishName" => "Thanksgiving Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月第二个星期三",
"Name" => "国际减轻自然灾害日",
"EnglishName" => "International Day for Natural Disaster Reduction",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "10月第二个星期四",
"Name" => "世界爱眼日",
"EnglishName" => "World Sight Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "11月最后一个星期四",
"Name" => "美国感恩节",
"EnglishName" => "Thanksgiving Day",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
);
//阴历
$LunarCalendarHoliday = array(
array(
"Time" => "正月初一",
"Name" => "春节",
"EnglishName" => "the Spring Festival",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 6,
),
array(
"Time" => "正月十五",
"Name" => "元宵节",
"EnglishName" => "Lantern Festival",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "五月初五",
"Name" => "端午节",
"EnglishName" => "the Dragon-Boat Festival",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "七月初七",
"Name" => "乞巧节",
"EnglishName" => "Double-Seventh Day",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "八月十五",
"Name" => "中秋节",
"EnglishName" => "the Mid-Autumn Festival",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "九月初九",
"Name" => "重阳节",
"EnglishName" => "the Double Ninth Festival",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "腊月初八",
"Name" => "腊八节",
"EnglishName" => "the laba Rice Porridge Festival",
"IsNotWork" => Work,
"Start" => 0,
"End" => 0,
),
array(
"Time" => "十二月三十",
"Name" => "除夕",
"EnglishName" => "New Year's Eve",
"IsNotWork" => NotWork,
"Start" => 0,
"End" => 0,
),
);