Giter VIP home page Giter VIP logo

slack-productivity-bots's Introduction

Build Status

Appveyor Server side coverage Client side coverage Code Climate Code Climate Issue Count
Build status Coverage Status Client Side Coverage Status Code Climate Issue Count

slack-erp-custom-integration-mvc

Slack Custom Integration/Apps for Leave Management, Standup Meetings, Task status.

slack-productivity-bots's People

Contributors

chintans avatar gouravagrwal avatar iamronakshah avatar iroshni avatar juliepromact avatar rushi216 avatar shreel2015 avatar siddharthashw avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

slack-productivity-bots's Issues

convert string constant to non static

String constant is used as static property class. It should ideally be used through Dependency Injection mechanism. convert this class to make it Di friendly. This is similar to #58

Create a common way to access all environment variables

Create a common way to access all environment variables quickly. Right now a common way of using it is to Environment.GetEnvironmentVariable("","Scope). Whenever this variable is re-used, there will be code repetition. Instead, create something that will unify it.

remove all string from code

Currently, all strings are inside the code in a string constant. If I want to change any string, I would need to redeploy the application. Suggest a better way to manage text outside code and implement it.

Sick Leave Flow

What will be action after admin applies sick leave for an employee? Will all team leader and management get any slack message as casual leave and email regarding sick leave has been applied for the employee?
And the same question arise for sick leave update?

List all environment variables

List out all environment variables in a text file as an instruction file. for example, create SETUP.md file and write down set up instruction for the project. make sure you use dummy values and not the actual values in instructions

improve build time

Improve build time by caching packages and node_modules folder. Also try to use yarn instead of npm for package management.

Passing access token as a parameter in every function

Access token is being passed as a parameter in every method that calls oauth server. Instead of that we can move its generation to the place from where we actually make call to oauth server (to be specific Http Client Repository).

In "Task Report" add loader.

Steps to be followed:

  1. Open a link (https://promactslack.azurewebsites.net)
  2. Then click on Login with Promact.
  3. Then you may see "Task Report" when you click on it and you may see a text "Nothing is Loading Now" instead of text we may have a loader when we click on Task Report a loader must be installed the all the reports must be generated.

Please see the screenshot.
2016-10-18_10-33-56

Add more properties for slack user

right now we are not utilizing all the fields provided by slack to filter out the users. We should ideally filterout all the bots and inactive users. SlackUserDetail should have more fields that will allow us to accomplish this. Here is the sample json that we receive.

{
            "id": "U051J2QKG",
            "team_id": "T04K6NL66",
            "name": "johnlenin",
            "deleted": false,
            "status": null,
            "color": "d1707d",
            "real_name": "John Lenin",
            "tz": "Asia\/Kolkata",
            "tz_label": "India Standard Time",
            "tz_offset": 19800,
            "profile": {
                "first_name": "John",
                "last_name": "Lenin",
                "avatar_hash": "762f356b8ed5",
                "image_24": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_24.jpg",
                "image_32": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_32.jpg",
                "image_48": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_48.jpg",
                "image_72": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_72.jpg",
                "image_192": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_192.jpg",
                "image_512": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_512.jpg",
                "image_1024": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_1024.jpg",
                "image_original": "https:\/\/avatars.slack-edge.com\/2016-06-24\/53960066869888_762f356b8ed5768f4f87_original.jpg",
                "title": "",
                "phone": "",
                "skype": "",
                "real_name": "John Lenin",
                "real_name_normalized": "John Lenin",
                "email": "[email protected]"
            },
            "is_admin": false,
            "is_owner": false,
            "is_primary_owner": false,
            "is_restricted": false,
            "is_ultra_restricted": false,
            "is_bot": false,
            "has_2fa": false
        },

Enable User details updation

When we add Slack Username and it does not match with the username in the slack, So we are not able to change it.
We have the function implemented for the edit but it is not been updated in the database.

Exception while adding slack app

I tried adding slack app to the application. But, It showed this exception.

2016-09-29 09:49:37.7141 Promact.Erp.Core.Controllers.OAuthController Error in OAuth Controller-Slack OAuth. Error -> System.Data.Entity.Infrastructure.DbUpdateException: An error occurred while updating the entries. See the inner exception for details. ---> System.Data.Entity.Core.UpdateException: An error occurred while updating the entries. See the inner exception for details. ---> System.Data.SqlClient.SqlException: Cannot insert the value NULL into column 'Id', table 'promactslack.dbo.SlackUserDetails'; column does not allow nulls. INSERT fails.
The statement has been terminated.
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds, Boolean describeParameterEncryptionRequest) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
at System.Data.Entity.Infrastructure.Interception.InternalDispatcher1.Dispatch[TTarget,TInterceptionContext,TResult](TTarget target, Func3 operation, TInterceptionContext interceptionContext, Action3 executing, Action3 executed)
at System.Data.Entity.Infrastructure.Interception.DbCommandDispatcher.Reader(DbCommand command, DbCommandInterceptionContext interceptionContext)
at System.Data.Entity.Core.Mapping.Update.Internal.DynamicUpdateCommand.Execute(Dictionary2 identifierValues, List1 generatedValues)
at System.Data.Entity.Core.Mapping.Update.Internal.UpdateTranslator.Update()
--- End of inner exception stack trace ---
at System.Data.Entity.Core.Mapping.Update.Internal.UpdateTranslator.Update()
at System.Data.Entity.Core.Objects.ObjectContext.ExecuteInTransaction[T](Func1 func, IDbExecutionStrategy executionStrategy, Boolean startLocalTransaction, Boolean releaseConnectionOnSuccess) at System.Data.Entity.Core.Objects.ObjectContext.SaveChangesToStore(SaveOptions options, IDbExecutionStrategy executionStrategy, Boolean startLocalTransaction) at System.Data.Entity.SqlServer.DefaultSqlExecutionStrategy.Execute[TResult](Func1 operation)
at System.Data.Entity.Core.Objects.ObjectContext.SaveChangesInternal(SaveOptions options, Boolean executeInExistingTransaction)
at System.Data.Entity.Internal.InternalContext.SaveChanges()
--- End of inner exception stack trace ---
at System.Data.Entity.Internal.InternalContext.SaveChanges()
at Promact.Core.Repository.ExternalLoginRepository.OAuthLoginRepository.d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Promact.Erp.Core.Controllers.OAuthController.d__7.MoveNext()

Create a success page after Slack authorization to add Slack to team

right now When we hit Add to Slack. It redirects a user to Slack for authentication and returns on a blank page. There is no way to know whether it was successful or failed. Please add a page which indicates the outcome. i.e, If It comes back successfully. It should show

Promact Slack app has been successfully

if it comes back with a failure

Promact Slack app was not added successfully. There is something wrong Internally.

or there is a server side exception.

Promact Slack app was not added successfully. {{REPLACE_THIS_WITH_ACTUAL_ERROR_RETURNED_FROM_SLACK}}

And below this description add a button to continue which brings use back to Home page.

Exception while connecting to slack bot

An unhandled exception was thrown while connecting to slack bot using SlackSocketClient of SlackApi. It occurred after XMPP was enabled in slack team. Even after disabling it, this issue persists.

improve scrum bot implementation

think scrum bot needs a change in implementation.

  1. Job of the scrum bot is to conduct scrum meeting only
  2. Instead of using something like "scrum time" we can use "@scrumstaging start". It is much better way to start.
  3. Once a meeting is completed. It should not allow another scrum meeting during that day.
  4. If somebody tries 2nd scrum meeting. It should reply something like "meeting is done for today. Try again tomorrow."
  5. As an enhancement, we can look to add force start even if a meeting is conducted in a day already.

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.