示例#1
0
        public string PinDocumentForUser(RequestObject requestObject, Client client, DocumentData documentData)
        {
            string status = string.Empty;

            if (null != requestObject && null != client && null != documentData && ValidationHelperFunctions.CheckRequestValidatorToken())
            {
                ////Create document object and populate meta-data
                DocumentData userPinnedDocumentData = new DocumentData()
                {
                    DocumentName         = SearchHelperFunctions.EncodeValues(documentData.DocumentName),
                    DocumentVersion      = SearchHelperFunctions.EncodeValues(documentData.DocumentVersion),
                    DocumentClient       = SearchHelperFunctions.EncodeValues(documentData.DocumentClient),
                    DocumentClientId     = SearchHelperFunctions.EncodeValues(documentData.DocumentClientId),
                    DocumentClientUrl    = SearchHelperFunctions.EncodeValues(documentData.DocumentClientUrl),
                    DocumentMatter       = SearchHelperFunctions.EncodeValues(documentData.DocumentMatter),
                    DocumentMatterId     = SearchHelperFunctions.EncodeValues(documentData.DocumentMatterId),
                    DocumentOwner        = SearchHelperFunctions.EncodeValues(documentData.DocumentOwner),
                    DocumentUrl          = SearchHelperFunctions.EncodeValues(documentData.DocumentUrl),
                    DocumentOWAUrl       = SearchHelperFunctions.EncodeValues(documentData.DocumentOWAUrl),
                    DocumentExtension    = SearchHelperFunctions.EncodeValues(documentData.DocumentExtension),
                    DocumentCreatedDate  = SearchHelperFunctions.EncodeValues(documentData.DocumentCreatedDate),
                    DocumentModifiedDate = SearchHelperFunctions.EncodeValues(documentData.DocumentModifiedDate),
                    DocumentCheckoutUser = SearchHelperFunctions.EncodeValues(documentData.DocumentCheckoutUser),
                    DocumentMatterUrl    = SearchHelperFunctions.EncodeValues(documentData.DocumentMatterUrl),
                    DocumentParentUrl    = SearchHelperFunctions.EncodeValues(documentData.DocumentParentUrl),
                    DocumentID           = SearchHelperFunctions.EncodeValues(documentData.DocumentID)
                };
                status = SearchHelperFunctions.PopulateMetadeta(requestObject, client, null, userPinnedDocumentData);
            }
            else
            {
                status = TextConstants.MessageNoInputs;
            }
            return(status);
        }
示例#2
0
        public string PinMatterForUser(RequestObject requestObject, Client client, MatterData matterData)
        {
            string status = string.Empty;

            if (null != requestObject && null != client && null != matterData && ValidationHelperFunctions.CheckRequestValidatorToken())
            {
                ////Create matter object and populate meta-data
                MatterData userPinnedMatterData = new MatterData()
                {
                    MatterName                = SearchHelperFunctions.EncodeValues(matterData.MatterName),
                    MatterDescription         = SearchHelperFunctions.EncodeValues(matterData.MatterDescription),
                    MatterCreatedDate         = SearchHelperFunctions.EncodeValues(matterData.MatterCreatedDate),
                    MatterUrl                 = SearchHelperFunctions.EncodeValues(matterData.MatterUrl),
                    MatterPracticeGroup       = SearchHelperFunctions.EncodeValues(matterData.MatterPracticeGroup),
                    MatterAreaOfLaw           = SearchHelperFunctions.EncodeValues(matterData.MatterAreaOfLaw),
                    MatterSubAreaOfLaw        = SearchHelperFunctions.EncodeValues(matterData.MatterSubAreaOfLaw),
                    MatterClientUrl           = SearchHelperFunctions.EncodeValues(matterData.MatterClientUrl),
                    MatterClient              = SearchHelperFunctions.EncodeValues(matterData.MatterClient),
                    MatterClientId            = SearchHelperFunctions.EncodeValues(matterData.MatterClientId),
                    HideUpload                = SearchHelperFunctions.EncodeValues(matterData.HideUpload),
                    MatterID                  = SearchHelperFunctions.EncodeValues(matterData.MatterID),
                    MatterResponsibleAttorney = SearchHelperFunctions.EncodeValues(matterData.MatterResponsibleAttorney),
                    MatterModifiedDate        = SearchHelperFunctions.EncodeValues(matterData.MatterModifiedDate),
                    MatterGuid                = SearchHelperFunctions.EncodeValues(matterData.MatterGuid)
                };
                status = SearchHelperFunctions.PopulateMetadeta(requestObject, client, userPinnedMatterData, null);
            }
            else
            {
                status = TextConstants.MessageNoInputs;
            }
            return(status);
        }