isite 2022.9.20 → 2022.9.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -0
- package/apps/client-side/app.js +2 -0
- package/apps/client-side/site_files/css/bootstrap5-addon.css +9 -1
- package/apps/client-side/site_files/css/checkbox.css +80 -76
- package/apps/client-side/site_files/css/form.css +2 -2
- package/apps/client-side/site_files/css/images.css +32 -15
- package/apps/client-side/site_files/css/modal.css +153 -155
- package/apps/client-side/site_files/css/scrollbar.css +4 -3
- package/apps/client-side/site_files/css/theme.css +4 -2
- package/apps/client-side/site_files/css/theme_paper.css +4 -2
- package/apps/client-side/site_files/css/treeview.css +17 -4
- package/apps/client-side/site_files/html/directive/i-button.html +1 -1
- package/apps/client-side/site_files/html/directive/i-treenode.html +3 -3
- package/apps/client-side/site_files/html/directive/i-treeview.html +6 -11
- package/apps/client-side/site_files/js/bootstrap-5-directive.js +6 -2
- package/apps/client-side/site_files/js/site.js +5 -3
- package/index.js +2 -0
- package/lib/helper.js +43 -0
- package/lib/session.js +5 -2
- package/object-options/index.js +238 -234
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -85,6 +85,7 @@ site = isite({
|
|
|
85
85
|
dir: process.cwd() + '/site_files',
|
|
86
86
|
upload_dir: process.cwd() + '/../uploads',
|
|
87
87
|
download_dir: process.cwd() + '/../downloads',
|
|
88
|
+
backup_dir: process.cwd() + '/../backup',
|
|
88
89
|
apps: !0,
|
|
89
90
|
apps_dir: process.cwd() + '/apps',
|
|
90
91
|
name: 'Your Site',
|
|
@@ -819,6 +820,24 @@ $employees.deleteDuplicate({'profile.name' : 1 } , (err , result)=>{
|
|
|
819
820
|
|
|
820
821
|
}
|
|
821
822
|
|
|
823
|
+
// backup database
|
|
824
|
+
site.backupDB() // backup current database to current backup folder
|
|
825
|
+
site.backupDB({db:'' , path : ''})
|
|
826
|
+
|
|
827
|
+
// restore database
|
|
828
|
+
site.restoreDB() // restore current database from current backup folder
|
|
829
|
+
site.restoreDB({db:'' , path : ''})
|
|
830
|
+
|
|
831
|
+
// API to download backup db
|
|
832
|
+
site.onGET('db', (req, res) => {
|
|
833
|
+
site.backupDB(null, (err, options) => {
|
|
834
|
+
if (!err) {
|
|
835
|
+
res.download(options.path);
|
|
836
|
+
} else {
|
|
837
|
+
res.json(err);
|
|
838
|
+
}
|
|
839
|
+
});
|
|
840
|
+
});
|
|
822
841
|
|
|
823
842
|
//==================================================================
|
|
824
843
|
// Global Database Events
|
package/apps/client-side/app.js
CHANGED
|
@@ -172,6 +172,7 @@ module.exports = function (site) {
|
|
|
172
172
|
__dirname + '/site_files/css/effect.css',
|
|
173
173
|
__dirname + '/site_files/css/scrollbar.css',
|
|
174
174
|
__dirname + '/site_files/css/table.css',
|
|
175
|
+
__dirname + '/site_files/css/treeview.css',
|
|
175
176
|
__dirname + '/site_files/css/tabs.css',
|
|
176
177
|
__dirname + '/site_files/css/help.css',
|
|
177
178
|
__dirname + '/site_files/css/print.css',
|
|
@@ -179,6 +180,7 @@ module.exports = function (site) {
|
|
|
179
180
|
__dirname + '/site_files/css/theme_paper.css',
|
|
180
181
|
__dirname + '/site_files/css/bootstrap5.css',
|
|
181
182
|
__dirname + '/site_files/css/bootstrap5-addon.css',
|
|
183
|
+
__dirname + '/site_files/css/font-awesome.css',
|
|
182
184
|
],
|
|
183
185
|
});
|
|
184
186
|
|
|
@@ -34,7 +34,7 @@ body {
|
|
|
34
34
|
margin-bottom: 100px;
|
|
35
35
|
}
|
|
36
36
|
.container {
|
|
37
|
-
max-width:
|
|
37
|
+
max-width: 100%;
|
|
38
38
|
}
|
|
39
39
|
.ar .form-check .form-check-input {
|
|
40
40
|
float: right;
|
|
@@ -52,6 +52,7 @@ fieldset {
|
|
|
52
52
|
background: var(--fieldset-background);
|
|
53
53
|
border: var(--fieldset-border);
|
|
54
54
|
border-radius: 10px;
|
|
55
|
+
max-width: 98% !important;
|
|
55
56
|
}
|
|
56
57
|
|
|
57
58
|
fieldset legend {
|
|
@@ -80,6 +81,9 @@ i-checkbox {
|
|
|
80
81
|
padding-left: 20px !important;
|
|
81
82
|
padding-right: 20px !important;
|
|
82
83
|
}
|
|
84
|
+
i-checkbox label{
|
|
85
|
+
cursor: pointer;
|
|
86
|
+
}
|
|
83
87
|
i-checkbox,
|
|
84
88
|
i-radio {
|
|
85
89
|
align-self: center;
|
|
@@ -128,6 +132,10 @@ i-datetime.is-invalid .row {
|
|
|
128
132
|
width: 75vw;
|
|
129
133
|
height: 100vh;
|
|
130
134
|
}
|
|
135
|
+
.full .modal-content {
|
|
136
|
+
width: 95vw;
|
|
137
|
+
height: 100vh;
|
|
138
|
+
}
|
|
131
139
|
.modal-body {
|
|
132
140
|
padding: 1rem;
|
|
133
141
|
display: block;
|
|
@@ -1,121 +1,125 @@
|
|
|
1
1
|
.check-list label.checkbox {
|
|
2
|
-
|
|
2
|
+
text-align: var(--text-align);
|
|
3
3
|
}
|
|
4
4
|
|
|
5
5
|
.check-list .control {
|
|
6
|
-
|
|
6
|
+
padding: 0px;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
9
|
.check-list .title {
|
|
10
|
-
|
|
10
|
+
font-size: 16px;
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
.checkbox {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
14
|
+
margin: 5px;
|
|
15
|
+
margin-right: 10px;
|
|
16
|
+
display: inline-block;
|
|
17
|
+
position: relative;
|
|
18
|
+
padding-right: 35px;
|
|
19
|
+
padding-left: 0px;
|
|
20
|
+
margin-bottom: 12px;
|
|
21
|
+
cursor: pointer;
|
|
22
|
+
direction: ltr;
|
|
23
|
+
-webkit-user-select: none;
|
|
24
|
+
-moz-user-select: none;
|
|
25
|
+
-ms-user-select: none;
|
|
26
|
+
user-select: none;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
.en .checkbox {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
direction: rtl;
|
|
31
|
+
padding-left: 35px;
|
|
32
|
+
padding-right: 0px;
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
.checkbox span.title {
|
|
36
|
-
|
|
36
|
+
vertical-align: sub;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
.checkbox input {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
40
|
+
position: absolute;
|
|
41
|
+
opacity: 0;
|
|
42
|
+
cursor: pointer;
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
.checkbox .checkmark {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
46
|
+
position: absolute;
|
|
47
|
+
top: 3px;
|
|
48
|
+
margin-left: 5px;
|
|
49
|
+
margin-right: 5px;
|
|
50
|
+
height: 20px;
|
|
51
|
+
width: 20px;
|
|
52
|
+
border: 2px solid var(--modal-header-background-color);
|
|
53
|
+
transition: color 0.1s ease;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
.checkbox .checkbox:hover input
|
|
57
|
-
|
|
56
|
+
.checkbox .checkbox:hover input ~ .checkmark {
|
|
57
|
+
border: 10px dashed var(--modal-header-background-color);
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
.checkbox input:checked
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
60
|
+
.checkbox input:checked ~ .checkmark {
|
|
61
|
+
background-color: var(--modal-header-background-color);
|
|
62
|
+
border: none;
|
|
63
|
+
border-radius: 5px;
|
|
65
64
|
}
|
|
66
65
|
|
|
67
66
|
.checkbox .checkmark:after {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
67
|
+
content: '';
|
|
68
|
+
position: absolute;
|
|
69
|
+
display: none;
|
|
71
70
|
}
|
|
72
71
|
|
|
73
|
-
.checkbox input:checked
|
|
74
|
-
|
|
72
|
+
.checkbox input:checked ~ .checkmark:after {
|
|
73
|
+
display: block;
|
|
75
74
|
}
|
|
76
75
|
|
|
77
76
|
.checkbox .checkmark:after {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
77
|
+
left: 7px;
|
|
78
|
+
top: 2px;
|
|
79
|
+
width: 5px;
|
|
80
|
+
height: 10px;
|
|
81
|
+
border: solid white;
|
|
82
|
+
border-width: 0 2px 2px 0;
|
|
83
|
+
-webkit-transform: rotate(45deg);
|
|
84
|
+
-ms-transform: rotate(45deg);
|
|
85
|
+
transform: rotate(45deg);
|
|
87
86
|
}
|
|
88
87
|
|
|
88
|
+
i-checkbox {
|
|
89
|
+
display: inline-block;
|
|
90
|
+
}
|
|
91
|
+
i-checkbox label {
|
|
92
|
+
cursor: pointer;
|
|
93
|
+
}
|
|
89
94
|
i-checkbox .selector {
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
95
|
+
user-select: none;
|
|
96
|
+
-webkit-user-select: none;
|
|
97
|
+
-moz-user-select: none;
|
|
98
|
+
cursor: pointer;
|
|
99
|
+
display: inline-block;
|
|
100
|
+
padding: 5px 9px;
|
|
101
|
+
margin: 5px;
|
|
102
|
+
min-width: 25px;
|
|
103
|
+
min-height: 25px;
|
|
104
|
+
border-radius: 0px;
|
|
105
|
+
border: none;
|
|
106
|
+
color: #fff;
|
|
107
|
+
background: red;
|
|
103
108
|
}
|
|
104
109
|
|
|
105
|
-
i-checkbox .selector.selected .fa{
|
|
106
|
-
|
|
110
|
+
i-checkbox .selector.selected .fa {
|
|
111
|
+
color: #ffffff;
|
|
107
112
|
}
|
|
108
|
-
i-checkbox .selector.un-selected .fa{
|
|
109
|
-
|
|
113
|
+
i-checkbox .selector.un-selected .fa {
|
|
114
|
+
color: #fff;
|
|
110
115
|
}
|
|
111
116
|
|
|
112
|
-
|
|
113
117
|
i-checkbox .selector.selected {
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
118
|
+
background: #ffffff;
|
|
119
|
+
color: #ffffff;
|
|
120
|
+
background: #118011;
|
|
117
121
|
}
|
|
118
122
|
i-checkbox .selector.un-selected {
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
}
|
|
123
|
+
background: #aaa;
|
|
124
|
+
color: #fff;
|
|
125
|
+
}
|
|
@@ -136,8 +136,8 @@ textarea:focus {
|
|
|
136
136
|
}
|
|
137
137
|
|
|
138
138
|
fieldset {
|
|
139
|
-
padding: var(--fieldset-padding);
|
|
140
|
-
margin: var(--fieldset-margin);
|
|
139
|
+
padding: var(--fieldset-padding) ;
|
|
140
|
+
margin: var(--fieldset-margin) ;
|
|
141
141
|
background: var(--fieldset-background);
|
|
142
142
|
border: var(--fieldset-border);
|
|
143
143
|
}
|
|
@@ -10,44 +10,61 @@
|
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
i-image {
|
|
13
|
+
display: inline-block;
|
|
13
14
|
width: auto !important;
|
|
14
15
|
height: auto !important;
|
|
15
|
-
|
|
16
|
+
border: var(--i-image-border);
|
|
16
17
|
}
|
|
17
18
|
i-image img {
|
|
18
|
-
width:
|
|
19
|
-
height:
|
|
20
|
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
24
|
-
|
|
19
|
+
width: 256px;
|
|
20
|
+
height: 256px;
|
|
21
|
+
object-fit: cover;
|
|
22
|
+
background-image: url('/images/no.png');
|
|
23
|
+
background-size: contain;
|
|
24
|
+
background-position: center;
|
|
25
|
+
background-repeat: no-repeat;
|
|
26
|
+
|
|
25
27
|
}
|
|
26
28
|
|
|
27
29
|
i-image.full img {
|
|
28
|
-
width: 100
|
|
29
|
-
height: auto;
|
|
30
|
-
|
|
30
|
+
width: 100% !important;
|
|
31
|
+
height: auto !important;
|
|
32
|
+
|
|
31
33
|
padding: 5px;
|
|
32
34
|
}
|
|
33
35
|
|
|
34
|
-
i-image.
|
|
36
|
+
i-image.img32 img {
|
|
37
|
+
width: 32px;
|
|
38
|
+
height: 32px;
|
|
39
|
+
}
|
|
40
|
+
i-image.logo img,
|
|
41
|
+
i-image.img48 img {
|
|
35
42
|
width: 48px;
|
|
36
43
|
height: 48px;
|
|
37
44
|
}
|
|
38
|
-
i-image.
|
|
45
|
+
i-image.img64 img {
|
|
46
|
+
width: 64px;
|
|
47
|
+
height: 64px;
|
|
48
|
+
}
|
|
49
|
+
i-image.img128 img {
|
|
39
50
|
width: 64px;
|
|
40
51
|
height: 64px;
|
|
41
52
|
}
|
|
42
|
-
i-image.
|
|
53
|
+
i-image.img256 img {
|
|
43
54
|
width: 256px;
|
|
44
55
|
height: 256px;
|
|
56
|
+
min-width: 256px;
|
|
57
|
+
min-height: 256px;
|
|
45
58
|
}
|
|
46
59
|
|
|
47
60
|
i-image.hover img:hover {
|
|
48
61
|
transform: scale(1.1);
|
|
49
62
|
}
|
|
50
63
|
|
|
51
|
-
i-image[view]
|
|
64
|
+
i-image[view] {
|
|
52
65
|
border: var(--i-image-view-border);
|
|
53
66
|
}
|
|
67
|
+
i-image[view] img{
|
|
68
|
+
background-image: none;
|
|
69
|
+
background-color: transparent;
|
|
70
|
+
}
|