..
This commit is contained in:
49
SubProject/FEQ0000/PurchaseNR/fMailForm.cs
Normal file
49
SubProject/FEQ0000/PurchaseNR/fMailForm.cs
Normal file
@@ -0,0 +1,49 @@
|
||||
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 FEQ0000.Purchase
|
||||
{
|
||||
public partial class fMailForm : Form
|
||||
{
|
||||
string Cate = string.Empty;
|
||||
public fMailForm(string cate)
|
||||
{
|
||||
InitializeComponent();
|
||||
Properties.Settings.Default["gwcs"] = FCOMMON.info.CS;
|
||||
Properties.Settings.Default["EEEntities"] = FCOMMON.info.CS;
|
||||
Cate = cate;
|
||||
}
|
||||
|
||||
private void fMailForm_Load(object sender, EventArgs e)
|
||||
{
|
||||
var db = new DataClasses1DataContext();
|
||||
|
||||
var mailform = db.MailForm.Where(t => t.gcode == FCOMMON.info.Login.gcode && t.cate == Cate).ToList();
|
||||
this.cmbForm.DataSource = mailform;
|
||||
this.cmbForm.DisplayMember = "title";
|
||||
this.cmbForm.ValueMember = "idx";
|
||||
}
|
||||
|
||||
private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
var item = this.cmbForm.SelectedItem as MailForm;
|
||||
this.tbSubject.Text = item.subject;
|
||||
this.tbTo.Text = item.tolist;
|
||||
this.tbCC.Text = item.cc;
|
||||
this.tbBcc.Text = item.bcc;
|
||||
this.htmlEditor1.Html = item.body;
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
{
|
||||
DialogResult = DialogResult.OK;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user