|
|
@@ -25,10 +25,11 @@ namespace UAS_Web
|
|
|
InitializeComponent();
|
|
|
Text = "供应商条码打印";
|
|
|
|
|
|
- string path = "http://183.238.39.179:8099/ERP/jsps/vendbarcode/login.jsp";
|
|
|
+ string path = "http://113.108.109.210:8099/ERP/vendbarcode/relogin.action";
|
|
|
webBrowser = new ChromiumWebBrowser(path)
|
|
|
{
|
|
|
Dock = DockStyle.Fill
|
|
|
+
|
|
|
};
|
|
|
CheckForIllegalCrossThreadCalls = false;
|
|
|
webBrowser.MenuHandler = new MenuHandler();
|
|
|
@@ -61,7 +62,7 @@ namespace UAS_Web
|
|
|
|
|
|
private void visitor_SendCookie(CefSharp.Cookie obj)
|
|
|
{
|
|
|
- if (obj.Path.Contains("jsps/vendbarcode"))
|
|
|
+ if (obj.Path.Contains("vendbarcode"))
|
|
|
{
|
|
|
if (obj.Name == "username")
|
|
|
BaseUtil.SetCacheData("username", HttpUtility.UrlDecode(obj.Value));
|
|
|
@@ -76,14 +77,14 @@ namespace UAS_Web
|
|
|
|
|
|
private void WebBrowser_LoadError(object sender, LoadErrorEventArgs e)
|
|
|
{
|
|
|
- //指定放大镜
|
|
|
- if (e.FailedUrl.Contains("vendbarcode/batchdelivery.jsp?whoami=Delivery!Deal#"))
|
|
|
- return;
|
|
|
- if (e.FailedUrl.Contains("common/excel"))
|
|
|
- return;
|
|
|
- if (e.FailedUrl.Contains("common/downloadbyId.action"))
|
|
|
- return;
|
|
|
- MessageBox.Show("当前网络无法访问" + e.ErrorText);
|
|
|
+ ////指定放大镜
|
|
|
+ //if (e.FailedUrl.Contains("vendbarcode/batchdelivery.jsp?whoami=Delivery!Deal#"))
|
|
|
+ // return;
|
|
|
+ //if (e.FailedUrl.Contains("common/excel"))
|
|
|
+ // return;
|
|
|
+ //if (e.FailedUrl.Contains("common/downloadbyId.action"))
|
|
|
+ // return;
|
|
|
+ //MessageBox.Show("当前网络无法访问" + e.ErrorText);
|
|
|
}
|
|
|
|
|
|
private void Browser_FormClosing(object sender, FormClosingEventArgs e)
|
|
|
@@ -102,6 +103,15 @@ namespace UAS_Web
|
|
|
pro[i].Kill();
|
|
|
}
|
|
|
}
|
|
|
+ textBox1.Text = webBrowser.Address;
|
|
|
+ }
|
|
|
+
|
|
|
+ private void textBox1_KeyDown(object sender, KeyEventArgs e)
|
|
|
+ {
|
|
|
+ if (e.KeyCode == Keys.Enter)
|
|
|
+ {
|
|
|
+ webBrowser.Load(textBox1.Text);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|