outlook & teamsteams reshma.gawade@techneai.com Panchgani@2024 ticketing ReshmaG Abcd@123 11 MARCH READ ABOUT CRUDBOOSTER **************************************************************************************************** 12 MARCH install xampp ,already provided 8.2 php v but for crud booster 7.2 needed so there was issue occuring so fz setup direct given ' Inside Prat i can work created tables using crud booster setup first need to create the tables in database then using the all steps 4 controller generated after each controller is generated we need to give chmod command php download for outside for crud booster https://www.filehorse.com/download-php-64/55212/download/ ************************************************************************** php and xammpp https://phpandmysql.com/extras/installing-xampp/ ****************************************************************************88888 https://www.javatpoint.com/uninstalling-xampp-completely#:~:text=Step%204%2D%20By%20typing%20%22X,modules%2C%20click%20%22YES.%22&text=Step%206%2D%20For%20effectively%20removing,C%3A%5Cxampp%5Chtdocs%20folder. *****************************************************************************8 composer install https://www.hostinger.in/tutorials/how-to-install-composer ******************************************************************************************** crud booster https://github.com/crocodic-studio/crudbooster/blob/v5.6/docs/en/installation.m *************************************************************************************** 7.2 version download https://www.filehorse.com/download-php-64/55212/download/ terminal for composer running first time Microsoft Windows [Version 10.0.19044.3086] (c) Microsoft Corporation. All rights reserved. C:\Users\User>cmd Microsoft Windows [Version 10.0.19044.3086] (c) Microsoft Corporation. All rights reserved. C:\Users\User>composer ______ / ____/___ ____ ___ ____ ____ ________ _____ / / / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/ / /___/ /_/ / / / / / / /_/ / /_/ (__ ) __/ / \____/\____/_/ /_/ /_/ .___/\____/____/\___/_/ /_/ Composer version 2.7.2 2024-03-11 17:12:18 Usage: command [options] [arguments] Options: -h, --help Display help for the given command. When no command is given display help for the list command -q, --quiet Do not output any message -V, --version Display this application version --ansi|--no-ansi Force (or disable --no-ansi) ANSI output -n, --no-interaction Do not ask any interactive question --profile Display timing and memory usage information --no-plugins Whether to disable plugins. --no-scripts Skips the execution of all scripts defined in composer.json file. -d, --working-dir=WORKING-DIR If specified, use the given directory as working directory. --no-cache Prevent use of the cache -v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug Available commands: about Shows a short information about Composer archive Creates an archive of this composer package audit Checks for security vulnerability advisories for installed packages browse [home] Opens the package's repository URL or homepage in your browser bump Increases the lower limit of your composer.json requirements to the currently installed versions check-platform-reqs Check that platform requirements are satisfied clear-cache [clearcache|cc] Clears composer's internal package cache completion Dump the shell completion script config Sets config options create-project Creates new project from a package into given directory depends [why] Shows which packages cause the given package to be installed diagnose Diagnoses the system to identify common errors dump-autoload [dumpautoload] Dumps the autoloader exec Executes a vendored binary/script fund Discover how to help fund the maintenance of your dependencies global Allows running commands in the global composer dir ($COMPOSER_HOME) help Display help for a command init Creates a basic composer.json file in current directory install [i] Installs the project dependencies from the composer.lock file if present, or falls back on the composer.json licenses Shows information about licenses of dependencies list List commands outdated Shows a list of installed packages that have updates available, including their latest version prohibits [why-not] Shows which packages prevent the given package from being installed reinstall Uninstalls and reinstalls the given package names remove [rm] Removes a package from the require or require-dev require [r] Adds required packages to your composer.json and installs them run-script [run] Runs the scripts defined in composer.json search Searches for packages self-update [selfupdate] Updates composer.phar to the latest version show [info] Shows information about packages status Shows a list of locally modified packages suggests Shows package suggestions update [u|upgrade] Updates your dependencies to the latest version according to composer.json, and updates the composer.lock file validate Validates a composer.json and composer.lock C:\Users\User> ********************************************************************************************************* crud booster browser link http://43.204.64.80/prat/public/admin/module_generator/step1/22 browser by default columns for all table is_active remark created_by created_at updated_by updated_at composer create-project laravel/laravel DemoCrudBooster *******************************************************************************************************888 13 MARCH parent child relationship that is if we select the india then only the states related to india like maharashtra and karnataka will be seen not clear after task helper methods are used for acess related things 1)CRUDBooster::getCurrentMethod() : if we wiil be on index page then we wil get the getIndex() 2)CRUDBooster::mainpath($slug=NULL) : if we use this method then we will get this mainpath e.g : http://localhost/project/public/admin/module_name 3)CRUDBooster::adminPath($slug=NULL) : if we use this method then we will get the admin path e.g : http://localhost/project/public/admin 4)CRUDBooster::myId() : if we use this we get the user id in my case 1 5)CRUDBooster::getSetting($name): it is giving me null ****************************************************************** 14 march 1)history tables create them for all three in mysql but no need to create the modules for it we can show on one page only by using $_GET['history'] echo $_SERVER['SCRIPT_NAME']; $_SERVER['REMOTE_ADDR'] 2) How To Add More Action Button In Grid Data history button we add with the buttons of view and all 3) add in before edit add two fields updated_by and updated_at in that function first need to add pass the parameters id,table action $this->call dynamic function get the parameters inside this get the details of id unset $table.id $data['action']=$action; $data['ip_address']= ******************************************************************************* ***********How To Add More Action Button In Grid Data*************************** history and duplication handled on 14 march ********************************************************************************* 15 march history of state and city handled ****export button custom code ************* https://nestify.io/blog/php-and-mysql-to-import-and-export-csv/ *********************************** child form :like jar india select kele tr tyatil state select kele tar form mdhe disle pahijhe ************************************************************* ************************************************************************* 18 march Employee Master with validations along with history name : only letter not alpha numeric but space it should accept it dob : future date should not accept mobile number : only 10 digits country state city email is_active remark created_by created_at updated_by updated_at **************************************************** regex:/^[a-zA-Z ]+$/ regex:/[a-zA-Z][a-zA-Z ]+[a-zA-Z]$/| at start and end no space but in between $('#employee_dob').on('input',function(){ alert('hii'); // $('#employee_dob').on('focus', function(){ // // alert('hello'); // $('#employee_dob').datepicker( // ); // const $currentDate = new Date(); // // console.log(currentDate); // }); // $('#employee_dob').datepicker( // dateFormat: 'dd/mm/yy', // changeMonth: true, // changeYear: true, // minDate: '-3M', // maxDate: '+28D', // ); ****************************************************************************************** 19 march Department table id ,department_name employee_department table emp id deptid one employee should be able to work in multiple departments multi select karta ale pahijhe departments while editing also if we remove the that department name then to the in before edit or after edit we will need to write the logic is_active set =0 karta ale pahijhe // $departments = DB::table('department_master')->get(); // dd($departments); $updatedData = DB::table("employee_department_mapping")->where('employee_id', $id)->update('is_active', 0); hook_before_add : when we ckick on submit button if we want to carry out the things then we write code hook_before_edit : hook_after_add: // $('#department_id').on('change',function(){ // // alert('hii'); // document.getElementById('department_id'); // var selectedOptions = []; // var options = this.options; // for(var i =0 ;i 0 ? selectedOptions.join(', ') :'Please Select the department'; // this.('placeholder',palceHolderText); // // console.log(hii); // }); https://www.positronx.io/php-select2-multi-select-with-jquery-ajax-tutorial/ // var deptId = $('#department_id option:selected').val(); // console.log(deptId); // var url = '" . CRUDBooster::mainpath('emp-dept-mapping') . "/'+; // var empDetails = DB::table('employee_master')->where('employee_email',empEmail)->get(); // console.log(empDetails); public function hook_after_edit($id) { //Your code here $this->generateHistory($id, 'country_master', 'UPDATE'); } public function generateHistory($id, $table, $action){ $data = DB::table($table)->where('id', $id)->first(); $data[$table."_id"] = $data['id']; unset($data['id']); $data['action'] = $action; $data['ip_address'] = $_SERVER['REMOTE_ADDR']; // insert into history DB::table($table."_history")->instert($data); return true; } 29 march putty connnection get() using get object we will be getting [{ }] but we needed singlw value so $('#cu_branch_masters_id').change(function(){ var cu_branch_masters_id = $('#cu_branch_masters_id option:selected').val(); var url = '" . CRUDBooster::mainpath('selected-branch-mapping') . "/'+cu_branch_masters_id; $('#device_id').empty(); $('#category_id').empty(); $.get( url, function( data ) { var json = JSON.parse(data); console.log(json); $('#device_id').append(''); for( var i = 0; i < json.length; i++){ var id = json[i].device_id; var name = json[i].device_name; $('#device_id').append(''); } }); }); $('#department_id').append(''); for( var i = 0; i < result.length; i++){ var dname = result[i].value; console.log(dname); $('#department_id').append(''); } public function getDepartment($empId) { $employeeId = DB::table('employee_master')->select('id') ->where('employee_email', $empId) ->pluck('id')->toArray(); $dept = DB::table('employee_department_mapping') ->whereIn('employee_id', $employeeId) ->where('employee_department_mapping.is_active', 1) ->join('department_master', 'employee_department_mapping.department_id', 'department_master.id') // ->select('department_master.id', 'department_master.department_name') ->pluck('employee_department_mapping.id') ->toArray(); // $all_dept = DB::table('department_master')->('id', 'department_name')->get() // $option = ''; foreach ($dept as $row) { $option .= ''; } return $option; } /22/3/2024 HRMS employee joining this project is regarding the joining process but offer letter will not be generated follow up history is for hr experience no of years in dropd own hardcode values like active interview master we can add steps of iv walkin asel tr hr manully form fill nahitr scan qr thourgh they will be redirected to the cspl carrer page remark master mdhe dropdown asel tithun fecth krta yeyil 1)reamark is by hr befor iv link will be sent before one day while scheduling third column for whom https://www.positronx.io/php-select2-multi-select-with-jquery-ajax-tutorial/ import export csv https://nestify.io/blog/php-and-mysql-to-import-and-export-csv/ how to build rest api in php https://wpwebinfotech.com/blog/how-to-build-simple-rest-api-in-php