コード例 #1
0
        private void FrmTL_ModifyTask_Load(object sender, EventArgs e)
        {
            if (DocId != -1)
            {
                txtDocId.Text = DocId.ToString();
            }
            if (AnalystName != null)
            {
                txtAnalyst.Text = AnalystName;
            }
            if (ReviewerName != null)
            {
                txtReviewer.Text = ReviewerName;
            }
            if (QcAnalystName != null)
            {
                txtQc.Text = QcAnalystName;
            }
            DataTable dtActiveCurators = UserManagementDB.GetUserDetailsOnRoleId(8, Common.GlobalVariables.Module);

            BindActiveCurators(dtActiveCurators);

            DataTable dtActiveReviewers = UserManagementDB.GetUserDetailsOnRoleId(7, Common.GlobalVariables.Module);

            BindActiveReviewers(dtActiveReviewers);

            DataTable dtActiveQcs = UserManagementDB.GetUserDetailsOnRoleId(6, Common.GlobalVariables.Module);

            BindActiveQcs(dtActiveQcs);
        }
コード例 #2
0
    protected void IbtnNext_Click(object sender, ImageClickEventArgs e)
    {
        Int32 DocId;

        DocId = 0;
        DataTable dt = new DataTable();

        //dt = clsDocument.SelectDocumentforApprovalNext (Convert.ToInt32(hdnDocId.Value));

        dt = clsDocument.SelectDocumentforApproval(hdnDocId.Value, "True");
        if (dt.Rows.Count > 0)
        {
            if (jk < dt.Rows.Count && jk >= 0)
            {
                DocId          = Convert.ToInt32(dt.Rows[jk]["DocumentId"].ToString());
                hdnDocId.Value = DocId.ToString();
                jk             = jk + 1;
            }
        }
        if (DocId != 0)
        {
            LoadPdf(DocId);
            FillDocDetail(sender, e);
        }

        ibtnFirst.Enabled = true;
        IbtnNext.Enabled  = true;
        IbtnPrev.Enabled  = true;
        IbtnLast.Enabled  = true;
    }
コード例 #3
0
        /// <summary>
        /// Returns a list of doc id's for the pages in the root of the passed directory
        /// </summary>
        /// <param name="dir"></param>
        /// <returns></returns>
        public static List <DocId> ListPages(string dir)
        {
            var repoDir = HttpContext.Current.Server.MapPath(Settings.RepositoryPath);
            var path    = Path.Combine(repoDir, dir);

            return((from file in Directory.EnumerateFiles(path)
                    where !Path.GetFileName(file).StartsWith(".")
                    select DocId.ForPath(file.Replace(repoDir, ""))).ToList());
        }
コード例 #4
0
 public IEnumerable<IDocument> Store(IEnumerable<IDocument> documents)
 {
     foreach (var document in documents)
     {
         var key = new DocId(document);
         _data[key] = document;
         yield return document;
     }
 }
コード例 #5
0
        public IDocument Retrieve(Type type, string id)
        {
            if (type == null) throw new ArgumentNullException("type");
            if (id == null) throw new ArgumentNullException("id");

            var key = new DocId(type, id);
            IDocument value;
            _data.TryGetValue(key, out value);
            return value;
        }
コード例 #6
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (DocId != 0)
            {
                hash ^= DocId.GetHashCode();
            }
            if (WithName != false)
            {
                hash ^= WithName.GetHashCode();
            }
            hash ^= codes_.GetHashCode();
            return(hash);
        }
コード例 #7
0
        public override string ToString()
        {
            string gender;

            if (DocGender)
            {
                gender = "male";
            }
            else
            {
                gender = "female";
            }
            return($"Id: {DocId.ToString()}," +
                   $" Doctor Name: {DocForename} {DocSurname}," +
                   $" Gender: {gender}," +
                   $" DocAddress: {DocAddress}," +
                   $" DocPhoneNum: {DocPhoneNumber}" +
                   $" Qualifications: {DocQualification}" +
                   $" Department: {DeptId.ToString()}");
        }
コード例 #8
0
        public MissingTypeInfo(AssemblyInfo sourceAssembly, string docId, List <Version> targetStatus, string recommendedChanges)
            : base(docId)
        {
            int pos = DocId.IndexOf("T:");

            if (pos == -1)
            {
                throw new ArgumentException(LocalizedStrings.MemberShouldBeDefinedOnTypeException, "docId");
            }

            TypeName            = DocId.Substring(pos);
            MissingMembers      = new HashSet <MissingMemberInfo>();
            TargetStatus        = targetStatus?.Select(GenerateTargetStatusMessage).ToList() ?? Enumerable.Empty <string>();
            TargetVersionStatus = new List <Version>(targetStatus ?? Enumerable.Empty <Version>());

            RecommendedChanges = recommendedChanges;
            _usedInAssemblies  = new HashSet <AssemblyInfo>();

            if (sourceAssembly != null)
            {
                _usedInAssemblies.Add(sourceAssembly);
            }
        }
コード例 #9
0
    protected void IbtnLast_Click(object sender, ImageClickEventArgs e)
    {
        Int32 DocId;

        DocId             = 0;
        ibtnFirst.Enabled = true;
        IbtnNext.Enabled  = false;
        IbtnPrev.Enabled  = true;
        IbtnLast.Enabled  = false;
        DataTable dt = new DataTable();

        dt = clsDocument.SelectDocumentforApprovalLast();
        if (dt.Rows.Count > 0)
        {
            DocId          = Convert.ToInt32(dt.Rows[0]["DocumentId"].ToString());
            hdnDocId.Value = DocId.ToString();
        }
        if (DocId != 0)
        {
            LoadPdf(DocId);
            FillDocDetail(sender, e);
        }
    }
コード例 #10
0
 public override int GetHashCode()
 {
     return(_type.GetHashCode() + DocId.GetHashCode());
 }
コード例 #11
0
 public override int GetHashCode()
 {
     return(DocId.GetHashCode());
 }
コード例 #12
0
ファイル: Index.cs プロジェクト: ronnieoverby/GetYoCastOn
 internal abstract void Remove(DocId docId);
コード例 #13
0
        public override bool Equals(object obj)
        {
            var other = obj as DocumentModel;

            return(DocId.Equals(other.DocId));
        }
コード例 #14
0
 public void Remove(Type type, string id)
 {
     IDocument value;
     var key = new DocId(type, id);
     _data.TryRemove(key, out value);
 }
コード例 #15
0
        //The ID of a generic method uses postfix ``n, n is the count of in method parameters, for example, System.Tuple.Create``1(``0)
        public override void Build(ECMAStore store)
        {
            if (DocId != null && DocId.Contains('|'))
            {
                var parts = DocId.Split(':');
                if (parts?.Length == 2)
                {
                    Id = parts[1];
                    if (Id.StartsWith(Parent.Uid))
                    {
                        Id = Id.Substring(Parent.Uid.Length, Id.Length - Parent.Uid.Length).TrimStart('.');
                        return;
                    }
                }
            }
            Id = Name.Replace('.', '#');
            if (TypeParameters?.Count > 0)
            {
                Id = Id.Substring(0, Id.LastIndexOf('<')) + "``" + TypeParameters.Count;
            }
            //handle eii prefix
            Id = Id.Replace('<', '{').Replace('>', '}');
            Id = Id.Replace(',', '@');
            if (Parameters?.Count > 0)
            {
                //Type conversion operator can be considered a special operator whose name is the UID of the target type,
                //with one parameter of the source type.
                //For example, an operator that converts from string to int should be Explicit(System.String to System.Int32).
                if (Name == "op_Explicit" || Name == "op_Implicit")
                {
                    var typeParamsOnType   = Parent.TypeParameters?.Select(tp => tp.Name).ToList();
                    var typeParamsOnMember = TypeParameters?.Select(tp => tp.Name).ToList();

                    var rtype = ReturnValueType.VersionedTypes.First().Value;

                    Id += string.Format("({0})~{1}",
                                        Parameters.First().Type.ToSpecId(typeParamsOnType, typeParamsOnMember),
                                        rtype.ToSpecId(typeParamsOnType, typeParamsOnMember));
                }
                //spec is wrong, no need to treat indexer specially, so comment this part out
                //else if (MemberType == MemberType.Property && Signatures.ContainsKey("C#") && Signatures["C#"].Contains("["))
                //{
                //    Id += string.Format("[{0}]", string.Join(",", GetParameterUids(store)));
                //}
                else
                {
                    Id += string.Format("({0})", string.Join(",", GetParameterUids(store)));
                }
            }

            //special handling for compatibility in UWP legacy MD content
            if (store.UWPMode && DocId != null)
            {
                var pos1 = Id.IndexOf('(');
                var pos2 = DocId.IndexOf('(');
                if (pos1 > 0 && pos2 > 0)
                {
                    Id = Id.Substring(0, pos1) + DocId.Substring(pos2);
                }
            }
        }
コード例 #16
0
 public override int GetHashCode()
 => DocId.GetHashCode();