本文整理汇总了C#中Ebada.Scgl.Model.WF_ModleRecordWorkTaskIns类的典型用法代码示例。如果您正苦于以下问题:C# WF_ModleRecordWorkTaskIns类的具体用法?C# WF_ModleRecordWorkTaskIns怎么用?C# WF_ModleRecordWorkTaskIns使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
WF_ModleRecordWorkTaskIns类属于Ebada.Scgl.Model命名空间,在下文中一共展示了WF_ModleRecordWorkTaskIns类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: gridView1_DoubleClick
private void gridView1_DoubleClick(object sender, EventArgs e) {
if (gridView1.FocusedRowHandle < -1)
return;
PJ_anqgjcrkd rowdata = gridView1.GetFocusedRow() as PJ_anqgjcrkd;
rowdata = ClientHelper.PlatformSqlMap.GetOneByKey<PJ_anqgjcrkd>(rowdata.ID);
frmAQGJCKSingleXZ frm = new frmAQGJCKSingleXZ();
frm.RowData = new PJ_anqgjcrkd();
ConvertHelper.CopyTo<PJ_anqgjcrkd>(rowdata, (PJ_anqgjcrkd)frm.RowData);
((PJ_anqgjcrkd)frm.RowData).Remark = "";
IList<PJ_anqgjcrkd> pnumli = Client.ClientHelper.PlatformSqlMap.GetListByWhere
<PJ_anqgjcrkd>(" where id like '" + DateTime.Now.ToString("yyyyMMdd") + "%' and type='" + comboBoxEdit6.Text + "' order by id desc ");
if (pnumli.Count == 0)
((PJ_anqgjcrkd)frm.RowData).num = "JAQGJCK" + DateTime.Now.ToString("yyyyMMdd") + string.Format("{0:D4}", 1);
else {
((PJ_anqgjcrkd)frm.RowData).num = "JAQGJCK" + (Convert.ToDecimal(pnumli[0].num.Replace("JAQGJCK", "")) + 1);
}
((PJ_anqgjcrkd)frm.RowData).ckdate = DateTime.Now;
double i = 0;
if (frm.ShowDialog() == DialogResult.OK) {
PJ_anqgjcrkd ckd = new PJ_anqgjcrkd();
ConvertHelper.CopyTo<PJ_anqgjcrkd>(rowdata, ckd);
ckd.ID = ckd.CreateID();
System.Collections.IList mclist = ClientHelper.PlatformSqlMap.GetList("SelectOneInt",
"select sum(cast(kcsl as float) ) from PJ_anqgjcrkd where (type = '局安全工器具入库单' or type = '局安全工器具入库单原始库存')"
+ " and wpmc='" + rowdata.wpmc + "' "
+ " and wpgg='" + rowdata.wpgg + "' ");
if (mclist[0] != null) i = Convert.ToDouble(mclist[0].ToString());
double cktemp = Convert.ToDouble(frm.ReturnData.cksl);
double zkc = Convert.ToDouble(i);
// i = Client.ClientHelper.PlatformSqlMap.GetRowCount
//<PJ_anqgjcrkd>(" where id like '" + DateTime.Now.ToString("yyyyMMdd") + "%' and type='" + comboBoxEdit6.Text + "' ");
ckd.num = frm.ReturnData.num;
ckd.type = comboBoxEdit6.Text;
ckd.Remark = frm.ReturnData.Remark;
ckd.OrgName = frm.ReturnData.OrgName;
ckd.OrgCode = frm.ReturnData.OrgCode;
ckd.ckdate = DateTime.Now;
if (cktemp >= Convert.ToDouble(rowdata.kcsl)) {
ckd.cksl = rowdata.kcsl;
ckd.zkcsl = (zkc - Convert.ToDouble(rowdata.kcsl)).ToString();
cktemp = cktemp - Convert.ToDouble(rowdata.kcsl);
ckd.kcsl = "0";
rowdata.kcsl = "0";
ClientHelper.PlatformSqlMap.Update<PJ_anqgjcrkd>(rowdata);
} else {
ckd.cksl = cktemp.ToString();
ckd.zkcsl = (zkc - cktemp).ToString();
rowdata.kcsl = (Convert.ToDouble(rowdata.kcsl) - cktemp).ToString();
ckd.kcsl = rowdata.kcsl;
cktemp = 0;
ClientHelper.PlatformSqlMap.Update<PJ_anqgjcrkd>(rowdata);
}
ckd.lyparent = rowdata.ID;
zkc = Convert.ToDouble(ckd.zkcsl);
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
if (isWorkflowCall) {
MainHelper.PlatformSqlMap.DeleteByWhere<WF_ModleRecordWorkTaskIns>(" where ModleRecordID='" + ckd.ID + "' and RecordID='" + currRecord.ID + "'"
+ " and WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "'"
+ " and WorkFlowInsId='" + WorkFlowData.Rows[0]["WorkFlowInsId"].ToString() + "'"
+ " and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "'"
+ " and WorkTaskInsId='" + WorkFlowData.Rows[0]["WorkTaskInsId"].ToString() + "'");
}
ClientHelper.PlatformSqlMap.Create<PJ_anqgjcrkd>(ckd);
if (isWorkflowCall) {
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ModleRecordID = ckd.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = ckd.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
}
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
PJ_anqgjcrkd slkd = new PJ_anqgjcrkd();
//ConvertHelper.CopyTo<PJ_anqgjcrkd>(ckd, slkd);
decimal snum;
double szkc = 0;
pnumli = Client.ClientHelper.PlatformSqlMap.GetListByWhere
<PJ_anqgjcrkd>(" where id like '" + DateTime.Now.ToString("yyyyMMdd") + "%' and type='所安全工器具入库单' order by id desc ");
if (pnumli.Count == 0)
snum = Convert.ToDecimal(DateTime.Now.ToString("yyyyMMdd") + string.Format("{0:D4}", 0));
else {
snum = (Convert.ToDecimal(pnumli[0].num.Replace("SAQGJRK", "")));
}
slkd.ID = slkd.CreateID();
slkd.wpmc = ckd.wpmc;
slkd.wpgg = ckd.wpgg;
slkd.wpdw = ckd.wpdw;
slkd.wpdj = ckd.wpdj;
slkd.wpsl = ckd.cksl;
//.........这里部分代码省略.........
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:101,代码来源:UCAQGJCKGL.cs
示例2: barxqjl_ItemClick
private void barxqjl_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
{
if (gridView1.FocusedRowHandle < 0) return;
//请求确认
if (MsgBox.ShowAskMessageBox("是否确认选中记录消缺,并进入下一流程?") != DialogResult.OK)
{
return;
}
foreach (var item in gridView1.GetSelectedRows())
{
PJ_qxfl pj = gridView1.GetRow(item) as PJ_qxfl;
PJ_qxfl pj1 = gridView1.GetRow(item) as PJ_qxfl;
if (pj.s1 != pj1.s1)
{
MsgBox.ShowWarningMessageBox("类型不一致,请统一后再消缺!");
return;
}
}
foreach (var item in gridView1.GetSelectedRows())
{
PJ_qxfl pj = gridView1.GetRow(item) as PJ_qxfl;
if (pj != null)
{
ClientHelper.PlatformSqlMap.Update<PJ_qxfl>(pj);
}
}
PJ_qxfl qxfl = gridView1.GetFocusedRow() as PJ_qxfl;
string strmes = "";
currRecord.OrgName = qxfl.OrgName;
currRecord.LastChangeTime = DateTime.Now.ToString();
if (RecordWorkTask.CheckOnRiZhi(WorkFlowData))
{
RecordWorkTask.CreatRiZhi(WorkFlowData, null, currRecord.ID, new object[] { qxfl, currRecord });
}
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ModleRecordID = qxfl.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = qxfl.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
WF_WorkTaskCommands wt;
//string[] strtemp = RecordWorkTask.RunNewGZPRecord(currRecord.ID, kind, MainHelper.User.UserID);
wt = (WF_WorkTaskCommands)MainHelper.PlatformSqlMap.GetObject("SelectWF_WorkTaskCommandsList", " where WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "' and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "'");
if (wt != null)
{
strmes = RecordWorkTask.RunWorkFlow(MainHelper.User.UserID, WorkFlowData.Rows[0]["OperatorInsId"].ToString(), WorkFlowData.Rows[0]["WorkTaskInsId"].ToString(), wt.CommandName);
}
else
{
strmes = RecordWorkTask.RunWorkFlow(MainHelper.User.UserID, WorkFlowData.Rows[0]["OperatorInsId"].ToString(), WorkFlowData.Rows[0]["WorkTaskInsId"].ToString(), "提交");
}
if (strmes.IndexOf("未提交至任何人") > -1)
{
MsgBox.ShowTipMessageBox("未提交至任何人,创建失败,请检查流程模板和组织机构配置是否正确!");
return;
}
else
MsgBox.ShowTipMessageBox(strmes);
strmes = RecordWorkTask.GetWorkFlowTaskCaption(WorkFlowData.Rows[0]["WorkTaskInsId"].ToString());
if (strmes == "结束节点1")
{
currRecord.Status = "存档";
}
else
{
currRecord.Status = strmes;
}
if (currRecord.ImageAttachment == null)
{
currRecord.ImageAttachment = new byte[0];
}
if (currRecord.DocContent == null)
{
currRecord.DocContent = new byte[0];
}
if (currRecord.SignImg == null)
{
currRecord.SignImg = new byte[0];
}
currRecord.LastChangeTime = DateTime.Now.ToString();
if (currRecord.ImageAttachment == null) currRecord.ImageAttachment = new byte[0];
if (currRecord.SignImg == null) currRecord.SignImg = new byte[0];
MainHelper.PlatformSqlMap.Update("UpdateLP_Record", currRecord);
gridControl1.FindForm().Close();
}
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:99,代码来源:UCPJ_SBQXMX.cs
示例3: simpleButton4_Click
private void simpleButton4_Click(object sender, EventArgs e)
{
rowData.ID = rowData.CreateID();
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
Client.ClientHelper.PlatformSqlMap.Create<PJ_wgclcrkd>(rowData);
if (isWorkflowCall)
{
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ModleRecordID = rowData.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = rowData.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
}
MsgBox.ShowTipMessageBox("添加成功!");
rowData.ID = rowData.CreateID();
}
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:21,代码来源:frmWGCJCLRKEdit.cs
示例4: ExportExceljhbAllSubmitToWF_ModleRecordWorkTaskIns
public void ExportExceljhbAllSubmitToWF_ModleRecordWorkTaskIns(string orgid, string strProject, string strfenProject)
{
string filter = "";
int i = 0;
List<WF_ModleRecordWorkTaskIns> mrwtlist = new List<WF_ModleRecordWorkTaskIns>();
string strfirst = "";
string filter2 = "";
string filter3 = "";
string filter4 = "";
if (strProject != "全部")
filter2 = " where 1=1 and ssgc='" + strProject + "' and type = '撤旧材料出库单' ";
else
filter2 = " where 1=1 and type = '撤旧材料出库单' ";
IList mclist = ClientHelper.PlatformSqlMap.GetList("SelectOneStr", "select distinct ssgc from PJ_clcrkd " + filter2 + " order by ssgc");
foreach (string mc in mclist)
{
if (strfenProject == "全部")
filter3 = " where 1=1 and type = '撤旧材料出库单' ";
else
filter3 = " where ssxm='" + strfenProject + "' and type = '撤旧材料出库单' ";
IList xmlist = ClientHelper.PlatformSqlMap.GetList("SelectOneStr", "select distinct ssxm from PJ_clcrkd " + filter3 + " order by ssxm");
foreach (string xm in xmlist)
{
filter4 = " where 1=1 and type = '撤旧材料出库单'"
+ " and ssgc='" + mc + "' "
+ " and ssxm='" + xm + "' ";
//IList sjlist = ClientHelper.PlatformSqlMap.GetList("SelectOneStr", "select distinct CONVERT(varchar(50) ,indate, 112 ) from PJ_clcrkd " + filter4 + " ");
IList sjlist = ClientHelper.PlatformSqlMap.GetList("SelectOneStr", "select distinct num from PJ_clcrkd " + filter4 + " ");
foreach (string sj in sjlist)
{
filter = " where 1=1 and type = '撤旧材料出库单'"
+ " and ssgc='" + mc + "' "
+ " and ssxm='" + xm
+ "' and num= '" + sj + "' ";
if (isWorkflowCall)
{
filter = filter + " and id not in (select ModleRecordID from WF_ModleRecordWorkTaskIns where WorkFlowId='"
+ WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "') "
+ " or id in (select ModleRecordID from WF_ModleRecordWorkTaskIns where "
+ " RecordID='" + currRecord.ID + "') "
;
}
IList<PJ_clcrkd> datalist = Client.ClientHelper.PlatformSqlMap.GetListByWhere<PJ_clcrkd>(
filter
);
if (isWorkflowCall)
{
for (i = 0; i < datalist.Count; i++)
{
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ID = mrwt.CreateID();
mrwt.ModleRecordID = datalist[i].ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.ModleTableName = datalist[i].GetType().ToString();
mrwt.CreatTime = DateTime.Now;
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
mrwtlist.Add(mrwt);
}
}
}
}
}
List<SqlQueryObject> list3 = new List<SqlQueryObject>();
if (mrwtlist.Count > 0)
{
SqlQueryObject obj3 = new SqlQueryObject(SqlQueryType.Insert, mrwtlist.ToArray());
list3.Add(obj3);
}
MainHelper.PlatformSqlMap.ExecuteTransationUpdate(list3);
}
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:90,代码来源:ExportCJCLCKEdit.cs
示例5: gridView1_DoubleClick
private void gridView1_DoubleClick(object sender, EventArgs e)
{
if (gridView1.FocusedRowHandle < -1)
return;
PJ_clcrkd rowdata = gridView1.GetFocusedRow() as PJ_clcrkd;
rowdata = ClientHelper.PlatformSqlMap.GetOneByKey<PJ_clcrkd>(rowdata.ID);
frmFCLCKSingleXZ frm = new frmFCLCKSingleXZ();
frm.RowData = new PJ_clcrkd();
ConvertHelper.CopyTo<PJ_clcrkd>(rowdata, (PJ_clcrkd)frm.RowData);
((PJ_clcrkd)frm.RowData).Remark = "";
IList<PJ_clcrkd> pnumli = Client.ClientHelper.PlatformSqlMap.GetListByWhere
<PJ_clcrkd>(" where id like '" + DateTime.Now.ToString("yyyyMMdd") + "%' and type='" + comboBoxEdit6.Text + "' order by id desc ");
if (pnumli.Count == 0)
((PJ_clcrkd)frm.RowData).num = "FSCCK" + DateTime.Now.ToString("yyyyMMdd") + string.Format("{0:D4}", 1);
else
{
((PJ_clcrkd)frm.RowData).num = "FSCCK" + (Convert.ToDecimal(pnumli[0].num.Replace("FSCCK", "")) + 1);
}
((PJ_clcrkd)frm.RowData).ckdate = DateTime.Now;
double i = 0;
if (frm.ShowDialog() == DialogResult.OK)
{
PJ_clcrkd ckd = new PJ_clcrkd();
ConvertHelper.CopyTo<PJ_clcrkd>(rowdata, ckd);
ckd.ID = ckd.CreateID();
System.Collections.IList mclist = ClientHelper.PlatformSqlMap.GetList("SelectOneInt",
"select sum(cast(kcsl as float) ) from PJ_clcrkd where (type = '非生产物资入库单' or type = '非生产物资入库单单原始库存')"
+ " and wpmc='" + rowdata.wpmc + "' " + " and ssgc='" + rowdata.ssgc + "' "
+ " and wpgg='" + rowdata.wpgg + "' ");
if (mclist[0] != null) i = Convert.ToDouble(mclist[0].ToString());
double cktemp = Convert.ToDouble(frm.ReturnData.cksl);
double zkc = Convert.ToDouble(i);
// i = Client.ClientHelper.PlatformSqlMap.GetRowCount
//<PJ_clcrkd>(" where id like '" + DateTime.Now.ToString("yyyyMMdd") + "%' and type='" + comboBoxEdit6.Text + "' ");
ckd.num = frm.ReturnData.num;
ckd.type = comboBoxEdit6.Text;
ckd.Remark = frm.ReturnData.Remark;
ckd.yt = frm.ReturnData.yt;
ckd.ssxm = frm.ReturnData.ssxm;
ckd.lqdw = frm.ReturnData.lqdw;
ckd.ghdw = frm.ReturnData.ghdw;
ckd.ckdate = DateTime.Now;
if (cktemp >= Convert.ToDouble(rowdata.kcsl))
{
ckd.cksl = rowdata.kcsl;
ckd.zkcsl = (zkc - Convert.ToDouble(rowdata.kcsl)).ToString();
cktemp = cktemp - Convert.ToDouble(rowdata.kcsl);
ckd.kcsl = "0";
rowdata.kcsl = "0";
ClientHelper.PlatformSqlMap.Update<PJ_clcrkd>(rowdata);
}
else
{
ckd.cksl = cktemp.ToString();
ckd.zkcsl = (zkc - cktemp).ToString();
rowdata.kcsl = (Convert.ToDouble(rowdata.kcsl) - cktemp).ToString();
ckd.kcsl = rowdata.kcsl;
cktemp = 0;
ClientHelper.PlatformSqlMap.Update<PJ_clcrkd>(rowdata);
}
ckd.lyparent = rowdata.ID;
zkc = Convert.ToDouble(ckd.zkcsl);
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
if (isWorkflowCall)
{
MainHelper.PlatformSqlMap.DeleteByWhere<WF_ModleRecordWorkTaskIns>(" where ModleRecordID='" + ckd.ID + "' and RecordID='" + currRecord.ID + "'"
+ " and WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "'"
+ " and WorkFlowInsId='" + WorkFlowData.Rows[0]["WorkFlowInsId"].ToString() + "'"
+ " and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "'"
+ " and WorkTaskInsId='" + WorkFlowData.Rows[0]["WorkTaskInsId"].ToString() + "'");
}
ClientHelper.PlatformSqlMap.Create<PJ_clcrkd>(ckd);
if (isWorkflowCall)
{
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ModleRecordID = ckd.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = ckd.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
}
ucclck1.inidata();
//simpleButton2_Click(sender, e);
}
}
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:94,代码来源:UCFCKGL.cs
示例6: btnOK_Click
private void btnOK_Click(object sender, EventArgs e) {
string strmes = "";
PJ_qxfl sbxs = RowData as PJ_qxfl;
object obj = MainHelper.PlatformSqlMap.GetOneByKey<PJ_qxfl>(sbxs.ID);
if (obj == null && isWorkflowCall) {
sbxs.CreateDate = DateTime.Now;
sbxs.CreateMan = MainHelper.User.UserName;
MainHelper.PlatformSqlMap.Create<PJ_qxfl>(sbxs);
if (isWorkflowCall) {
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ModleRecordID = sbxs.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = sbxs.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
}
} else if (isWorkflowCall) {
MainHelper.PlatformSqlMap.Update<PJ_qxfl>(RowData);
}
PJ_06sbxsmx qxfltemp = new PJ_06sbxsmx();
{
qxfltemp.ID = sbxs.ID;
qxfltemp.LineID = sbxs.LineID;
qxfltemp.LineName = sbxs.LineName;
qxfltemp.OrgCode = sbxs.OrgCode;
qxfltemp.OrgName = sbxs.OrgName;
qxfltemp.qxlb = sbxs.qxlb;
qxfltemp.qxnr = sbxs.qxnr;
qxfltemp.xssj = sbxs.xssj;
qxfltemp.xsr = sbxs.xsr;
qxfltemp.xcqx = sbxs.xcqx;
qxfltemp.xlqd = sbxs.xlqd; ;
qxfltemp.xcr = sbxs.xcr;
qxfltemp.xcrq = sbxs.xcrq;
qxfltemp.CreateMan = sbxs.CreateMan;
}
frmWorkFlow06sbxsEdit.update(qxfltemp);
//currRecord.ImageAttachment = bt;
//currRecord.SignImg = bt;
currRecord.OrgName = rowData.OrgName;
currRecord.LastChangeTime = DateTime.Now.ToString();
if (RecordWorkTask.CheckOnRiZhi(WorkFlowData)) {
RecordWorkTask.CreatRiZhi(WorkFlowData, null, currRecord.ID, new object[] { sbxs, currRecord });
}
WF_WorkTaskCommands wt;
//if (RecordWorkTask.CheckOnRiZhi(WorkFlowData)) {
// RecordWorkTask.CreatRiZhi(WorkFlowData, null, currRecord.ID, new object[] { sbxs, currRecord });
//}
//string[] strtemp = RecordWorkTask.RunNewGZPRecord(currRecord.ID, kind, MainHelper.User.UserID);
wt = (WF_WorkTaskCommands)MainHelper.PlatformSqlMap.GetObject("SelectWF_WorkTaskCommandsList", " where WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "' and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "'");
if (wt != null) {
strmes = RecordWorkTask.RunWorkFlow(MainHelper.User.UserID, WorkFlowData.Rows[0]["OperatorInsId"].ToString(), WorkFlowData.Rows[0]["WorkTaskInsId"].ToString(), wt.CommandName);
} else {
strmes = RecordWorkTask.RunWorkFlow(MainHelper.User.UserID, WorkFlowData.Rows[0]["OperatorInsId"].ToString(), WorkFlowData.Rows[0]["WorkTaskInsId"].ToString(), "提交");
}
if (strmes.IndexOf("未提交至任何人") > -1) {
MsgBox.ShowTipMessageBox("未提交至任何人,创建失败,请检查流程模板和组织机构配置是否正确!");
return;
} else
MsgBox.ShowTipMessageBox(strmes);
strmes = RecordWorkTask.GetWorkFlowTaskCaption(WorkFlowData.Rows[0]["WorkTaskInsId"].ToString());
if (strmes == "结束节点1") {
currRecord.Status = "存档";
} else {
currRecord.Status = strmes;
}
if (currRecord.ImageAttachment == null) {
currRecord.ImageAttachment = new byte[0];
}
if (currRecord.DocContent == null) {
currRecord.DocContent = new byte[0];
}
if (currRecord.SignImg == null) {
currRecord.SignImg = new byte[0];
}
currRecord.LastChangeTime = DateTime.Now.ToString();
if (currRecord.ImageAttachment == null) currRecord.ImageAttachment = new byte[0];
if (currRecord.SignImg == null) currRecord.SignImg = new byte[0];
MainHelper.PlatformSqlMap.Update("UpdateLP_Record", currRecord);
}
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:93,代码来源:frmsbqxWorkFlowEdit.cs
示例7: btnOK_Click
private void btnOK_Click(object sender, EventArgs e)
{
string strname = "";
string fname = "";
string bhname = "";
int icount = 1;
DSOFramerControl dsoFramerControl1 = new DSOFramerControl();
Microsoft.Office.Interop.Excel.Workbook wb;
ExcelAccess ea = new ExcelAccess();
if (rowData.BigData == null || rowData.BigData.Length == 0)
{
fname = Application.StartupPath + "\\00记录模板\\26防护通知书.xls";
dsoFramerControl1.FileOpen(fname);
}
else
dsoFramerControl1.FileData = rowData.BigData;
wb = dsoFramerControl1.AxFramerControl.ActiveDocument as Microsoft.Office.Interop.Excel.Workbook;
ea.MyWorkBook = wb;
ea.MyExcel = wb.Application;
if (rowData.BigData == null || rowData.BigData.Length == 0)
{
fname = Application.StartupPath + "\\00记录模板\\26防护通知书.xls";
mOrg org = MainHelper.PlatformSqlMap.GetOneByKey<mOrg>(rowData.ParentID);
bhname = org.OrgName.Replace("供电所", "");
PJ_26 objtemp = (PJ_26)MainHelper.PlatformSqlMap.GetObject("SelectPJ_26List", "where ParentID='" + rowData.ParentID + "' and xybh like '" + SelectorHelper.GetPysm(org.OrgName.Replace("供电所", ""), true) + "-" + DateTime.Now.Year.ToString() + "-%' order by xybh ASC");
if (objtemp != null && objtemp.xybh != "")
{
icount = Convert.ToInt32(objtemp.xybh.Split('-')[2]) + 1;
}
rowData.xybh = SelectorHelper.GetPysm(bhname, true).ToUpper() + "-" + DateTime.Now.Year.ToString() + "-" + string.Format("{0:D3}", icount);
strname = SelectorHelper.GetPysm(bhname, true);
ea.SetCellValue(strname.ToUpper(), 4, 9);
strname = DateTime.Now.Year.ToString();
ea.SetCellValue(strname, 4, 11);
strname = string.Format("{0:D3}", icount);
ea.SetCellValue(strname, 4, 13);
}
ea.SetCellValue(comboBoxEdit1.Text + ":", 5, 2);
ea.SetCellValue(comboBoxEdit3.Text, 6, 11);
if (memoEdit2.Text.Length > 25)
{
ea.SetCellValue(memoEdit2.Text.Substring(0, 25), 7, 3);
ea.SetCellValue(memoEdit2.Text.Substring(26), 8, 2);
}
else
{
ea.SetCellValue(memoEdit2.Text, 7, 3);
}
if (memoEdit3.Text.Length > 23)
{
ea.SetCellValue(memoEdit3.Text.Substring(0, 23), 13, 4);
ea.SetCellValue(memoEdit3.Text.Substring(24), 14, 2);
}
else
{
ea.SetCellValue(memoEdit3.Text, 13, 4);
}
dsoFramerControl1.FileSave();
rowData.BigData = dsoFramerControl1.FileData;
dsoFramerControl1.FileClose();
dsoFramerControl1.Dispose();
dsoFramerControl1 = null;
PJ_26 sbxs = RowData as PJ_26;
string strmes = "";
object obj = MainHelper.PlatformSqlMap.GetOneByKey<PJ_26>(sbxs.ID);
if (obj == null)
{
MainHelper.PlatformSqlMap.Create<PJ_26>(sbxs);
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ModleRecordID = sbxs.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = sbxs.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
}
else
{
MainHelper.PlatformSqlMap.Update<PJ_26>(sbxs);
}
currRecord.LastChangeTime = DateTime.Now.ToString();
if (RecordWorkTask.CheckOnRiZhi(WorkFlowData))
{
RecordWorkTask.CreatRiZhi(WorkFlowData, null, currRecord.ID, new object[] { rowData, currRecord });
//.........这里部分代码省略.........
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:101,代码来源:frm26WorkFlowEdit.cs
示例8: barxqjh_ItemClick
private void barxqjh_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
{
//请求确认
if (MsgBox.ShowAskMessageBox("是否确认此节点结束,生成消缺计划并进入下一流程?") != DialogResult.OK)
{
//SendMessage(this.Handle, 0x0010, (IntPtr)0, (IntPtr)0);
return;
}
string slqwhere = "where OrgCode='" + parentID + "' ";
slqwhere = slqwhere + " and id not in (select ModleRecordID from WF_ModleRecordWorkTaskIns where RecordID='" + CurrRecord.ID + "'";
slqwhere = slqwhere + " and WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "'"
+ " and WorkFlowInsId='" + WorkFlowData.Rows[0]["WorkFlowInsId"].ToString() + "'"
+ " and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "'"
+ " and WorkTaskInsId='" + WorkFlowData.Rows[0]["WorkTaskInsId"].ToString() + "')"
+ " and DATEDIFF(day,cast('1900-1-1' as datetime ) ,cast(xcrq as datetime) )<1 ";
slqwhere += " order by id desc";
dalist = MainHelper.PlatformSqlMap.GetListByWhere<PJ_06sbxs>(slqwhere);
string strmes = "";
if (RecordWorkTask.CheckOnRiZhi(WorkFlowData))
{
RecordWorkTask.CreatRiZhi(WorkFlowData, null, currRecord.ID, new object[] { currRecord });
}
WF_WorkTaskCommands wt = (WF_WorkTaskCommands)MainHelper.PlatformSqlMap.GetObject("SelectWF_WorkTaskCommandsList", " where WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "' and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "'");
if (wt != null)
{
strmes = RecordWorkTask.RunWorkFlow(MainHelper.User.UserID, WorkFlowData.Rows[0]["OperatorInsId"].ToString(), WorkFlowData.Rows[0]["WorkTaskInsId"].ToString(), wt.CommandName);
}
else
{
strmes = RecordWorkTask.RunWorkFlow(MainHelper.User.UserID, WorkFlowData.Rows[0]["OperatorInsId"].ToString(), WorkFlowData.Rows[0]["WorkTaskInsId"].ToString(), "提交");
}
if (strmes.IndexOf("未提交至任何人") > -1)
{
MsgBox.ShowTipMessageBox("未提交至任何人,创建失败,请检查流程模板和组织机构配置是否正确!");
return;
}
else
MsgBox.ShowTipMessageBox(strmes);
if (fjly == null) fjly = new frmModleFjly();
fjly.btn_Submit_Click(sender, e);
strmes = RecordWorkTask.GetWorkFlowTaskCaption(WorkFlowData.Rows[0]["WorkTaskInsId"].ToString());
if (strmes == "结束节点1")
{
currRecord.Status = "存档";
}
else
{
currRecord.Status = strmes;
}
currRecord.LastChangeTime = DateTime.Now.ToString();
if (currRecord.ImageAttachment == null) currRecord.ImageAttachment = new byte[0];
if (currRecord.SignImg == null) currRecord.SignImg = new byte[0];
MainHelper.PlatformSqlMap.Update("UpdateLP_Record", CurrRecord);
DataTable dt = RecordWorkTask.GetRecordWorkFlowData(currRecord.ID, MainHelper.User.UserID);
slqwhere = "where OrgCode='" + parentID + "' ";
slqwhere = slqwhere + " and (id not in (select ModleRecordID from WF_ModleRecordWorkTaskIns where 1=1 ";
slqwhere = slqwhere + " and WorkFlowId='" + WorkFlowData.Rows[0]["WorkFlowId"].ToString() + "'"
+ " and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "') "
+ " or (id in (select ModleRecordID from WF_ModleRecordWorkTaskIns where 1=1 ";
slqwhere = slqwhere + " and RecordID='" + currRecord.ID + "'"
+ " and WorkFlowInsId='" + WorkFlowData.Rows[0]["WorkFlowInsId"].ToString() + "' "
+ " and WorkTaskInsId='" + WorkFlowData.Rows[0]["WorkTaskInsId"].ToString() + "' "
+ " and WorkTaskId='" + WorkFlowData.Rows[0]["WorkTaskId"].ToString() + "')) "
+ ")"
;
slqwhere += " order by id desc";
dalist = MainHelper.PlatformSqlMap.GetListByWhere<PJ_06sbxs>(slqwhere);
foreach (PJ_06sbxs sbxs in dalist)
{
if (sbxs.qxlb == "") continue;
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
PJ_qxfl qxfj = new PJ_qxfl();
if (WorkFlowData.Rows[0]["flowcaption"].ToString() == "春查消缺外查")
{
PJ_ccxqjh ccxqjh = new PJ_ccxqjh();
ccxqjh.ID = sbxs.ID;
ccxqjh.OrgCode = sbxs.OrgCode;
ccxqjh.OrgName = sbxs.OrgName;
ccxqjh.qxlb = sbxs.qxlb;
ccxqjh.xqlr = sbxs.qxnr;
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
try
{
MainHelper.PlatformSqlMap.Create<PJ_ccxqjh>(ccxqjh);
}
catch { }
qxfj.ID = ccxqjh.ID;
mrwt.ID = mrwt.CreateID();
mrwt.ModleRecordID = ccxqjh.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = dt.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = dt.Rows[0]["WorkFlowInsId"].ToString();
//.........这里部分代码省略.........
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:101,代码来源:UCPJ_cq06sbxsmain.cs
示例9: btAddfrm_ItemClick
//.........这里部分代码省略.........
((UserControl)obj).Dock = DockStyle.Fill;
dlg.Show();
}
else
if (obj is Form)
{
if (obj is frmyxfxWorkFlowEdit)
{
PJ_03yxfx yxfx = new PJ_03yxfx();
yxfx.OrgCode = MainHelper.UserOrg.OrgCode;
yxfx.OrgName = MainHelper.UserOrg.OrgName;
if (parentObj.FlowCaption.IndexOf("定期分析") > 0)
yxfx.type = "定期分析";
else
if (parentObj.FlowCaption.IndexOf("专题分析") > 0)
yxfx.type = "专题分析";
((frmyxfxWorkFlowEdit)obj).RecordStatus = 0;
yxfx.rq = DateTime.Now;
((frmyxfxWorkFlowEdit)obj).RowData = yxfx;
}
else if (obj is frmsbqxWorkFlowEdit)
{
PJ_qxfl qxfl = new PJ_qxfl();
qxfl = new PJ_qxfl();
qxfl.OrgCode = MainHelper.UserOrg.OrgCode;
qxfl.OrgName = MainHelper.UserOrg.OrgName;
((frmsbqxWorkFlowEdit)obj).RowData = qxfl;
}
else if (obj is frmWorkFlow06sbxsEdit)
{
IList<WF_ModleRecordWorkTaskIns> li = MainHelper.PlatformSqlMap.GetListByWhere<WF_ModleRecordWorkTaskIns>(" where RecordID='" + lpr.ID + "'"
+ " and WorkFlowId='" + recordWorkFlowData.Rows[0]["WorkFlowId"].ToString() + "' and ModleTableName='Ebada.Scgl.Model.PJ_06sbxsmx'"
+ " and WorkFlowInsId='" + recordWorkFlowData.Rows[0]["WorkFlowInsId"].ToString() + "' order by CreatTime desc");
PJ_06sbxsmx qxfl = new PJ_06sbxsmx();
if (li.Count > 0)
{
PJ_qxfl qxfltemp = MainHelper.PlatformSqlMap.GetOneByKey<PJ_qxfl>(li[0].ModleRecordID);
qxfl = MainHelper.PlatformSqlMap.GetOne<PJ_06sbxsmx>(" where CONVERT(varchar, CreateDate, 120 ) = '" + qxfltemp.CreateDate + "'"
+ " and LineID='" + qxfltemp.LineID + "'"
+ " and OrgCode='" + qxfltemp.OrgCode + "'"
+ " and qxlb='" + qxfltemp.qxlb + "'"
+ " and xsr='" + qxfltemp.xsr + "'"
+ " and xlqd='" + qxfltemp.xlqd + "'"
);
if (qxfl == null)
{
qxfl = new PJ_06sbxsmx();
qxfl.CreateDate = qxfltemp.CreateDate;
qxfl.LineID = qxfltemp.LineID;
qxfl.LineName = qxfltemp.LineName;
qxfl.OrgCode = qxfltemp.OrgCode;
qxfl.OrgName = qxfltemp.OrgName;
qxfl.qxlb = qxfltemp.qxlb;
qxfl.qxnr = qxfltemp.qxnr;
qxfl.xssj = qxfltemp.xssj;
qxfl.xsr = qxfltemp.xsr;
qxfl.xcqx = qxfltemp.xcqx;
qxfl.xlqd = qxfltemp.xlqd;
qxfl.CreateDate = DateTime.Now;
qxfl.CreateMan = MainHelper.User.UserName;
//MainHelper.PlatformSqlMap.Create<PJ_06sbxs>(qxfl);
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:67,代码来源:UCmLPRecord.cs
示例10: ExportExceljhbAllSubmitToWF_ModleRecordWorkTaskIns
public void ExportExceljhbAllSubmitToWF_ModleRecordWorkTaskIns(DateTime dt,DateTime dt2, string orgid)
{
string filter = "";
int i = 0;
if (orgid != "") filter = " and OrgCode='" + orgid + "'";
string startday = "20";
IList list = Client.ClientHelper.PlatformSqlMap.GetList("SelectOneStr",
string.Format("select nr from pj_dyk where dx='所月度停电计划' and sx like '%{0}%' and nr!=''", "申报截止日期"));
if (list.Count > 0)
startday = list[0].ToString();
filter = " where (TDtime between '" + dt.Year + "-"
+ dt.Month + "-" + dt.Day
+ " 00:00:00' and '"
+ dt2.Year + "-"
+ dt2.Month + "-" + dt2.Day + " 23:59:59' ) ";
if (orgid != "") filter += " and OrgCode='" + orgid + "'";
if (isWorkflowCall)
{
filter = filter + " and (id not in (select ModleRecordID from WF_ModleRecordWorkTaskIns where WorkFlowInsId='"
+ WorkFlowData.Rows[0]["WorkFlowInsId"].ToString() + "') "
+ " or id in (select ModleRecordID from WF_ModleRecordWorkTaskIns where "
+ " RecordID='" + currRecord.ID + "')) "
;
}
IList<PJ_tdjh> datalist = Client.ClientHelper.PlatformSqlMap.GetListByWhere<PJ_tdjh>(
filter
);
List<WF_ModleRecordWorkTaskIns> mrwtlist = new List<WF_ModleRecordWorkTaskIns>();
if (isWorkflowCall)
{
for (i = 0; i < datalist.Count; i++)
{
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
mrwt.ID = mrwt.CreateID();
mrwt.ModleRecordID = datalist[i].ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.ModleTableName = datalist[i].GetType().ToString();
mrwt.CreatTime = DateTime.Now;
Thread.Sleep(new TimeSpan(100000));//0.1毫秒
mrwtlist.Add(mrwt);
}
}
List<SqlQueryObject> list3 = new List<SqlQueryObject>();
if (mrwtlist.Count > 0)
{
SqlQueryObject obj3 = new SqlQueryObject(SqlQueryType.Insert, mrwtlist.ToArray());
list3.Add(obj3);
}
MainHelper.PlatformSqlMap.ExecuteTransationUpdate(list3);
}
开发者ID:s7loves,项目名称:mypowerscgl,代码行数:63,代码来源:ExportJTDJH.cs
示例11: gridViewOperation_AfterAdd
void gridViewOperation_AfterAdd(PJ_06sbxs newobj)
{
WF_ModleRecordWorkTaskIns mrwt = new WF_ModleRecordWorkTaskIns();
if (isWorkflowCall)
{
mrwt.ModleRecordID = newobj.ID;
mrwt.RecordID = currRecord.ID;
mrwt.WorkFlowId = WorkFlowData.Rows[0]["WorkFlowId"].ToString();
mrwt.WorkFlowInsId = WorkFlowData.Rows[0]["WorkFlowInsId"].ToString();
mrwt.WorkTaskId = WorkFlowData.Rows[0]["WorkTaskId"].ToString();
mrwt.ModleTableName = newobj.GetType().ToString();
mrwt.WorkTaskInsId = WorkFlowData.Rows[0]["WorkTaskInsId"].ToString();
mrwt.CreatTime = DateTime.Now;
MainHelper.PlatformSqlMap.Create<WF_ModleRecordWorkTaskIns>(mrwt);
//currRecord.DocContent = newobj.BigData;
//MainHelper.PlatformSqlMap.Update<LP_Record>(currRecord);
}
if (newobj.qxlb != "")
{
PJ_qxfl qxfj = new PJ_qxfl();
qxfj.ID = newobj.ID;
qxfj.CreateDate = newobj.CreateDate;
qxfj.CreateMan = newobj.CreateMan;
qxfj.LineID = newobj.LineID;
qxfj.LineName = newobj.LineName;
qxfj.OrgCode = newobj.OrgCode;
qxfj.OrgName = newobj.O
|
请发表评论