updated library

net6.0
Don Oerkfitz 4 years ago
parent 679e252af5
commit 86c16c0c32

@ -1,12 +0,0 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\Common.Library.DTO\Common.Library.DTO.csproj" />
<ProjectReference Include="..\Common.Library\Common.Library.csproj" />
</ItemGroup>
</Project>

@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net5.0</TargetFramework>
</PropertyGroup>
<ItemGroup>

@ -0,0 +1,54 @@
using Common.Library.SQL.MySQL;
using System;
using System.Data;
using Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC;
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class AboutCompanyDAO : MySQL
{
public AboutCompanyDAO(string server, string database, string username, string password) : base(server, database, username, password)
{
}
public AboutCompanyDTOCollection SelectAll()
{
InitConnection();
try
{
AboutCompanyDTOCollection items = new();
DBCommand.CommandType = CommandType.StoredProcedure;
DBCommand.CommandText = "About_Company_SelectAll";
DBReader = DBCommand.ExecuteReader();
while(DBReader.Read())
{
AboutCompanyDTO item = new AboutCompanyDTO()
{
AboutCompanyID = GetInt("AboutCompanyID").Value,
AboutHeader = GetString("AboutHeader"),
AboutDescription = GetString("AboutDescription"),
IsVisible = GetBool("IsVisible").Value,
CSS = GetString("CSS"),
ImagePath = GetString("ImagePath")
};
items.Add(item);
}
return items.Count == 0 ? null : items;
}
catch(Exception)
{
throw;
}
finally
{
DisposeConnection();
}
}
}
}

@ -1,9 +1,9 @@
using Common.Library.SQL.MySQL;
using System;
using System.Data;
using Common.Library.DTO.Websites.DMCDynamics.LLC;
using Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC;
namespace Common.Library.DAO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class CompanyInfoDAO : MySQL
{

@ -1,9 +1,9 @@
using Common.Library.SQL.MySQL;
using System;
using System.Data;
using Common.Library.DTO.Websites.DMCDynamics.LLC;
using Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC;
namespace Common.Library.DAO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class ServiceInformationDAO : MySQL
{

@ -1,9 +1,9 @@
using Common.Library.SQL.MySQL;
using System;
using System.Data;
using Common.Library.DTO.Websites.DMCDynamics.LLC;
using Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC;
namespace Common.Library.DAO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class ServicesDAO : MySQL
{

@ -0,0 +1,55 @@
using Common.Library.SQL.MySQL;
using MySql.Data.MySqlClient;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class TestimonialGuidsDAO : MySQL
{
public TestimonialGuidsDAO(string server, string database, string username, string password) : base(server, database, username, password)
{
}
public bool IsTestimonialGUIDValid(string guid)
{
InitConnection();
try
{
bool isValid = false;
DBCommand.CommandType = CommandType.StoredProcedure;
DBCommand.CommandText = "Testimonials_ValidateGUID";
DBCommand.Parameters.Add(new MySqlParameter("GUID", MySqlDbType.VarChar, 255, ParameterDirection.Input, false, 0, 0, string.Empty, DataRowVersion.Proposed, guid));
DBCommand.Parameters.Add(new MySqlParameter("IsValid", MySqlDbType.Bit, 1, ParameterDirection.InputOutput, false, 0, 0, string.Empty, DataRowVersion.Proposed, isValid));
DBCommand.ExecuteNonQuery();
isValid = Convert.ToBoolean(DBCommand.Parameters["IsValid"].Value);
return isValid;
}
catch (Exception)
{
throw;
}
finally
{
DisposeConnection();
}
}
public void MarkGUIDAsUsed(string guid)
{
}
}
}

@ -1,10 +1,10 @@
using Common.Library.SQL.MySQL;
using System;
using System.Data;
using Common.Library.DTO.Websites.DMCDynamics.LLC;
using Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC;
using System.Collections.Generic;
namespace Common.Library.DAO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class TestimonialImagesDAO : MySQL
{
@ -22,7 +22,7 @@ namespace Common.Library.DAO.Websites.DMCDynamics.LLC
DBCommand.CommandType = CommandType.StoredProcedure;
DBCommand.CommandText = "Testimonial_Images_SelectOne";
DBCommand.Parameters.AddWithValue("@testimonialID", testimonialID);
DBCommand.Parameters.AddWithValue("tID", testimonialID);
DBReader = DBCommand.ExecuteReader();
if (DBReader.Read())

@ -1,10 +1,11 @@
using Common.Library.SQL.MySQL;
using System;
using System.Data;
using Common.Library.DTO.Websites.DMCDynamics.LLC;
using Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC;
using System.Collections.Generic;
using MySql.Data.MySqlClient;
namespace Common.Library.DAO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DAO.Websites.DMCDynamics.LLC
{
public class TestimonialsDAO : MySQL
{
@ -13,49 +14,12 @@ namespace Common.Library.DAO.Websites.DMCDynamics.LLC
}
//public TestimonialImagesDTO SelectOne(int testimonialID)
//{
// InitConnection();
// try
// {
// TestimonialImagesDTO item = null;
// DBCommand.CommandType = CommandType.StoredProcedure;
// DBCommand.CommandText = "Testimonial_Images_SelectOne";
// DBCommand.Parameters.AddWithValue("@testimonialID", testimonialID);
// DBReader = DBCommand.ExecuteReader();
// if (DBReader.Read())
// {
// item = new TestimonialImagesDTO()
// {
// TestimonialImageID = GetInt("TestimonialImageID").Value,
// TestimonialID = GetInt("TestimonialID").Value,
// ImageType = GetString("ImageType"),
// ImageData = GetBytes("ImageData")
// };
// }
// return item;
// }
// catch (Exception)
// {
// throw;
// }
// finally
// {
// DisposeConnection();
// }
//}
public TestimonialsDTOCollection SelectAll()
{
InitConnection();
try
{
TestimonialsDTOCollection items = new TestimonialsDTOCollection();
TestimonialsDTOCollection items = new();
DBCommand.CommandType = CommandType.StoredProcedure;
DBCommand.CommandText = "Testimonials_SelectAll";
@ -65,7 +29,7 @@ namespace Common.Library.DAO.Websites.DMCDynamics.LLC
while (DBReader.Read())
{
TestimonialsDTO item = new TestimonialsDTO()
TestimonialsDTO item = new()
{
TestimonialID = GetInt("TestimonialID").Value,
CompanyName = GetString("CompanyName"),
@ -79,7 +43,7 @@ namespace Common.Library.DAO.Websites.DMCDynamics.LLC
}
return (TestimonialsDTOCollection)(items.Count == 0 ? null : items);
return (items.Count == 0 ? null : items);
}
catch (Exception)
{
@ -91,6 +55,32 @@ namespace Common.Library.DAO.Websites.DMCDynamics.LLC
}
}
public int Insert(TestimonialsDTO testimonial)
{
InitConnection();
try
{
DBCommand.CommandType = CommandType.StoredProcedure;
DBCommand.CommandText = "Testimonials_Insert";
//> Add parameters
DBCommand.ExecuteNonQuery();
return (int)DBCommand.Parameters["TestimonialID"].Value;
}
catch(Exception)
{
throw;
}
finally
{
DisposeConnection();
}
}
//public void InsertImage(int testimonialID, KeyValuePair<string, byte[]> imageData)
//{
// InitConnection();

@ -0,0 +1,20 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC
{
public class AboutCompanyDTO
{
public int AboutCompanyID { get; set; }
public string AboutHeader { get; set; }
public string AboutDescription { get; set; }
public bool IsVisible { get; set; }
public string CSS { get; set; }
public string ImagePath { get; set; }
}
public class AboutCompanyDTOCollection : List<AboutCompanyDTO> { }
}

@ -2,7 +2,7 @@ using System.Collections.Generic;
using Common.Library.CustomObjects;
using System.Linq;
namespace Common.Library.DTO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC
{
public class CompanyInfoDTO
{

@ -1,6 +1,6 @@
using System.Collections.Generic;
namespace Common.Library.DTO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC
{
public class ServiceInformationDTO
{

@ -1,6 +1,6 @@
using System.Collections.Generic;
namespace Common.Library.DTO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC
{
public class ServicesDTO
{

@ -4,7 +4,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace Common.Library.DTO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC
{
public class TestimonialImagesDTO
{
@ -13,8 +13,15 @@ namespace Common.Library.DTO.Websites.DMCDynamics.LLC
public string ImageType { get; set; }
public byte[] ImageData { get; set; }
public string ImageDataForWeb => string.Format("data:{0};base64,{1}", ImageType, Convert.ToBase64String(ImageData));
public string ImageDataForWeb => GetImageDataForWeb();
private string GetImageDataForWeb()
{
string imageData = ImageData == null ? string.Empty : Convert.ToBase64String(ImageData);
return $"data:{ImageType ?? string.Empty};base64,{imageData}";
}
}
public class TestimonialImagesDTOCollection : List<TestimonialImagesDTO> { }

@ -4,7 +4,7 @@ using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace Common.Library.DTO.Websites.DMCDynamics.LLC
namespace Common.Library.DataLayer.DTO.Websites.DMCDynamics.LLC
{
public class TestimonialsDTO
{
@ -15,6 +15,8 @@ namespace Common.Library.DTO.Websites.DMCDynamics.LLC
public string CompanyWebsite { get; set; }
public string Testimonial { get; set; }
public TestimonialImagesDTO TestimonialImage { get; set; }
public string TestimonialGUID { get; set; }
}
public class TestimonialsDTOCollection : List<TestimonialsDTO> { }

@ -1,15 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net5.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.StaticFiles" Version="2.2.0" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="3.1.7" />
<PackageReference Include="MySql.Data" Version="8.0.21" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.1" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="5.0.0" />
<PackageReference Include="MySql.Data" Version="8.0.22" />
<PackageReference Include="Serilog" Version="2.10.1-dev-01265" />
<PackageReference Include="Serilog.AspNetCore" Version="3.4.1-dev-00188" />
<PackageReference Include="SixLabors.ImageSharp" Version="1.0.2" />
<PackageReference Include="System.Text.Json" Version="5.0.0" />
</ItemGroup>
</Project>

@ -1,102 +0,0 @@
CREATE DATABASE IF NOT EXISTS dmcdynamics;
CREATE USER 'dmcdynamics'@'localhost' IDENTIFIED BY 'Iu5I03ZDYjtYtqfD';
GRANT ALL ON dmcdynamics.* TO 'dmcdynamics'@'localhost';
FLUSH PRIVILEGES;
CREATE TABLE `companyinfo` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`CompanyName` varchar(255) NOT NULL,
`PhoneNumber` varchar(20) NOT NULL,
`EmailAddress` varchar(100) NOT NULL,
`Address` varchar(255) NOT NULL,
`CompanySlogan` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ;
INSERT INTO `CompanyInfo`
(
CompanyName,
PhoneNumber,
EmailAddress,
Address
)
VALUES
(
'DMC Dynamics LLC',
'(224) 241-2285',
'jobs@dmcdynamics.llc',
'4600 Sycamore Ln, Rolling Meadows, IL 60008'
);
DROP PROCEDURE IF EXISTS dmcdynamics.GetCompanyInfo;
DELIMITER $$
$$
CREATE PROCEDURE dmcdynamics.GetCompanyInfo()
begin
SELECT CompanyName,
PhoneNumber,
EmailAddress,
Address,
CompanySlogan
FROM `CompanyInfo`
LIMIT 1;
END$$
DELIMITER ;
CREATE TABLE `services` (
`ServiceID` int NOT NULL AUTO_INCREMENT,
`ServiceName` varchar(255) NOT NULL,
`ServiceTags` varchar(255) NULL,
`FontAwesomeIcon` varchar(50) NOT NULL,
`IsEnabled` bit(1) NOT NULL DEFAULT b'1',
PRIMARY KEY (`ServiceID`)
);
INSERT INTO `Services` (ServiceName) VALUES ('Software Development');
INSERT INTO `Services` (ServiceName) VALUES ('Web Design & Hosting');
INSERT INTO `Services` (ServiceName) VALUES ('Custom Computers');
INSERT INTO `Services` (ServiceName) VALUES ('Resume Services');
INSERT INTO `Services` (ServiceName) VALUES ('VHS to DVD Conversion');
INSERT INTO `Services` (ServiceName) VALUES ('Tech Consulting');
DROP PROCEDURE IF EXISTS dmcdynamics.GetServices;
DELIMITER $$
$$
CREATE PROCEDURE dmcdynamics.GetServices()
begin
SELECT ServiceID,
ServiceName,
ServiceTags,
FontAwesomeIcon,
IsEnabled
FROM `Services`
WHERE IsEnabled = 1;
END$$
DELIMITER ;
CREATE TABLE dmcdynamics.`service-information` (
ServiceInformationID INT auto_increment NOT NULL,
ServiceID INT NOT NULL,
ServiceDescription varchar(1000) NOT NULL,
CONSTRAINT service_information_pk PRIMARY KEY (ServiceInformationID),
CONSTRAINT service_information_ServiceID_FK FOREIGN KEY (ServiceID) REFERENCES dmcdynamics.services(ServiceID)
)
DROP PROCEDURE IF EXISTS dmcdynamics.ServiceInformation_SelectOne;
DELIMITER $$
$$
CREATE PROCEDURE dmcdynamics.ServiceInformation_SelectOne(
IN ID INT
)
BEGIN
SELECT ServiceInformationID,
ServiceID,
ServiceDescription
FROM `dmcdynamics`.`service-information`
WHERE ServiceID = ID;
END$$
DELIMITER ;

@ -1,136 +0,0 @@
-- MySQL dump 10.13 Distrib 8.0.21, for Win64 (x86_64)
--
-- Host: localhost Database: dmcdynamics
-- ------------------------------------------------------
-- Server version 5.5.5-10.4.14-MariaDB
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!50503 SET NAMES utf8mb4 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
-- Table structure for table `companyinfo`
--
DROP TABLE IF EXISTS `companyinfo`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `companyinfo` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`CompanyName` varchar(255) NOT NULL,
`PhoneNumber` varchar(20) NOT NULL,
`EmailAddress` varchar(100) NOT NULL,
`Address` varchar(255) NOT NULL,
`CompanySlogan` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `companyinfo`
--
LOCK TABLES `companyinfo` WRITE;
/*!40000 ALTER TABLE `companyinfo` DISABLE KEYS */;
INSERT INTO `companyinfo` VALUES (1,'DMC Dynamics LLC','(224) 241-2285','jobs@dmcdynamics.llc','4600 Sycamore Ln, Rolling Meadows, IL 60008',NULL);
/*!40000 ALTER TABLE `companyinfo` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `services`
--
DROP TABLE IF EXISTS `services`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `services` (
`ServiceID` int(11) NOT NULL AUTO_INCREMENT,
`ServiceName` varchar(255) NOT NULL,
`ServiceTags` varchar(255) DEFAULT NULL,
`FontAwesomeIcon` varchar(50) NOT NULL,
`IsEnabled` bit(1) NOT NULL DEFAULT b'1',
PRIMARY KEY (`ServiceID`)
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb4;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `services`
--
LOCK TABLES `services` WRITE;
/*!40000 ALTER TABLE `services` DISABLE KEYS */;
INSERT INTO `services` VALUES (1,'Software Development','C#, ASP.net, PHP','fa-file-code',_binary ''),(2,'Web Design & Hosting','','',_binary '\0'),(3,'Custom Computers Systems','Gaming, Servers','fa-tv',_binary ''),(4,'Resume Services','Updating, Creating','fa-file-word',_binary ''),(5,'VHS to DVD Conversion','','fa-compact-disc',_binary ''),(6,'Tech Consulting','Engineering','fa-user-tie',_binary '');
/*!40000 ALTER TABLE `services` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Dumping routines for database 'dmcdynamics'
--
/*!50003 DROP PROCEDURE IF EXISTS `GetCompanyInfo` */;
/*!50003 SET @saved_cs_client = @@character_set_client */ ;
/*!50003 SET @saved_cs_results = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client = utf8mb4 */ ;
/*!50003 SET character_set_results = utf8mb4 */ ;
/*!50003 SET collation_connection = utf8mb4_general_ci */ ;
/*!50003 SET @saved_sql_mode = @@sql_mode */ ;
/*!50003 SET sql_mode = 'STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,NO_ENGINE_SUBSTITUTION' */ ;
DELIMITER ;;
CREATE DEFINER=`root`@`localhost` PROCEDURE `GetCompanyInfo`()
begin
SELECT CompanyName,
PhoneNumber,
EmailAddress,
Address,
CompanySlogan
FROM `CompanyInfo`
LIMIT 1;
END ;;
DELIMITER ;
/*!50003 SET sql_mode = @saved_sql_mode */ ;
/*!50003 SET character_set_client = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection = @saved_col_connection */ ;
/*!50003 DROP PROCEDURE IF EXISTS `GetServices` */;
/*!50003 SET @saved_cs_client = @@character_set_client */ ;
/*!50003 SET @saved_cs_results = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client = utf8mb4 */ ;
/*!50003 SET character_set_results = utf8mb4 */ ;
/*!50003 SET collation_connection = utf8mb4_general_ci */ ;
/*!50003 SET @saved_sql_mode = @@sql_mode */ ;
/*!50003 SET sql_mode = 'STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,NO_ENGINE_SUBSTITUTION' */ ;
DELIMITER ;;
CREATE DEFINER=`root`@`localhost` PROCEDURE `GetServices`()
begin
SELECT ServiceID,
ServiceName,
ServiceTags,
FontAwesomeIcon,
IsEnabled
FROM `Services`
WHERE IsEnabled = 1;
END ;;
DELIMITER ;
/*!50003 SET sql_mode = @saved_sql_mode */ ;
/*!50003 SET character_set_client = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection = @saved_col_connection */ ;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2020-09-16 20:56:29

@ -1,188 +0,0 @@
-- MySQL dump 10.13 Distrib 8.0.21, for Win64 (x86_64)
--
-- Host: localhost Database: dmcdynamics
-- ------------------------------------------------------
-- Server version 8.0.21
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!50503 SET NAMES utf8mb4 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
-- Table structure for table `companyinfo`
--
DROP TABLE IF EXISTS `companyinfo`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `companyinfo` (
`id` int NOT NULL AUTO_INCREMENT,
`CompanyName` varchar(255) NOT NULL,
`PhoneNumber` varchar(20) NOT NULL,
`EmailAddress` varchar(100) NOT NULL,
`Address` varchar(255) NOT NULL,
`CompanySlogan` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `companyinfo`
--
LOCK TABLES `companyinfo` WRITE;
/*!40000 ALTER TABLE `companyinfo` DISABLE KEYS */;
INSERT INTO `companyinfo` VALUES (1,'DMC Dynamics LLC','(224) 241-2285','jobs@dmcdynamics.llc','4600 Sycamore Ln, Rolling Meadows, IL 60008','Simple tech and personal service solutions that won\'t break the bank!');
/*!40000 ALTER TABLE `companyinfo` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `service-information`
--
DROP TABLE IF EXISTS `service-information`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `service-information` (
`ServiceInformationID` int NOT NULL AUTO_INCREMENT,
`ServiceID` int NOT NULL,
`ServiceDescription` text NOT NULL,
PRIMARY KEY (`ServiceInformationID`),
KEY `service_information_ServiceID_FK` (`ServiceID`),
CONSTRAINT `service_information_ServiceID_FK` FOREIGN KEY (`ServiceID`) REFERENCES `services` (`ServiceID`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `service-information`
--
LOCK TABLES `service-information` WRITE;
/*!40000 ALTER TABLE `service-information` DISABLE KEYS */;
INSERT INTO `service-information` VALUES (1,1,'Let me break it down for you; I have over 8 years of professional software development experience. I have worked in an enterprise setting on some of the most complex Windows desktop applications, server services, and Web APIs. I am confident that I will be able to fit the needs of your next project!');
/*!40000 ALTER TABLE `service-information` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `services`
--
DROP TABLE IF EXISTS `services`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `services` (
`ServiceID` int NOT NULL AUTO_INCREMENT,
`ServiceName` varchar(255) NOT NULL,
`ServiceTags` varchar(255) DEFAULT NULL,
`FontAwesomeIcon` varchar(50) NOT NULL,
`IsEnabled` bit(1) NOT NULL DEFAULT b'1',
PRIMARY KEY (`ServiceID`)
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `services`
--
LOCK TABLES `services` WRITE;
/*!40000 ALTER TABLE `services` DISABLE KEYS */;
INSERT INTO `services` VALUES (1,'Software Development','C#, ASP.net, PHP','fa-file-code',_binary ''),(2,'Web Design & Hosting','','',_binary '\0'),(3,'Custom Computers Systems','Gaming, Servers','fa-tv',_binary ''),(4,'Resume Services','Updating, Creating','fa-file-word',_binary ''),(5,'VHS to DVD Conversion','','fa-compact-disc',_binary ''),(6,'Tech Consulting','Engineering','fa-user-tie',_binary '');
/*!40000 ALTER TABLE `services` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Dumping routines for database 'dmcdynamics'
--
/*!50003 DROP PROCEDURE IF EXISTS `GetCompanyInfo` */;
/*!50003 SET @saved_cs_client = @@character_set_client */ ;
/*!50003 SET @saved_cs_results = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client = utf8mb4 */ ;
/*!50003 SET character_set_results = utf8mb4 */ ;
/*!50003 SET collation_connection = utf8mb4_general_ci */ ;
/*!50003 SET @saved_sql_mode = @@sql_mode */ ;
/*!50003 SET sql_mode = 'STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,NO_ENGINE_SUBSTITUTION' */ ;
DELIMITER ;;
CREATE DEFINER=`root`@`localhost` PROCEDURE `GetCompanyInfo`()
begin
SELECT CompanyName,
PhoneNumber,
EmailAddress,
Address,
CompanySlogan
FROM `CompanyInfo`
LIMIT 1;
END ;;
DELIMITER ;
/*!50003 SET sql_mode = @saved_sql_mode */ ;
/*!50003 SET character_set_client = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection = @saved_col_connection */ ;
/*!50003 DROP PROCEDURE IF EXISTS `GetServices` */;
/*!50003 SET @saved_cs_client = @@character_set_client */ ;
/*!50003 SET @saved_cs_results = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client = utf8mb4 */ ;
/*!50003 SET character_set_results = utf8mb4 */ ;
/*!50003 SET collation_connection = utf8mb4_general_ci */ ;
/*!50003 SET @saved_sql_mode = @@sql_mode */ ;
/*!50003 SET sql_mode = 'STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,NO_ENGINE_SUBSTITUTION' */ ;
DELIMITER ;;
CREATE DEFINER=`root`@`localhost` PROCEDURE `GetServices`()
begin
SELECT ServiceID,
ServiceName,
ServiceTags,
FontAwesomeIcon,
IsEnabled
FROM `Services`
WHERE IsEnabled = 1;
END ;;
DELIMITER ;
/*!50003 SET sql_mode = @saved_sql_mode */ ;
/*!50003 SET character_set_client = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection = @saved_col_connection */ ;
/*!50003 DROP PROCEDURE IF EXISTS `ServiceInformation_SelectOne` */;
/*!50003 SET @saved_cs_client = @@character_set_client */ ;
/*!50003 SET @saved_cs_results = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client = utf8mb4 */ ;
/*!50003 SET character_set_results = utf8mb4 */ ;
/*!50003 SET collation_connection = utf8mb4_0900_ai_ci */ ;
/*!50003 SET @saved_sql_mode = @@sql_mode */ ;
/*!50003 SET sql_mode = 'STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION' */ ;
DELIMITER ;;
CREATE DEFINER=`root`@`localhost` PROCEDURE `ServiceInformation_SelectOne`(
IN ID INT
)
BEGIN
SELECT ServiceInformationID,
ServiceID,
ServiceDescription
FROM `dmcdynamics`.`service-information`
WHERE ServiceID = ID;
END ;;
DELIMITER ;
/*!50003 SET sql_mode = @saved_sql_mode */ ;
/*!50003 SET character_set_client = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection = @saved_col_connection */ ;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2020-09-16 22:43:51

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save