Coder Social home page Coder Social logo

emranprojects / sahabee Goto Github PK

View Code? Open in Web Editor NEW
9.0 3.0 1.0 9.14 MB

Let the good times roll!

Home Page: https://sahabee.ir

License: GNU General Public License v3.0

Shell 5.14% Dockerfile 0.57% Python 48.28% JavaScript 43.08% HTML 1.92% Jinja 0.56% CSS 0.46%
rollcall timesheet timesheet-management

sahabee's People

Contributors

alireza73uk avatar dependabot[bot] avatar emranbm avatar yaser62 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

alireza73uk

sahabee's Issues

Add ability to connect existing account to Google

For current users, it's vital to be able to connect their current SahaBee account to their Google account, so can take the benefits of the future Google OAuth login feature.
For this reason, these features are needed, in order:

  • Ability to delete account. So can undo any unintentional Google login.
  • Ability to connect the current SahaBee account to a Google account. So that the future logins can be performed through Google.

Connect to Sentry

It's needed to connect SahaBee to Sentry for error tracking.
Preferably for both backend and frontend.

Clean docker cache periodically

Currently, the pulled images on deployments remain in the production server forever.
There should be a corn job to clean docker cache (i.e. docker system prune -a) periodically.

Switch to Postgres

Currently, SahaBee is using an SQLite database, which is better to be replaced with PostgreSQL.

CC manager when emailing the timesheet

  • UserDetail should contain also the manager's email address. (Backend)
  • Manager email should be settable on the profile page. (Frontend)
  • Manager should be in CCs of the timesheet email. (Backend)

Fix email sending authentication issue

There is a celery task that emails timesheets periodically. Currently, it fails due to the change to the mail server authentication system. It may or may not be fixed by replacing the new credentials.
The error log:

[2022-01-11 23:00:01,811: ERROR/ForkPoolWorker-2] Task TASK_SEND_ACTIVE_TIMESHEETS[3e6e4745-c225-432b-93bc-3e9b0c6e2e93] raised unexpected: SMTPAuthenticationError(535, b'5.7.8 Error: authentication fail
ed: authentication failure')
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/site-packages/celery/app/trace.py", line 451, in trace_task
    R = retval = fun(*args, **kwargs)
  File "/usr/local/lib/python3.8/site-packages/celery/app/trace.py", line 734, in __protected_call__
    return self.run(*args, **kwargs)
  File "/sahabee/rollcall/tasks.py", line 32, in send_active_timesheets
    _send_user_timesheet(user)
  File "/sahabee/rollcall/tasks.py", line 72, in _send_user_timesheet
    message.send()
  File "/usr/local/lib/python3.8/site-packages/django/core/mail/message.py", line 284, in send
    return self.get_connection(fail_silently).send_messages([self])
  File "/usr/local/lib/python3.8/site-packages/django/core/mail/backends/smtp.py", line 102, in send_messages
    new_conn_created = self.open()
  File "/usr/local/lib/python3.8/site-packages/django/core/mail/backends/smtp.py", line 69, in open
    self.connection.login(self.username, self.password)
  File "/usr/local/lib/python3.8/smtplib.py", line 734, in login
    raise last_exception
  File "/usr/local/lib/python3.8/smtplib.py", line 723, in login
    (code, resp) = self.auth(
  File "/usr/local/lib/python3.8/smtplib.py", line 646, in auth
    raise SMTPAuthenticationError(code, resp)
smtplib.SMTPAuthenticationError: (535, b'5.7.8 Error: authentication failed: authentication failure')

UserDetails edit page

Users should be able to see and edit their details (described by backend model UserDetail).

Nice form errors

Currently, when submitting a form (e.g. login) the error details text is toasted rawly.
It's better to show them near the corresponding error-faced fields.

Remove UserDetails API endpoint

There is no need for the user to be able to deal with user details.
The UserDetailViewSet and corresponding codes, should be removed.

Rollcall button toggle for exit/enter

In the dashboard, it's better to determine what the rollcall button is supposed to emit: An enter event or an exit?
Note that it's just a UI/UX facility since there is no difference between Rollout objects at the backend.

Backup restore fails to reload an auto-generated UserDetail

During the test run of the restore procedure, it failed to restore this backup on production.
So I manually destroyed the production data and restored a modified* version of the backup.
*By modification, I mean removing the problematic UserDetail from the backup file.
It didn't get reproduced locally but was reproducing at production, even with a clean database.

Specify time for rollcalling

In the dashboard, users should be able to determine the time of roll call.
Currently, it's only a single button to rollcall with the current time.
It's already implemented at the API level to send the time for rollcalling.

Prevent more than MAX rollouts per day

Currently, the timesheet format doesn't let more than 6 rollouts. It should be validated at the backend not to save more than 6 rollouts in a single day.

On restore failure, last database should be replaced back

The current restore procedure contains two steps:

  1. Flushing the DB. (i.e. emptying the whole database)
  2. Restoring the previous backup.

So, if step 2 is failed, we face an empty database!
It's important to back up the last DB file (i.e. db.sqlite) and replace it back to the position if the restore procedure failed for any reason.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.