FrmAgvTest.cs
2.1 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
using OnlineStore.DeviceLibrary;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace ConveyorLine
{
public partial class FrmAgvTest : Form
{
public FrmAgvTest()
{
InitializeComponent();
}
ContainerInfo containerInfo = new ContainerInfo();
private void button1_Click(object sender, EventArgs e)
{
containerInfo.InOrOutStore = ContainerType.InStore;
containerInfo.ContainerCode = txtContainerCode.Text;
containerInfo.InoutParam.slotCode = txtlocationCode.Text;
SServerManager.CreateInStoreOrder(new List<ContainerInfo>() { containerInfo },true);
}
private void button2_Click(object sender, EventArgs e)
{
containerInfo.InOrOutStore = ContainerType.OutStore;
containerInfo.ContainerCode = txtContainerCode.Text;
SServerManager.CreateOutStoreOrder(new List<ContainerInfo> { containerInfo },true);
}
private void button3_Click(object sender, EventArgs e)
{
SServerManager.ContarinerArrived(new OnlineStore.DeviceLibrary.ESS.EssModel() { containerCode = txtContainerCode.Text, slotCode = "1-4" });
}
private void radioButton1_CheckedChanged(object sender, EventArgs e)
{
if (radioButton1.Checked)
{
txtlocationCode.Enabled = true;
containerInfo.InOrOutStore = ContainerType.InStore;
button2.Enabled = false;
button1.Enabled = true;
button3.Enabled = true;
}
else if(radioButton2.Checked)
{
containerInfo.InOrOutStore = ContainerType.OutStore;
txtlocationCode.Enabled = false;
button2.Enabled = true;
button1.Enabled = false;
button3.Enabled = false;
}
}
}
}