예제 #1
0
        protected override void BeforeDelete(DataRow row)
        {
            CLAS.HardshipRow myRow      = (CLAS.HardshipRow)row;
            string           ObjectName = this.myDT.TableName;

            this.myA.FM.GetActivity().DeleteRelatedCA(myRow.FileId, ObjectName, myRow.HardshipId);
        }
예제 #2
0
        protected override void AfterUpdate(DataRow dr)
        {
            CLAS.HardshipRow myRow = (CLAS.HardshipRow)dr;

            System.Xml.XmlDocument xd = new System.Xml.XmlDocument();
            xd.InnerXml = myA.FM.CurrentFile.FileStructXml;
            MyXml(myRow, xd);
            myA.FM.CurrentFile.FileStructXml = xd.InnerXml;
        }
예제 #3
0
 protected override void AfterChange(DataColumn dc, DataRow ddr)
 {
     CLAS.HardshipRow myRow = (CLAS.HardshipRow)ddr;
     switch (dc.ColumnName)
     {
     default:
         break;
     }
 }
예제 #4
0
        protected override void AfterAdd(DataRow dr)
        {
            CLAS.HardshipRow myRow      = (CLAS.HardshipRow)dr;
            string           ObjectName = this.myDT.TableName;

            myRow.HardshipId  = this.myA.AtMng.PKIDGet(ObjectName, 1);
            myRow.FileId      = myA.FM.CurrentFileId;
            myRow.Recovery    = false;
            myRow.Setoff      = false;
            myRow.RequestDate = DateTime.Today;
        }
예제 #5
0
        public override void ApplySecurity(DataRow dr)
        {
            if (FileForm() != null && FileForm().ReadOnly)
            {
                return;
            }

            CLAS.HardshipRow cbr = (CLAS.HardshipRow)dr;
            UIHelper.EnableControls(hardshipBindingSource, FM.GetCLASMng().GetHardship().CanEdit(cbr));
            UIHelper.EnableCommandBarCommand(tsDelete, FM.GetCLASMng().GetHardship().CanDelete(cbr));
        }
예제 #6
0
        public override bool CanDelete(DataRow dr)
        {
            bool ok = false;

            CLAS.HardshipRow fo = (CLAS.HardshipRow)dr;
            atSecurity.SecurityManager.LevelPermissions perm = myA.AtMng.SecurityManager.CanDelete(fo.FileId, atSecurity.SecurityManager.Features.Hardship);
            if (perm != atSecurity.SecurityManager.LevelPermissions.No)
            {
                ok = true;
            }

            return(ok);
        }
예제 #7
0
        private void MyXml(CLAS.HardshipRow r, System.Xml.XmlDocument xd)
        {
            System.Xml.XmlElement xe = (System.Xml.XmlElement)xd.SelectSingleNode("//toc[@type='hardship' and @id=" + r.HardshipId.ToString() + "]");
            if (xe == null)
            {
                xe = xd.CreateElement("toc");
                xe.SetAttribute("type", "hardship");
                xe.SetAttribute("supertype", "bankruptcy");
            }
            xe.SetAttribute("id", r.HardshipId.ToString());

            string title = r.RequestDate.ToString("yyyy/MM/dd");

            xe.SetAttribute("titlee", title);
            xe.SetAttribute("titlef", title);


            if (xe.ParentNode == null)
            {
                System.Xml.XmlElement xes = EFileBE.XmlAddFld(xd, "hardship", "Hardships", "Hardships", 240);
                xes.AppendChild(xe);
            }
        }