├── src ├── images │ ├── doc1.gif │ ├── loading.gif │ └── sidebar-1.jpg ├── js-utils │ ├── main.js │ ├── material-dashboard.min.js │ ├── material-dashboard.js.map │ ├── material-dashboard.js │ └── plugins │ │ └── bootstrap-notify.js ├── AdminSliderbarContainer.html ├── SliderbarContainer.html ├── css │ └── main.css ├── index.html ├── AdminProfileView.html ├── Documents.html ├── ProfileView.html ├── ProfileEdit.html └── Appointment.html ├── bs-config.json ├── docs ├── images │ ├── doc1.gif │ ├── loading.gif │ └── sidebar-1.jpg ├── js-utils │ ├── main.js │ ├── material-dashboard.min.js │ ├── material-dashboard.js.map │ ├── material-dashboard.js │ └── plugins │ │ └── bootstrap-notify.js ├── AdminSliderbarContainer.html ├── SliderbarContainer.html ├── css │ └── main.css ├── index.html ├── AdminProfileView.html ├── Documents.html ├── ProfileView.html ├── ProfileEdit.html └── Appointment.html ├── migrations ├── 2_deploy_contracts.js └── 1_initial_migration.js ├── contracts ├── Migrations.sol └── EMRContract.sol ├── truffle-config.js ├── package.json ├── webpack.config.js ├── truffle.js ├── .gitignore ├── README.md ├── test └── EMR.js └── LICENSE /src/images/doc1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/papandas/Blockchain-EMR/HEAD/src/images/doc1.gif -------------------------------------------------------------------------------- /bs-config.json: -------------------------------------------------------------------------------- 1 | { 2 | "server": { 3 | "baseDir": ["./src", "./build/contracts"] 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /docs/images/doc1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/papandas/Blockchain-EMR/HEAD/docs/images/doc1.gif -------------------------------------------------------------------------------- /src/images/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/papandas/Blockchain-EMR/HEAD/src/images/loading.gif -------------------------------------------------------------------------------- /docs/images/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/papandas/Blockchain-EMR/HEAD/docs/images/loading.gif -------------------------------------------------------------------------------- /src/images/sidebar-1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/papandas/Blockchain-EMR/HEAD/src/images/sidebar-1.jpg -------------------------------------------------------------------------------- /docs/images/sidebar-1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/papandas/Blockchain-EMR/HEAD/docs/images/sidebar-1.jpg -------------------------------------------------------------------------------- /migrations/2_deploy_contracts.js: -------------------------------------------------------------------------------- 1 | var EMR = artifacts.require("./EMRContract.sol"); 2 | 3 | module.exports = function(deployer) { 4 | deployer.deploy(EMR); 5 | }; 6 | -------------------------------------------------------------------------------- /migrations/1_initial_migration.js: -------------------------------------------------------------------------------- 1 | var Migrations = artifacts.require("./Migrations.sol"); 2 | 3 | module.exports = function(deployer) { 4 | deployer.deploy(Migrations); 5 | }; 6 | -------------------------------------------------------------------------------- /docs/js-utils/main.js: -------------------------------------------------------------------------------- 1 | $(function() { 2 | 3 | $('#login-form-link').click(function(e) { 4 | $("#login-form").delay(100).fadeIn(100); 5 | $("#register-form").fadeOut(100); 6 | $('#register-form-link').removeClass('active'); 7 | $(this).addClass('active'); 8 | e.preventDefault(); 9 | }); 10 | $('#register-form-link').click(function(e) { 11 | $("#register-form").delay(100).fadeIn(100); 12 | $("#login-form").fadeOut(100); 13 | $('#login-form-link').removeClass('active'); 14 | $(this).addClass('active'); 15 | e.preventDefault(); 16 | }); 17 | 18 | }); 19 | -------------------------------------------------------------------------------- /src/js-utils/main.js: -------------------------------------------------------------------------------- 1 | $(function() { 2 | 3 | $('#login-form-link').click(function(e) { 4 | $("#login-form").delay(100).fadeIn(100); 5 | $("#register-form").fadeOut(100); 6 | $('#register-form-link').removeClass('active'); 7 | $(this).addClass('active'); 8 | e.preventDefault(); 9 | }); 10 | $('#register-form-link').click(function(e) { 11 | $("#register-form").delay(100).fadeIn(100); 12 | $("#login-form").fadeOut(100); 13 | $('#login-form-link').removeClass('active'); 14 | $(this).addClass('active'); 15 | e.preventDefault(); 16 | }); 17 | 18 | }); 19 | -------------------------------------------------------------------------------- /contracts/Migrations.sol: -------------------------------------------------------------------------------- 1 | pragma solidity ^0.4.23; 2 | 3 | contract Migrations { 4 | address public owner; 5 | uint public last_completed_migration; 6 | 7 | constructor() public { 8 | owner = msg.sender; 9 | } 10 | 11 | modifier restricted() { 12 | if (msg.sender == owner) _; 13 | } 14 | 15 | function setCompleted(uint completed) public restricted { 16 | last_completed_migration = completed; 17 | } 18 | 19 | function upgrade(address new_address) public restricted { 20 | Migrations upgraded = Migrations(new_address); 21 | upgraded.setCompleted(last_completed_migration); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /truffle-config.js: -------------------------------------------------------------------------------- 1 | /* 2 | * NB: since truffle-hdwallet-provider 0.0.5 you must wrap HDWallet providers in a 3 | * function when declaring them. Failure to do so will cause commands to hang. ex: 4 | * ``` 5 | * mainnet: { 6 | * provider: function() { 7 | * return new HDWalletProvider(mnemonic, 'https://mainnet.infura.io/') 8 | * }, 9 | * network_id: '1', 10 | * gas: 4500000, 11 | * gasPrice: 10000000000, 12 | * }, 13 | */ 14 | 15 | module.exports = { 16 | // See 17 | // to customize your Truffle configuration! 18 | }; 19 | -------------------------------------------------------------------------------- /docs/AdminSliderbarContainer.html: -------------------------------------------------------------------------------- 1 | 6 | 7 | -------------------------------------------------------------------------------- /src/AdminSliderbarContainer.html: -------------------------------------------------------------------------------- 1 | 6 | 7 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "EMR", 3 | "version": "1.0.0", 4 | "description": "SAFIANT MEDDATA - A Blockchain EMR Network.", 5 | "main": "truffle-config.js", 6 | "directories": { 7 | "test": "test" 8 | }, 9 | "scripts": { 10 | "build": "webpack", 11 | "dev": "lite-server", 12 | "test": "echo \"Error: no test specified\" && exit 1" 13 | }, 14 | "keywords": [], 15 | "author": "", 16 | "license": "ISC", 17 | "devDependencies": { 18 | "babel-core": "^6.26.3", 19 | "babel-loader": "^7.1.4", 20 | "babel-preset-env": "^1.6.1", 21 | "lite-server": "^2.3.0", 22 | "webpack": "^4.8.1", 23 | "webpack-cli": "^2.1.3" 24 | }, 25 | "dependencies": { 26 | "ethereumjs-util": "^5.2.0", 27 | "truffle-contract": "^3.0.6", 28 | "web3": "^1.0.0-beta.35" 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /webpack.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path') 2 | module.exports = { 3 | entry: path.join(__dirname, 'src/js', 'app.js'), 4 | mode: "production", 5 | devServer: { 6 | contentBase: path.join(__dirname, 'src'), 7 | }, 8 | output: { 9 | path: path.join(__dirname, 'dist'), 10 | filename: 'build.js' 11 | }, 12 | module: { 13 | rules: [ 14 | { 15 | test: /\.css$/, 16 | use: ['style-loader','css-loader'], 17 | include: [/src/, /node_modules/] 18 | }, { 19 | test: /\.jsx?$/, 20 | loader: 'babel-loader', 21 | exclude: /node_modules/, 22 | query: { 23 | presets: ['es2015', 'react', 'stage-2'] 24 | } 25 | }, { 26 | test: /\.json$/, 27 | loader: 'json-loader', 28 | include: '/build/contracts/' 29 | } 30 | ] 31 | } 32 | } -------------------------------------------------------------------------------- /truffle.js: -------------------------------------------------------------------------------- 1 | /* 2 | * NB: since truffle-hdwallet-provider 0.0.5 you must wrap HDWallet providers in a 3 | * function when declaring them. Failure to do so will cause commands to hang. ex: 4 | * ``` 5 | * mainnet: { 6 | * provider: function() { 7 | * return new HDWalletProvider(mnemonic, 'https://mainnet.infura.io/') 8 | * }, 9 | * network_id: '1', 10 | * gas: 4500000, 11 | * gasPrice: 10000000000, 12 | * }, 13 | */ 14 | 15 | module.exports = { 16 | networks: { 17 | development: { 18 | host: "localhost", 19 | port: 7545, 20 | network_id: "*", 21 | gas: 6000000, 22 | gasPrice: 100000000000 23 | }, 24 | rinkeby: { 25 | host:"localhost", 26 | port:8545, 27 | from: "0x2d62771cb1bbb9fc81289276014b76954a57b648", 28 | network_id: 4, 29 | gas: 6000000, 30 | gasPrice: 100000000000 31 | } 32 | } 33 | }; 34 | -------------------------------------------------------------------------------- /docs/SliderbarContainer.html: -------------------------------------------------------------------------------- 1 | 6 | 7 | -------------------------------------------------------------------------------- /src/SliderbarContainer.html: -------------------------------------------------------------------------------- 1 | 6 | 7 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | package-lock.json* 8 | INSTRUCTIONS.txt 9 | HTML 10 | 11 | # Runtime data 12 | pids 13 | *.pid 14 | *.seed 15 | *.pid.lock 16 | 17 | # Directory for instrumented libs generated by jscoverage/JSCover 18 | lib-cov 19 | 20 | # Coverage directory used by tools like istanbul 21 | coverage 22 | 23 | # nyc test coverage 24 | .nyc_output 25 | 26 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 27 | .grunt 28 | 29 | # Bower dependency directory (https://bower.io/) 30 | bower_components 31 | 32 | # node-waf configuration 33 | .lock-wscript 34 | 35 | # Compiled binary addons (https://nodejs.org/api/addons.html) 36 | build/Release 37 | 38 | # Dependency directories 39 | node_modules/ 40 | jspm_packages/ 41 | 42 | # TypeScript v1 declaration files 43 | typings/ 44 | 45 | # Optional npm cache directory 46 | .npm 47 | 48 | # Optional eslint cache 49 | .eslintcache 50 | 51 | # Optional REPL history 52 | .node_repl_history 53 | 54 | # Output of 'npm pack' 55 | *.tgz 56 | 57 | # Yarn Integrity file 58 | .yarn-integrity 59 | 60 | # dotenv environment variables file 61 | .env 62 | 63 | # next.js build output 64 | .next 65 | -------------------------------------------------------------------------------- /src/css/main.css: -------------------------------------------------------------------------------- 1 | .tim-typo { 2 | padding-left: 25%; 3 | margin-bottom: 40px; 4 | position: relative; 5 | width: 100%; 6 | } 7 | 8 | .tim-typo .tim-note { 9 | bottom: 5px; 10 | color: #c0c1c2; 11 | display: block; 12 | font-weight: 400; 13 | font-size: 13px; 14 | line-height: 15px; 15 | left: 0; 16 | margin-left: 20px; 17 | position: absolute; 18 | width: 260px; 19 | } 20 | 21 | /* offline-doc */ 22 | 23 | .offline-doc .navbar.navbar-transparent { 24 | padding-top: 25px; 25 | border-bottom: none; 26 | } 27 | 28 | .offline-doc .navbar.navbar-transparent .navbar-minimize { 29 | display: none; 30 | } 31 | 32 | .offline-doc .navbar.navbar-transparent .navbar-brand, 33 | .offline-doc .navbar.navbar-transparent .collapse .navbar-nav .nav-link { 34 | color: #FFFFFF !important; 35 | } 36 | 37 | .offline-doc .footer { 38 | z-index: 3 !important; 39 | } 40 | 41 | .offline-doc .page-header .container { 42 | z-index: 3; 43 | } 44 | 45 | .offline-doc .page-header:after { 46 | background-color: rgba(0, 0, 0, 0.5); 47 | content: ""; 48 | display: block; 49 | height: 100%; 50 | left: 0; 51 | position: absolute; 52 | top: 0; 53 | width: 100%; 54 | z-index: 2; 55 | } 56 | 57 | #map { 58 | z-index: 2; 59 | height: calc(100vh - 70px); 60 | margin-top: 70px; 61 | } -------------------------------------------------------------------------------- /docs/css/main.css: -------------------------------------------------------------------------------- 1 | .tim-typo { 2 | padding-left: 25%; 3 | margin-bottom: 40px; 4 | position: relative; 5 | width: 100%; 6 | } 7 | 8 | .tim-typo .tim-note { 9 | bottom: 5px; 10 | color: #c0c1c2; 11 | display: block; 12 | font-weight: 400; 13 | font-size: 13px; 14 | line-height: 15px; 15 | left: 0; 16 | margin-left: 20px; 17 | position: absolute; 18 | width: 260px; 19 | } 20 | 21 | /* offline-doc */ 22 | 23 | .offline-doc .navbar.navbar-transparent { 24 | padding-top: 25px; 25 | border-bottom: none; 26 | } 27 | 28 | .offline-doc .navbar.navbar-transparent .navbar-minimize { 29 | display: none; 30 | } 31 | 32 | .offline-doc .navbar.navbar-transparent .navbar-brand, 33 | .offline-doc .navbar.navbar-transparent .collapse .navbar-nav .nav-link { 34 | color: #FFFFFF !important; 35 | } 36 | 37 | .offline-doc .footer { 38 | z-index: 3 !important; 39 | } 40 | 41 | .offline-doc .page-header .container { 42 | z-index: 3; 43 | } 44 | 45 | .offline-doc .page-header:after { 46 | background-color: rgba(0, 0, 0, 0.5); 47 | content: ""; 48 | display: block; 49 | height: 100%; 50 | left: 0; 51 | position: absolute; 52 | top: 0; 53 | width: 100%; 54 | z-index: 2; 55 | } 56 | 57 | #map { 58 | z-index: 2; 59 | height: calc(100vh - 70px); 60 | margin-top: 70px; 61 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Blockchain-EMR 2 | Blockchain EMR is a blockchain based electronic health records and medical practice management solution. 3 | 4 | # SAFIANT MEDDATA 5 | To-Do Task List: 6 | 7 | Patient Demographics: 8 | 1) Track patient demographics 9 | 2) Primary information (name, date of birth, sex, identification) 10 | 3) Marital status 11 | 4) Contact information of patient and patient's employer 12 | 5) Primary provider 13 | 6) HIPAA information 14 | 7) Language and ethnicity 15 | 8) Insurance coverage 16 | 9) Deceased Tracking 17 | 18 | Patient Scheduling: 19 | 1) Patient Tracking and Reporting 20 | 2) Patient appointment 21 | 3) Calendar features include: 22 | 3.1) Find open appointment slots 23 | 3.2) Categories for appointment types 24 | 3.3) Repeating appointments 25 | 26 | Medical Records: 27 | 1) Medical Issues 28 | 2) Medications 29 | 3) Forms and clinical notes: 30 | 3.1) growth charts included 31 | 3.2) note 32 | 3.3) Review of systems 33 | 4) Patient Reports 34 | 5) Referrals 35 | 6) Patient Notes 36 | 7) Disclosures 37 | 8) document management 38 | 39 | Prescriptions: 40 | 1) Track patient prescriptions and medications 41 | 2) Create and send prescriptions 42 | 3) E-Prescribe 43 | 4) Print 44 | 5) Email 45 | 46 | Medical Billing: 47 | 1) Ether payment 48 | 49 | Patient Portal: 50 | 1) Modern User Interface 51 | 2) Scheduling and Appointments 52 | 3) Messaging 53 | 4) Ether Payment 54 | 5) New Patient Registration 55 | 6) Reports 56 | 7) Medical Problems 57 | 8) Medications 58 | 9) Allergies 59 | 10) Appointments 60 | 61 | Reports (Admin): 62 | 1) Appointments 63 | 2) Patient Lists 64 | 3) Prescriptions and Drug Dispensing 65 | 4) Pending Orders 66 | -------------------------------------------------------------------------------- /docs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | SAFIANT MEDDATA 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 |

25 | 26 |

27 |
28 | 29 |
30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /src/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | SAFIANT MEDDATA 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 |

25 | 26 |

27 |
28 | 29 |
30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /docs/AdminProfileView.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 | 5 |
6 | 7 | 8 | 27 | 28 |
29 |
30 | 31 | 32 | 33 |
34 |
35 |

Administrators

36 | 39 |
40 | 41 |
42 |
43 |
44 | 45 |
46 | 47 |
48 | 49 | 50 | 51 |
52 |
53 |
54 | 55 |
56 |
57 |
58 | 59 |
60 | 61 |
62 | 63 | 64 | 65 |
66 |
67 |
68 | 69 |
70 | 71 | 72 | 73 |
74 |
75 | 76 |
77 | 78 |
-------------------------------------------------------------------------------- /src/AdminProfileView.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 | 5 |
6 | 7 | 8 | 27 | 28 |
29 |
30 | 31 | 32 | 33 |
34 |
35 |

Administrators

36 | 39 |
40 | 41 |
42 |
43 |
44 | 45 |
46 | 47 |
48 | 49 | 50 | 51 |
52 |
53 |
54 | 55 |
56 |
57 |
58 | 59 |
60 | 61 |
62 | 63 | 64 | 65 |
66 |
67 |
68 | 69 |
70 | 71 | 72 | 73 |
74 |
75 | 76 |
77 | 78 |
-------------------------------------------------------------------------------- /contracts/EMRContract.sol: -------------------------------------------------------------------------------- 1 | pragma solidity ^0.4.23; 2 | 3 | contract EMRContract { 4 | 5 | enum SexType { MALE, FEMALE } 6 | enum MaritalType { single, married, remarried, separated, divorced, widowed } 7 | enum AppointmentStat { CREATED, APPROVED, REJECTED, BILLING, CLOSE } 8 | 9 | struct Patient { 10 | address client; 11 | string fullname; 12 | string dob; 13 | SexType sex; 14 | MaritalType marital; 15 | string email; 16 | uint256[] medicalreport; 17 | } 18 | 19 | struct Appointment{ 20 | uint256 index; 21 | address patient; 22 | uint256 datetime; 23 | AppointmentStat stat; 24 | string remark; 25 | } 26 | 27 | struct MedicalReport{ 28 | string docname; 29 | string docpath; 30 | string docdesp; 31 | bool isActive; 32 | uint256 index; 33 | } 34 | 35 | mapping(address => Patient) public patients; 36 | 37 | mapping(uint256 => Appointment) public appointments; 38 | mapping(address => bool) public administrator; 39 | 40 | mapping(uint256 => MedicalReport) public medicalreports; 41 | 42 | uint256 public AppointmentIndex; 43 | uint256 public MedicalReportIndex; 44 | 45 | address public owner; 46 | 47 | 48 | string public version = "0.0.1"; 49 | 50 | event eAppointmentAdd(uint256 indexed index, address sender); 51 | 52 | event eAppointmentUpdate(uint256 indexed index, address sender); 53 | 54 | 55 | modifier isOwner() { 56 | if (msg.sender == owner) _; 57 | } 58 | 59 | modifier isAdministrator(address _admin) { 60 | if (administrator[_admin] == true) _; 61 | } 62 | 63 | constructor() public { 64 | owner = msg.sender; 65 | administrator[msg.sender] = true; 66 | } 67 | 68 | function UpdateVersion (string _version) public { 69 | version = _version; 70 | } 71 | 72 | function SetAdministrator (address _admin) public { 73 | require(msg.sender == owner); 74 | require(!administrator[_admin]); 75 | 76 | administrator[_admin] = true; 77 | } 78 | 79 | /* 80 | * Sign Up Patients 81 | */ 82 | 83 | function SignupPatient(string _fullname, 84 | string _dob, 85 | SexType _sex, 86 | MaritalType _marital, 87 | string _email, 88 | uint256[] _medicalreport) public { 89 | 90 | require(msg.sender != patients[msg.sender].client); 91 | 92 | patients[msg.sender] = Patient(msg.sender, 93 | _fullname, 94 | _dob, 95 | _sex, 96 | _marital, 97 | _email, 98 | _medicalreport); 99 | 100 | } 101 | 102 | 103 | function PatientUpdate(string _fullname, 104 | string _dob, 105 | SexType _sex, 106 | MaritalType _marital, 107 | string _email) public { 108 | 109 | require(msg.sender == patients[msg.sender].client); 110 | 111 | patients[msg.sender].fullname = _fullname; 112 | patients[msg.sender].dob = _dob; 113 | patients[msg.sender].sex = _sex; 114 | patients[msg.sender].marital = _marital; 115 | patients[msg.sender].email = _email; 116 | 117 | } 118 | 119 | 120 | function AppointmentAdd(uint256 _datetime, 121 | AppointmentStat _stat, string _remark) public { 122 | 123 | require(msg.sender == patients[msg.sender].client); 124 | require(_datetime > now); 125 | 126 | AppointmentIndex++; 127 | 128 | appointments[AppointmentIndex] = Appointment(AppointmentIndex, 129 | msg.sender, 130 | _datetime, 131 | _stat, 132 | _remark); 133 | 134 | emit eAppointmentAdd(AppointmentIndex, msg.sender); 135 | 136 | } 137 | 138 | function AppointmentUpdate(uint256 _AppointmentIndex, 139 | AppointmentStat _stat, 140 | string _remark) public { 141 | 142 | require(administrator[msg.sender] == true || msg.sender == patients[msg.sender].client); 143 | require(_AppointmentIndex > 0); 144 | require(_AppointmentIndex <= AppointmentIndex); 145 | 146 | appointments[_AppointmentIndex].stat = _stat; 147 | appointments[_AppointmentIndex].remark = _remark; 148 | 149 | emit eAppointmentUpdate(_AppointmentIndex, msg.sender); 150 | 151 | } 152 | 153 | function AppointmentGet() public view returns (uint256[]){ 154 | uint256[] memory results; 155 | uint256 count; 156 | for (uint256 i = 1; i <= AppointmentIndex; i++) { 157 | if(appointments[i].patient == msg.sender) 158 | { 159 | //results.push(appointments[i].index); 160 | results[count] = i; 161 | count++; 162 | } 163 | } 164 | return results; 165 | } 166 | 167 | function payment(address _receiver) public payable { 168 | _receiver.transfer(msg.value); 169 | } 170 | 171 | function MedicalReportAdd(string _docname, 172 | string _docpath, 173 | string _docdesp) public { 174 | 175 | require(msg.sender == patients[msg.sender].client, "Sender has to be a patient"); 176 | 177 | MedicalReportIndex++; 178 | medicalreports[MedicalReportIndex] = MedicalReport(_docname, 179 | _docpath, 180 | _docdesp, 181 | true, MedicalReportIndex); 182 | 183 | patients[msg.sender].medicalreport.push(MedicalReportIndex); 184 | 185 | } 186 | 187 | function MedicalReportGet(address _addr) public view returns(uint256[]){ 188 | return patients[_addr].medicalreport; 189 | } 190 | 191 | 192 | 193 | function kill() public { 194 | require(msg.sender == owner); 195 | selfdestruct(msg.sender); 196 | } 197 | 198 | 199 | 200 | 201 | } 202 | -------------------------------------------------------------------------------- /docs/Documents.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 27 | 28 |
29 |
30 | 31 |
32 |
33 |

Upload Documents

34 |
35 | 36 |
37 |
38 |
39 | 40 |
41 |
42 |
43 | 44 | 45 |
46 |
47 |
48 | 49 |
50 | 51 | 52 |
53 |
54 |
55 |
56 | 57 | 58 |
59 |
60 |
61 |
62 | 63 | 64 |
65 |
66 |
67 |
68 |
69 |
70 | 71 |
72 |
73 |

Documents

74 | 77 |
78 | 79 |
80 |
81 |
82 | 83 |
84 | 85 | 86 | 99 |
100 | 101 | 102 | 103 |
104 |
105 |
106 |
107 | 108 | 109 | 110 |
111 |
112 | 113 | 114 | 115 |
116 | 117 | 118 |
-------------------------------------------------------------------------------- /src/Documents.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 27 | 28 |
29 |
30 | 31 |
32 |
33 |

Upload Documents

34 |
35 | 36 |
37 |
38 |
39 | 40 |
41 |
42 |
43 | 44 | 45 |
46 |
47 |
48 | 49 |
50 | 51 | 52 |
53 |
54 |
55 |
56 | 57 | 58 |
59 |
60 |
61 |
62 | 63 | 64 |
65 |
66 |
67 |
68 |
69 |
70 | 71 |
72 |
73 |

Documents

74 | 77 |
78 | 79 |
80 |
81 |
82 | 83 |
84 | 85 | 86 | 99 |
100 | 101 | 102 | 103 |
104 |
105 |
106 |
107 | 108 | 109 | 110 |
111 |
112 | 113 | 114 | 115 |
116 | 117 | 118 |
-------------------------------------------------------------------------------- /docs/ProfileView.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 | 5 |
6 | 7 | 8 | 27 | 28 |
29 |
30 | 31 | 32 | 33 |
34 |
35 |

PROFILE DEMOGRAPHICS

36 | 39 |
40 | 41 |
42 |
43 |
44 | 45 |
46 |
47 |
Who
48 |
49 | 50 |
51 |
52 |
53 | 54 |
55 |
56 |
57 | 58 |
59 |
60 |
61 | 62 |
63 |
64 |
65 | 66 |
67 |
68 |
69 |
70 | 71 | 72 |
73 |
74 |
Contact
75 |
76 |
77 |
78 |
79 | 80 |
81 |
82 |
83 |
84 |
85 |
86 | 87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 | 98 | 99 | 100 |
101 |
102 |
Stats
103 |
104 | 105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 | 116 |
117 |
118 |
119 |
120 | 121 | 122 | 123 |
124 |
125 | 126 |
127 | 128 |
-------------------------------------------------------------------------------- /src/ProfileView.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 | 5 |
6 | 7 | 8 | 27 | 28 |
29 |
30 | 31 | 32 | 33 |
34 |
35 |

PROFILE DEMOGRAPHICS

36 | 39 |
40 | 41 |
42 |
43 |
44 | 45 |
46 |
47 |
Who
48 |
49 | 50 |
51 |
52 |
53 | 54 |
55 |
56 |
57 | 58 |
59 |
60 |
61 | 62 |
63 |
64 |
65 | 66 |
67 |
68 |
69 |
70 | 71 | 72 |
73 |
74 |
Contact
75 |
76 |
77 |
78 |
79 | 80 |
81 |
82 |
83 |
84 |
85 |
86 | 87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 | 98 | 99 | 100 |
101 |
102 |
Stats
103 |
104 | 105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 | 116 |
117 |
118 |
119 |
120 | 121 | 122 | 123 |
124 |
125 | 126 |
127 | 128 |
-------------------------------------------------------------------------------- /docs/js-utils/material-dashboard.min.js: -------------------------------------------------------------------------------- 1 | isWindows=-1');0!=$("body").find(".main-panel").length?e.appendTo(".main-panel"):$("body").hasClass("off-canvas-sidebar")&&e.appendTo(".wrapper-full-page"),setTimeout(function(){e.addClass("visible")},100),e.click(function(){$("html").removeClass("nav-open"),mobile_menu_visible=0,e.removeClass("visible"),setTimeout(function(){e.remove(),$toggle.removeClass("toggled")},400)}),$("html").addClass("nav-open"),mobile_menu_visible=1}}),$(window).resize(function(){md.initSidebarsCheck(),seq=seq2=0,setTimeout(function(){md.initDashboardPageCharts()},500)}),md={misc:{navbar_menu_visible:0,active_collapse:!0,disabled_collapse_init:0},checkSidebarImage:function(){$sidebar=$(".sidebar"),image_src=$sidebar.data("image"),void 0!==image_src&&(sidebar_container='');0!=$("body").find(".main-panel").length?e.appendTo(".main-panel"):$("body").hasClass("off-canvas-sidebar")&&e.appendTo(".wrapper-full-page"),setTimeout(function(){e.addClass("visible")},100),e.click(function(){$("html").removeClass("nav-open"),mobile_menu_visible=0,e.removeClass("visible"),setTimeout(function(){e.remove(),$toggle.removeClass("toggled")},400)}),$("html").addClass("nav-open"),mobile_menu_visible=1}}),$(window).resize(function(){md.initSidebarsCheck(),seq=seq2=0,setTimeout(function(){md.initDashboardPageCharts()},500)}),md={misc:{navbar_menu_visible:0,active_collapse:!0,disabled_collapse_init:0},checkSidebarImage:function(){$sidebar=$(".sidebar"),image_src=$sidebar.data("image"),void 0!==image_src&&(sidebar_container='