移动表单的保存自动提交、审核、反审核操作怎么做?有类似的dome没?
IOperationResult result = Kingdee.BOS.ServiceHelper.BusinessDataServiceHelper.Save(this.Context, _info, new DynamicObject[] { _currentSaleObj }, null, "Save");
if (result.IsSuccess)
{
if (result.SuccessDataEnity != null && result.SuccessDataEnity.Count() > 0)
{
DynamicObject successDy = result.SuccessDataEnity.FirstOrDefault();
string key = successDy.DynamicObjectType.PrimaryKey.Name;
//这就是保存成功后的主键值
int PrimaryKeyValue = Convert.ToInt32(successDy[key]);
}
StringBuilder mes = new StringBuilder();
foreach (OperateResult res in result.OperateResult)
{
mes.Append(res.Message).Append(";");
}
this.View.ShowMessage(mes.ToString());
}
else
{
StringBuilder stringBuilder = new StringBuilder();
OperateResultCollection operateResult = result.OperateResult;
foreach (OperateResult current in operateResult)
{
if (!current.SuccessStatus)
{
stringBuilder.AppendLine(current.Message + ";");
}
}
base.View.ShowErrMessage(string.Format("保存失败:{0}", stringBuilder.ToString()), "", MessageBoxType.Notice);
}
TIM截图20171019152941.png(17.21KB)
推荐阅读