Beispiel #1
0
        public string tab3(string patronId, LdapPatron p)
        {
            string dateNowUpdate = DateTime.Now.ToString("yyyyMMdd");

            string hoTen = p.HoTen;
            string str   = "";

            if (hoTen != null && hoTen != "")
            {
                str = addNameKey(p.HoTen) + patronId;
            }
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.Append("<z303>");
            stringBuilder.Append("<match-id-type>00</match-id-type>");
            stringBuilder.Append("<match-id>" + patronId + "</match-id>");
            stringBuilder.Append("<record-action>A</record-action>");
            stringBuilder.Append("<z303-id>" + patronId + "</z303-id>");
            stringBuilder.Append("<z303-name-key>" + str + "</z303-name-key>");
            stringBuilder.Append("<z303-update-date>" + dateNowUpdate + "</z303-update-date>");
            stringBuilder.Append("<z303-name>" + hoTen + "</z303-name>");
            stringBuilder.Append("<z303-delinq-1-update-date>" + dateNowUpdate + "</z303-delinq-1-update-date>");
            stringBuilder.Append("<z303-delinq-2-update-date>" + dateNowUpdate + "</z303-delinq-2-update-date>");
            stringBuilder.Append("<z303-delinq-3-update-date>" + dateNowUpdate + "</z303-delinq-3-update-date>");
            stringBuilder.Append("<z303-profile-id>TNUE-LSP</z303-profile-id>");
            stringBuilder.Append(new ToolP().WriteStringCheckNull(p.Lop, "z303-field-1"));
            stringBuilder.Append(new ToolP().WriteStringCheckNull(p.KhoaHoc, "z303-field-2"));
            stringBuilder.Append(new ToolP().WriteStringCheckNull(p.KhoaNganh, "z303-field-3"));
            stringBuilder.Append("</z303>");
            return(stringBuilder.ToString());
        }
Beispiel #2
0
        public string tab8(string patronId, LdapPatron user)
        {
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.Append("<z308>");
            stringBuilder.Append("<record-action>A</record-action>");
            stringBuilder.Append("<z308-key-type>00</z308-key-type>");
            stringBuilder.Append("<z308-key-data>" + patronId + "</z308-key-data>");
            stringBuilder.Append("<z308-user-library></z308-user-library>");
            stringBuilder.Append("<z308-verification>" + user.userPassword + "</z308-verification>");
            stringBuilder.Append("<z308-verification-type>00</z308-verification-type>");
            stringBuilder.Append("<z308-id>" + patronId + "</z308-id>");
            stringBuilder.Append("<z308-status>AC</z308-status>");
            stringBuilder.Append("<z308-encryption>H</z308-encryption>");
            stringBuilder.Append("</z308>");
            stringBuilder.Append("<z308>");
            stringBuilder.Append("<record-action>A</record-action>");
            stringBuilder.Append("<z308-key-type>01</z308-key-type>");
            stringBuilder.Append("<z308-key-data>" + user.userLogin + "</z308-key-data>");
            stringBuilder.Append("<z308-user-library></z308-user-library>");
            stringBuilder.Append("<z308-verification>" + user.userPassword + "</z308-verification>");
            stringBuilder.Append("<z308-verification-type>00</z308-verification-type>");
            stringBuilder.Append("<z308-id>" + patronId + "</z308-id>");
            stringBuilder.Append("<z308-status>AC</z308-status>");
            stringBuilder.Append("<z308-encryption>H</z308-encryption>");
            stringBuilder.Append("</z308>");
            return(stringBuilder.ToString());
        }
Beispiel #3
0
        public string tab4(string patronId, LdapPatron user)
        {
            ToolP         toolP         = new ToolP();
            string        str           = toolP.formatDate(DateTime.Now.ToString("dd/MM/yyyy"));
            StringBuilder stringBuilder = new StringBuilder();

            stringBuilder.Append("<z304>");
            stringBuilder.Append("<record-action>A</record-action>");
            stringBuilder.Append("<email-address>" + user.userMail + "</email-address>");
            stringBuilder.Append("<z304-id>" + patronId + "</z304-id>");
            stringBuilder.Append("<z304-sequence>01</z304-sequence>");
            stringBuilder.Append("<z304-email-address>" + user.userMail + "</z304-email-address>");
            stringBuilder.Append("<z304-telephone>" + user.telephoneNumber + "</z304-telephone>");
            stringBuilder.Append("<z304-address-type>01</z304-address-type>");
            stringBuilder.Append("<z304-update-date>" + str + "</z304-update-date>");
            stringBuilder.Append("</z304>");
            return(stringBuilder.ToString());
        }