├── public ├── temp │ ├── footer.html │ ├── nav.html │ └── chatbox.html ├── uploads │ ├── as.jpg │ ├── hero.jpg │ ├── home.jpg │ ├── hero2.jpg │ ├── image.jpg │ ├── askdaskdj.jpg │ ├── 1652132667558gta5.png │ ├── banners │ │ ├── testtest.png │ │ └── placeholder-background.jpg │ ├── 1652122795955lolgta.jpg │ ├── placeholder-profile.jpg │ ├── 1652217690008askdaskdj.jpg │ ├── gettyimages-1061959920.jpg │ ├── 1652240942593carly_orr_web.jpg │ ├── 1652242555319carly_orr_web.jpg │ ├── 1652297874730carly_orr_web.jpg │ ├── 1653071362456Screenshot_1.png │ ├── 0ea012b1d902c41fecb41ccb572b2414.jpg │ ├── tXHWkXQxaRPZwzX2AwmKTJ-1200-80.jpg │ ├── 0626_celeb100-jackie-chan_1200x675.jpg │ ├── Screenshot_20220507-153952_Gallery.jpg │ ├── cool-profile-pic-matheus-ferrero.jpeg │ ├── 1652985706882MDot-TheOffice-640x360-MP.jpg │ ├── 6f979ad64096012948b281ce187c59812e30c3ac.png │ └── 1652217561891cool-profile-pic-matheus-ferrero.jpeg ├── images │ ├── hero.jpg │ ├── hero2.jpg │ ├── home.jpg │ ├── logo.png │ ├── batman.mp3 │ ├── batman.png │ ├── checkout.jpg │ ├── therapist1.jpg │ ├── therapist2.jpg │ ├── orderhistory.jpg │ ├── placeholder-profile.jpg │ ├── placeholder-background.jpg │ ├── send.svg │ ├── heart-pulse.svg │ ├── radial-bg.svg │ ├── logo-bl.svg │ ├── logo-wh.svg │ ├── logo.svg │ └── thankyou.svg ├── originaljs │ ├── thank-you.js │ ├── index.js │ ├── login.js │ ├── therapists.js │ ├── sign-up.js │ ├── my-patients.js │ └── checkout.js ├── css │ ├── privacy-terms.css │ ├── 404.css │ ├── thank-you.css │ ├── my-patients.css │ └── chat-session.css └── js │ ├── thank-you.js │ ├── login.js │ ├── home.js │ ├── index.js │ ├── therapists.js │ ├── sign-up.js │ ├── my-patients.js │ ├── checkout.js │ └── order-history.js ├── .gitignore ├── vercel.json ├── models ├── BBY_31_messages.js ├── BBY_31_shoppingCarts.js └── BBY_31_users.js ├── package.json ├── LICENSE ├── README.md └── html ├── 404.html ├── chat-session.html ├── thank-you.html ├── my-patients.html ├── login.html ├── therapists.html ├── index.html └── order-history.html /public/temp/footer.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .env 2 | node_modules 3 | package-lock.json 4 | /data 5 | passwords.txt -------------------------------------------------------------------------------- /public/uploads/as.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/as.jpg -------------------------------------------------------------------------------- /public/images/hero.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/hero.jpg -------------------------------------------------------------------------------- /public/images/hero2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/hero2.jpg -------------------------------------------------------------------------------- /public/images/home.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/home.jpg -------------------------------------------------------------------------------- /public/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/logo.png -------------------------------------------------------------------------------- /public/uploads/hero.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/hero.jpg -------------------------------------------------------------------------------- /public/uploads/home.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/home.jpg -------------------------------------------------------------------------------- /public/images/batman.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/batman.mp3 -------------------------------------------------------------------------------- /public/images/batman.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/batman.png -------------------------------------------------------------------------------- /public/images/checkout.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/checkout.jpg -------------------------------------------------------------------------------- /public/uploads/hero2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/hero2.jpg -------------------------------------------------------------------------------- /public/uploads/image.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/image.jpg -------------------------------------------------------------------------------- /public/images/therapist1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/therapist1.jpg -------------------------------------------------------------------------------- /public/images/therapist2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/therapist2.jpg -------------------------------------------------------------------------------- /public/uploads/askdaskdj.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/askdaskdj.jpg -------------------------------------------------------------------------------- /public/images/orderhistory.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/orderhistory.jpg -------------------------------------------------------------------------------- /public/uploads/1652132667558gta5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652132667558gta5.png -------------------------------------------------------------------------------- /public/uploads/banners/testtest.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/banners/testtest.png -------------------------------------------------------------------------------- /public/images/placeholder-profile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/placeholder-profile.jpg -------------------------------------------------------------------------------- /public/uploads/1652122795955lolgta.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652122795955lolgta.jpg -------------------------------------------------------------------------------- /public/uploads/placeholder-profile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/placeholder-profile.jpg -------------------------------------------------------------------------------- /public/images/placeholder-background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/images/placeholder-background.jpg -------------------------------------------------------------------------------- /public/uploads/1652217690008askdaskdj.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652217690008askdaskdj.jpg -------------------------------------------------------------------------------- /public/uploads/gettyimages-1061959920.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/gettyimages-1061959920.jpg -------------------------------------------------------------------------------- /public/uploads/1652240942593carly_orr_web.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652240942593carly_orr_web.jpg -------------------------------------------------------------------------------- /public/uploads/1652242555319carly_orr_web.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652242555319carly_orr_web.jpg -------------------------------------------------------------------------------- /public/uploads/1652297874730carly_orr_web.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652297874730carly_orr_web.jpg -------------------------------------------------------------------------------- /public/uploads/1653071362456Screenshot_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1653071362456Screenshot_1.png -------------------------------------------------------------------------------- /public/uploads/0ea012b1d902c41fecb41ccb572b2414.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/0ea012b1d902c41fecb41ccb572b2414.jpg -------------------------------------------------------------------------------- /public/uploads/banners/placeholder-background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/banners/placeholder-background.jpg -------------------------------------------------------------------------------- /public/uploads/tXHWkXQxaRPZwzX2AwmKTJ-1200-80.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/tXHWkXQxaRPZwzX2AwmKTJ-1200-80.jpg -------------------------------------------------------------------------------- /public/uploads/0626_celeb100-jackie-chan_1200x675.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/0626_celeb100-jackie-chan_1200x675.jpg -------------------------------------------------------------------------------- /public/uploads/Screenshot_20220507-153952_Gallery.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/Screenshot_20220507-153952_Gallery.jpg -------------------------------------------------------------------------------- /public/uploads/cool-profile-pic-matheus-ferrero.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/cool-profile-pic-matheus-ferrero.jpeg -------------------------------------------------------------------------------- /public/uploads/1652985706882MDot-TheOffice-640x360-MP.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652985706882MDot-TheOffice-640x360-MP.jpg -------------------------------------------------------------------------------- /public/uploads/6f979ad64096012948b281ce187c59812e30c3ac.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/6f979ad64096012948b281ce187c59812e30c3ac.png -------------------------------------------------------------------------------- /public/uploads/1652217561891cool-profile-pic-matheus-ferrero.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/salesp07/MyMind/HEAD/public/uploads/1652217561891cool-profile-pic-matheus-ferrero.jpeg -------------------------------------------------------------------------------- /public/images/send.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /vercel.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 2, 3 | "builds": [ 4 | { 5 | "src": "./index.js", 6 | "use": "@vercel/node" 7 | } 8 | ], 9 | "routes": [ 10 | { 11 | "src": "/(.*)", 12 | "dest": "/" 13 | } 14 | ] 15 | } -------------------------------------------------------------------------------- /public/originaljs/thank-you.js: -------------------------------------------------------------------------------- 1 | /** 2 | * AJAX call that checks to see if the user placed an order in the past three minutes. 3 | * If yes, renders the order information. 4 | */ 5 | $.ajax({ 6 | url: '/recentPurchase', 7 | method: "GET", 8 | success: function(obj) { 9 | document.getElementById("orderNumber").innerHTML = obj.orderId; 10 | } 11 | }) -------------------------------------------------------------------------------- /models/BBY_31_messages.js: -------------------------------------------------------------------------------- 1 | const mongoose = require("mongoose"); 2 | const Schema = mongoose.Schema; 3 | 4 | const messageSchema = new Schema({ 5 | message: { 6 | type: String, 7 | required: true 8 | }, 9 | sender: { 10 | type: String, 11 | required: true 12 | }, 13 | orderId: { 14 | type: String, 15 | required: true 16 | } 17 | }, { timestamps: true }); 18 | 19 | const Chat = mongoose.model('dms', messageSchema); 20 | module.exports = Chat; -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "mymind", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "start": "node index.js", 8 | "devStart": "nodemon index.js" 9 | }, 10 | "keywords": [], 11 | "author": "", 12 | "license": "ISC", 13 | "dependencies": { 14 | "bcrypt": "^5.0.1", 15 | "dotenv": "^16.0.1", 16 | "express": "^4.18.1", 17 | "express-session": "^1.17.2", 18 | "mongodb": "^4.5.0", 19 | "mongoose": "^6.3.3", 20 | "multer": "^1.4.4", 21 | "nodemailer": "^6.7.5", 22 | "nodemon": "^2.0.16", 23 | "path": "^0.12.7", 24 | "socket.io": "^4.5.1", 25 | "socket.io-client": "^4.5.0" 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /public/images/heart-pulse.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /public/css/privacy-terms.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --primaryColor: #09C5A3; 3 | --secondaryColor: #00A98B; 4 | } 5 | 6 | /* Privacy Policy & Terms and Conditions */ 7 | #wrapper #defaultContainer { 8 | grid-column: 1 / span 4; 9 | grid-row: 2 / span 1; 10 | width: 100%; 11 | padding: 5rem 7rem; 12 | color: black; 13 | } 14 | 15 | #wrapper #defaultContainer h1 { 16 | font-size: 2.5rem; 17 | padding-bottom: 1.5rem; 18 | } 19 | 20 | #wrapper #defaultContainer p { 21 | font-size: 1rem; 22 | line-height: 2rem; 23 | padding-bottom: 1rem; 24 | } 25 | 26 | #wrapper #defaultContainer ul { 27 | padding-left: 3rem; 28 | padding-bottom: 1rem; 29 | } 30 | 31 | #wrapper #defaultContainer ul li { 32 | line-height: 2rem; 33 | } 34 | 35 | #wrapper #defaultContainer a { 36 | text-decoration: none; 37 | font-weight: 700; 38 | color: var(--primaryColor); 39 | } -------------------------------------------------------------------------------- /models/BBY_31_shoppingCarts.js: -------------------------------------------------------------------------------- 1 | const mongoose = require("mongoose"); 2 | 3 | const cartSchema = new mongoose.Schema({ 4 | orderId: { 5 | type: String, 6 | required: true 7 | }, 8 | therapist: { 9 | type: String, 10 | required: true 11 | }, 12 | userId: { 13 | type: mongoose.Schema.Types.ObjectId, 14 | required: true 15 | }, 16 | timeLength: { 17 | type: String, 18 | enum: ["freePlan", "monthPlan", "threeMonthPlan", "yearPlan"], 19 | required: true, 20 | default: "freePlan" 21 | }, 22 | status: { 23 | type: String, 24 | enum: ["completed", "active", "deleted", "refunded"], 25 | required: true 26 | }, 27 | cost: { 28 | type: String 29 | }, 30 | expiringTime: { 31 | type: Date 32 | }, 33 | purchased: { 34 | type: Date 35 | } 36 | }, { versionKey: false }); 37 | 38 | const Cart = mongoose.model('shoppingCart', cartSchema); 39 | module.exports = Cart; 40 | 41 | -------------------------------------------------------------------------------- /public/temp/nav.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Pedro Sales Muniz, Alex Gibbison, Kian Azizkhani, Towa Quimbayo 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /public/temp/chatbox.html: -------------------------------------------------------------------------------- 1 | 2 |
3 |
4 |
5 |
6 | Profile Picture of Therapist / Patient 7 |
8 |
9 |

10 |

Offline

11 |
12 |
13 |
14 | 15 | 18 |
19 |
20 | 23 |
24 | 26 | 29 |
30 |
-------------------------------------------------------------------------------- /public/js/thank-you.js: -------------------------------------------------------------------------------- 1 | function _0x3d07(_0x2261f5,_0x2c019a){var _0x26d2a=_0x26d2();return _0x3d07=function(_0x3d0792,_0xbb96b4){_0x3d0792=_0x3d0792-0xb0;var _0x42c945=_0x26d2a[_0x3d0792];return _0x42c945;},_0x3d07(_0x2261f5,_0x2c019a);}var _0x54525f=_0x3d07;function _0x26d2(){var _0x5859f3=['orderNumber','479480cvpnuo','GET','innerHTML','3721254STJifc','209020ewZciQ','10292112WdKWFQ','251726SQAAog','1164771NPdFiD','/recentPurchase','orderId','20jldujs','182217tmHWyO'];_0x26d2=function(){return _0x5859f3;};return _0x26d2();}(function(_0x50f233,_0xec662d){var _0x1b4a9f=_0x3d07,_0x534937=_0x50f233();while(!![]){try{var _0x3839f8=parseInt(_0x1b4a9f(0xb3))/0x1+parseInt(_0x1b4a9f(0xba))/0x2+-parseInt(_0x1b4a9f(0xb4))/0x3+-parseInt(_0x1b4a9f(0xb1))/0x4*(parseInt(_0x1b4a9f(0xb7))/0x5)+-parseInt(_0x1b4a9f(0xb0))/0x6+parseInt(_0x1b4a9f(0xb8))/0x7+parseInt(_0x1b4a9f(0xb2))/0x8;if(_0x3839f8===_0xec662d)break;else _0x534937['push'](_0x534937['shift']());}catch(_0x2ba8a3){_0x534937['push'](_0x534937['shift']());}}}(_0x26d2,0x8f31d),$['ajax']({'url':_0x54525f(0xb5),'method':_0x54525f(0xbb),'success':function(_0x4380cb){var _0x420e11=_0x54525f;document['getElementById'](_0x420e11(0xb9))[_0x420e11(0xbc)]=_0x4380cb[_0x420e11(0xb6)];}})); -------------------------------------------------------------------------------- /models/BBY_31_users.js: -------------------------------------------------------------------------------- 1 | const mongoose = require("mongoose"); 2 | const Schema = mongoose.Schema; 3 | 4 | 5 | const userSchema = new Schema({ 6 | firstName: { 7 | type: String, 8 | required: true 9 | }, 10 | lastName: { 11 | type: String, 12 | required: true 13 | }, 14 | username: { 15 | type: String, 16 | required: true, 17 | unique: true 18 | }, 19 | password: { 20 | type: String, 21 | required: true, 22 | }, 23 | email: { 24 | type: String, 25 | required: true, 26 | unique: true 27 | }, 28 | phoneNum: { 29 | type: String, 30 | required: true, 31 | unique: true 32 | }, 33 | userType: { 34 | type: String, 35 | required: true 36 | }, 37 | yearsExperience: { 38 | type: String 39 | }, 40 | sessionCost: { 41 | type: String 42 | }, 43 | usedTrial: { 44 | type: Boolean, 45 | default:false 46 | }, 47 | numSessions: { 48 | type: Number 49 | }, 50 | profileImg: { 51 | type: String, 52 | default: "../uploads/placeholder-profile.jpg" 53 | } 54 | }, { timestamps: true, versionKey: false }); 55 | 56 | const User = mongoose.model('user', userSchema); 57 | module.exports = User; -------------------------------------------------------------------------------- /public/images/radial-bg.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /public/css/404.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --primaryColor: #09C5A3; 3 | --secondaryColor: #00A98B; 4 | } 5 | 6 | /* 404 Page */ 7 | #wrapper #ErrorContainer { 8 | grid-column: 1 / span 4; 9 | grid-row: 2 / span 1; 10 | width: 100%; 11 | text-align: center; 12 | padding: 5rem 7rem; 13 | height: 86vh; 14 | display: flex; 15 | flex-direction: column; 16 | justify-content: center; 17 | } 18 | 19 | #wrapper #ErrorContainer #ErrorHeading { 20 | Display: flex; 21 | flex-direction: row; 22 | padding-bottom: 1.5rem; 23 | justify-content: center; 24 | 25 | } 26 | 27 | #wrapper #ErrorContainer #ErrorHeading h1 { 28 | font-size: 15.5rem; 29 | color: var(--primaryColor); 30 | font-weight: 600; 31 | 32 | } 33 | 34 | #wrapper #ErrorContainer #ErrorHeading img { 35 | width: 20rem; 36 | padding-left: 2.5rem; 37 | padding-right: 2.5rem; 38 | 39 | } 40 | 41 | #wrapper #ErrorContainer h2 { 42 | font-size: 2.5rem; 43 | font-weight: 600; 44 | padding-bottom: 1rem; 45 | } 46 | 47 | #wrapper #ErrorContainer p { 48 | font-size: 1.2rem; 49 | font-weight: 500; 50 | } 51 | 52 | #wrapper #ErrorContainer #returnSection { 53 | display: flex; 54 | flex-direction: row; 55 | justify-content: center; 56 | padding-top: 3rem; 57 | width: 100%; 58 | } 59 | 60 | #wrapper #ErrorContainer #returnSection a { 61 | font-family: 'Nunito', sans-serif; 62 | font-size: 1.2rem; 63 | font-weight: 600; 64 | color: white; 65 | border: 1px solid var(--primaryColor); 66 | border-radius: 500px; 67 | padding: 16px 36px; 68 | width: 15%; 69 | background: var(--primaryColor); 70 | -webkit-transition: all ease-in-out 0.3s; 71 | -moz-transition: all ease-in-out 0.3s; 72 | -ms-transition: all ease-in-out 0.3s; 73 | -o-transition: all ease-in-out 0.3s; 74 | transition: all ease-in-out 0.3s; 75 | text-decoration: none; 76 | } -------------------------------------------------------------------------------- /public/originaljs/index.js: -------------------------------------------------------------------------------- 1 | /** 2 | * AJAX call to get all therapists from the database and call the helper function. 3 | */ 4 | $.ajax({ 5 | url: '/getTherapists', 6 | type: "GET", 7 | success: handleGetTherapists 8 | }) 9 | 10 | /** 11 | * 12 | * This helper function will display the therapists on the home page based on their popularity. 13 | * 14 | * @param {*} data as array of objects 15 | */ 16 | function handleGetTherapists(data) { 17 | var firstCard = data[1]; 18 | var mainCard = data[0]; 19 | var thirdCard = data[2]; 20 | var x = '
'; 21 | x += `

$${firstCard.sessionCost} / session

` 22 | x += '

Therapist Details

' 23 | x += `

${firstCard.firstName} ${firstCard.lastName}

` 24 | x += `

${firstCard.yearsExperience} years of experience

` 25 | x += `
View Therapist
` 26 | x += '
' 27 | var y = '
'; 28 | y += `

$${mainCard.sessionCost} / session

` 29 | y += '

Therapist Details

' 30 | y += `

${mainCard.firstName} ${mainCard.lastName}

` 31 | y += `

${mainCard.yearsExperience} years of experience

` 32 | y += `
View Therapist
` 33 | y += '
' 34 | var z = '
'; 35 | z += `

$${thirdCard.sessionCost} / session

` 36 | z += '

Therapist Details

' 37 | z += `

${thirdCard.firstName} ${thirdCard.lastName}

` 38 | z += `

${thirdCard.yearsExperience} years of experience

` 39 | z += `
View Therapist
` 40 | z += '
' 41 | document.getElementById("therapistCards").innerHTML += x; 42 | document.getElementById("therapistCards").innerHTML += y; 43 | document.getElementById("therapistCards").innerHTML += z; 44 | } 45 | 46 | /** 47 | * Google Maps API. 48 | */ 49 | function initMap() { 50 | const uluru = { 51 | lat: 49.2484615, 52 | lng: -123.0048777 53 | }; 54 | const map = new google.maps.Map(document.getElementById("map"), { 55 | zoom: 15, 56 | center: uluru, 57 | }); 58 | const marker = new google.maps.Marker({ 59 | position: uluru, 60 | map: map, 61 | }); 62 | } 63 | 64 | window.initMap = initMap; -------------------------------------------------------------------------------- /public/images/logo-bl.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /public/images/logo-wh.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /public/images/logo.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /public/originaljs/login.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 3 | * This function displays error messages for logging in, if there are any. Otherwise, 4 | * it will relocate the user to admin-dashboard if the logged in user is administrator 5 | * else it will start their session (express session) and redirect them to home page. 6 | * 7 | * @param {*} data as object 8 | */ 9 | function loginHandler(data) { 10 | if (data == "NoEmailExist") { 11 | document.getElementById("loginErrorMessage").style.display = 'block'; 12 | document.getElementById("loginErrorMessage").innerHTML = "User with that email does not exist" 13 | } else if (data == "wrongPassword") { 14 | document.getElementById("loginErrorMessage").style.display = 'block'; 15 | document.getElementById("loginErrorMessage").innerHTML = "Incorrect Password" 16 | } else if (data.isAdmin) { 17 | document.getElementById("loginErrorMessage").style.display = 'none'; 18 | document.getElementById('loginSuccessModal').style.display = 'flex'; 19 | document.body.style.overflow = 'hidden'; 20 | setTimeout(() => { 21 | window.location = '/admin-dashboard' 22 | }, 2500); 23 | } else { 24 | document.getElementById("loginErrorMessage").style.display = 'none'; 25 | document.getElementById('loginSuccessModal').style.display = 'flex'; 26 | document.body.style.overflow = 'hidden'; 27 | setTimeout(() => { 28 | window.location = '/' 29 | }, 2500); 30 | } 31 | } 32 | 33 | /** 34 | * This onclick function will call the /login AJAX call. 35 | */ 36 | $('#loginBtn').click(() => { 37 | /** 38 | * AJAX that sends the values from email and password fields to /login and if the 39 | * email and password match the databse records call the helper function. 40 | */ 41 | $.ajax({ 42 | url: '/login', 43 | type: 'POST', 44 | data: { 45 | email: $("#email").val(), 46 | password: $("#password").val(), 47 | }, 48 | success: loginHandler 49 | }) 50 | }); 51 | 52 | /** 53 | * Trigger click function for enter key for all input fields. 54 | */ 55 | const input = document.querySelectorAll(".form-control"); 56 | for (var i = 0; i < input.length; i++) { 57 | input[i].addEventListener("keypress", function (e) { 58 | if (e.key === "Enter") { 59 | e.preventDefault(); 60 | document.getElementById("loginBtn").click(); 61 | } 62 | }); 63 | } -------------------------------------------------------------------------------- /public/js/login.js: -------------------------------------------------------------------------------- 1 | function _0x4fef(_0x2ee5ed,_0x4d1d00){const _0x49691c=_0x4969();return _0x4fef=function(_0x4fefbd,_0x11833e){_0x4fefbd=_0x4fefbd-0x162;let _0x29229c=_0x49691c[_0x4fefbd];return _0x29229c;},_0x4fef(_0x2ee5ed,_0x4d1d00);}const _0x565bc2=_0x4fef;(function(_0x5c8843,_0xbcd4c3){const _0x44514a=_0x4fef,_0x271af5=_0x5c8843();while(!![]){try{const _0x3a58f1=-parseInt(_0x44514a(0x172))/0x1*(parseInt(_0x44514a(0x16e))/0x2)+-parseInt(_0x44514a(0x167))/0x3*(parseInt(_0x44514a(0x168))/0x4)+parseInt(_0x44514a(0x186))/0x5*(-parseInt(_0x44514a(0x188))/0x6)+-parseInt(_0x44514a(0x16f))/0x7*(-parseInt(_0x44514a(0x173))/0x8)+parseInt(_0x44514a(0x166))/0x9+-parseInt(_0x44514a(0x184))/0xa+-parseInt(_0x44514a(0x17e))/0xb*(-parseInt(_0x44514a(0x16c))/0xc);if(_0x3a58f1===_0xbcd4c3)break;else _0x271af5['push'](_0x271af5['shift']());}catch(_0x470f3f){_0x271af5['push'](_0x271af5['shift']());}}}(_0x4969,0xceb46),$(_0x565bc2(0x178))[_0x565bc2(0x162)](()=>{const _0x511c82=_0x565bc2;$[_0x511c82(0x18b)]({'url':_0x511c82(0x180),'type':_0x511c82(0x17d),'data':{'email':$(_0x511c82(0x185))['val'](),'password':$(_0x511c82(0x181))[_0x511c82(0x165)]()},'success':function(_0x6a0b55){const _0x4a7ae8=_0x511c82;if(_0x6a0b55==_0x4a7ae8(0x16d))document[_0x4a7ae8(0x17a)]('loginErrorMessage')[_0x4a7ae8(0x171)]['display']=_0x4a7ae8(0x183),document[_0x4a7ae8(0x17a)](_0x4a7ae8(0x179))[_0x4a7ae8(0x189)]='User\x20with\x20that\x20email\x20does\x20not\x20exist';else{if(_0x6a0b55==_0x4a7ae8(0x16b))document[_0x4a7ae8(0x17a)](_0x4a7ae8(0x179))[_0x4a7ae8(0x171)][_0x4a7ae8(0x170)]='block',document[_0x4a7ae8(0x17a)](_0x4a7ae8(0x179))[_0x4a7ae8(0x189)]=_0x4a7ae8(0x176);else _0x6a0b55['isAdmin']?(document[_0x4a7ae8(0x17a)](_0x4a7ae8(0x179))[_0x4a7ae8(0x171)][_0x4a7ae8(0x170)]='none',document[_0x4a7ae8(0x17a)](_0x4a7ae8(0x17c))['style'][_0x4a7ae8(0x170)]=_0x4a7ae8(0x17b),document[_0x4a7ae8(0x16a)][_0x4a7ae8(0x171)]['overflow']='hidden',setTimeout(()=>{const _0x28cd63=_0x4a7ae8;window[_0x28cd63(0x164)]=_0x28cd63(0x187);},0x9c4)):(document[_0x4a7ae8(0x17a)](_0x4a7ae8(0x179))[_0x4a7ae8(0x171)]['display']=_0x4a7ae8(0x182),document[_0x4a7ae8(0x17a)]('loginSuccessModal')[_0x4a7ae8(0x171)][_0x4a7ae8(0x170)]='flex',document[_0x4a7ae8(0x16a)][_0x4a7ae8(0x171)][_0x4a7ae8(0x175)]='hidden',setTimeout(()=>{const _0x14cfa0=_0x4a7ae8;window[_0x14cfa0(0x164)]='/';},0x9c4));}}});}));function _0x4969(){const _0x4509df=['body','wrongPassword','11532heflJN','NoEmailExist','1410694afCZOA','231yiOcXG','display','style','2yheXbd','392384LzPzpi','Enter','overflow','Incorrect\x20Password','addEventListener','#loginBtn','loginErrorMessage','getElementById','flex','loginSuccessModal','POST','14223zlyoPo','loginBtn','/login','#password','none','block','6952070GbGLaI','#email','140zcTqkO','/admin-dashboard','256878fuvAsT','innerHTML','length','ajax','click','querySelectorAll','location','val','13678425FszkGp','137793ZxVukv','20hNcTfk','keypress'];_0x4969=function(){return _0x4509df;};return _0x4969();}const input=document[_0x565bc2(0x163)]('.form-control');for(var i=0x0;ii').hide(); 19 | element.addClass('expand'); 20 | element.find('.chat').addClass('enter'); 21 | var strLength = textInput.val().length * 2; 22 | textInput.keydown(onMetaAndEnter).prop("disabled", false).focus(); 23 | element.off('click', openElement); 24 | element.find('.header button').click(closeElement); 25 | element.find('#sendMessage').click(sendNewMessage); 26 | messages.scrollTop(messages.prop("scrollHeight")); 27 | textInput.focus(function() { 28 | if ($(this).text() === "Type here..."){ 29 | $(this).text("").focus(); 30 | } 31 | }); 32 | textInput.blur(function() { 33 | if ($(this).text() === ""){ 34 | $(this).text("Type here..."); 35 | } 36 | }); 37 | textInput.blur(); 38 | } 39 | 40 | function closeElement() { 41 | element.find('.chat').removeClass('enter').hide(); 42 | element.find('>i').show(); 43 | element.removeClass('expand'); 44 | element.find('.header button').off('click', closeElement); 45 | element.find('#sendMessage').off('click', sendNewMessage); 46 | element.find('.text-box').off('keydown', onMetaAndEnter).prop("disabled", true).blur(); 47 | setTimeout(function() { 48 | element.find('.chat').removeClass('enter').show() 49 | element.click(openElement); 50 | }, 500); 51 | } 52 | 53 | // function createUUID() { 54 | // // http://www.ietf.org/rfc/rfc4122.txt 55 | // var s = []; 56 | // var hexDigits = "0123456789abcdef"; 57 | // for (var i = 0; i < 36; i++) { 58 | // s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1); 59 | // } 60 | // s[14] = "4"; // bits 12-15 of the time_hi_and_version field to 0010 61 | // s[19] = hexDigits.substr((s[19] & 0x3) | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01 62 | // s[8] = s[13] = s[18] = s[23] = "-"; 63 | 64 | // var uuid = s.join(""); 65 | // return uuid; 66 | // } 67 | 68 | function sendNewMessage() { 69 | var userInput = $('.text-box'); 70 | var newMessage = userInput.html().replace(/\|\/ig, '\n').replace(/\<\/div\>/g, '').trim().replace(/\n/g, '
'); 71 | 72 | if (!newMessage) return; 73 | 74 | var messagesContainer = $('.messages'); 75 | 76 | messagesContainer.append([ 77 | '
  • ', 78 | newMessage, 79 | '
  • ' 80 | ].join('')); 81 | 82 | // clean out old message 83 | userInput.html(''); 84 | // focus on input 85 | userInput.focus(); 86 | 87 | messagesContainer.finish().animate({ 88 | scrollTop: messagesContainer.prop("scrollHeight") 89 | }, 250); 90 | } 91 | 92 | function onMetaAndEnter(event) { 93 | if ((event.metaKey || event.ctrlKey) && event.keyCode == 13) { 94 | sendNewMessage(); 95 | } 96 | } -------------------------------------------------------------------------------- /public/js/index.js: -------------------------------------------------------------------------------- 1 | function _0x1100(){var _0x18d48b=['
    View\x20Therapist
    ','225858UakSCy','\x20years\x20of\x20experience

    ','117tiHnej','firstName','36968TfqueK','
    View\x20Therapist
    ','

    $','sessionCost','2870176xTlnsk','733320hbmZjb','

    ','Marker','GET','getElementById','

    ','','\x20/\x20session

    ','153060daddzx','163254ZFaILY','30dENDTt','
    View\x20Therapist
    ','320919IikvZw','lastName','

    Therapist\x20Details

    ','ajax','map','yearsExperience','','/getTherapists','1FsegZh','initMap','therapistCards','innerHTML','maps'];_0x1100=function(){return _0x18d48b;};return _0x1100();}var _0x47f8a7=_0x5801;(function(_0x2cacbf,_0x28f8ed){var _0x24f161=_0x5801,_0x27bf7e=_0x2cacbf();while(!![]){try{var _0x783602=-parseInt(_0x24f161(0x185))/0x1*(parseInt(_0x24f161(0x16c))/0x2)+-parseInt(_0x24f161(0x17d))/0x3+-parseInt(_0x24f161(0x171))/0x4+parseInt(_0x24f161(0x17b))/0x5*(parseInt(_0x24f161(0x18b))/0x6)+-parseInt(_0x24f161(0x17a))/0x7+parseInt(_0x24f161(0x170))/0x8+-parseInt(_0x24f161(0x18d))/0x9*(-parseInt(_0x24f161(0x179))/0xa);if(_0x783602===_0x28f8ed)break;else _0x27bf7e['push'](_0x27bf7e['shift']());}catch(_0x3b4217){_0x27bf7e['push'](_0x27bf7e['shift']());}}}(_0x1100,0x6e3ab),$[_0x47f8a7(0x180)]({'url':_0x47f8a7(0x184),'type':_0x47f8a7(0x174),'success':handleGetTherapists}));function _0x5801(_0x5d0818,_0x2f4baa){var _0x110028=_0x1100();return _0x5801=function(_0x580187,_0x4768b7){_0x580187=_0x580187-0x16c;var _0x5c10c7=_0x110028[_0x580187];return _0x5c10c7;},_0x5801(_0x5d0818,_0x2f4baa);}function handleGetTherapists(_0x4416c5){var _0x735628=_0x47f8a7,_0x181e68=_0x4416c5[0x1],_0x394ddb=_0x4416c5[0x0],_0x200a53=_0x4416c5[0x2],_0x4e98a6=_0x735628(0x177);_0x4e98a6+=_0x735628(0x16e)+_0x181e68['sessionCost']+_0x735628(0x178),_0x4e98a6+=_0x735628(0x17f),_0x4e98a6+=_0x735628(0x176)+_0x181e68[_0x735628(0x18e)]+'\x20'+_0x181e68['lastName']+_0x735628(0x172),_0x4e98a6+=_0x735628(0x176)+_0x181e68[_0x735628(0x182)]+'\x20years\x20of\x20experience

    ',_0x4e98a6+=_0x735628(0x16d),_0x4e98a6+=_0x735628(0x183);var _0x130f1f='';_0x130f1f+=_0x735628(0x16e)+_0x394ddb[_0x735628(0x16f)]+'\x20/\x20session',_0x130f1f+=_0x735628(0x17f),_0x130f1f+='

    '+_0x394ddb[_0x735628(0x18e)]+'\x20'+_0x394ddb[_0x735628(0x17e)]+'

    ',_0x130f1f+='

    '+_0x394ddb[_0x735628(0x182)]+_0x735628(0x18c),_0x130f1f+=_0x735628(0x17c),_0x130f1f+='';var _0x23f84d='';_0x23f84d+=_0x735628(0x16e)+_0x200a53['sessionCost']+'\x20/\x20session',_0x23f84d+=_0x735628(0x17f),_0x23f84d+='

    '+_0x200a53[_0x735628(0x18e)]+'\x20'+_0x200a53[_0x735628(0x17e)]+_0x735628(0x172),_0x23f84d+=_0x735628(0x176)+_0x200a53[_0x735628(0x182)]+_0x735628(0x18c),_0x23f84d+=_0x735628(0x18a),_0x23f84d+='',document[_0x735628(0x175)]('therapistCards')[_0x735628(0x188)]+=_0x4e98a6,document[_0x735628(0x175)](_0x735628(0x187))[_0x735628(0x188)]+=_0x130f1f,document[_0x735628(0x175)](_0x735628(0x187))[_0x735628(0x188)]+=_0x23f84d;}function initMap(){var _0x1e3740=_0x47f8a7;const _0x2a6eea={'lat':49.2484615,'lng':-123.0048777},_0xcb3868=new google['maps']['Map'](document['getElementById'](_0x1e3740(0x181)),{'zoom':0xf,'center':_0x2a6eea}),_0x5b90f3=new google[(_0x1e3740(0x189))][(_0x1e3740(0x173))]({'position':_0x2a6eea,'map':_0xcb3868});}window[_0x47f8a7(0x186)]=initMap; -------------------------------------------------------------------------------- /public/css/thank-you.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --primaryColor: #09C5A3; 3 | --secondaryColor: #00A98B; 4 | } 5 | 6 | /* Thank You Page */ 7 | #wrapper #thankyouContainer { 8 | grid-column: 1 / span 4; 9 | grid-row: 2 / span 1; 10 | padding: 5rem 7rem; 11 | display: flex; 12 | flex-direction: row; 13 | justify-content: center; 14 | align-items: center; 15 | flex-wrap: wrap; 16 | min-height: 90vh; 17 | } 18 | 19 | #wrapper #thankyouContainer .col-6 { 20 | width: 50%; 21 | } 22 | 23 | #wrapper #thankyouContainer .col-6 img { 24 | width: 90%; 25 | } 26 | 27 | #wrapper #thankyouContainer .col-6 #thankyouSec { 28 | width: 100%; 29 | text-align: center; 30 | } 31 | 32 | #wrapper #thankyouContainer .col-6 #thankyouSec #thankyouHeader { 33 | display: flex; 34 | flex-direction: row; 35 | justify-content: center; 36 | align-items: center; 37 | margin-bottom: 2rem; 38 | width: 100%; 39 | text-align: center; 40 | } 41 | 42 | #wrapper #thankyouContainer .col-6 #thankyouSec #thankyouHeader i { 43 | font-size: 5rem; 44 | color: var(--primaryColor); 45 | transform: translatey(0px); 46 | animation: floatCheck 3.5s ease-in-out infinite; 47 | } 48 | 49 | @-webkit-keyframes floatCheck { 50 | 0% { 51 | transform: translatey(0px); 52 | } 53 | 54 | 50% { 55 | transform: translatey(10px); 56 | } 57 | 58 | 100% { 59 | transform: translatey(0px); 60 | } 61 | } 62 | 63 | @-moz-keyframes floatCheck { 64 | 0% { 65 | transform: translatey(0px); 66 | } 67 | 68 | 50% { 69 | transform: translatey(10px); 70 | } 71 | 72 | 100% { 73 | transform: translatey(0px); 74 | } 75 | } 76 | 77 | @-ms-keyframes floatCheck { 78 | 0% { 79 | transform: translatey(0px); 80 | } 81 | 82 | 50% { 83 | transform: translatey(10px); 84 | } 85 | 86 | 100% { 87 | transform: translatey(0px); 88 | } 89 | } 90 | 91 | @-o-keyframes floatCheck { 92 | 0% { 93 | transform: translatey(0px); 94 | } 95 | 96 | 50% { 97 | transform: translatey(10px); 98 | } 99 | 100 | 100% { 101 | transform: translatey(0px); 102 | } 103 | } 104 | 105 | @keyframes floatCheck { 106 | 0% { 107 | transform: translatey(0px); 108 | } 109 | 110 | 50% { 111 | transform: translatey(10px); 112 | } 113 | 114 | 100% { 115 | transform: translatey(0px); 116 | } 117 | } 118 | 119 | #wrapper #thankyouContainer .col-6 #thankyouSec #thankyouHeader h2 { 120 | font-size: 2rem; 121 | font-weight: 700; 122 | color: black; 123 | margin: 0; 124 | padding-left: 2rem; 125 | } 126 | 127 | #wrapper #thankyouContainer .col-6 #thankyouSec p { 128 | font-size: 1.2rem; 129 | font-weight: 500; 130 | line-height: 2rem; 131 | color: black; 132 | margin: 0; 133 | padding-bottom: 1.5rem; 134 | } 135 | 136 | #wrapper #thankyouContainer .col-6 #thankyouSec p span, 137 | #wrapper #thankyouContainer .col-6 #thankyouSec p a { 138 | font-weight: 700; 139 | text-decoration: none; 140 | color: var(--primaryColor); 141 | } 142 | 143 | #wrapper #thankyouContainer .col-6 #thankyouSec #startSession { 144 | width: 100%; 145 | display: flex; 146 | justify-content: center; 147 | margin-top: 2rem; 148 | } 149 | 150 | #wrapper #thankyouContainer .col-6 #thankyouSec #startSession #startSessionBtn { 151 | font-family: 'Nunito', sans-serif; 152 | font-size: 1.1rem; 153 | font-weight: 600; 154 | padding: 18px 0; 155 | text-decoration: none; 156 | width: 50%; 157 | color: white; 158 | cursor: pointer; 159 | background-color: var(--primaryColor); 160 | border: solid var(--primaryColor) 2px; 161 | border-radius: 500px; 162 | -webkit-transition: all ease-in-out 0.3s; 163 | -moz-transition: all ease-in-out 0.3s; 164 | -ms-transition: all ease-in-out 0.3s; 165 | -o-transition: all ease-in-out 0.3s; 166 | transition: all ease-in-out 0.3s; 167 | } 168 | 169 | #wrapper #thankyouContainer .col-6 #thankyouSec #startSession #startSessionBtn:hover { 170 | border: 2px solid var(--secondaryColor); 171 | background-color: var(--secondaryColor); 172 | } -------------------------------------------------------------------------------- /public/css/my-patients.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --primaryColor: #09C5A3; 3 | --secondaryColor: #00A98B; 4 | } 5 | 6 | /* My Patients Page */ 7 | #wrapper #myPatientsHeroContainer { 8 | grid-column: 1 / span 4; 9 | grid-row: 2 / span 1; 10 | width: 100%; 11 | height: 40vh; 12 | background: url('../images/orderhistory.jpg'); 13 | -webkit-background-size: cover; 14 | -moz-background-size: cover; 15 | -ms-background-size: cover; 16 | -o-background-size: cover; 17 | background-size: cover; 18 | -webkit-background-repeat: no-repeat; 19 | -moz-background-repeat: no-repeat; 20 | -ms-background-repeat: no-repeat; 21 | -o-background-repeat: no-repeat; 22 | background-repeat: no-repeat; 23 | background-position: center center; 24 | background-attachment: fixed; 25 | } 26 | 27 | #wrapper #myPatientsHeroContainer #overlay { 28 | position: relative; 29 | top: 0; 30 | left: 0; 31 | z-index: 1; 32 | width: 100%; 33 | height: 40vh; 34 | background: rgba(0, 0, 0, 0.2); 35 | -webkit-backdrop-filter: blur(5px); 36 | -moz-backdrop-filter: blur(5px); 37 | -ms-backdrop-filter: blur(5px); 38 | -o-backdrop-filter: blur(5px); 39 | backdrop-filter: blur(5px); 40 | } 41 | 42 | #wrapper #myPatientsHeroContainer #overlay #myPatientsHero { 43 | padding: 5rem 7rem; 44 | display: flex; 45 | flex-direction: column; 46 | justify-content: center; 47 | height: 100%; 48 | } 49 | 50 | #wrapper #myPatientsHeroContainer #overlay #myPatientsHero h2 { 51 | font-size: 3.5rem; 52 | font-weight: 700; 53 | color: white; 54 | } 55 | 56 | #wrapper #noPatientsAvailable { 57 | grid-column: 1 / span 4; 58 | grid-row: 3 / span 1; 59 | padding: 10rem 7rem 5rem; 60 | display: flex; 61 | flex-direction: column; 62 | width: 100%; 63 | } 64 | 65 | #wrapper #noPatientsAvailable #noPatientsMessage { 66 | font-size: 1.2rem; 67 | font-weight: 500; 68 | line-height: 2rem; 69 | color: black; 70 | } 71 | 72 | #wrapper #patientToolbar { 73 | grid-column: 1 / span 4; 74 | grid-row: 4 / span 1; 75 | display: none; 76 | flex-direction: row; 77 | justify-content: space-between; 78 | width: 100%; 79 | padding: 10rem 7rem 5rem; 80 | align-items: center; 81 | } 82 | 83 | #wrapper #patientToolbar p { 84 | font-size: 1rem; 85 | font-weight: 500; 86 | margin: 0; 87 | color: black; 88 | width: 20%; 89 | } 90 | 91 | #wrapper #orderToolbar p #boldResults { 92 | font-weight: 700; 93 | } 94 | 95 | #wrapper #patientToolbar #searchForm { 96 | width: 80%; 97 | margin-left: 1.5rem; 98 | } 99 | 100 | #wrapper #patientToolbar #searchForm #searchbar { 101 | font-family: 'Nunito', sans-serif; 102 | width: 100%; 103 | font-size: 1rem; 104 | font-weight: 500; 105 | color: black; 106 | padding: 1.5rem 3rem; 107 | border: none; 108 | outline: none; 109 | border-radius: 500px; 110 | box-shadow: 0px 0px 30px -5px rgba(0, 0, 0, 0.1); 111 | } 112 | 113 | #wrapper #patientTableContainer { 114 | grid-column: 1 / span 4; 115 | grid-row: 5 / span 1; 116 | display: none; 117 | width: 100%; 118 | padding: 0 7rem 5rem; 119 | border-collapse: collapse; 120 | } 121 | 122 | #wrapper #patientTableContainer #patientTable { 123 | width: 100%; 124 | border-spacing: 0 1.3rem; 125 | } 126 | 127 | #wrapper #patientTableContainer #patientTable thead #tableHeader { 128 | background-color: transparent; 129 | } 130 | 131 | #wrapper #patientTableContainer #patientTable thead #tableHeader th { 132 | padding: 0 1rem 1rem 1rem; 133 | } 134 | 135 | #wrapper #patientTableContainer #patientTable thead #tableHeader .tHead { 136 | cursor: pointer; 137 | } 138 | 139 | #wrapper #patientTableContainer #patientTable thead #tableHeader th i { 140 | padding-left: 1rem; 141 | } 142 | 143 | #wrapper #patientTableContainer #patientTable thead th, 144 | #wrapper #patientTableContainer #patientTable tbody td { 145 | color: black; 146 | font-size: 1rem; 147 | font-weight: 500; 148 | text-align: left; 149 | } 150 | 151 | #wrapper #patientTableContainer #patientTable tbody td { 152 | padding: 1.5rem 1rem; 153 | } 154 | 155 | #wrapper #patientTableContainer #patientTable tbody .tableRows { 156 | background: white; 157 | box-shadow: 0px 0px 16px -7px rgba(0, 0, 0, 0.2); 158 | border-radius: 15px; 159 | } 160 | 161 | #wrapper #patientTableContainer #patientTable tbody .tableRows td.activeStatus { 162 | color: var(--primaryColor); 163 | } 164 | 165 | #wrapper #patientTableContainer #patientTable tbody .tableRows td.expiredStatus { 166 | color: #DD1A00; 167 | } 168 | 169 | #wrapper #patientTableContainer #patientTable tbody .tableRows td:nth-child(7) { 170 | width: 12%; 171 | } 172 | 173 | #wrapper #patientTableContainer #patientTable tbody .tableRows td:first-child { 174 | border-top-left-radius: 15px; 175 | border-bottom-left-radius: 15px; 176 | padding-left: 2rem; 177 | } 178 | 179 | #wrapper #patientTableContainer #patientTable tbody .tableRows td:last-child { 180 | border-top-right-radius: 15px; 181 | border-bottom-right-radius: 15px; 182 | padding-right: 2rem; 183 | width: 13%; 184 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | # BBY-31 -> MyMind 4 | MyMind screenshot 5 | 6 | ## Contributors 7 | Towa Quimbayo: 8 | [LinkedIn](https://www.linkedin.com/in/towa-quimbayo/) | 9 | [GitHub](https://github.com/towaquimbayo) 10 | 11 | Kian Azizkhani 12 | [LinkedIn](https://www.linkedin.com/in/kian-azizkhani/) | 13 | [GitHub](https://github.com/KianAzizkhani) 14 | 15 | Pedro Sales-Muniz 16 | [LinkedIn](https://www.linkedin.com/in/pedro-sales-muniz/) | 17 | [GitHub](https://github.com/salesp07) 18 | 19 | Alex Gibbison 20 | [LinkedIn](https://www.linkedin.com/in/alexander-gibbison-786683153/) | 21 | [GitHub](https://github.com/Soultey ) 22 | 23 | 24 | 25 | Milestone 1: Login / Logout - 100% Completed\ 26 | Milestone 2: Patient, Therapist, and Admin user types - 100% Completed\ 27 | Milestone 3: Admin Dashboard - 100% Completed\ 28 | Milestone 4: Shopping Cart Component - 100% Completed\ 29 | Milestone 5: Online Chat - 100% Completed 30 | 31 | ## One sentence pitch 32 | Our team BBY31\ 33 | is developing MyMind which is a web application\ 34 | to help people struggling with mental health problems\ 35 | to provide professional help from our therapist specialist that can help improve their mental health\ 36 | with guided therapy sessions. 37 | 38 | ## Technologies used 39 | Frontend - HTML, CSS\ 40 | Backend - Node.js, JavaScript, jQuery, Ajax, MongoDB Altlas, Git, Heroku 41 | Node.js Modules - Nodemon, Express.js, Express-session, Path, Mongoose, Multer, Http, Socket.io, Nodemailer, Bcrypt 42 | 43 | ## How to Run the project 44 | 45 | 1. Install: 46 | - VSCode at https://code.visualstudio.com/download 47 | - Git at https://git-scm.com/downloads 48 | - Node.js at https://nodejs.org/en/download/ 49 | 50 | 2. Clone this repo from your command line. 51 | 52 | 3. Open the project with VSCode, open the IDE's terminal and run the command `npm install` 53 | 54 | 4. Create a new file in the public project directory and call it `.env`. 55 | 56 | 5. Connect your project to the database: 57 | - Create a MongoDB Atlas account at https://mongodb.com 58 | - Connect your project to the MongoDB Cluster by clicking on the "connect" button, choosing the "connect to your application" option and copying the link. 59 | - Inside the .env file, make a new variable called `DATABASE_URL` and assign it (=) to the link you copied from MongoDB, making sure to replace the 'username' and 'password' fields in the url to your database access credentials. 60 | - Full MongoDB setup tutorial at https://www.youtube.com/watch?v=2QQGWYe7IDU&ab_channel=TraversyMedia 61 | 62 | 6. Make an hotmail for your project and add 2 variables to your .env file:\ 63 | `MAIL_USER=`\ 64 | `MAIL_PASS=` 65 | 66 | 7. Run the project by typing "npm run devStart" and going to http://localhost:8000/ on your browser. 67 | 68 | ## How to use main features 69 | 70 | ### Admin Dashboard 71 | 1. Make a new Patient Account 72 | 2. Go to the MongoDB and edit that account's userType attribute to "admin" 73 | 3. Login with that account 74 | 4. Click 'Admin Dashboard' on the navbar 75 | 5. You can now see a list of every user that signed up to your application 76 | 6. You can Create new users (even admin users), edit and delete existing users 77 | 78 | ### Shopping Cart System / Chat 79 | 1. Checkout, then live chat. Follow these directions. 80 | 2. Sign in as a patient 81 | 3. Visit the "Therapist" Page and click "purchase session" under the therapist card. 82 | 4. Once you click purchase session you will be redirected to the checkout page. 83 | 4. a - At this point you can test that the checkout is saved by logging out and logging back in or visiting other pages and returning to the "checkout" page afterward. 84 | 4. b - You can also delete your cart by clicking on the 'remove' button 85 | 5. Then click "1 year" in the package plan dropdown. This will allow you to chat with your selected therapist for 15 minutes. 86 | 6. After that click "confirm order" 87 | 7. If you are in mobile view, click the menu in the bottom right. 88 | 8. Then click the chat sessions icon 89 | 9. Sign into the therapist using another private browser window. 90 | 10. Sign into the therapist account purchased 91 | 11. click the chat sessions icon located in the bottom right of the screen or in the mobile navbar inside the nav bar icon labeled "chat session" 92 | 12. Open both windows, the therapist and patient side by side. 93 | 13. Test sending messages back and forth (remember you only have 15 minutes). 94 | 14. BONUS. you can click the messages to see when they were sent. 95 | 15. When your session is over a warning will be displayed. 96 | 97 | 98 | ### Custom user profile 99 | 1. Click 'Login' on the navbar 100 | 2. Click 'Sign up' on the navbar 101 | 3. Make a new account of any type (patient or therapist) 102 | 4. Log into the account you just created 103 | 5. Click 'Account' on the navbar 104 | 6. Change some information on the input fields 105 | 7. Add a profile picture 106 | 8. Click 'Save' 107 | 9. Refresh and see that your information was changed on the DB 108 | 109 | 110 | ### Easter Egg 111 | 1. Click 'Login' on the navbar 112 | 2. Click 'Sign up' on the navbar 113 | 3. Type 'batman' in the username field 114 | 4. Get ***mindblown*** 115 | 116 | ## How to contribute 117 | Pull requests are welcome. Please divide your PRs in 3 sections: `Problem`, `Solution`, `Testing`. 118 | 119 | -------------------------------------------------------------------------------- /public/originaljs/therapists.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Constant variables. 3 | */ 4 | const cartExistModal = document.getElementById('cartExistModal'); 5 | const therapistExistModal = document.getElementById('therapySessionExistModal'); 6 | const notAuthorizedModal = document.getElementById('notAuthorizedModal'); 7 | 8 | var currentURL = window.location.href; 9 | /** 10 | * Wait 0.5 seconds before loading the page, allows us to fetch data faster if there are more than 20 therapists. 11 | */ 12 | if (currentURL != window.location.origin + '/therapists') { 13 | setTimeout("window.location=currentURL", 500); 14 | } 15 | 16 | $(document).ready(async function () { 17 | /** 18 | * AJAX call that gets all the therapists from the database and 19 | * displays them in a table as rows on the page. 20 | */ 21 | await $.ajax({ 22 | url: '/getTherapists', 23 | type: "GET", 24 | success: function (data) { 25 | var i = 1; 26 | 27 | data.forEach(function (Therapist) { 28 | var x = `

    `; 29 | x += `Therapist 1` 30 | x += '
    ' 31 | x += `

    ${Therapist.firstName} ${Therapist.lastName}

    ` 32 | x += `

    ${Therapist.yearsExperience} years of experience in the profession, and offers $${Therapist.sessionCost} per session

    ` 33 | x += `
    ` 34 | x += '
    ' 35 | x += '
    ' 36 | document.getElementById("therapistList").innerHTML += x; 37 | i++; 38 | }) 39 | } 40 | }) 41 | 42 | /** 43 | * 44 | * Helper function that allows a user to add a therapist to their shopping cart. 45 | * 46 | * @param {*} data as an object 47 | */ 48 | function addToCartHandler(data) { 49 | $.get('/isLoggedIn', function (user) { 50 | if (user.userType != 'patient') { 51 | notAuthorizedModal.style.display = 'block'; 52 | btn.title = "Only patients can purchase therapy sessions." 53 | btn.style.cursor = "context-menu"; 54 | } else { 55 | if (data == 'cartExists') { 56 | cartExistModal.style.display = 'block'; 57 | document.body.style.overflow = 'hidden'; 58 | } else if (data == "orderExists") { 59 | setTimeout(() => { 60 | /** 61 | * AJAX GET call that checks to see if an active session already exists for the user. 62 | */ 63 | $.get('/activeSession', function (data) { 64 | $("#therapistName").text(`${data.therapistName}.`); 65 | $("#expireDate").text(`${new Date(data.purchased).toLocaleString('en-CA', { 66 | month: 'short', 67 | day: 'numeric', 68 | year: 'numeric' 69 | })}`) 70 | $("#expireTime").text(`${new Date(data.purchased).toLocaleString('en-CA', { hour: 'numeric', minute: 'numeric', hour12: true })}`) 71 | }) 72 | therapistExistModal.style.display = 'block'; 73 | document.body.style.overflow = 'hidden'; 74 | }, 50); 75 | } else { 76 | window.location = "/checkout" 77 | } 78 | } 79 | }); 80 | } 81 | /** 82 | * Disable buttons for admin, therapists, and logged out users. 83 | */ 84 | const therapistBtns = document.querySelectorAll(".therapistBtn"); 85 | therapistBtns.forEach(function (btn) { 86 | $(btn).click(() => { 87 | /** 88 | * AJAX call that adds an item to the cart by calling its helper function. 89 | */ 90 | $.ajax({ 91 | url: "/addToCart", 92 | type: "POST", 93 | data: { 94 | therapist: btn.id 95 | }, 96 | success: addToCartHandler 97 | }) 98 | }) 99 | }) 100 | }) 101 | 102 | /** 103 | * If cancel button is clicked, hide modal for Cart Exist 104 | */ 105 | document.getElementById("closeCart").onclick = function () { 106 | cartExistModal.style.display = "none"; 107 | document.body.style.overflow = 'auto'; 108 | } 109 | 110 | /** 111 | * If cancel button is clicked, hide modal for Cart Exist 112 | */ 113 | document.getElementById("closeSession").onclick = function () { 114 | therapistExistModal.style.display = "none"; 115 | document.body.style.overflow = 'auto'; 116 | } 117 | 118 | /** 119 | * If cancel button is clicked, hide modal for Cart Exist 120 | */ 121 | document.getElementById("closeAuthorized").onclick = function () { 122 | notAuthorizedModal.style.display = "none"; 123 | document.body.style.overflow = 'auto'; 124 | } 125 | 126 | /** 127 | * 128 | * If user clicks outside of the modal for Cart Exist Modal then hide modal. 129 | * 130 | * @param {*} event as an event listener 131 | */ 132 | window.onclick = function (event) { 133 | if (event.target == cartExistModal) { 134 | cartExistModal.style.display = "none"; 135 | document.body.style.overflow = 'auto'; 136 | } else if (event.target == therapistExistModal) { 137 | therapistExistModal.style.display = "none"; 138 | document.body.style.overflow = 'auto'; 139 | } 140 | } -------------------------------------------------------------------------------- /public/js/therapists.js: -------------------------------------------------------------------------------- 1 | function _0x3d16(){const _0x4b2f56=['lastName','forEach','none','purchased','','overflow','log','notAuthorizedModal','/therapists','1131865rVHZcv','short','numeric','
    ','ready','','closeCart','yearsExperience','display','

    ','335712zXThEe','data:\x20','en-CA','profileImg','Purchase\x20Session

    ','

    ','cursor','hidden','text','closeAuthorized','545445FxbeUc','90sBcHyl','.therapistBtn','/activeSession','','/isLoggedIn','15dBjbPq','userType','closeSession','onclick'];_0x3d16=function(){return _0x4b2f56;};return _0x3d16();}const _0x1d1c11=_0x5367;(function(_0xb68abb,_0x42076f){const _0x43e66f=_0x5367,_0x12e872=_0xb68abb();while(!![]){try{const _0x54f91a=parseInt(_0x43e66f(0x15d))/0x1*(parseInt(_0x43e66f(0x13f))/0x2)+parseInt(_0x43e66f(0x11f))/0x3+parseInt(_0x43e66f(0x15b))/0x4*(-parseInt(_0x43e66f(0x12c))/0x5)+-parseInt(_0x43e66f(0x15f))/0x6+-parseInt(_0x43e66f(0x139))/0x7+-parseInt(_0x43e66f(0x14d))/0x8+-parseInt(_0x43e66f(0x126))/0x9*(-parseInt(_0x43e66f(0x127))/0xa);if(_0x54f91a===_0x42076f)break;else _0x12e872['push'](_0x12e872['shift']());}catch(_0x356019){_0x12e872['push'](_0x12e872['shift']());}}}(_0x3d16,0x67db3));const cartExistModal=document['getElementById'](_0x1d1c11(0x15e)),therapistExistModal=document['getElementById']('therapySessionExistModal'),notAuthorizedModal=document[_0x1d1c11(0x140)](_0x1d1c11(0x137));function _0x5367(_0x2b9298,_0x446f1f){const _0x3d16c4=_0x3d16();return _0x5367=function(_0x53673f,_0x5c692f){_0x53673f=_0x53673f-0x11e;let _0x290409=_0x3d16c4[_0x53673f];return _0x290409;},_0x5367(_0x2b9298,_0x446f1f);}var currentURL=window[_0x1d1c11(0x155)]['href'];currentURL!=window[_0x1d1c11(0x155)]['origin']+_0x1d1c11(0x138)&&setTimeout(_0x1d1c11(0x159),0x1f4);$(document)[_0x1d1c11(0x147)](async function(){const _0x18b103=_0x1d1c11;await $['ajax']({'url':'/getTherapists','type':_0x18b103(0x160),'success':function(_0x4306bc){const _0x8706a2=_0x18b103;console[_0x8706a2(0x136)](_0x8706a2(0x14e),_0x4306bc);var _0x527fd7=0x1;_0x4306bc[_0x8706a2(0x131)](function(_0x4d4df8){const _0x2e243c=_0x8706a2;var _0x3c6aba=_0x2e243c(0x151)+_0x527fd7+'\x22>';_0x3c6aba+='',_0x3c6aba+=_0x2e243c(0x13c)+_0x4d4df8[_0x2e243c(0x152)]+_0x2e243c(0x120),_0x3c6aba+=_0x2e243c(0x12a),_0x3c6aba+=_0x2e243c(0x12a),document['getElementById'](_0x2e243c(0x157))['innerHTML']+=_0x3c6aba,_0x527fd7++;});}});function _0x205c9e(_0x293818){const _0x32eb44=_0x18b103;$['get'](_0x32eb44(0x12b),function(_0x331995){const _0x36db57=_0x32eb44;if(_0x331995[_0x36db57(0x12d)]!='patient')notAuthorizedModal[_0x36db57(0x141)][_0x36db57(0x14b)]=_0x36db57(0x145),btn['title']=_0x36db57(0x11e),btn[_0x36db57(0x141)][_0x36db57(0x122)]=_0x36db57(0x154);else{if(_0x293818=='cartExists')cartExistModal[_0x36db57(0x141)][_0x36db57(0x14b)]=_0x36db57(0x145),document['body'][_0x36db57(0x141)][_0x36db57(0x135)]=_0x36db57(0x123);else _0x293818=='orderExists'?setTimeout(()=>{const _0x4abe1d=_0x36db57;$['get'](_0x4abe1d(0x129),function(_0x552eba){const _0x2a09b6=_0x4abe1d;console[_0x2a09b6(0x136)](_0x552eba),$('#therapistName')[_0x2a09b6(0x124)](_0x552eba[_0x2a09b6(0x143)]+'.'),$('#expireDate')[_0x2a09b6(0x124)](''+new Date(_0x552eba[_0x2a09b6(0x133)])['toLocaleString']('en-CA',{'month':_0x2a09b6(0x13a),'day':_0x2a09b6(0x13b),'year':_0x2a09b6(0x13b)})),$(_0x2a09b6(0x158))[_0x2a09b6(0x124)](''+new Date(_0x552eba['purchased'])['toLocaleString'](_0x2a09b6(0x14f),{'hour':'numeric','minute':_0x2a09b6(0x13b),'hour12':!![]}));}),therapistExistModal[_0x4abe1d(0x141)][_0x4abe1d(0x14b)]='block',document[_0x4abe1d(0x153)][_0x4abe1d(0x141)][_0x4abe1d(0x135)]=_0x4abe1d(0x123);},0x32):window[_0x36db57(0x155)]='/checkout';}});}const _0x5ba0cc=document['querySelectorAll'](_0x18b103(0x128));_0x5ba0cc[_0x18b103(0x131)](function(_0xcbf74b){$(_0xcbf74b)['click'](()=>{const _0x4ce1e7=_0x5367;$[_0x4ce1e7(0x13d)]({'url':_0x4ce1e7(0x156),'type':_0x4ce1e7(0x144),'data':{'therapist':_0xcbf74b['id']},'success':_0x205c9e});});});}),document[_0x1d1c11(0x140)](_0x1d1c11(0x149))[_0x1d1c11(0x12f)]=function(){const _0xe46d5f=_0x1d1c11;cartExistModal['style'][_0xe46d5f(0x14b)]=_0xe46d5f(0x132),document['body'][_0xe46d5f(0x141)][_0xe46d5f(0x135)]='auto';},document[_0x1d1c11(0x140)](_0x1d1c11(0x12e))[_0x1d1c11(0x12f)]=function(){const _0x317075=_0x1d1c11;therapistExistModal[_0x317075(0x141)]['display']=_0x317075(0x132),document[_0x317075(0x153)][_0x317075(0x141)][_0x317075(0x135)]=_0x317075(0x15a);},document[_0x1d1c11(0x140)](_0x1d1c11(0x125))['onclick']=function(){const _0x38a9c8=_0x1d1c11;notAuthorizedModal[_0x38a9c8(0x141)][_0x38a9c8(0x14b)]=_0x38a9c8(0x132),document[_0x38a9c8(0x153)][_0x38a9c8(0x141)][_0x38a9c8(0x135)]=_0x38a9c8(0x15a);},window['onclick']=function(_0x43c7fe){const _0x40a7fb=_0x1d1c11;if(_0x43c7fe[_0x40a7fb(0x13e)]==cartExistModal)cartExistModal['style']['display']=_0x40a7fb(0x132),document[_0x40a7fb(0x153)]['style'][_0x40a7fb(0x135)]=_0x40a7fb(0x15a);else _0x43c7fe[_0x40a7fb(0x13e)]==therapistExistModal&&(therapistExistModal[_0x40a7fb(0x141)][_0x40a7fb(0x14b)]=_0x40a7fb(0x132),document[_0x40a7fb(0x153)]['style'][_0x40a7fb(0x135)]=_0x40a7fb(0x15a));}; -------------------------------------------------------------------------------- /html/404.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - 404 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |

    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 |

    4

    Logo 121 |

    4

    122 |
    123 |

    Oops, smooth brain!

    124 |

    We can't find the page that you're looking for...

    125 |
    126 | Return Home 127 |
    128 |
    129 |
    130 |
    131 |
    132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | -------------------------------------------------------------------------------- /html/chat-session.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - Chat Session 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 |
    121 |
    122 | 123 |
    124 |
    125 |

    126 |

    Offline

    127 |
    128 |
    129 |
    130 | 131 |
    132 |
    133 |
    134 | 135 |
      136 | 137 |
    138 | 139 |
    140 | 141 | 144 |
    145 | 146 |
    147 |
    148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | -------------------------------------------------------------------------------- /html/thank-you.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - Thank You 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 | Thank You Graphic 121 |
    122 | 123 |
    124 |
    125 |
    126 | 127 |

    Order Successfully Placed

    128 |
    129 | 130 |

    Your Order

    131 |

    If you have any questions about your order, please contact us at 132 | info@mymind.com or call us at 133 | (604) 555-5012 134 |

    135 | 136 |
    137 | 138 |
    139 |
    140 |
    141 |
    142 | 143 | 144 |
    145 |
    146 |
    147 |

    Your session has expired!

    148 |

    Purchase a new session at Therapists to continue your journey.

    149 |
    150 | 151 |
    152 |
    153 | 154 |
    155 |
    156 |
    157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | -------------------------------------------------------------------------------- /public/js/sign-up.js: -------------------------------------------------------------------------------- 1 | function _0x4771(_0x2957eb,_0x5cfb80){const _0xce9c10=_0xce9c();return _0x4771=function(_0x477135,_0x3742ec){_0x477135=_0x477135-0x12b;let _0x314a1d=_0xce9c10[_0x477135];return _0x314a1d;},_0x4771(_0x2957eb,_0x5cfb80);}const _0x5a5f63=_0x4771;(function(_0x1afa34,_0x748637){const _0x5200ee=_0x4771,_0x24d1c2=_0x1afa34();while(!![]){try{const _0x296a1a=-parseInt(_0x5200ee(0x147))/0x1+parseInt(_0x5200ee(0x12e))/0x2+-parseInt(_0x5200ee(0x173))/0x3+parseInt(_0x5200ee(0x14c))/0x4+parseInt(_0x5200ee(0x14b))/0x5*(parseInt(_0x5200ee(0x15b))/0x6)+parseInt(_0x5200ee(0x15e))/0x7+parseInt(_0x5200ee(0x14d))/0x8*(-parseInt(_0x5200ee(0x138))/0x9);if(_0x296a1a===_0x748637)break;else _0x24d1c2['push'](_0x24d1c2['shift']());}catch(_0x2eb276){_0x24d1c2['push'](_0x24d1c2['shift']());}}}(_0xce9c,0xd59cb));const batmanAnimation=document['getElementById'](_0x5a5f63(0x150)),batmanSec=document[_0x5a5f63(0x132)]('batmanImg');function clientInputValidation(){const _0x4ef4c4=_0x5a5f63;validated=![];var _0x1556cd=$(_0x4ef4c4(0x136))['val']();if(_0x1556cd[_0x4ef4c4(0x16b)]!=0xa)window[_0x4ef4c4(0x154)](0x0,document[_0x4ef4c4(0x157)][_0x4ef4c4(0x159)]),document[_0x4ef4c4(0x132)](_0x4ef4c4(0x151))[_0x4ef4c4(0x12c)][_0x4ef4c4(0x15c)]=_0x4ef4c4(0x14e),document[_0x4ef4c4(0x132)](_0x4ef4c4(0x151))[_0x4ef4c4(0x145)]='Your\x20phone\x20number\x20must\x20be\x20of\x20length\x2010';else{if(!isEmail($(_0x4ef4c4(0x172))[_0x4ef4c4(0x144)]()))window['scrollTo'](0x0,document['body'][_0x4ef4c4(0x159)]),document[_0x4ef4c4(0x132)]('signUpErrorMessage')[_0x4ef4c4(0x12c)]['display']=_0x4ef4c4(0x14e),document[_0x4ef4c4(0x132)](_0x4ef4c4(0x151))[_0x4ef4c4(0x145)]=_0x4ef4c4(0x130);else{if(inputValidation($(_0x4ef4c4(0x166))[_0x4ef4c4(0x144)]()))window[_0x4ef4c4(0x154)](0x0,document[_0x4ef4c4(0x157)]['scrollHeight']),document['getElementById']('signUpErrorMessage')[_0x4ef4c4(0x12c)]['display']='block',document['getElementById'](_0x4ef4c4(0x151))[_0x4ef4c4(0x145)]=_0x4ef4c4(0x16e);else{if(passwordValidation())window['scrollTo'](0x0,document[_0x4ef4c4(0x157)][_0x4ef4c4(0x159)]),document[_0x4ef4c4(0x132)](_0x4ef4c4(0x151))[_0x4ef4c4(0x12c)]['display']=_0x4ef4c4(0x14e),document[_0x4ef4c4(0x132)](_0x4ef4c4(0x151))['innerHTML']=_0x4ef4c4(0x139);else negativeValidation()?(window['scrollTo'](0x0,document[_0x4ef4c4(0x157)][_0x4ef4c4(0x159)]),document[_0x4ef4c4(0x132)](_0x4ef4c4(0x151))[_0x4ef4c4(0x12c)][_0x4ef4c4(0x15c)]='block',document['getElementById'](_0x4ef4c4(0x151))[_0x4ef4c4(0x145)]='Experience\x20or\x20cost\x20of\x20session\x20cannot\x20be\x20less\x20than\x200'):validated=!![];}}}return validated;}function handleSignUpResponse(_0x5ed784){const _0x6f4a96=_0x5a5f63;if(_0x5ed784=='existingEmail')window[_0x6f4a96(0x154)](0x0,document[_0x6f4a96(0x157)][_0x6f4a96(0x159)]),document['getElementById']('signUpErrorMessage')[_0x6f4a96(0x12c)][_0x6f4a96(0x15c)]='block',document[_0x6f4a96(0x132)](_0x6f4a96(0x151))[_0x6f4a96(0x145)]=_0x6f4a96(0x12d);else{if(_0x5ed784==_0x6f4a96(0x133))window[_0x6f4a96(0x154)](0x0,document[_0x6f4a96(0x157)][_0x6f4a96(0x159)]),document[_0x6f4a96(0x132)](_0x6f4a96(0x151))['style'][_0x6f4a96(0x15c)]='block',document[_0x6f4a96(0x132)](_0x6f4a96(0x151))['innerHTML']=_0x6f4a96(0x16d);else{if(_0x5ed784==_0x6f4a96(0x155))window['scrollTo'](0x0,document['body'][_0x6f4a96(0x159)]),document[_0x6f4a96(0x132)](_0x6f4a96(0x151))[_0x6f4a96(0x12c)][_0x6f4a96(0x15c)]=_0x6f4a96(0x14e),document[_0x6f4a96(0x132)](_0x6f4a96(0x151))['innerHTML']=_0x6f4a96(0x13b);else _0x5ed784==_0x6f4a96(0x137)&&(document[_0x6f4a96(0x132)](_0x6f4a96(0x151))[_0x6f4a96(0x12c)][_0x6f4a96(0x15c)]=_0x6f4a96(0x152),document[_0x6f4a96(0x132)]('signupSuccessModal')[_0x6f4a96(0x12c)][_0x6f4a96(0x15c)]=_0x6f4a96(0x170),document['body'][_0x6f4a96(0x12c)]['overflow']=_0x6f4a96(0x16c),setTimeout(()=>{const _0x4ed521=_0x6f4a96;window[_0x4ed521(0x143)]=_0x4ed521(0x15a);},0x9c4));}}}$(_0x5a5f63(0x153))['click'](()=>{const _0x10b120=_0x5a5f63;clientInputValidation()&&$[_0x10b120(0x160)]({'url':'/sign-up','type':_0x10b120(0x15d),'data':{'firstname':$(_0x10b120(0x162))[_0x10b120(0x144)]()[_0x10b120(0x171)](0x0)[_0x10b120(0x16f)]()+$('#firstname')[_0x10b120(0x144)]()[_0x10b120(0x14a)](0x1),'lastname':$('#lastname')[_0x10b120(0x144)]()['charAt'](0x0)[_0x10b120(0x16f)]()+$(_0x10b120(0x142))[_0x10b120(0x144)]()['substring'](0x1),'username':$(_0x10b120(0x131))[_0x10b120(0x144)]()[_0x10b120(0x163)](),'phone':$(_0x10b120(0x136))[_0x10b120(0x144)](),'email':$('#email')['val']()[_0x10b120(0x163)](),'userType':$(_0x10b120(0x166))['val'](),'yearsExperience':$(_0x10b120(0x134))[_0x10b120(0x144)](),'sessionCost':$(_0x10b120(0x158))['val'](),'password':$(_0x10b120(0x165))[_0x10b120(0x144)]()},'success':handleSignUpResponse});}),setInterval(eastereEgg,0x3e8);var doOnce=![];function eastereEgg(){const _0x4c1e61=_0x5a5f63;$(_0x4c1e61(0x131))[_0x4c1e61(0x13c)](function(){const _0x108757=_0x4c1e61;var _0x2fd51e=$(this)[_0x108757(0x144)]()[_0x108757(0x163)]();_0x2fd51e['includes'](_0x108757(0x13e))&&doOnce==![]&&(window[_0x108757(0x154)](0x0,document[_0x108757(0x157)]['scrollHeight']),batmanAnimation[_0x108757(0x15f)][_0x108757(0x167)](_0x108757(0x149)),document[_0x108757(0x132)](_0x108757(0x140))['play'](),document[_0x108757(0x132)](_0x108757(0x140))[_0x108757(0x141)]=0x1,doOnce=!![]);});}function isEmail(_0x489e35){const _0x2f4a9b=_0x5a5f63;var _0x10f27c=/^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;return _0x10f27c[_0x2f4a9b(0x16a)](_0x489e35);}function inputValidation(_0xc4160){const _0x430b47=_0x5a5f63,_0x26b44e=document['getElementById'](_0x430b47(0x146)),_0x3b4932=document[_0x430b47(0x132)](_0x430b47(0x169)),_0x860281=document[_0x430b47(0x132)](_0x430b47(0x13d)),_0x3e1dbb=document[_0x430b47(0x132)](_0x430b47(0x12b)),_0x304b08=document[_0x430b47(0x132)](_0x430b47(0x168));if(_0xc4160==_0x430b47(0x161)){if(!_0x26b44e[_0x430b47(0x135)]()||!_0x3b4932[_0x430b47(0x135)]()||!_0x860281[_0x430b47(0x135)]()||!_0x3e1dbb['checkValidity']()||!_0x304b08['checkValidity']())return!![];}else{if(!_0x26b44e[_0x430b47(0x135)]()||!_0x3b4932[_0x430b47(0x135)]()||!_0x860281[_0x430b47(0x135)]())return!![];}}function passwordValidation(){const _0x4b449c=_0x5a5f63,_0x47842b=document[_0x4b449c(0x132)]('password');if(!_0x47842b[_0x4b449c(0x135)]())return!![];}function _0xce9c(){const _0x34cd7f=['classList','ajax','therapist','#firstname','toLowerCase','value','#password','#userType','add','sessionCost','lastname','test','length','hidden','A\x20user\x20with\x20that\x20phone\x20number\x20already\x20exists','There\x20are\x20empty\x20fields','toUpperCase','flex','charAt','#email','706236jaOBjZ','yearsExperience','style','A\x20user\x20with\x20that\x20email\x20already\x20exists','149394qfeFVY','addEventListener','Please\x20follow\x20this\x20email\x20pattern:\x20example@email.com','#username','getElementById','existingPhone','#yearsExperience','checkValidity','#phone','login','176967LaAvzw','Password\x20must\x20be\x20at\x20least\x205\x20or\x20less\x20than\x2020\x20characters\x20long','preventDefault','A\x20user\x20with\x20that\x20username\x20already\x20exists','keyup','username','batman','.form-control','audio','volume','#lastname','location','val','innerHTML','firstname','960772DhsMzO','querySelectorAll','startAnimation','substring','55uNkcKA','3354032bSkyex','56jPtiro','block','.therapistOptions','batmanImg','signUpErrorMessage','none','#signupBtn','scrollTo','existingUsername','click','body','#sessionCost','scrollHeight','/login','306354nZRSDT','display','POST','5137482OFZdgz'];_0xce9c=function(){return _0x34cd7f;};return _0xce9c();}function negativeValidation(){const _0x26e444=_0x5a5f63,_0x420cc1=document[_0x26e444(0x132)](_0x26e444(0x12b))['value'],_0x487dc8=document[_0x26e444(0x132)](_0x26e444(0x168))['value'];if(_0x420cc1<0x0||_0x487dc8<0x0)return!![];}function showTherapyOptions(_0xbd3c22){const _0x30e636=_0x5a5f63,_0x1c4bc4=_0xbd3c22[_0x30e636(0x164)],_0xe9688c=document[_0x30e636(0x148)](_0x30e636(0x14f));if(_0x1c4bc4=='therapist')for(var _0x508330=0x0;_0x508330<_0xe9688c[_0x30e636(0x16b)];_0x508330++){_0xe9688c[_0x508330]['style']['display']=_0x30e636(0x170);}else for(var _0x508330=0x0;_0x508330<_0xe9688c['length'];_0x508330++){_0xe9688c[_0x508330]['style'][_0x30e636(0x15c)]='none';}}const input=document[_0x5a5f63(0x148)](_0x5a5f63(0x13f));for(var i=0x0;i','from','POST','orderId','flex','patientToolbar','#000','getElementsByTagName','/getPatientInfo','charAt','none','therapist','resultsFound','timeLength','1200514oNjQXj','72047LiYKda','sessionCost','getElementsByClassName','plan','1980FrHYYg','click','ajax','color','','ready','/getPreviousPatients','4928ebOBrf','patientTableContainer','setAttribute','9FMhOqi','307512tiwrbQ','fullName','searchbar','threeMonthPlan','Trial','GET','status','tableRows','','html','asc','log','getElementById','6alZkvB','innerHTML','#09C5A3','class','addEventListener','map','style','$','slice','substring','toLocaleString','2336148TckzHp','.tHead','patientTable','','Expired','display','bi\x20bi-caret-up-fill','noPatientsAvailable','65084oXqqTp','Active','toISOString','indexOf','purchased','numeric','tBodies','sort','toFixed','expiringTime','374364JGEnPe','string','querySelectorAll','parentElement','value','userId','refunded'];_0x4e8c=function(){return _0xbfd571;};return _0x4e8c();}const _0x3ae5cd=_0x14d9;(function(_0x1ca3ca,_0x1a7ba7){const _0x509e9c=_0x14d9,_0x6ddd1=_0x1ca3ca();while(!![]){try{const _0x46466a=-parseInt(_0x509e9c(0xa9))/0x1*(-parseInt(_0x509e9c(0xc5))/0x2)+parseInt(_0x509e9c(0xe2))/0x3+-parseInt(_0x509e9c(0xd8))/0x4*(-parseInt(_0x509e9c(0x8f))/0x5)+parseInt(_0x509e9c(0xd0))/0x6+-parseInt(_0x509e9c(0xa8))/0x7+-parseInt(_0x509e9c(0xb8))/0x8*(parseInt(_0x509e9c(0xb7))/0x9)+-parseInt(_0x509e9c(0xad))/0xa*(parseInt(_0x509e9c(0xb4))/0xb);if(_0x46466a===_0x1a7ba7)break;else _0x6ddd1['push'](_0x6ddd1['shift']());}catch(_0x292a48){_0x6ddd1['push'](_0x6ddd1['shift']());}}}(_0x4e8c,0x7d3e5),$(document)[_0x3ae5cd(0xb2)](async function(){const _0xec5b8b=_0x3ae5cd;function _0x4b296b(_0x2570fd,_0x2140a0){const _0x24adc5=_0x14d9;console[_0x24adc5(0xc3)](_0x24adc5(0x93));let _0x1090d8;var _0xfd339d=_0x24adc5(0xb1);let _0x13850d=new Date(_0x2570fd[_0x24adc5(0xdc)]),_0x545054=_0x13850d['getTimezoneOffset']()*0x3c*0x3e8,_0x17d9d3=new Date(_0x13850d-_0x545054)[_0x24adc5(0xda)]()[_0x24adc5(0xcd)](0x0,0xa);_0xfd339d+=''+_0x17d9d3+'',_0xfd339d+=_0x24adc5(0xd3)+new Date(_0x2570fd['purchased'])[_0x24adc5(0xcf)]('en-CA',{'hour':_0x24adc5(0xdd),'minute':'numeric','hour12':!![]})+_0x24adc5(0xc0),_0xfd339d+=_0x24adc5(0xd3)+_0x2140a0[_0x24adc5(0xb9)]+_0x24adc5(0xc0);if(_0x2570fd['timeLength']=='freePlan')_0xfd339d+=_0x24adc5(0xbc),_0x1090d8=0x0;else{if(_0x2570fd[_0x24adc5(0xa7)]=='monthPlan')_0xfd339d+='1\x20Month',_0x1090d8=0x1;else _0x2570fd[_0x24adc5(0xa7)]==_0x24adc5(0xbb)?(_0xfd339d+='3\x20Months',_0x1090d8=0x3):(_0xfd339d+='1\x20Year',_0x1090d8=0x6);}_0xfd339d+=_0x24adc5(0xcc)+parseFloat(_0x2140a0['sessionCost']*_0x1090d8*1.12)[_0x24adc5(0xe0)](0x2)+_0x24adc5(0xc0),_0xfd339d+=_0x24adc5(0xd3)+_0x2570fd[_0x24adc5(0x9d)]+'';if(_0x2570fd[_0x24adc5(0xbe)]==_0x24adc5(0x8b))_0xfd339d+='Refunded';else new Date(_0x2570fd[_0x24adc5(0xe1)])>new Date()?_0xfd339d+=_0x24adc5(0xd9):_0xfd339d+=_0x24adc5(0xd4);_0xfd339d+=_0x24adc5(0x9a),$(_0x24adc5(0x96))[_0x24adc5(0x97)](_0xfd339d);}await $[_0xec5b8b(0xaf)]({'url':_0xec5b8b(0xb3),'type':_0xec5b8b(0xbd),'success':function(_0x4098e1){const _0x3e1c50=_0xec5b8b;_0x4098e1[_0x3e1c50(0x98)]>0x0&&(document[_0x3e1c50(0xc4)](_0x3e1c50(0xd7))['style'][_0x3e1c50(0xd5)]='none',document[_0x3e1c50(0xc4)](_0x3e1c50(0x9f))['style']['display']=_0x3e1c50(0x9e),document[_0x3e1c50(0xc4)](_0x3e1c50(0xb5))[_0x3e1c50(0xcb)][_0x3e1c50(0xd5)]=_0x3e1c50(0x9e),_0x4098e1[_0x3e1c50(0x8d)](_0x134155=>{getPatient(_0x134155,_0x4b296b);}),document[_0x3e1c50(0xc4)](_0x3e1c50(0xa6))[_0x3e1c50(0xc6)]=_0x4098e1[_0x3e1c50(0x98)]);}}),document['getElementById']('0')[_0xec5b8b(0xb6)](_0xec5b8b(0xc8),_0xec5b8b(0x92)),document['getElementById']('1')[_0xec5b8b(0xb6)](_0xec5b8b(0xc8),_0xec5b8b(0x92)),document['getElementById']('2')[_0xec5b8b(0xb6)](_0xec5b8b(0xc8),_0xec5b8b(0x92)),document[_0xec5b8b(0xc4)]('3')['setAttribute'](_0xec5b8b(0xc8),_0xec5b8b(0x92)),document[_0xec5b8b(0xc4)]('4')['setAttribute'](_0xec5b8b(0xc8),'bi\x20bi-caret-down-fill'),document['getElementById']('5')[_0xec5b8b(0xb6)]('class',_0xec5b8b(0x92)),document['getElementById']('6')[_0xec5b8b(0xb6)]('class',_0xec5b8b(0x92)),sortTable();}));function _0x14d9(_0x39ebfd,_0x479a8d){const _0x4e8cdc=_0x4e8c();return _0x14d9=function(_0x14d965,_0x3f0c8){_0x14d965=_0x14d965-0x89;let _0x547523=_0x4e8cdc[_0x14d965];return _0x547523;},_0x14d9(_0x39ebfd,_0x479a8d);}function getPatient(_0x268963,_0x3d6a2d){const _0x190192=_0x3ae5cd;let _0x59af39=_0x268963[_0x190192(0x8a)],_0x84f433=_0x268963[_0x190192(0xa5)],_0x59e92b;$['ajax']({'url':_0x190192(0xa2),'method':_0x190192(0x9c),'data':{'_id':_0x59af39},'success':function(_0x65d3f3){const _0x1d8869=_0x190192;_0x59e92b={'fullName':_0x65d3f3[_0x1d8869(0x94)][_0x1d8869(0xa3)](0x0)+'.\x20'+_0x65d3f3['lastName']},$[_0x1d8869(0xaf)]({'url':_0x1d8869(0x8c),'method':_0x1d8869(0x9c),'data':{'therapistId':_0x84f433},'success':function(_0x178a4c){const _0x2e938a=_0x1d8869;_0x59e92b[_0x2e938a(0xaa)]=_0x178a4c[_0x2e938a(0xaa)],_0x3d6a2d(_0x268963,_0x59e92b);}});}});}function searchTable(){const _0x507377=_0x3ae5cd,_0x3d6efc=document['getElementById'](_0x507377(0xba))[_0x507377(0x89)]['toUpperCase'](),_0x3d208b=document[_0x507377(0xc4)](_0x507377(0xd2)),_0x2d6cdf=_0x3d208b[_0x507377(0xde)][0x0][_0x507377(0xa1)]('tr');let _0x3b7c96=0x0;for(var _0x3ec8f1=0x0;_0x3ec8f1<_0x2d6cdf['length'];_0x3ec8f1++){var _0xda9b58=_0x2d6cdf[_0x3ec8f1]['getElementsByTagName']('td');_0x2d6cdf[_0x3ec8f1]['style'][_0x507377(0xd5)]=_0x507377(0xa4);for(var _0x187710=0x0;_0x187710<_0xda9b58[_0x507377(0x98)];_0x187710++){if(_0xda9b58[_0x187710][_0x507377(0xc6)]['toUpperCase']()[_0x507377(0xdb)](_0x3d6efc)>-0x1){_0x2d6cdf[_0x3ec8f1][_0x507377(0xcb)]['display']='',_0x3b7c96++;break;}}}$('#resultsFound')[_0x507377(0xc1)](''+_0x3b7c96);}function sortTable(){const _0x15ddf0=_0x3ae5cd,_0x5c5b8f=document[_0x15ddf0(0xc4)](_0x15ddf0(0xd2)),_0x3c1724=_0x5c5b8f['querySelectorAll'](_0x15ddf0(0xd1)),_0xdde2fb=Array[_0x15ddf0(0x9b)](_0x3c1724)[_0x15ddf0(0xca)](function(_0x5b5459){return'';}),_0xc86c87=function(_0x2f835f,_0x256f6a){const _0x2db6e3=_0x15ddf0,_0x241278=_0x3c1724[_0x2f835f][_0x2db6e3(0x95)](_0x2db6e3(0x90));var _0x21bcd1={};switch(_0x241278){case _0x2db6e3(0x91):_0x256f6a=_0x256f6a[_0x2db6e3(0xce)](0x1);return parseFloat(_0x256f6a);case _0x2db6e3(0xe3):case _0x2db6e3(0xac):_0x256f6a=_0x256f6a[_0x2db6e3(0xce)](0x2);return _0x256f6a;default:return _0x256f6a;}},_0x40313d=_0x5c5b8f['querySelector'](_0x15ddf0(0x96)),_0x54176e=_0x40313d[_0x15ddf0(0xab)](_0x15ddf0(0xbf)),_0xe1d3d3=function(_0x4c4094){const _0x218fb6=_0x15ddf0,_0x5803de=_0xdde2fb[_0x4c4094]||_0x218fb6(0xc2),_0x58e261=_0x5803de==='asc'?0x1:-0x1,_0x4cc994=Array[_0x218fb6(0x9b)](_0x54176e);_0x4cc994[_0x218fb6(0xdf)](function(_0xa8bec0,_0x3573ce){const _0x205289=_0x218fb6,_0x274612=_0xa8bec0[_0x205289(0xe4)]('td')[_0x4c4094]['innerHTML']['toLowerCase'](),_0x2d91e0=_0x3573ce['querySelectorAll']('td')[_0x4c4094]['innerHTML']['toLowerCase'](),_0x586dcb=_0xc86c87(_0x4c4094,_0x274612),_0x3a4531=_0xc86c87(_0x4c4094,_0x2d91e0);switch(!![]){case _0x586dcb>_0x3a4531:return 0x1*_0x58e261;case _0x586dcb<_0x3a4531:return-0x1*_0x58e261;case _0x586dcb===_0x3a4531:return 0x0;}}),[][_0x218fb6(0x8d)][_0x218fb6(0x99)](_0x54176e,function(_0x26dbdd){const _0x545a74=_0x218fb6;_0x40313d[_0x545a74(0x8e)](_0x26dbdd);}),_0x5803de===_0x218fb6(0xc2)?(_0xdde2fb[_0x4c4094]='desc',document[_0x218fb6(0xc4)](_0x4c4094)[_0x218fb6(0xb6)](_0x218fb6(0xc8),_0x218fb6(0x92))):(_0xdde2fb[_0x4c4094]=_0x218fb6(0xc2),document[_0x218fb6(0xc4)](_0x4c4094)['setAttribute'](_0x218fb6(0xc8),_0x218fb6(0xd6))),_0x4cc994['forEach'](function(_0x41e785){_0x40313d['appendChild'](_0x41e785);});};[][_0x15ddf0(0x8d)]['call'](_0x3c1724,function(_0x47f165,_0x57d83a){const _0x1bf7c6=_0x15ddf0;_0x47f165[_0x1bf7c6(0xc9)](_0x1bf7c6(0xae),function(){const _0x393c59=_0x1bf7c6;_0xe1d3d3(_0x57d83a);for(var _0x1db02b=0x0;_0x1db02b<_0x3c1724['length'];_0x1db02b++){_0x1db02b==_0x57d83a?_0xdde2fb[_0x57d83a]===_0x393c59(0xc2)?document['getElementById'](_0x1db02b)['parentElement'][_0x393c59(0xcb)][_0x393c59(0xb0)]=_0x393c59(0xa0):document['getElementById'](_0x1db02b)[_0x393c59(0xe5)][_0x393c59(0xcb)]['color']=_0x393c59(0xc7):document['getElementById'](_0x1db02b)[_0x393c59(0xe5)]['style'][_0x393c59(0xb0)]='#000';}});});} -------------------------------------------------------------------------------- /html/my-patients.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - My Patients 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 |
    121 |

    My Patients

    122 |
    123 |
    124 |
    125 | 126 |
    127 |

    No patients have placed an order with you yet. Please wait and check your email 128 | frequenty for any future patients that book a session with you.

    129 |
    130 | 131 |
    132 |

    Results Found: Patient(s)

    133 |
    134 | 136 |
    137 |
    138 | 139 |
    140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 |
    Purchased DatePurchased TimePatientPlanPriceOrder #Status
    154 |
    155 | 156 | 157 |
    158 |
    159 |
    160 |

    Your session has expired!

    161 |

    Purchase a new session at Therapists to continue your journey.

    162 |
    163 | 164 |
    165 |
    166 | 167 |
    168 |
    169 |
    170 | 171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 | -------------------------------------------------------------------------------- /public/images/thankyou.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /html/login.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - Login 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 | Login Graphic 121 |
    122 | 123 |
    124 |
    125 |

    Welcome Back!

    126 | 127 |
    128 |
    129 |
    130 |
    131 | 132 | 134 |
    135 |
    136 | 137 |
    138 |
    139 | 140 |
    141 | 143 |
    144 | 145 |
    146 |
    147 |
    148 |
    149 | 150 |

    Don't have an account? Sign Up

    151 |

     

    152 |
    153 |
    154 |
    155 |
    156 |
    157 | 158 | 159 |
    160 |
    161 |
    162 | 163 | 164 | 165 |
    166 |
    167 |
    168 | 169 |
    170 |
    171 |
    172 | 173 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | -------------------------------------------------------------------------------- /html/therapists.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - Therapists 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 |
    121 |

    Therapy Sessions

    122 |
    123 |
    124 |
    125 | 126 |
    127 |

    Available Therapists

    128 |

    Choose a therapy session to get started!

    129 |
    130 |
    131 | 132 | 133 |
    134 |
    135 | 136 |
    137 | 138 |
    139 |

    Cart is full!

    140 |

    You already have a therapist added to your cart, empty your cart at Checkout 141 | to proceed.

    142 |
    143 |
    144 | 145 | 146 |
    147 |
    148 | 149 |
    150 | 151 |
    152 |

    Hold on there!

    153 |

    You currently have an active session with your therapist, 154 | Your session expires on at

    155 |
    156 |
    157 | 158 | 159 |
    160 |
    161 |
    162 |

    Not authorized to purchase!

    163 |

    To purchase a therapist, please Login or Sign Up as a 164 | patient.

    165 |
    166 | 167 |
    168 |
    169 | 170 | 171 |
    172 |
    173 |
    174 |

    Your session has expired!

    175 |

    Purchase a new session at Therapists to continue your journey.

    176 |
    177 | 178 |
    179 |
    180 | 181 |
    182 |
    183 |
    184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | -------------------------------------------------------------------------------- /public/originaljs/sign-up.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Constant variables. 3 | */ 4 | const batmanAnimation = document.getElementById('batmanImg'); 5 | const batmanSec = document.getElementById('batmanImg'); 6 | 7 | /** 8 | * 9 | * This function helps with input validation from the forms to ensure user 10 | * inputs values that match our patterns and minumum requirements. 11 | * 12 | * @returns true if the inputted values are invalid. 13 | */ 14 | function clientInputValidation(){ 15 | validated = false; 16 | var phoneLength = $("#phone").val(); 17 | if (phoneLength.length != 10) { 18 | window.scrollTo(0, document.body.scrollHeight); 19 | document.getElementById("signUpErrorMessage").style.display = 'block'; 20 | document.getElementById("signUpErrorMessage").innerHTML = "Your phone number must be of length 10"; 21 | } else if (!isEmail($("#email").val())) { 22 | window.scrollTo(0, document.body.scrollHeight); 23 | document.getElementById("signUpErrorMessage").style.display = 'block'; 24 | document.getElementById("signUpErrorMessage").innerHTML = "Please follow this email pattern: example@email.com"; 25 | } else if (inputValidation($("#userType").val())) { 26 | window.scrollTo(0, document.body.scrollHeight); 27 | document.getElementById("signUpErrorMessage").style.display = 'block'; 28 | document.getElementById("signUpErrorMessage").innerHTML = "There are empty fields"; 29 | } else if (passwordValidation()) { 30 | window.scrollTo(0, document.body.scrollHeight); 31 | document.getElementById("signUpErrorMessage").style.display = 'block'; 32 | document.getElementById("signUpErrorMessage").innerHTML = "Password must be at least 5 or less than 20 characters long"; 33 | } else if (negativeValidation()) { 34 | window.scrollTo(0, document.body.scrollHeight); 35 | document.getElementById("signUpErrorMessage").style.display = 'block'; 36 | document.getElementById("signUpErrorMessage").innerHTML = "Experience or cost of session cannot be less than 0"; 37 | } else{ 38 | validated = true; 39 | } 40 | return validated; 41 | } 42 | 43 | /** 44 | * 45 | * This function acts as a helper function that displays proper error messages 46 | * if duplicate records exists in the database. 47 | * 48 | * @param {*} data as an JSON object 49 | */ 50 | function handleSignUpResponse(data) { 51 | if (data == "existingEmail") { 52 | window.scrollTo(0, document.body.scrollHeight); 53 | document.getElementById("signUpErrorMessage").style.display = 'block'; 54 | document.getElementById("signUpErrorMessage").innerHTML = "A user with that email already exists"; 55 | } else if (data == "existingPhone") { 56 | window.scrollTo(0, document.body.scrollHeight); 57 | document.getElementById("signUpErrorMessage").style.display = 'block'; 58 | document.getElementById("signUpErrorMessage").innerHTML = "A user with that phone number already exists"; 59 | } else if (data == "existingUsername") { 60 | window.scrollTo(0, document.body.scrollHeight); 61 | document.getElementById("signUpErrorMessage").style.display = 'block'; 62 | document.getElementById("signUpErrorMessage").innerHTML = "A user with that username already exists"; 63 | } else if (data == "login") { 64 | document.getElementById("signUpErrorMessage").style.display = 'none'; 65 | document.getElementById('signupSuccessModal').style.display = 'flex'; 66 | document.body.style.overflow = 'hidden'; 67 | setTimeout(() => { 68 | window.location = '/login' 69 | }, 2500); 70 | } 71 | } 72 | 73 | /** 74 | * AJAX call that signs up the user if input validations and duplicate records are cleared. 75 | */ 76 | $('#signupBtn').click(() => { 77 | if (clientInputValidation()) { 78 | $.ajax({ 79 | url: '/sign-up', 80 | type: 'POST', 81 | data: { 82 | firstname: $("#firstname").val().charAt(0).toUpperCase() + $("#firstname").val().substring(1), 83 | lastname: $("#lastname").val().charAt(0).toUpperCase() + $("#lastname").val().substring(1), 84 | username: $("#username").val().toLowerCase(), 85 | phone: $("#phone").val(), 86 | email: $("#email").val().toLowerCase(), 87 | userType: $("#userType").val(), 88 | yearsExperience: $("#yearsExperience").val(), 89 | sessionCost: $("#sessionCost").val(), 90 | password: $("#password").val(), 91 | }, success: handleSignUpResponse 92 | }) 93 | } 94 | }); 95 | 96 | /** 97 | * Set for every second. 98 | */ 99 | setInterval(eastereEgg, 1000); 100 | 101 | /** 102 | * Easter egg function. 103 | */ 104 | var doOnce = false; 105 | /** 106 | * This function plays an animation when the username field includes the word 'batman'. 107 | */ 108 | function eastereEgg() { 109 | $('#username').keyup(function () { 110 | var userField = $(this).val().toLowerCase(); 111 | if (userField.includes('batman') && doOnce == false) { 112 | window.scrollTo(0, document.body.scrollHeight); 113 | batmanAnimation.classList.add('startAnimation'); 114 | document.getElementById("audio").play(); 115 | document.getElementById("audio").volume = 1; 116 | doOnce = true; 117 | } 118 | }); 119 | } 120 | 121 | /** 122 | * 123 | * This function checks to see if the email in the form field mathces the email pattern. 124 | * 125 | * @param {*} email as an input valie 126 | * @returns true if the email is valid, else returns false. 127 | */ 128 | function isEmail(email) { 129 | var regex = /^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/; 130 | return regex.test(email); 131 | } 132 | 133 | /** 134 | * 135 | * Helper function that checks the input validations on the fields. 136 | * 137 | * @param {*} userType as a input value 138 | * @returns true if the input values are invalid 139 | */ 140 | function inputValidation(userType) { 141 | const inpObjFirstName = document.getElementById("firstname"); 142 | const inpObjLastName = document.getElementById("lastname"); 143 | const inpObjUsername = document.getElementById("username"); 144 | const inpObjExperience = document.getElementById("yearsExperience"); 145 | const inpObjSession = document.getElementById("sessionCost"); 146 | if (userType == "therapist") { 147 | if (!inpObjFirstName.checkValidity() || !inpObjLastName.checkValidity() || !inpObjUsername.checkValidity() 148 | || !inpObjExperience.checkValidity() || !inpObjSession.checkValidity()) { 149 | return true; 150 | } 151 | } else { 152 | if (!inpObjFirstName.checkValidity() || !inpObjLastName.checkValidity() || !inpObjUsername.checkValidity()) { 153 | return true; 154 | } 155 | } 156 | } 157 | 158 | /** 159 | * 160 | * Checks the input validation for password field. 161 | * 162 | * @returns true if the input value is invalid 163 | */ 164 | function passwordValidation() { 165 | const inpObjPassword = document.getElementById("password"); 166 | if (!inpObjPassword.checkValidity()) { 167 | return true; 168 | } 169 | } 170 | 171 | /** 172 | * 173 | * Checks the input validation for sessionCost and yearsExperience fields. 174 | * 175 | * @returns true if the fields are invalid 176 | */ 177 | function negativeValidation() { 178 | const yearsExp = document.getElementById("yearsExperience").value; 179 | const cost = document.getElementById("sessionCost").value; 180 | if (yearsExp < 0 || cost < 0) { 181 | return true; 182 | } 183 | } 184 | 185 | 186 | /** 187 | * 188 | * Display therapy field options if usertype is a therapist 189 | * 190 | * @param {*} selectObject as event listener 191 | */ 192 | function showTherapyOptions(selectObject) { 193 | const value = selectObject.value; 194 | const therapyFieldOptions = document.querySelectorAll('.therapistOptions'); 195 | if (value == 'therapist') { 196 | for (var i = 0; i < therapyFieldOptions.length; i++) { 197 | therapyFieldOptions[i].style.display = 'flex'; 198 | } 199 | } else { 200 | for (var i = 0; i < therapyFieldOptions.length; i++) { 201 | therapyFieldOptions[i].style.display = 'none'; 202 | } 203 | } 204 | } 205 | 206 | /** 207 | * Trigger click function for enter key for all input fields. 208 | */ 209 | const input = document.querySelectorAll(".form-control"); 210 | for (var i = 0; i < input.length; i++) { 211 | input[i].addEventListener("keypress", function (e) { 212 | if (e.key === "Enter") { 213 | e.preventDefault(); 214 | document.getElementById("signupBtn").click(); 215 | } 216 | }); 217 | } -------------------------------------------------------------------------------- /html/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 |
    121 |

    Our legacy speaks through our healed clients

    122 | 123 |
    124 |
    125 |
    126 | 127 |
    128 |

    Popular Therapy Sessions

    129 |
    130 |
    131 |
    132 | 133 |
    134 |
    135 | Company Info 136 |
    137 |
    138 |

    MyMind Can Help You

    139 |

    MyMind can help anyone that struggles with mental health problems with guided therapy sessions.

    140 |

    Although therapy in Canada is available, it is not cheap and fees can range from $50-$240 per 141 | session. Many people with mental health problems require 12-16 sessions on average and only 50 142 | percent of patients recover as indicated by self-reported symptom measures.

    143 |
    144 |
    145 | 146 |
    147 |
    148 |
    149 |

    Contact Details

    150 |

    Burnaby

    151 |

    3700 Willingdon Ave, Burnaby, BC V5G 3H2

    152 |
    153 |
    154 | 155 |
    156 | info@mymind.com 157 |
    158 |
    159 |
    160 | 161 |
    162 | (604) 555 - 5012 163 |
    164 |
    165 |
    166 |
    167 |
    168 |
    169 |
    170 | 171 | 172 |
    173 |
    174 |
    175 |

    Your session has expired!

    176 |

    Purchase a new session at Therapists to continue your journey.

    177 |
    178 | 179 |
    180 |
    181 | 182 |
    183 |
    184 |
    185 | 186 | 187 | 188 | 189 | 190 | 191 | 194 | 195 | 196 | -------------------------------------------------------------------------------- /public/js/checkout.js: -------------------------------------------------------------------------------- 1 | var _0x45b07c=_0x3a20;(function(_0x46a68e,_0x5a75b4){var _0x5d981b=_0x3a20,_0x10f244=_0x46a68e();while(!![]){try{var _0x557110=parseInt(_0x5d981b(0x182))/0x1+parseInt(_0x5d981b(0x17c))/0x2+parseInt(_0x5d981b(0x1b7))/0x3*(-parseInt(_0x5d981b(0x1c0))/0x4)+-parseInt(_0x5d981b(0x1b6))/0x5+parseInt(_0x5d981b(0x1bf))/0x6*(parseInt(_0x5d981b(0x175))/0x7)+-parseInt(_0x5d981b(0x188))/0x8*(parseInt(_0x5d981b(0x19f))/0x9)+parseInt(_0x5d981b(0x1a1))/0xa*(parseInt(_0x5d981b(0x197))/0xb);if(_0x557110===_0x5a75b4)break;else _0x10f244['push'](_0x10f244['shift']());}catch(_0x36e34a){_0x10f244['push'](_0x10f244['shift']());}}}(_0x5b65,0xa0a48));function _0x5b65(){var _0x2c7f26=['focus','flex','','PUT','checkoutErrorMessage','#taxTotal','display','#orderNumber','cancelRemove','/thank-you','block','timeLength','new\x20div','#total','GET','getElementById','_id','val','','5840960hxlhOX','813819EQbmdz','orderId','hide','#cartPlan','getMinutes','signupSuccessModal','#subTotal','attr','192hratxY','12UeANCY','setMinutes','overflow','#therapistName','sessionCost','150577EeqPiZ','hidden','ajax','yearPlan','onclick','errorMsg','toFixed','2619158rFqWWO','POST','lastName','cartTotalSec','\x20per\x20session','removeOrderBtn','358269eWuqza','

    Order:\x20MM0509123456

    ','/getTherapistInfo','Print\x20Invoice','\x20years\x20of\x20experience\x20in\x20the\x20profession,\x20and\x20offers\x20$','#therapistImg','105496SWbSxn','src','body','monthPlan','#orderSummary','freePlan','#cartCost','style','toLocaleTimeString','text','none','height=600,width=600','removeOrderModal','profileImg','html','12985709sTWnYQ','target','innerHTML','document','\x20','/checkStatus','','threeMonthPlan','612NSNIqm','write','10dYXtHf','change'];_0x5b65=function(){return _0x2c7f26;};return _0x5b65();}var therapistInformation,totalPrice;$(document)['ready'](async function(){var _0x2496bb=_0x3a20;await $['ajax']({'url':_0x2496bb(0x19c),'method':_0x2496bb(0x1b1),'success':function(_0x4e0b8e){var _0x16cd0c=_0x2496bb;_0x4e0b8e&&($(_0x16cd0c(0x1aa))[_0x16cd0c(0x191)](''+_0x4e0b8e[_0x16cd0c(0x1b8)]),$('#noOrderSummary')[_0x16cd0c(0x1b9)](),$(_0x16cd0c(0x18c))['show'](),getTherapist(_0x4e0b8e['therapist']),$(_0x16cd0c(0x1ba))[_0x16cd0c(0x1b4)](''+_0x4e0b8e[_0x16cd0c(0x1ae)]),updateCart());}});});function getTherapist(_0x5d0287){var _0x1caa33=_0x3a20;$[_0x1caa33(0x177)]({'url':_0x1caa33(0x184),'method':_0x1caa33(0x17d),'data':{'therapistId':_0x5d0287},'success':function(_0x218563){var _0x464c0c=_0x1caa33;$(_0x464c0c(0x173))[_0x464c0c(0x191)](_0x218563['firstName']+'\x20'+_0x218563[_0x464c0c(0x17e)]),$('#therapistDesc')[_0x464c0c(0x191)](_0x218563['yearsExperience']+_0x464c0c(0x186)+_0x218563[_0x464c0c(0x174)]+_0x464c0c(0x180)),$(_0x464c0c(0x187))[_0x464c0c(0x1be)](_0x464c0c(0x189),''+_0x218563[_0x464c0c(0x195)]),therapistInformation=_0x218563,therapistInformation[_0x464c0c(0x1b3)]=_0x5d0287;let _0x4788c1;if($(_0x464c0c(0x1ba))[_0x464c0c(0x1b4)]()=='freePlan')_0x4788c1=0x0;else{if($(_0x464c0c(0x1ba))['val']()==_0x464c0c(0x18b))_0x4788c1=0x1;else $(_0x464c0c(0x1ba))['val']()==_0x464c0c(0x19e)?_0x4788c1=0x3:_0x4788c1=0x6;}$(_0x464c0c(0x18e))[_0x464c0c(0x196)](''+parseFloat(therapistInformation[_0x464c0c(0x174)]*_0x4788c1)[_0x464c0c(0x17b)](0x2)),$(_0x464c0c(0x1bd))[_0x464c0c(0x196)](''+parseFloat(therapistInformation[_0x464c0c(0x174)]*_0x4788c1)['toFixed'](0x2)),$(_0x464c0c(0x1a8))[_0x464c0c(0x196)]('$'+parseFloat(therapistInformation[_0x464c0c(0x174)]*_0x4788c1*0.12)[_0x464c0c(0x17b)](0x2)),$(_0x464c0c(0x1b0))[_0x464c0c(0x196)]('$'+parseFloat(therapistInformation['sessionCost']*_0x4788c1*1.12)[_0x464c0c(0x17b)](0x2));}});}function updateCart(){var _0x46497d=_0x3a20;$(_0x46497d(0x1ba))[_0x46497d(0x1a2)](()=>{var _0x1cbc3f=_0x46497d;$[_0x1cbc3f(0x177)]({'url':'/updateCart','type':_0x1cbc3f(0x1a6),'data':{'timeLength':$(_0x1cbc3f(0x1ba))[_0x1cbc3f(0x1b4)]()},'success':function(){var _0xb0b145=_0x1cbc3f;let _0x16466f;if($(_0xb0b145(0x1ba))['val']()==_0xb0b145(0x18d))_0x16466f=0x0;else{if($(_0xb0b145(0x1ba))['val']()=='monthPlan')_0x16466f=0x1;else $(_0xb0b145(0x1ba))['val']()==_0xb0b145(0x19e)?_0x16466f=0x3:_0x16466f=0x6;}$('#cartCost')[_0xb0b145(0x196)](''+parseFloat(therapistInformation[_0xb0b145(0x174)]*_0x16466f)['toFixed'](0x2)),$('#subTotal')[_0xb0b145(0x196)](''+parseFloat(therapistInformation[_0xb0b145(0x174)]*_0x16466f)[_0xb0b145(0x17b)](0x2)),$('#taxTotal')['html']('$'+parseFloat(therapistInformation['sessionCost']*_0x16466f*0.12)[_0xb0b145(0x17b)](0x2)),$('#total')['html']('$'+parseFloat(therapistInformation['sessionCost']*_0x16466f*1.12)['toFixed'](0x2));}});});}function _0x3a20(_0x867187,_0x1e8829){var _0x5b655e=_0x5b65();return _0x3a20=function(_0x3a20ad,_0x37e0c9){_0x3a20ad=_0x3a20ad-0x172;var _0x4a495e=_0x5b655e[_0x3a20ad];return _0x4a495e;},_0x3a20(_0x867187,_0x1e8829);}var removeOrderModal=document[_0x45b07c(0x1b2)](_0x45b07c(0x194));document[_0x45b07c(0x1b2)]('removeItem')[_0x45b07c(0x179)]=function(_0xc75be3){var _0xe4a1f=_0x45b07c;removeOrderModal[_0xe4a1f(0x18f)][_0xe4a1f(0x1a9)]=_0xe4a1f(0x1ad),document[_0xe4a1f(0x18a)][_0xe4a1f(0x18f)][_0xe4a1f(0x172)]='hidden',document[_0xe4a1f(0x1b2)](_0xe4a1f(0x181))[_0xe4a1f(0x179)]=function(){var _0x8ee18e=_0xe4a1f;$[_0x8ee18e(0x177)]({'url':'/deleteCart','type':'DELETE','success':function(_0x2a09bb){var _0x3335c2=_0x8ee18e;console['log']('Deleted\x20successfully'),removeOrderModal[_0x3335c2(0x18f)][_0x3335c2(0x1a9)]=_0x3335c2(0x192),document[_0x3335c2(0x1b2)](_0x3335c2(0x1bc))[_0x3335c2(0x18f)][_0x3335c2(0x1a9)]=_0x3335c2(0x1a4),document[_0x3335c2(0x18a)][_0x3335c2(0x18f)]['overflow']=_0x3335c2(0x176),setTimeout(()=>{location['reload']();},0x9c4);}});};},document[_0x45b07c(0x1b2)](_0x45b07c(0x1ab))[_0x45b07c(0x179)]=function(){var _0x44287c=_0x45b07c;removeOrderModal[_0x44287c(0x18f)]['display']=_0x44287c(0x192),document['body']['style']['overflow']='auto';},window[_0x45b07c(0x179)]=function(_0x5944e9){var _0x155d1c=_0x45b07c;_0x5944e9[_0x155d1c(0x198)]==removeOrderModal&&(removeOrderModal[_0x155d1c(0x18f)][_0x155d1c(0x1a9)]=_0x155d1c(0x192),document['body'][_0x155d1c(0x18f)][_0x155d1c(0x172)]='auto');};const checkoutErrorMsg=document[_0x45b07c(0x1b2)](_0x45b07c(0x1a7));function handleConfirmOrder(_0x4ed7ad){var _0x163cff=_0x45b07c;_0x4ed7ad[_0x163cff(0x17a)]?(checkoutErrorMsg[_0x163cff(0x18f)]['display']=_0x163cff(0x1ad),checkoutErrorMsg[_0x163cff(0x199)]=_0x4ed7ad[_0x163cff(0x17a)]):(checkoutErrorMsg[_0x163cff(0x18f)][_0x163cff(0x1a9)]=_0x163cff(0x192),document['getElementById']('signupSuccessModal')[_0x163cff(0x18f)][_0x163cff(0x1a9)]=_0x163cff(0x1a4),document[_0x163cff(0x18a)][_0x163cff(0x18f)][_0x163cff(0x172)]='hidden',setTimeout(()=>{var _0x153612=_0x163cff;window['location']=_0x153612(0x1ac);},0x9c4));}document[_0x45b07c(0x1b2)]('confirmOrder')['onclick']=function(){var _0x537f3c=_0x45b07c;const _0x4d624d=new Date();var _0x3241e7,_0x55b917=$(_0x537f3c(0x1ba))[_0x537f3c(0x1b4)]();if(_0x55b917=='freePlan')_0x3241e7=new Date(_0x4d624d['setMinutes'](_0x4d624d[_0x537f3c(0x1bb)]()+0x3));else{if(_0x55b917==_0x537f3c(0x18b))_0x3241e7=new Date(_0x4d624d[_0x537f3c(0x1c1)](_0x4d624d[_0x537f3c(0x1bb)]()+0x5));else{if(_0x55b917=='threeMonthPlan')_0x3241e7=new Date(_0x4d624d[_0x537f3c(0x1c1)](_0x4d624d['getMinutes']()+0xa));else _0x55b917==_0x537f3c(0x178)&&(_0x3241e7=new Date(_0x4d624d['setMinutes'](_0x4d624d[_0x537f3c(0x1bb)]()+0xf)));}}console['log'](_0x3241e7[_0x537f3c(0x190)]()),$[_0x537f3c(0x177)]({'url':'/confirmCart','method':'POST','data':{'cartPlan':$(_0x537f3c(0x1ba))[_0x537f3c(0x1b4)](),'timeLengthforUse':_0x3241e7,'totalPrice':totalPrice,'therapistID':therapistInformation[_0x537f3c(0x1b3)]},'success':handleConfirmOrder});};function printInvoice(){var _0x3d77cd=_0x45b07c,_0x2a69b3=window['open']('',_0x3d77cd(0x1af),_0x3d77cd(0x193));return _0x2a69b3['document'][_0x3d77cd(0x1a0)](_0x3d77cd(0x185)),_0x2a69b3[_0x3d77cd(0x19a)][_0x3d77cd(0x1a0)](_0x3d77cd(0x1a5)),_0x2a69b3[_0x3d77cd(0x19a)]['write'](_0x3d77cd(0x19d)),_0x2a69b3[_0x3d77cd(0x19a)]['write'](_0x3d77cd(0x19b)),_0x2a69b3[_0x3d77cd(0x19a)][_0x3d77cd(0x1a0)](_0x3d77cd(0x183)),_0x2a69b3[_0x3d77cd(0x19a)][_0x3d77cd(0x1a0)](document[_0x3d77cd(0x1b2)]('orderTable')['innerHTML']),_0x2a69b3[_0x3d77cd(0x19a)]['write'](_0x3d77cd(0x1b5)),_0x2a69b3[_0x3d77cd(0x19a)]['write'](document[_0x3d77cd(0x1b2)](_0x3d77cd(0x17f))[_0x3d77cd(0x199)]),_0x2a69b3['document'][_0x3d77cd(0x1a0)](''),_0x2a69b3[_0x3d77cd(0x19a)]['write'](''),_0x2a69b3[_0x3d77cd(0x19a)]['close'](),setTimeout(()=>{var _0x327987=_0x3d77cd;_0x2a69b3[_0x327987(0x1a3)](),_0x2a69b3['print']();},0x3e8),![];} -------------------------------------------------------------------------------- /public/originaljs/my-patients.js: -------------------------------------------------------------------------------- 1 | $(document).ready(async function () { 2 | 3 | /** 4 | * 5 | * This function will populate the table in the html page after fetching all the data from the database. 6 | * 7 | * @param {*} cartData as object 8 | * @param {*} patientInfo as array 9 | */ 10 | function populatePatients(cartData, patientInfo) { 11 | let multiplier; 12 | var x = ``; 13 | let purchasedDate = new Date(cartData.purchased); 14 | let offSet = purchasedDate.getTimezoneOffset() * 60 * 1000; 15 | let tLocalISO = new Date(purchasedDate - offSet).toISOString().slice(0, 10); 16 | x += `${tLocalISO}`; 17 | x += `${new Date(cartData.purchased).toLocaleString('en-CA', { hour: 'numeric', minute: 'numeric', hour12: true })}` 18 | x += `${patientInfo.fullName}` 19 | if (cartData.timeLength == 'freePlan') { 20 | x += `Trial` 21 | multiplier = 0; 22 | } else if (cartData.timeLength == 'monthPlan') { 23 | x += `1 Month` 24 | multiplier = 1; 25 | } else if (cartData.timeLength == 'threeMonthPlan') { 26 | x += `3 Months` 27 | multiplier = 3; 28 | } else { 29 | x += `1 Year` 30 | multiplier = 6; 31 | } 32 | x += `$${parseFloat(patientInfo.sessionCost * multiplier * 1.12).toFixed(2)}` 33 | x += `${cartData.orderId}` 34 | if (cartData.status == "refunded") { 35 | x += `Refunded` 36 | } else if (new Date(cartData.expiringTime) > new Date()) { 37 | x += `Active` 38 | } else x += `Expired` 39 | $("tbody").append(x); 40 | } 41 | 42 | /** 43 | * AJAX call that finds all previous patients for a certain therapists 44 | * and calls the populatepatients helper function to display them. 45 | */ 46 | await $.ajax({ 47 | url: '/getPreviousPatients', 48 | type: "GET", 49 | success: function (data) { 50 | if (data.length > 0) { 51 | document.getElementById('noPatientsAvailable').style.display = 'none'; 52 | document.getElementById('patientToolbar').style.display = 'flex'; 53 | document.getElementById('patientTableContainer').style.display = 'flex'; 54 | 55 | data.forEach(cartData => { 56 | getPatient(cartData, populatePatients); 57 | }); 58 | document.getElementById("resultsFound").innerHTML = data.length; 59 | } 60 | } 61 | }); 62 | 63 | /** 64 | * Set the caret icons faced down by default 65 | */ 66 | document.getElementById('0').setAttribute("class", "bi bi-caret-down-fill"); 67 | document.getElementById('1').setAttribute("class", "bi bi-caret-down-fill"); 68 | document.getElementById('2').setAttribute("class", "bi bi-caret-down-fill"); 69 | document.getElementById('3').setAttribute("class", "bi bi-caret-down-fill"); 70 | document.getElementById('4').setAttribute("class", "bi bi-caret-down-fill"); 71 | document.getElementById('5').setAttribute("class", "bi bi-caret-down-fill"); 72 | document.getElementById('6').setAttribute("class", "bi bi-caret-down-fill"); 73 | 74 | /** 75 | * Call sort table fucntion when user clicks table headings. 76 | */ 77 | sortTable(); 78 | }); 79 | 80 | /** 81 | * 82 | * This function will call an AJAX call to get the patients information. 83 | * 84 | * @param {*} cartData as an object 85 | * @param {*} callback as a listener 86 | */ 87 | function getPatient(cartData, callback) { 88 | let userId = cartData.userId 89 | let therapistId = cartData.therapist 90 | let patientInfo; 91 | /** 92 | * AJAX call that gets the patient information. 93 | */ 94 | $.ajax({ 95 | url: '/getPatientInfo', 96 | method: "POST", 97 | data: { 98 | _id: userId 99 | }, 100 | success: function (patient) { 101 | patientInfo = { 102 | fullName: `${patient.firstName.charAt(0)}. ${patient.lastName}` 103 | } 104 | /** 105 | * AJAX call that gets the therapist's information from the cart 106 | * and returns it along with the patient information from previous AJAX call. 107 | */ 108 | $.ajax({ 109 | url: '/getTherapistInfo', 110 | method: "POST", 111 | data: { 112 | therapistId: therapistId 113 | }, 114 | success: function (therapist) { 115 | patientInfo.sessionCost = therapist.sessionCost; 116 | callback(cartData, patientInfo); 117 | } 118 | }) 119 | } 120 | }) 121 | } 122 | 123 | /** 124 | * Live search function for table search. 125 | */ 126 | function searchTable() { 127 | const searchInput = document.getElementById("searchbar").value.toUpperCase(); 128 | const table = document.getElementById("patientTable"); 129 | const trs = table.tBodies[0].getElementsByTagName("tr"); 130 | let count = 0; 131 | 132 | // Loop through tbody's rows 133 | for (var i = 0; i < trs.length; i++) { 134 | var tds = trs[i].getElementsByTagName("td"); 135 | trs[i].style.display = "none"; 136 | 137 | // loop through row cells to check each element 138 | for (var j = 0; j < tds.length; j++) { 139 | // check if there's a match in the table 140 | if (tds[j].innerHTML.toUpperCase().indexOf(searchInput) > -1) { 141 | trs[i].style.display = ""; 142 | count++; 143 | break; 144 | } 145 | } 146 | } 147 | $("#resultsFound").html(`${count}`); 148 | } 149 | 150 | /** 151 | * Sort table function when table headings is clicked. 152 | */ 153 | function sortTable() { 154 | const table = document.getElementById('patientTable'); 155 | const headers = table.querySelectorAll('.tHead'); 156 | const directions = Array.from(headers).map(function (header) { 157 | return ''; 158 | }); 159 | 160 | const transform = function (index, content) { 161 | const type = headers[index].getAttribute('data-type'); 162 | var sort = {}; 163 | switch (type) { 164 | case 'number': 165 | content = content.substring(1); 166 | return parseFloat(content); 167 | case 'string': 168 | case 'plan': 169 | content = content.substring(2); 170 | return content; 171 | default: 172 | return content; 173 | } 174 | }; 175 | 176 | const tableBody = table.querySelector('tbody'); 177 | const rows = tableBody.getElementsByClassName('tableRows'); 178 | 179 | const sortColumn = function (index) { 180 | const direction = directions[index] || 'asc'; 181 | const multiplier = direction === 'asc' ? 1 : -1; 182 | const newRows = Array.from(rows); 183 | 184 | newRows.sort(function (rowA, rowB) { 185 | const cellA = rowA.querySelectorAll('td')[index].innerHTML.toLowerCase(); 186 | const cellB = rowB.querySelectorAll('td')[index].innerHTML.toLowerCase(); 187 | 188 | const a = transform(index, cellA); 189 | const b = transform(index, cellB); 190 | 191 | switch (true) { 192 | case a > b: 193 | return 1 * multiplier; 194 | case a < b: 195 | return -1 * multiplier; 196 | case a === b: 197 | return 0; 198 | } 199 | }); 200 | 201 | [].forEach.call(rows, function (row) { 202 | tableBody.removeChild(row); 203 | }); 204 | 205 | if (direction === 'asc') { 206 | directions[index] = 'desc'; 207 | document.getElementById(index).setAttribute("class", "bi bi-caret-down-fill"); 208 | 209 | } else { 210 | directions[index] = 'asc'; 211 | document.getElementById(index).setAttribute("class", "bi bi-caret-up-fill"); 212 | } 213 | 214 | newRows.forEach(function (newRow) { 215 | tableBody.appendChild(newRow); 216 | }); 217 | }; 218 | 219 | [].forEach.call(headers, function (header, index) { 220 | header.addEventListener('click', function () { 221 | sortColumn(index); 222 | for (var i = 0; i < headers.length; i++) { 223 | if (i == index) { 224 | if (directions[index] === 'asc') { 225 | document.getElementById(i).parentElement.style.color = '#000'; 226 | } else { 227 | document.getElementById(i).parentElement.style.color = '#09C5A3'; 228 | } 229 | } else { 230 | document.getElementById(i).parentElement.style.color = '#000'; 231 | } 232 | } 233 | }); 234 | }); 235 | } -------------------------------------------------------------------------------- /public/originaljs/checkout.js: -------------------------------------------------------------------------------- 1 | var therapistInformation; 2 | var totalPrice; 3 | $(document).ready(async function () { 4 | /** 5 | * AJAX call that checks the status of a cart to see if 6 | * there is an item that exist in the shopping cart. 7 | */ 8 | await $.ajax({ 9 | url: '/checkStatus', 10 | method: 'GET', 11 | success: function (cart) { 12 | if (cart) { 13 | $('#orderNumber').text(`${cart.orderId}`) 14 | $("#noOrderSummary").hide(); 15 | $("#orderSummary").show(); 16 | getTherapist(cart.therapist); 17 | $('#cartPlan').val(`${cart.timeLength}`) 18 | updateCart(); 19 | } 20 | } 21 | }) 22 | }) 23 | 24 | /** 25 | * 26 | * This function has an AJAX call that finds the therapist that is selected from the shopping cart 27 | * and displays their information in the checkout page. 28 | * 29 | * @param {*} therapistId as object id 30 | */ 31 | function getTherapist(therapistId) { 32 | $.ajax({ 33 | url: '/getTherapistInfo', 34 | method: "POST", 35 | data: { 36 | therapistId: therapistId 37 | }, 38 | success: function (therapist) { 39 | $('#therapistName').text(`${therapist.firstName} ${therapist.lastName}`) 40 | $('#therapistDesc').text(`${therapist.yearsExperience} years of experience in the profession, and offers $${therapist.sessionCost} per session`) 41 | $('#therapistImg').attr('src', `${therapist.profileImg}`) 42 | therapistInformation = therapist; 43 | therapistInformation._id = therapistId; 44 | let multiplier; 45 | if ($('#cartPlan').val() == "freePlan") { 46 | multiplier = 0; 47 | } else if ($('#cartPlan').val() == "monthPlan") { 48 | multiplier = 1; 49 | } else if ($('#cartPlan').val() == "threeMonthPlan") { 50 | multiplier = 3; 51 | } else { 52 | multiplier = 6; 53 | } 54 | $("#cartCost").html(`${parseFloat(therapistInformation.sessionCost * multiplier).toFixed(2)}`) 55 | $("#subTotal").html(`${parseFloat(therapistInformation.sessionCost * multiplier).toFixed(2)}`) 56 | $("#taxTotal").html(`$${parseFloat(therapistInformation.sessionCost * multiplier * 0.12).toFixed(2)}`) 57 | $("#total").html(`$${parseFloat(therapistInformation.sessionCost * multiplier * 1.12).toFixed(2)}`) 58 | } 59 | }) 60 | } 61 | 62 | /** 63 | * This function allows users to change their shopping cart's timelength. 64 | * It has an AJAX call that changes the timelength for the user's shopping cart 65 | * in the database so when the order is confirmed the expiring time changes 66 | * corrosponding to the timelength. 67 | */ 68 | function updateCart() { 69 | $('#cartPlan').change(() => { 70 | $.ajax({ 71 | url: '/updateCart', 72 | type: 'PUT', 73 | data: { 74 | timeLength: $('#cartPlan').val() 75 | }, 76 | success: function () { 77 | let multiplier; 78 | if ($('#cartPlan').val() == "freePlan") { 79 | multiplier = 0; 80 | } else if ($('#cartPlan').val() == "monthPlan") { 81 | multiplier = 1; 82 | } else if ($('#cartPlan').val() == "threeMonthPlan") { 83 | multiplier = 3; 84 | } else { 85 | multiplier = 6; 86 | } 87 | $("#cartCost").html(`${parseFloat(therapistInformation.sessionCost * multiplier).toFixed(2)}`) 88 | $("#subTotal").html(`${parseFloat(therapistInformation.sessionCost * multiplier).toFixed(2)}`) 89 | $("#taxTotal").html(`$${parseFloat(therapistInformation.sessionCost * multiplier * 0.12).toFixed(2)}`) 90 | $("#total").html(`$${parseFloat(therapistInformation.sessionCost * multiplier * 1.12).toFixed(2)}`) 91 | } 92 | }) 93 | }) 94 | } 95 | 96 | /** 97 | * Variables for Delete User Modal. 98 | */ 99 | var removeOrderModal = document.getElementById("removeOrderModal"); 100 | document.getElementById('removeItem').onclick = function (e) { 101 | removeOrderModal.style.display = "block"; 102 | document.body.style.overflow = 'hidden'; 103 | 104 | document.getElementById('removeOrderBtn').onclick = function () { 105 | /** 106 | * AJAX call that deletes a item from the shopping cart and changes the status of the cart. 107 | */ 108 | $.ajax({ 109 | url: '/deleteCart', 110 | type: 'DELETE', 111 | success: function (data) { 112 | removeOrderModal.style.display = "none"; 113 | document.getElementById('signupSuccessModal').style.display = 'flex'; 114 | document.body.style.overflow = 'hidden'; 115 | setTimeout(() => { 116 | location.reload(); 117 | }, 2500); 118 | } 119 | }) 120 | } 121 | } 122 | 123 | /** 124 | * If cancel button is clicked, hide modal for Delete User 125 | */ 126 | document.getElementById("cancelRemove").onclick = function () { 127 | removeOrderModal.style.display = "none"; 128 | document.body.style.overflow = 'auto'; 129 | } 130 | 131 | /** 132 | * 133 | * If user clicks outside of the modal for both Create and Delete then hide modal 134 | * 135 | * @param {*} event as an event listener 136 | */ 137 | window.onclick = function (event) { 138 | if (event.target == removeOrderModal) { 139 | removeOrderModal.style.display = "none"; 140 | document.body.style.overflow = 'auto'; 141 | } 142 | } 143 | 144 | const checkoutErrorMsg = document.getElementById("checkoutErrorMessage"); 145 | 146 | /** 147 | * 148 | * If the order is successfully placed redirect patient to 149 | * thank you page and display their order number and a 150 | * thank you message. 151 | * 152 | * @param {*} data as form field 153 | */ 154 | function handleConfirmOrder(data) { 155 | if (data.errorMsg) { 156 | checkoutErrorMsg.style.display = 'block'; 157 | checkoutErrorMsg.innerHTML = data.errorMsg; 158 | } else { 159 | checkoutErrorMsg.style.display = 'none'; 160 | document.getElementById('signupSuccessModal').style.display = 'flex'; 161 | document.body.style.overflow = 'hidden'; 162 | setTimeout(() => { 163 | window.location = "/thank-you" 164 | }, 2500); 165 | } 166 | } 167 | 168 | /** 169 | * This onclick calls the AJAX call that confirms an order. Before 170 | * calling the AJAX call it will check the timeLength the user 171 | * chose for their session. It will then change the expiring time 172 | * of the cart based on the timeLength when confirm order is done. 173 | */ 174 | document.getElementById('confirmOrder').onclick = function () { 175 | const time = new Date(); 176 | var timeLengthforUse; 177 | var selectedTime = $('#cartPlan').val(); 178 | if (selectedTime == "freePlan") { 179 | timeLengthforUse = new Date(time.setMinutes(time.getMinutes() + 3)); 180 | } else if (selectedTime == "monthPlan") { 181 | timeLengthforUse = new Date(time.setMinutes(time.getMinutes() + 5)); 182 | } else if (selectedTime == "threeMonthPlan") { 183 | timeLengthforUse = new Date(time.setMinutes(time.getMinutes() + 10)); 184 | } else if (selectedTime == "yearPlan") { 185 | timeLengthforUse = new Date(time.setMinutes(time.getMinutes() + 15)); 186 | } 187 | /** 188 | * AJAX call that will confirm the order in the database and start the session for the user. 189 | */ 190 | $.ajax({ 191 | url: "/confirmCart", 192 | method: "POST", 193 | data: { 194 | cartPlan: $('#cartPlan').val(), 195 | timeLengthforUse: timeLengthforUse, 196 | totalPrice: totalPrice, 197 | therapistID: therapistInformation._id 198 | }, 199 | success: handleConfirmOrder 200 | }) 201 | } 202 | 203 | /** 204 | * 205 | * Print invoice function 206 | * 207 | * @returns N/A 208 | */ 209 | function printInvoice() { 210 | var printWindow = window.open('', 'new div', 'height=600,width=600'); 211 | printWindow.document.write('Print Invoice'); 212 | printWindow.document.write(''); 213 | printWindow.document.write(''); 214 | printWindow.document.write('
    '); 215 | printWindow.document.write('

    Order: MM0509123456

    '); 216 | printWindow.document.write(document.getElementById('orderTable').innerHTML); 217 | printWindow.document.write('

    '); 218 | printWindow.document.write(document.getElementById('cartTotalSec').innerHTML); 219 | printWindow.document.write('
    '); 220 | printWindow.document.write('
    '); 221 | printWindow.document.close(); 222 | 223 | setTimeout(() => { 224 | printWindow.focus(); 225 | printWindow.print(); 226 | }, 1000); 227 | return false; 228 | } -------------------------------------------------------------------------------- /html/order-history.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | MyMind - Order History 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 |
    38 | 116 |
    117 | 118 |
    119 |
    120 |
    121 |

    Order History

    122 |
    123 |
    124 |
    125 | 126 |
    127 |

    No orders have been placed. Please visit Therapists and 128 | purchase a therapy package to start your journey!

    129 |
    130 | 131 |
    132 |

    Results Found: Order(s)

    133 |
    134 | 136 |
    137 | 138 |
    139 | 140 |
    141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 |
    DateTimeTherapistPlanPriceOrder #Status
    155 |
    156 | 157 | 158 |
    159 |
    160 |
    161 | 162 | 164 | 165 |
    166 |
    167 |
    168 | 169 | 170 |
    171 |
    172 |
    173 | 174 |
    175 |

    Want to refund?

    176 |

    You're about to refund your session order for the user and will be refunded This action is 178 | irreversible and cannot be undone. Are you sure?

    179 |
    180 | 181 | 182 |
    183 |
    184 |
    185 | 186 | 187 |
    188 |
    189 |
    190 |

    Your session has expired!

    191 |

    Purchase a new session at Therapists to continue your journey.

    192 |
    193 | 194 |
    195 |
    196 | 197 |
    198 |
    199 |
    200 | 201 | 202 | 203 | 204 | 205 | 206 | 207 | 208 | -------------------------------------------------------------------------------- /public/css/chat-session.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --primaryColor: #09C5A3; 3 | --secondaryColor: #00A98B; 4 | } 5 | 6 | /* Chat Session Page for Mobile */ 7 | #wrapper #chatProfileSec { 8 | grid-column: 1 / span 4; 9 | grid-row: 1 / span 1; 10 | position: sticky; 11 | top: 0; 12 | width: 100%; 13 | min-height: 10vh; 14 | padding: 1rem 3rem; 15 | background-color: var(--primaryColor); 16 | box-shadow: 0px 10px 28px -5px rgba(0, 0, 0, 0.2); 17 | z-index: 9999; 18 | } 19 | 20 | #wrapper #chatProfileSec #chatHeader { 21 | display: flex; 22 | flex-direction: row; 23 | justify-content: space-between; 24 | align-items: center; 25 | } 26 | 27 | #wrapper #chatProfileSec #chatHeader #chatProfile { 28 | display: flex; 29 | flex-direction: row; 30 | align-items: center; 31 | max-width: 80%; 32 | } 33 | 34 | #wrapper #chatProfileSec #chatHeader #chatProfile div { 35 | display: flex; 36 | } 37 | 38 | #wrapper #chatProfileSec #chatHeader #chatProfile div #chatImg { 39 | width: 4rem; 40 | height: 4rem; 41 | border-radius: 50%; 42 | object-fit: cover; 43 | object-position: center center; 44 | } 45 | 46 | #wrapper #chatProfileSec #chatHeader #chatProfile #chatProfileDesc { 47 | display: flex; 48 | flex-direction: column; 49 | padding-left: 2rem; 50 | } 51 | 52 | #wrapper #chatProfileSec #chatHeader #chatProfile #chatProfileDesc #chatName { 53 | font-size: 1.3rem; 54 | font-weight: 700; 55 | color: white; 56 | padding-bottom: 0.5rem; 57 | } 58 | 59 | #wrapper #chatProfileSec #chatHeader #chatProfile #chatProfileDesc p:nth-child(2) { 60 | font-size: 1rem; 61 | font-weight: 500; 62 | color: #EFEFEF; 63 | } 64 | 65 | #wrapper #chatProfileSec #chatHeader #chatTools { 66 | display: flex; 67 | flex-direction: row; 68 | align-items: center; 69 | max-width: 20%; 70 | } 71 | 72 | #wrapper #chatProfileSec #chatHeader #chatTools a { 73 | display: flex; 74 | flex-direction: column; 75 | justify-content: center; 76 | align-items: center; 77 | text-decoration: none; 78 | } 79 | 80 | #wrapper #chatProfileSec #chatHeader #chatTools a i { 81 | font-size: 1.5rem; 82 | color: white; 83 | } 84 | 85 | #wrapper #chatMessages { 86 | grid-column: 1 / span 4; 87 | grid-row: 2 / span 1; 88 | padding: 3rem 2rem; 89 | width: 100%; 90 | height: 70vh; 91 | margin: 0; 92 | list-style: none; 93 | overflow-x: hidden; 94 | overflow-y: scroll; 95 | } 96 | 97 | #wrapper #chatMessages #sessionTimer { 98 | position: absolute; 99 | bottom: 10rem; 100 | left: 0; 101 | width: 100%; 102 | font-size: 14px; 103 | font-weight: 500; 104 | text-align: center; 105 | color: #858585; 106 | background-color: white; 107 | padding-top: 0.5rem; 108 | z-index: 2; 109 | } 110 | 111 | #wrapper #chatMessages::-webkit-scrollbar { 112 | width: 5px; 113 | } 114 | 115 | #wrapper #chatMessages::-webkit-scrollbar-track { 116 | background-color: rgba(211, 211, 211, 0.5); 117 | } 118 | 119 | #wrapper #chatMessages::-webkit-scrollbar-thumb { 120 | border-radius: 500px; 121 | background-color: var(--primaryColor); 122 | } 123 | 124 | #wrapper #chatMessages li { 125 | display: inline-block; 126 | position: relative; 127 | font-size: 1rem; 128 | font-weight: 400; 129 | clear: both; 130 | max-width: 65%; 131 | padding: 0.8rem 1rem; 132 | margin: 0 0 1.5rem 0; 133 | cursor: pointer; 134 | color: white; 135 | word-wrap: break-word; 136 | border-radius: 15px; 137 | background-color: var(--primaryColor); 138 | -webkit-transition: all ease-in-out 0.3s; 139 | -moz-transition: all ease-in-out 0.3s; 140 | -ms-transition: all ease-in-out 0.3s; 141 | -o-transition: all ease-in-out 0.3s; 142 | transition: all ease-in-out 0.3s; 143 | } 144 | 145 | #wrapper #chatMessages li:after { 146 | position: absolute; 147 | content: ''; 148 | width: 0; 149 | height: 0; 150 | } 151 | 152 | #wrapper #chatMessages li.other { 153 | float: left; 154 | margin-left: 10px; 155 | color: black; 156 | background-color: #F2F2F2; 157 | -webkit-animation: show-chat-odd 0.15s 1 ease-in-out; 158 | -moz-animation: show-chat-odd 0.15s 1 ease-in-out; 159 | -ms-animation: show-chat-odd 0.15s 1 ease-in-out; 160 | -o-animation: show-chat-odd 0.15s 1 ease-in-out; 161 | animation: show-chat-odd 0.15s 1 ease-in-out; 162 | } 163 | 164 | #wrapper #chatMessages li.other.showTime { 165 | margin-bottom: 2.2rem; 166 | } 167 | 168 | #wrapper #chatMessages li.other.showTime::before { 169 | display: block; 170 | content: attr(data-before); 171 | position: absolute; 172 | left: 0; 173 | bottom: -1.3rem; 174 | font-size: 12px; 175 | font-weight: 400; 176 | color: #858585; 177 | text-align: left; 178 | width: fit-content; 179 | min-width: 10rem; 180 | } 181 | 182 | #wrapper #chatMessages li.other:after { 183 | border-top: 20px solid #F2F2F2; 184 | border-left: 20px solid transparent; 185 | bottom: 0%; 186 | left: -10px; 187 | -webkit-transform: rotate(90deg); 188 | -moz-transform: rotate(90deg); 189 | -ms-transform: rotate(90deg); 190 | -o-transform: rotate(90deg); 191 | transform: rotate(90deg); 192 | } 193 | 194 | #wrapper #chatMessages li.self { 195 | float: right; 196 | margin-right: 10px; 197 | -webkit-animation: show-chat-even 0.15s 1 ease-in-out; 198 | -moz-animation: show-chat-even 0.15s 1 ease-in-out; 199 | -ms-animation: show-chat-even 0.15s 1 ease-in-out; 200 | -o-animation: show-chat-even 0.15s 1 ease-in-out; 201 | animation: show-chat-even 0.15s 1 ease-in-out; 202 | } 203 | 204 | #wrapper #chatMessages li.self.showTime { 205 | margin-bottom: 2.2rem; 206 | } 207 | 208 | #wrapper #chatMessages li.self.showTime::before { 209 | display: block; 210 | content: attr(data-before); 211 | position: absolute; 212 | right: 0; 213 | bottom: -1.3rem; 214 | font-size: 12px; 215 | font-weight: 400; 216 | color: #858585; 217 | text-align: right; 218 | width: fit-content; 219 | min-width: 10rem; 220 | } 221 | 222 | #wrapper #chatMessages li.self:after { 223 | border-top: 20px solid var(--primaryColor); 224 | border-right: 20px solid transparent; 225 | right: -8px; 226 | bottom: 0%; 227 | -webkit-transform: rotate(270deg); 228 | -moz-transform: rotate(270deg); 229 | -ms-transform: rotate(270deg); 230 | -o-transform: rotate(270deg); 231 | transform: rotate(270deg); 232 | } 233 | 234 | #wrapper #sendMessageContainer { 235 | grid-column: 1 / span 4; 236 | grid-row: 3 / span 1; 237 | display: flex; 238 | position: fixed; 239 | bottom: 5rem; 240 | left: 0; 241 | right: 0; 242 | padding: 1rem 3rem; 243 | z-index: 2; 244 | } 245 | 246 | #wrapper #sendMessageContainer #chatbox { 247 | font-family: 'Nunito', sans-serif; 248 | font-size: 1rem; 249 | resize: none; 250 | color: black; 251 | border: 1px solid #CCCCCC; 252 | border-radius: 15px; 253 | width: 100%; 254 | max-height: 15rem; 255 | height: 3.2rem; 256 | word-wrap: break-word; 257 | word-break: break-all; 258 | padding: 0.8rem 4rem 0.8rem 1rem; 259 | overflow-y: auto; 260 | outline: none; 261 | } 262 | 263 | #wrapper #sendMessageContainer #chatbox::-webkit-scrollbar { 264 | width: 5px; 265 | } 266 | 267 | #wrapper #sendMessageContainer #chatbox::-webkit-scrollbar-track { 268 | margin-top: 15px; 269 | margin-bottom: 15px; 270 | border-radius: 500px; 271 | background-color: rgba(211, 211, 211, 0.5); 272 | } 273 | 274 | #wrapper #sendMessageContainer #chatbox::-webkit-scrollbar-thumb { 275 | border-radius: 500px; 276 | background-color: var(--primaryColor); 277 | } 278 | 279 | #wrapper #sendMessageContainer #sendMessage { 280 | display: flex; 281 | flex-direction: column; 282 | justify-content: center; 283 | align-items: center; 284 | position: absolute; 285 | right: 4rem; 286 | bottom: 1.5rem; 287 | height: 2.2rem; 288 | width: 2.2rem; 289 | padding: 5px; 290 | background: var(--primaryColor); 291 | border-radius: 50px; 292 | border: none; 293 | cursor: pointer; 294 | } 295 | 296 | #wrapper #sendMessageContainer #sendMessage img { 297 | color: black; 298 | width: 100%; 299 | height: 100%; 300 | margin-right: -2px; 301 | } 302 | 303 | @-webkit-keyframes show-chat-even { 304 | 0% { 305 | margin-left: -480px; 306 | } 307 | 308 | 100% { 309 | margin-left: 0; 310 | } 311 | } 312 | 313 | @-moz-keyframes show-chat-even { 314 | 0% { 315 | margin-left: -480px; 316 | } 317 | 318 | 100% { 319 | margin-left: 0; 320 | } 321 | } 322 | 323 | @-ms-keyframes show-chat-even { 324 | 0% { 325 | margin-left: -480px; 326 | } 327 | 328 | 100% { 329 | margin-left: 0; 330 | } 331 | } 332 | 333 | @-o-keyframes show-chat-even { 334 | 0% { 335 | margin-left: -480px; 336 | } 337 | 338 | 100% { 339 | margin-left: 0; 340 | } 341 | } 342 | 343 | @keyframes show-chat-even { 344 | 0% { 345 | margin-left: -480px; 346 | } 347 | 348 | 100% { 349 | margin-left: 0; 350 | } 351 | } 352 | 353 | @-webkit-keyframes show-chat-odd { 354 | 0% { 355 | margin-right: -480px; 356 | } 357 | 358 | 100% { 359 | margin-right: 0; 360 | } 361 | } 362 | 363 | @-moz-keyframes show-chat-odd { 364 | 0% { 365 | margin-right: -480px; 366 | } 367 | 368 | 100% { 369 | margin-right: 0; 370 | } 371 | } 372 | 373 | @-ms-keyframes show-chat-odd { 374 | 0% { 375 | margin-right: -480px; 376 | } 377 | 378 | 100% { 379 | margin-right: 0; 380 | } 381 | } 382 | 383 | @-o-keyframes show-chat-odd { 384 | 0% { 385 | margin-right: -480px; 386 | } 387 | 388 | 100% { 389 | margin-right: 0; 390 | } 391 | } 392 | 393 | @keyframes show-chat-odd { 394 | 0% { 395 | margin-right: -480px; 396 | } 397 | 398 | 100% { 399 | margin-right: 0; 400 | } 401 | } -------------------------------------------------------------------------------- /public/js/order-history.js: -------------------------------------------------------------------------------- 1 | const _0x1e764d=_0x4341;function _0x4341(_0x1d80e5,_0x2ca851){const _0x365d49=_0x365d();return _0x4341=function(_0x434155,_0x58f56d){_0x434155=_0x434155-0x165;let _0x1b46fa=_0x365d49[_0x434155];return _0x1b46fa;},_0x4341(_0x1d80e5,_0x2ca851);}(function(_0x716c1c,_0x559312){const _0x43f23a=_0x4341,_0x1c63fb=_0x716c1c();while(!![]){try{const _0x54153a=-parseInt(_0x43f23a(0x172))/0x1+-parseInt(_0x43f23a(0x1bf))/0x2+-parseInt(_0x43f23a(0x190))/0x3+parseInt(_0x43f23a(0x1c8))/0x4+-parseInt(_0x43f23a(0x16a))/0x5*(parseInt(_0x43f23a(0x1a1))/0x6)+parseInt(_0x43f23a(0x177))/0x7*(parseInt(_0x43f23a(0x195))/0x8)+parseInt(_0x43f23a(0x1c9))/0x9;if(_0x54153a===_0x559312)break;else _0x1c63fb['push'](_0x1c63fb['shift']());}catch(_0x5a3f7b){_0x1c63fb['push'](_0x1c63fb['shift']());}}}(_0x365d,0x50336));const orderRefundModal=document[_0x1e764d(0x17c)](_0x1e764d(0x1bc));$(document)[_0x1e764d(0x1a9)](async function(){const _0x56fdf6=_0x1e764d;function _0x43dd45(_0x1358bf){const _0x12a4ed=_0x4341;let _0x512734=_0x1358bf[_0x12a4ed(0x174)]()*0x3c*0x3e8,_0x56478b=new Date(_0x1358bf-_0x512734)[_0x12a4ed(0x1b6)]()['slice'](0x0,0xa);return _0x56478b;}function _0x273271(_0x594e1f,_0x419ab2){const _0x140d7d=_0x4341;let _0x16feff;var _0x2efa71=_0x140d7d(0x185);_0x2efa71+=''+_0x43dd45(new Date(_0x419ab2[_0x140d7d(0x18b)]))+_0x140d7d(0x1bd),_0x2efa71+=''+new Date(_0x419ab2['expiringTime'])[_0x140d7d(0x173)]('en-CA',{'hour':_0x140d7d(0x19e),'minute':_0x140d7d(0x19e),'hour12':!![]})+_0x140d7d(0x1bd),_0x2efa71+=_0x140d7d(0x169)+_0x594e1f['fullName']+_0x140d7d(0x1bd);if(_0x419ab2[_0x140d7d(0x17b)]==_0x140d7d(0x1cd))_0x2efa71+=_0x140d7d(0x1cb),_0x16feff=0x0;else{if(_0x419ab2[_0x140d7d(0x17b)]==_0x140d7d(0x168))_0x2efa71+=_0x140d7d(0x171),_0x16feff=0x1;else _0x419ab2[_0x140d7d(0x17b)]=='threeMonthPlan'?(_0x2efa71+=_0x140d7d(0x1a2),_0x16feff=0x3):(_0x2efa71+='1\x20Year',_0x16feff=0x6);}_0x2efa71+='$'+parseFloat(_0x594e1f[_0x140d7d(0x1d0)]*_0x16feff*1.12)[_0x140d7d(0x19f)](0x2)+_0x140d7d(0x1bd),_0x2efa71+=_0x140d7d(0x169)+_0x419ab2[_0x140d7d(0x1b9)]+_0x140d7d(0x1bd);if(_0x419ab2[_0x140d7d(0x196)]==_0x140d7d(0x180))_0x2efa71+=_0x140d7d(0x1a6);else new Date(_0x419ab2['expiringTime'])>new Date()?_0x2efa71+=_0x140d7d(0x1ca):_0x2efa71+=_0x140d7d(0x183);$(_0x140d7d(0x1d2))[_0x140d7d(0x1c1)](_0x2efa71);}await $['ajax']({'url':_0x56fdf6(0x1c3),'type':_0x56fdf6(0x19c),'success':function(_0x54726d){const _0x4325fa=_0x56fdf6;_0x54726d[_0x4325fa(0x1c5)]>0x0&&(document['getElementById'](_0x4325fa(0x1c0))[_0x4325fa(0x16b)]['display']=_0x4325fa(0x1b5),document[_0x4325fa(0x17c)](_0x4325fa(0x1ac))[_0x4325fa(0x16b)][_0x4325fa(0x1b4)]=_0x4325fa(0x184),document[_0x4325fa(0x17c)]('orderTableContainer')[_0x4325fa(0x16b)][_0x4325fa(0x1b4)]=_0x4325fa(0x184),_0x54726d[_0x4325fa(0x1ab)](_0x4dc530=>{getTherapist(_0x4dc530,_0x273271);}),document[_0x4325fa(0x17c)]('resultsFound')[_0x4325fa(0x1b0)]=_0x54726d[_0x4325fa(0x1c5)]);}}),document[_0x56fdf6(0x17c)]('0')['setAttribute'](_0x56fdf6(0x18d),_0x56fdf6(0x1a5)),document[_0x56fdf6(0x17c)]('1')[_0x56fdf6(0x182)](_0x56fdf6(0x18d),_0x56fdf6(0x1a5)),document['getElementById']('2')[_0x56fdf6(0x182)](_0x56fdf6(0x18d),_0x56fdf6(0x1a5)),document[_0x56fdf6(0x17c)]('3')['setAttribute'](_0x56fdf6(0x18d),_0x56fdf6(0x1a5)),document[_0x56fdf6(0x17c)]('4')[_0x56fdf6(0x182)](_0x56fdf6(0x18d),_0x56fdf6(0x1a5)),document[_0x56fdf6(0x17c)]('5')[_0x56fdf6(0x182)](_0x56fdf6(0x18d),_0x56fdf6(0x1a5)),document[_0x56fdf6(0x17c)]('6')['setAttribute'](_0x56fdf6(0x18d),'bi\x20bi-caret-down-fill'),sortTable(),document[_0x56fdf6(0x17c)](_0x56fdf6(0x1d1))['onclick']=function(){const _0x484433=_0x56fdf6;setTimeout(()=>{const _0x116116=_0x4341;$[_0x116116(0x188)]('/activeSession',function(_0x249037){const _0x30041c=_0x116116;_0x249037==_0x30041c(0x19d)?(document[_0x30041c(0x17c)](_0x30041c(0x194))['style'][_0x30041c(0x1b4)]=_0x30041c(0x175),document[_0x30041c(0x17c)](_0x30041c(0x1b7))[_0x30041c(0x1b0)]=_0x30041c(0x165),document[_0x30041c(0x17c)](_0x30041c(0x178))[_0x30041c(0x1b0)]=_0x30041c(0x1c2),document[_0x30041c(0x17c)]('refundButtonsSec')['style'][_0x30041c(0x1b4)]='none'):($(_0x30041c(0x1be))[_0x30041c(0x1a7)](_0x249037[_0x30041c(0x197)]+'.'),$(_0x30041c(0x18f))[_0x30041c(0x1a7)]('$'+_0x249037[_0x30041c(0x1cc)]));}),orderRefundModal['style'][_0x116116(0x1b4)]='block',document[_0x116116(0x166)]['style'][_0x116116(0x16d)]=_0x116116(0x18c);},0x32),$('#orderRefundBtn')[_0x484433(0x167)](),$(_0x484433(0x193))[_0x484433(0x191)](()=>{const _0x51bb31=_0x484433;orderRefundModal[_0x51bb31(0x16b)][_0x51bb31(0x1b4)]=_0x51bb31(0x1b5),document[_0x51bb31(0x17c)]('signupSuccessModal')[_0x51bb31(0x16b)][_0x51bb31(0x1b4)]='flex',document[_0x51bb31(0x166)][_0x51bb31(0x16b)][_0x51bb31(0x16d)]=_0x51bb31(0x18c),setTimeout(()=>{const _0x4276c7=_0x51bb31;$[_0x4276c7(0x1aa)](_0x4276c7(0x198),function(){const _0x42f7dc=_0x4276c7;location[_0x42f7dc(0x187)]();});},0x9c4);});};});function getTherapist(_0x32d4d0,_0x5c6420){const _0x47118e=_0x1e764d;let _0x4606a4=_0x32d4d0[_0x47118e(0x199)],_0x33b902;$['ajax']({'url':_0x47118e(0x16f),'method':_0x47118e(0x189),'data':{'therapistId':_0x4606a4},'success':function(_0x3e4ee9){const _0x1ddc12=_0x47118e;_0x33b902={'fullName':_0x3e4ee9[_0x1ddc12(0x17a)]['charAt'](0x0)+'.\x20'+_0x3e4ee9[_0x1ddc12(0x1b2)],'sessionCost':_0x3e4ee9['sessionCost']},_0x5c6420(_0x33b902,_0x32d4d0);}});}function searchTable(){const _0x443dbb=_0x1e764d,_0xd52276=document['getElementById'](_0x443dbb(0x192))[_0x443dbb(0x1ae)][_0x443dbb(0x186)](),_0x1cad4b=document[_0x443dbb(0x17c)]('orderTable'),_0xcca7e3=_0x1cad4b['tBodies'][0x0][_0x443dbb(0x1cf)]('tr');let _0x5294c9=0x0;for(var _0x4475db=0x0;_0x4475db<_0xcca7e3['length'];_0x4475db++){var _0x4b3b4d=_0xcca7e3[_0x4475db][_0x443dbb(0x1cf)]('td');_0xcca7e3[_0x4475db][_0x443dbb(0x16b)][_0x443dbb(0x1b4)]=_0x443dbb(0x1b5);for(var _0x403da1=0x0;_0x403da1<_0x4b3b4d['length'];_0x403da1++){if(_0x4b3b4d[_0x403da1]['innerHTML'][_0x443dbb(0x186)]()[_0x443dbb(0x1a3)](_0xd52276)>-0x1){_0xcca7e3[_0x4475db][_0x443dbb(0x16b)][_0x443dbb(0x1b4)]='',_0x5294c9++;break;}}}$(_0x443dbb(0x1c6))['html'](''+_0x5294c9);}function sortTable(){const _0x33c98f=_0x1e764d,_0x14f335=document['getElementById'](_0x33c98f(0x17e)),_0x3721cd=_0x14f335['querySelectorAll'](_0x33c98f(0x179)),_0x2c755c=Array['from'](_0x3721cd)[_0x33c98f(0x19b)](function(_0x506d03){return'';}),_0xb48f3d=function(_0x34fe17,_0x3cbe95){const _0x1edf8d=_0x33c98f,_0x12a893=_0x3721cd[_0x34fe17][_0x1edf8d(0x18e)](_0x1edf8d(0x1bb));var _0x351085={};switch(_0x12a893){case _0x1edf8d(0x1a0):_0x3cbe95=_0x3cbe95[_0x1edf8d(0x1a8)](0x1);return parseFloat(_0x3cbe95);case'string':case'plan':_0x3cbe95=_0x3cbe95[_0x1edf8d(0x1a8)](0x2);return _0x3cbe95;default:return _0x3cbe95;}},_0x201d80=_0x14f335[_0x33c98f(0x1af)]('tbody'),_0x38b190=_0x201d80[_0x33c98f(0x1c7)](_0x33c98f(0x1a4)),_0x45bda8=function(_0x6def02){const _0x32ed5c=_0x33c98f,_0x55a384=_0x2c755c[_0x6def02]||'asc',_0x117d3f=_0x55a384===_0x32ed5c(0x19a)?0x1:-0x1,_0x5a8189=Array[_0x32ed5c(0x1b1)](_0x38b190);_0x5a8189[_0x32ed5c(0x181)](function(_0x15cf9,_0x2c75ea){const _0x57fbd9=_0x32ed5c,_0x365261=_0x15cf9[_0x57fbd9(0x1ce)]('td')[_0x6def02][_0x57fbd9(0x1b0)][_0x57fbd9(0x1c4)](),_0x1d77b7=_0x2c75ea['querySelectorAll']('td')[_0x6def02][_0x57fbd9(0x1b0)][_0x57fbd9(0x1c4)](),_0x4af1b3=_0xb48f3d(_0x6def02,_0x365261),_0x1719c0=_0xb48f3d(_0x6def02,_0x1d77b7);switch(!![]){case _0x4af1b3>_0x1719c0:return 0x1*_0x117d3f;case _0x4af1b3<_0x1719c0:return-0x1*_0x117d3f;case _0x4af1b3===_0x1719c0:return 0x0;}}),[][_0x32ed5c(0x1ab)][_0x32ed5c(0x1ad)](_0x38b190,function(_0x5343bc){_0x201d80['removeChild'](_0x5343bc);}),_0x55a384===_0x32ed5c(0x19a)?(_0x2c755c[_0x6def02]=_0x32ed5c(0x17d),document[_0x32ed5c(0x17c)](_0x6def02)[_0x32ed5c(0x182)]('class',_0x32ed5c(0x1a5))):(_0x2c755c[_0x6def02]='asc',document[_0x32ed5c(0x17c)](_0x6def02)[_0x32ed5c(0x182)](_0x32ed5c(0x18d),_0x32ed5c(0x16e))),_0x5a8189[_0x32ed5c(0x1ab)](function(_0xc41bd8){_0x201d80['appendChild'](_0xc41bd8);});};[][_0x33c98f(0x1ab)][_0x33c98f(0x1ad)](_0x3721cd,function(_0x2d19ec,_0x5189d0){const _0x4f6c3b=_0x33c98f;_0x2d19ec[_0x4f6c3b(0x1b3)](_0x4f6c3b(0x191),function(){const _0x5351ba=_0x4f6c3b;_0x45bda8(_0x5189d0);for(var _0x5b6cb7=0x0;_0x5b6cb7<_0x3721cd[_0x5351ba(0x1c5)];_0x5b6cb7++){_0x5b6cb7==_0x5189d0?_0x2c755c[_0x5189d0]===_0x5351ba(0x19a)?document[_0x5351ba(0x17c)](_0x5b6cb7)[_0x5351ba(0x18a)][_0x5351ba(0x16b)][_0x5351ba(0x17f)]=_0x5351ba(0x1b8):document[_0x5351ba(0x17c)](_0x5b6cb7)[_0x5351ba(0x18a)][_0x5351ba(0x16b)][_0x5351ba(0x17f)]=_0x5351ba(0x16c):document[_0x5351ba(0x17c)](_0x5b6cb7)[_0x5351ba(0x18a)][_0x5351ba(0x16b)][_0x5351ba(0x17f)]='#000';}});});}document[_0x1e764d(0x17c)](_0x1e764d(0x1ba))[_0x1e764d(0x176)]=function(){const _0x3a500f=_0x1e764d;orderRefundModal[_0x3a500f(0x16b)][_0x3a500f(0x1b4)]=_0x3a500f(0x1b5),document[_0x3a500f(0x166)][_0x3a500f(0x16b)][_0x3a500f(0x16d)]=_0x3a500f(0x170);},document[_0x1e764d(0x17c)]('closeRefundIcon')[_0x1e764d(0x176)]=function(){const _0x3077c8=_0x1e764d;orderRefundModal[_0x3077c8(0x16b)][_0x3077c8(0x1b4)]=_0x3077c8(0x1b5),document[_0x3077c8(0x166)][_0x3077c8(0x16b)][_0x3077c8(0x16d)]='auto';},window[_0x1e764d(0x176)]=function(_0x184660){const _0x317cd5=_0x1e764d;_0x184660['target']==orderRefundModal&&(orderRefundModal['style']['display']='none',document[_0x317cd5(0x166)][_0x317cd5(0x16b)][_0x317cd5(0x16d)]=_0x317cd5(0x170));};function _0x365d(){const _0x1eb8cc=['toFixed','number','1031502rslqEO','3\x20Months','indexOf','tableRows','bi\x20bi-caret-down-fill','Refunded','text','substring','ready','post','forEach','orderToolbar','call','value','querySelector','innerHTML','from','lastName','addEventListener','display','none','toISOString','headerRefund','#000','orderId','closeRefund','data-type','orderRefundModal','','#refundTherapist','439074tCYwsy','noOrderHistorySummary','append','You\x20have\x20no\x20active\x20session\x20at\x20this\x20time.\x20Please\x20place\x20an\x20order\x20from\x20our\x20Therapists\x20page','/getPreviousPurchases','toLowerCase','length','#resultsFound','getElementsByClassName','2324232onWcon','8619534gBWazj','Active','Trial','cost','freePlan','querySelectorAll','getElementsByTagName','sessionCost','refundBtn','tbody','No\x20active\x20orders\x20found','body','off','monthPlan','','10GGUtis','style','#09C5A3','overflow','bi\x20bi-caret-up-fill','/getTherapistInfo','auto','1\x20Month','133629iPjfPd','toLocaleString','getTimezoneOffset','block','onclick','21VGSBjL','msgRefund','.tHead','firstName','timeLength','getElementById','desc','orderTable','color','refunded','sort','setAttribute','Expired','flex','','toUpperCase','reload','get','POST','parentElement','purchased','hidden','class','getAttribute','#refundPrice','1874142uCnVOI','click','searchbar','#orderRefundBtn','modalHeader','297152WyejKe','status','therapistName','/refundOrder','therapist','asc','map','GET','NoActiveSession','numeric'];_0x365d=function(){return _0x1eb8cc;};return _0x365d();} --------------------------------------------------------------------------------