Beispiel #1
0
        //protected virtual string GetContent(string pk)
        //{
        //    Durados.Web.Mvc.View contentView = (Durados.Web.Mvc.View)Map.Database.Views[GetContentViewName()];
        //    contentView.Database.Logger.Log(contentView.Name, "Start", "GetContent", "Notifier", "", 14, DateTime.Now.Millisecond.ToString(), DateTime.Now);
        //    DataRow contentRow = contentView.GetDataRow(pk);

        //    if (contentRow == null)
        //        return null;

        //    string content = contentView.GetDisplayValue(GetContentFieldName(), contentRow);

        //    contentView.Database.Logger.Log(contentView.Name, "End", "GetContent", "Notifier", "", 14, DateTime.Now.Millisecond.ToString(), DateTime.Now);
        //    return content;
        //}

        protected virtual string GetContent(Durados.Workflow.INotifier controller, string pk)
        {
            Durados.Web.Mvc.View contentView = (Durados.Web.Mvc.View)controller.GetNonConfigView(GetContentViewName());
            Field field = contentView.Fields[GetContentFieldName()];

            return(controller.GetFieldValue((ColumnField)field, pk) ?? pk);
        }