Commit 3fbd8838 by Liv Haapala

Merge branch 'master' of gitlab.codecrew.fi:liv/moya-info-tools

Conflicts:
	MoyaAdmin/MoyaAdminUI/MoyaAdminUI/MainForm.Designer.cs
	MoyaAdmin/MoyaAdminUI/MoyaAdminUI/MainForm.resx
2 parents 19a24f7e 0931745e
......@@ -36,5 +36,7 @@ namespace MoyaAdminLib
return false;
}
}
}
......@@ -1177,6 +1177,7 @@ namespace MoyaAdminUI
OrgMealCounter frm = new OrgMealCounter();
frm.Show();
}
}
......
......@@ -100,6 +100,38 @@ namespace MoyaAdminUI
Card card = ser.Deserialize<Card>(json);
pictureBox1.ImageLocation = RestClient.GetRequestURL(Properties.Settings.Default.ApiURL, "card/GetImage/" + card.cardId);
CardState.Text = card.state;
/*
if (card.state == Card.CARD_STATE_PRINTED)
{
client = new RestClient(Properties.Settings.Default.ApiURL);
try
{
json = client.MakeRequest("meta/v1/printedcard/" + card.cardId + "/card-filing");
}
catch (ApplicationException ex)
{
if (!ex.Message.Contains("HTTP NoContent"))
return;
}
if (json != null && json != "")
{
MetaData data = getValue(json);
int bookNumber = 0;
int pageNumber = 0;
int slotNumber = 0;
getCardPlace(data, out bookNumber, out pageNumber, out slotNumber);
if (bookNumber > 0)
bookNumericUpDown.Value = bookNumber;
if (pageNumber > 0)
pageNumericUpDown.Value = pageNumber;
if (slotNumber > 0)
slotNumericUpDown.Value = slotNumber;
}
}
* */
}
}
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!