|
|
@ -5,6 +5,8 @@ using System.Text; |
|
|
|
using System.Threading.Tasks; |
|
|
|
using System.Threading.Tasks; |
|
|
|
using System.Data.SqlClient; |
|
|
|
using System.Data.SqlClient; |
|
|
|
using TinyPosEntity; |
|
|
|
using TinyPosEntity; |
|
|
|
|
|
|
|
using TinyPosEntity.Entity; |
|
|
|
|
|
|
|
using TinyPosEntity.Service; |
|
|
|
|
|
|
|
|
|
|
|
namespace TinyPosDBGen |
|
|
|
namespace TinyPosDBGen |
|
|
|
{ |
|
|
|
{ |
|
|
@ -30,12 +32,28 @@ namespace TinyPosDBGen |
|
|
|
|
|
|
|
|
|
|
|
Console.WriteLine(); |
|
|
|
Console.WriteLine(); |
|
|
|
Console.WriteLine("데이터베이스를 초기화 합니다."); |
|
|
|
Console.WriteLine("데이터베이스를 초기화 합니다."); |
|
|
|
|
|
|
|
Console.WriteLine(""); |
|
|
|
|
|
|
|
Console.WriteLine("처리중..."); |
|
|
|
|
|
|
|
|
|
|
|
EntityController.ConnectionString = connString; |
|
|
|
EntityController.ConnectionString = connString; |
|
|
|
EntityController.Instance.InitializeDatabase(); |
|
|
|
EntityController.Instance.InitializeDatabase(); |
|
|
|
|
|
|
|
|
|
|
|
Console.WriteLine("초기화가 완료되었습니다."); |
|
|
|
Console.WriteLine("초기화가 완료되었습니다."); |
|
|
|
Console.WriteLine(); |
|
|
|
|
|
|
|
|
|
|
|
Console.WriteLine("----------------------------------"); |
|
|
|
|
|
|
|
List<ProductType> productTypeList = ProductTypeService.Instance.FindAll(); |
|
|
|
|
|
|
|
if (productTypeList != null && productTypeList.Count > 0) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
Console.WriteLine("등록된 제품타입"); |
|
|
|
|
|
|
|
Console.WriteLine(); |
|
|
|
|
|
|
|
Console.WriteLine("id\t|\tname"); |
|
|
|
|
|
|
|
foreach (ProductType pt in productTypeList) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
Console.WriteLine(string.Format("{0}\t|\t{1}", pt.ProductTypeId, pt.Name)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
Console.WriteLine("----------------------------------"); |
|
|
|
|
|
|
|
|
|
|
|
Console.WriteLine("종료를 위해 아무키나 누르세요."); |
|
|
|
Console.WriteLine("종료를 위해 아무키나 누르세요."); |
|
|
|
Console.ReadKey(); |
|
|
|
Console.ReadKey(); |
|
|
|
//Student student = new Student() |
|
|
|
//Student student = new Student() |
|
|
|