private void getMetadata()
        {
            PlvsLogger.log("FieldEditor.getMetadata()");

            object           rawIssueObject = facade.getRawIssueObject(issue);
            List <JiraField> filledFields   = JiraActionFieldType.fillFieldValues(issue, rawIssueObject, new List <JiraField> {
                field
            });

            field = filledFields[0];
            field.setRawIssueObject(rawIssueObject);

            SortedDictionary <string, JiraProject> projects = JiraServerCache.Instance.getProjects(issue.Server);

            if (!projects.ContainsKey(issue.ProjectKey))
            {
                return;
            }

            JiraProject project = projects[issue.ProjectKey];

            // todo: these are not always necessary. refactor to make it more efficient and smart
            List <JiraNamedEntity> versions = facade.getVersions(issue.Server, project);

            versions.Reverse();
            List <JiraNamedEntity> comps = facade.getComponents(issue.Server, project);

            this.safeInvoke(new MethodInvoker(() => createEditorWidget(versions, comps, rawIssueObject)));
        }
コード例 #2
0
 private void loadComponents(AbstractJiraServerFacade facade, StatusLabel status)
 {
     try {
         List <JiraNamedEntity> components = facade.getComponents(Server, project);
         parent.Invoke(new MethodInvoker(() => populateComponents(components)));
     } catch (Exception e) {
         status.setError("Unable to retrieve component list", e);
     }
 }