반환 데이터 서버와 클라이언트로 나누기
This commit is contained in:
parent
c33e0240f6
commit
c7b6eaa106
|
|
@ -10,15 +10,18 @@ namespace Server.Git
|
|||
public string name { get { return _name; } }
|
||||
List<string> _variable;
|
||||
public List<string> variable { get { return _variable; } }
|
||||
List<string> _dataEnum;
|
||||
public List<string> dataEnum { get { return _dataEnum; } }
|
||||
List<string> _type;
|
||||
public List<string> type { get { return _type; } }
|
||||
Dictionary<long, Dictionary<string, object>> _dicViewer;
|
||||
public Dictionary<long, Dictionary<string, object>> dicViewer { get { return _dicViewer; } }
|
||||
|
||||
public sheet(string name, List<string> variable, List<string> type, Dictionary<long, Dictionary<string, object>> dicViewer)
|
||||
public sheet(string name, List<string> variable, List<string> dataEnum, List<string> type, Dictionary<long, Dictionary<string, object>> dicViewer)
|
||||
{
|
||||
this._name = name;
|
||||
this._variable = variable;
|
||||
this._dataEnum = dataEnum;
|
||||
this._type = type;
|
||||
this._dicViewer = dicViewer;
|
||||
}
|
||||
|
|
@ -61,6 +64,8 @@ namespace Server.Git
|
|||
{
|
||||
//변수이름
|
||||
List<string> variable = new List<string>();
|
||||
//서버용인지 클라용인지 나뉘는 타입
|
||||
List<string> dataEnum = new List<string>();
|
||||
//변수 타입
|
||||
List<string> type = new List<string>();
|
||||
Dictionary<long, Dictionary<string, object>> dicViewer = new Dictionary<long, Dictionary<string, object>>();
|
||||
|
|
@ -76,7 +81,8 @@ namespace Server.Git
|
|||
for (int n = 0; n <= horizontal; n++)
|
||||
{
|
||||
variable.Add((string)worksheet.Cells[0, n].Value);
|
||||
type.Add(((string)worksheet.Cells[2, n].Value).ToLower());
|
||||
type.Add(((string)worksheet.Cells[3, n].Value).ToLower());
|
||||
dataEnum.Add(((string)worksheet.Cells[2, n].Value).ToLower());
|
||||
}
|
||||
|
||||
bool isIndex = variable[0] == "index";
|
||||
|
|
@ -90,7 +96,7 @@ namespace Server.Git
|
|||
}
|
||||
dicViewer.Add((int)(isIndex ? worksheet.Cells[n, 0].Value : n - 3), dataList);
|
||||
}
|
||||
sheet sheet = new sheet(worksheet.Name, variable, type, dicViewer);
|
||||
sheet sheet = new sheet(worksheet.Name, variable, dataEnum, type, dicViewer);
|
||||
_sheets.Add(sheet);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,6 +44,9 @@ namespace Server.Git
|
|||
query = "";
|
||||
for (int n = 0; n < sheets.Count; n++)
|
||||
{
|
||||
if (sheets[n].dataEnum[0] == "client")
|
||||
continue;
|
||||
|
||||
//초기화
|
||||
newTableQuery = "";
|
||||
tableDatas = "(";
|
||||
|
|
|
|||
|
|
@ -22,6 +22,8 @@ namespace Server.Git
|
|||
sheets = em.sheets;
|
||||
for (int m = 0; m < sheets.Count; m++)
|
||||
{
|
||||
if (sheets[m].dataEnum[0] == "server")
|
||||
continue;
|
||||
sheetList.Add(sheets[m].name, sheets[m].dicViewer);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ namespace Server.Service
|
|||
user = new User();
|
||||
user.mail = req.mail;
|
||||
user.uuid = Guid.NewGuid().ToString();
|
||||
user.nickname = "";
|
||||
user.nickname = "NoName";
|
||||
userSql.Insert(user); //저장하고 유닛의 id를 얻어오기 위함.
|
||||
#endregion
|
||||
#region 초기 유닛 지급
|
||||
|
|
|
|||
Loading…
Reference in New Issue