lesli_audit 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/javascripts/lesli_audit/application.js +33 -98
  3. data/app/assets/javascripts/lesli_audit/application.js.LICENSE.txt +327 -0
  4. data/app/controllers/lesli_audit/accounts_controller.rb +60 -0
  5. data/app/controllers/lesli_audit/analytics_controller.rb +0 -4
  6. data/app/controllers/lesli_audit/requests_controller.rb +60 -0
  7. data/app/controllers/lesli_audit/users_controller.rb +60 -0
  8. data/app/helpers/lesli_audit/accounts_helper.rb +4 -0
  9. data/app/helpers/lesli_audit/requests_helper.rb +4 -0
  10. data/app/helpers/lesli_audit/users_helper.rb +4 -0
  11. data/app/models/lesli_audit/account.rb +6 -0
  12. data/app/models/lesli_audit/account_request.rb +5 -0
  13. data/app/models/lesli_audit/analytic.rb +2 -2
  14. data/app/models/lesli_audit/request.rb +4 -0
  15. data/app/models/lesli_audit/user.rb +4 -0
  16. data/app/models/lesli_audit/user_request.rb +7 -0
  17. data/app/services/lesli_audit/analytic_service.rb +13 -48
  18. data/app/views/lesli_audit/accounts/_account.html.erb +2 -0
  19. data/app/views/lesli_audit/accounts/_form.html.erb +17 -0
  20. data/app/views/lesli_audit/accounts/edit.html.erb +10 -0
  21. data/app/views/lesli_audit/accounts/index.html.erb +14 -0
  22. data/app/views/lesli_audit/accounts/new.html.erb +9 -0
  23. data/app/views/lesli_audit/accounts/show.html.erb +10 -0
  24. data/app/views/lesli_audit/requests/_form.html.erb +17 -0
  25. data/app/views/lesli_audit/requests/_request.html.erb +2 -0
  26. data/app/views/lesli_audit/requests/edit.html.erb +10 -0
  27. data/app/views/lesli_audit/requests/index.html.erb +14 -0
  28. data/app/views/lesli_audit/requests/new.html.erb +9 -0
  29. data/app/views/lesli_audit/requests/show.html.erb +10 -0
  30. data/app/views/lesli_audit/users/_form.html.erb +17 -0
  31. data/app/views/lesli_audit/users/_user.html.erb +2 -0
  32. data/app/views/lesli_audit/users/edit.html.erb +10 -0
  33. data/app/views/lesli_audit/users/index.html.erb +14 -0
  34. data/app/views/lesli_audit/users/new.html.erb +9 -0
  35. data/app/views/lesli_audit/users/show.html.erb +10 -0
  36. data/config/locales/translations.en.yml +7 -0
  37. data/config/locales/translations.es.yml +7 -0
  38. data/config/routes.rb +17 -11
  39. data/db/migrate/v1.0/0803100010_create_lesli_audit_account_requests.rb +44 -0
  40. data/db/migrate/v1.0/0803110010_create_lesli_audit_user_requests.rb +46 -0
  41. data/db/seed/development.rb +31 -24
  42. data/lib/lesli_audit/version.rb +2 -2
  43. data/lib/vue/apps/analytics/index.vue +3 -7
  44. data/lib/vue/components/requests.vue +0 -6
  45. data/lib/vue/components/visitors.vue +3 -0
  46. data/lib/vue/stores/analytics.js +0 -35
  47. data/lib/vue/stores/translations.json +38 -0
  48. data/readme.md +44 -93
  49. metadata +37 -3
  50. data/lib/vue/components/resources.vue +0 -73
data/readme.md CHANGED
@@ -1,120 +1,71 @@
1
1
  <p align="center">
2
- <img width="200" alt="Lesli logo" src="./app/assets/images/lesli/brand/app-logo.svg" />
2
+ <img width="90" alt="LesliCloud logo" src="./app/assets/images/lesli_admin/admin-logo.svg" />
3
+ <h3 align="center">Administration area for the Lesli Framework.</h3>
3
4
  </p>
4
5
 
5
- <h3 align="center">Ruby on Rails SaaS Development Framework.</h3>
6
-
6
+ <hr/>
7
+ <p align="center">
8
+ <a target="blank" href="https://rubygems.org/gems/lesli_admin">
9
+ <img src="https://badge.fury.io/rb/lesli_admin.svg" alt="Gem Version" height="18">
10
+ </a>
11
+ </p>
7
12
  <hr/>
8
13
 
9
- ## Introduction
10
-
11
- Lesli is a SaaS development framework designed to build highly scalable, secure and customizable software products.
12
-
13
- Built-on top of Ruby on Rails, Postgres, Vuejs, Bulma, SASS and many more awesome open-source libraries, packages, gems and tools.
14
-
15
- Lesli is completely open source and comes with features and tools that can save you years of development effort, additionally, our pre-built modules can seamlessly extend Lesli's functionality, allowing you to build your own SaaS in a matter of minutes.
16
-
17
- <br />
18
- <hr />
19
- <p align="center">
20
- Lesli is currently in alpha, but we're excited about the promising improvements coming soon!
21
- </p>
22
- <hr />
23
- <br />
24
- <br />
25
-
26
- Lesli is officially released and supported as of version 5
27
-
28
- > Lesli goes beyond being just a starter-kit, template, admin panel or dashboard. Lesli is a Ruby on Rails gem that you can use to build modules (a.k.a. engines) and standard Rails applications leveraging its robust set of built-in features, generators, components, and industry standards. With Lesli, you have the flexibility to extend existing functionalities or develop fully customized software tailored to your specific needs.
29
-
30
-
31
- ## Documentation
32
- * [Roadmap](./docs/roadmap.md)
33
- * [Core database](./docs/database.md)
34
- * [Main documentation](https://www.lesli.dev/documentation/)
35
-
36
-
37
- ## Installation
38
-
39
- __Get the latest stable version of Lesli__
40
-
41
- ```ruby
42
- # Gemfile
43
- gem "lesli"
44
- ```
45
-
46
- __Run bundle install:__
47
-
48
- ```shell
49
- bundle install
50
- ```
51
-
52
- __Generate the init files:__
14
+ ### Quick start
53
15
 
54
16
  ```shell
55
- rails g lesli:install
17
+ # Add LesliAdmin engine
18
+ bundle add lesli_admin
56
19
  ```
57
20
 
58
- __Load the database and demo data:__
59
-
60
21
  ```shell
61
- rake rake lesli:db:setup
22
+ # Setup database
23
+ rake lesli:db:setup
62
24
  ```
63
25
 
64
- __Run server__
65
- ```shell
66
- rails s # for development
67
- rails s --binding=0.0.0.0 # debug in local network
68
- RAILS_SERVE_STATIC_FILES=true rails s --environment=production # production mode
26
+ ```ruby
27
+ # Load LesliAdmin
28
+ Rails.application.routes.draw do
29
+ mount LesliAdmin::Engine => "/admin"
30
+ end
69
31
  ```
70
32
 
71
- For more details about the installation check the official [documentation.](https://www.lesli.dev/documentation)
72
33
 
34
+ ### Documentation
35
+ * [Roadmap](./docs/roadmap.md)
36
+ * [database](./docs/database.md)
37
+ * [documentation](https://www.lesli.dev/documentation/)
73
38
 
74
39
 
75
- ## Development
76
-
77
- __Get the latest version of Lesli source code__
78
-
79
- ```shell
80
- # clone the lesli repo inside your engine folder: RailsApp/engines
81
- git clone https://github.com/LesliTech/Lesli.git
82
- ```
83
-
84
- __Load Lesli as a Gem__
85
- ```ruby
86
- gem "lesli", path: "engines/Lesli"
87
- ```
88
-
89
- __Install the necessary Gems to run Lesli:__
40
+ ### Get in touch
90
41
 
91
- ```shell
92
- bundle install
93
- ```
42
+ * [Website: https://www.lesli.tech](https://www.lesli.tech)
43
+ * [Email: hello@lesli.tech](hello@lesli.tech)
44
+ * [Twitter: @LesliTech](https://twitter.com/LesliTech)
94
45
 
95
- __Work with the database:__
96
46
 
97
- ```shell
98
- # Hard reset for development:
99
- rake lesli:db:reset
100
- ```
47
+ ### License
48
+ -------
49
+ Copyright (c) 2023, Lesli Technologies, S. A.
101
50
 
102
- __Run server__
103
- ```shell
104
- rails s
105
- rails s --binding=0.0.0.0
106
- rails s --environment=test
107
- rails s --environment=development
108
- RAILS_SERVE_STATIC_FILES=true rails s --environment=production
109
- ```
51
+ This program is free software: you can redistribute it and/or modify
52
+ it under the terms of the GNU General Public License as published by
53
+ the Free Software Foundation, either version 3 of the License, or
54
+ (at your option) any later version.
110
55
 
56
+ This program is distributed in the hope that it will be useful,
57
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
58
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
59
+ GNU General Public License for more details.
111
60
 
112
- ## License
113
- ------
114
- Software developed in [Guatemala](http://visitguatemala.com/) by [LesliTech](https://www.lesli.tech) distributed under the *General Public License v 3.0* you can read the full license [here](http://www.gnu.org/licenses/gpl-3.0.html)
61
+ You should have received a copy of the GNU General Public License
62
+ along with this program. If not, see http://www.gnu.org/licenses/.
115
63
 
116
- <br>
64
+ <hr />
65
+ <br />
117
66
 
118
67
  <p align="center">
119
- <img alt="Lesli logo" width="100" src="./app/assets/images/lesli/brand/app-icon.svg" />
68
+ <img width="200" alt="Lesli logo" src="https://cdn.lesli.tech/lesli/brand/app-logo.svg" />
69
+ <h4 align="center">Ruby on Rails SaaS Development Framework.</h4>
120
70
  </p>
71
+
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lesli_audit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - The Lesli Development Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-10-06 00:00:00.000000000 Z
11
+ date: 2023-10-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -35,19 +35,31 @@ files:
35
35
  - app/assets/config/lesli_audit_manifest.js
36
36
  - app/assets/images/lesli_audit/audit-logo.svg
37
37
  - app/assets/javascripts/lesli_audit/application.js
38
+ - app/assets/javascripts/lesli_audit/application.js.LICENSE.txt
38
39
  - app/assets/stylesheets/lesli_audit/application.scss
39
40
  - app/assets/stylesheets/lesli_audit/dashboard.scss
41
+ - app/controllers/lesli_audit/accounts_controller.rb
40
42
  - app/controllers/lesli_audit/analytics_controller.rb
41
43
  - app/controllers/lesli_audit/application_controller.rb
42
44
  - app/controllers/lesli_audit/dashboards_controller.rb
45
+ - app/controllers/lesli_audit/requests_controller.rb
46
+ - app/controllers/lesli_audit/users_controller.rb
47
+ - app/helpers/lesli_audit/accounts_helper.rb
43
48
  - app/helpers/lesli_audit/analytics_helper.rb
44
49
  - app/helpers/lesli_audit/application_helper.rb
45
50
  - app/helpers/lesli_audit/dashboards_helper.rb
51
+ - app/helpers/lesli_audit/requests_helper.rb
52
+ - app/helpers/lesli_audit/users_helper.rb
46
53
  - app/jobs/lesli_audit/application_job.rb
47
54
  - app/mailers/lesli_audit/application_mailer.rb
55
+ - app/models/lesli_audit/account.rb
56
+ - app/models/lesli_audit/account_request.rb
48
57
  - app/models/lesli_audit/analytic.rb
49
58
  - app/models/lesli_audit/application_record.rb
50
59
  - app/models/lesli_audit/dashboard.rb
60
+ - app/models/lesli_audit/request.rb
61
+ - app/models/lesli_audit/user.rb
62
+ - app/models/lesli_audit/user_request.rb
51
63
  - app/services/lesli_audit/account/activity_services.rb
52
64
  - app/services/lesli_audit/analytic_service.rb
53
65
  - app/services/lesli_audit/analytics/trend_services.rb
@@ -58,6 +70,12 @@ files:
58
70
  - app/services/lesli_audit/users/registration_services.rb
59
71
  - app/services/lesli_audit/users/role_services.rb
60
72
  - app/services/lesli_audit/users/working_hour_services.rb
73
+ - app/views/lesli_audit/accounts/_account.html.erb
74
+ - app/views/lesli_audit/accounts/_form.html.erb
75
+ - app/views/lesli_audit/accounts/edit.html.erb
76
+ - app/views/lesli_audit/accounts/index.html.erb
77
+ - app/views/lesli_audit/accounts/new.html.erb
78
+ - app/views/lesli_audit/accounts/show.html.erb
61
79
  - app/views/lesli_audit/analytics/_analytic.html.erb
62
80
  - app/views/lesli_audit/analytics/_form.html.erb
63
81
  - app/views/lesli_audit/analytics/edit.html.erb
@@ -71,10 +89,26 @@ files:
71
89
  - app/views/lesli_audit/dashboards/new.html.erb
72
90
  - app/views/lesli_audit/dashboards/show.html.erb
73
91
  - app/views/lesli_audit/partials/_engine-navigation.html.erb
92
+ - app/views/lesli_audit/requests/_form.html.erb
93
+ - app/views/lesli_audit/requests/_request.html.erb
94
+ - app/views/lesli_audit/requests/edit.html.erb
95
+ - app/views/lesli_audit/requests/index.html.erb
96
+ - app/views/lesli_audit/requests/new.html.erb
97
+ - app/views/lesli_audit/requests/show.html.erb
98
+ - app/views/lesli_audit/users/_form.html.erb
99
+ - app/views/lesli_audit/users/_user.html.erb
100
+ - app/views/lesli_audit/users/edit.html.erb
101
+ - app/views/lesli_audit/users/index.html.erb
102
+ - app/views/lesli_audit/users/new.html.erb
103
+ - app/views/lesli_audit/users/show.html.erb
104
+ - config/locales/translations.en.yml
105
+ - config/locales/translations.es.yml
74
106
  - config/routes.rb
75
107
  - db/migrate/v1.0/0803000110_create_lesli_audit_accounts.rb
76
108
  - db/migrate/v1.0/0803050110_create_lesli_audit_dashboards.rb
77
109
  - db/migrate/v1.0/0803050210_create_lesli_audit_dashboard_components.rb
110
+ - db/migrate/v1.0/0803100010_create_lesli_audit_account_requests.rb
111
+ - db/migrate/v1.0/0803110010_create_lesli_audit_user_requests.rb
78
112
  - db/seed/development.rb
79
113
  - db/seed/production.rb
80
114
  - db/seed/test.rb
@@ -96,13 +130,13 @@ files:
96
130
  - lib/vue/apps/users/roles.vue
97
131
  - lib/vue/apps/users/workingHours.vue
98
132
  - lib/vue/components/requests.vue
99
- - lib/vue/components/resources.vue
100
133
  - lib/vue/components/visitors.vue
101
134
  - lib/vue/stores/accounts/activities.js
102
135
  - lib/vue/stores/analytics.js
103
136
  - lib/vue/stores/request.js
104
137
  - lib/vue/stores/security/password.js
105
138
  - lib/vue/stores/security/session.js
139
+ - lib/vue/stores/translations.json
106
140
  - lib/vue/stores/users/activities.js
107
141
  - lib/vue/stores/users/logs.js
108
142
  - lib/vue/stores/users/registrations.js
@@ -1,73 +0,0 @@
1
- <script setup>
2
- /*
3
- Lesli
4
-
5
- Copyright (c) 2023, Lesli Technologies, S. A.
6
-
7
- This program is free software: you can redistribute it and/or modify
8
- it under the terms of the GNU General Public License as published by
9
- the Free Software Foundation, either version 3 of the License, or
10
- (at your option) any later version.
11
-
12
- This program is distributed in the hope that it will be useful,
13
- but WITHOUT ANY WARRANTY; without even the implied warranty of
14
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
- GNU General Public License for more details.
16
-
17
- You should have received a copy of the GNU General Public License
18
- along with this program. If not, see http://www.gnu.org/licenses/.
19
-
20
- Lesli · Ruby on Rails SaaS Development Framework.
21
-
22
- Made with ♥ by https://www.lesli.tech
23
- Building a better future, one line of code at a time.
24
-
25
- @contact hello@lesli.tech
26
- @website https://www.lesli.tech
27
- @license GPLv3 http://www.gnu.org/licenses/gpl-3.0.en.html
28
-
29
- // · ~·~ ~·~ ~·~ ~·~ ~·~ ~·~ ~·~ ~·~ ~·~
30
- // ·
31
- */
32
-
33
-
34
- // · import vue tools
35
- import { ref, reactive, onMounted, watch, computed } from "vue"
36
-
37
-
38
- // · import Lesli components
39
- import { lesliChartBar } from "lesli-vue/components"
40
-
41
-
42
- // · import stores
43
- import { useAnalytics } from "LesliAudit/stores/analytics"
44
-
45
-
46
- // · implement stores
47
- const storeAnalytics = useAnalytics()
48
-
49
-
50
- // · define variables
51
- var series = ref([]);
52
- var labels = ref([]);
53
-
54
-
55
- // ·
56
- watch(() => storeAnalytics.resources.records, () => {
57
- labels.value = storeAnalytics.resources.records.map(visit => visit.date)
58
- series.value = [{
59
- name: "Resources",
60
- data: storeAnalytics.resources.records.map(visit => visit.resources)
61
- }]
62
- })
63
-
64
- </script>
65
- <template>
66
- <lesli-application-component>
67
- <lesli-chart-bar
68
- :title="'Resources'"
69
- :series="series"
70
- :labels="labels">
71
- </lesli-chart-bar>
72
- </lesli-application-component>
73
- </template>