Permalink
Browse files

Added a count next to unmatched values for the linking panel

  • Loading branch information...
1 parent b771ff0 commit ce1329d1cd5f591db230e82be1b8332b2f35ecb0 @danpaulsmith danpaulsmith committed Mar 23, 2012
Showing with 42 additions and 22 deletions.
  1. +13 −7 module/scripts/project/panels/linkingPanel.js
  2. +29 −15 module/styles/project.css
@@ -628,7 +628,7 @@ var LinkedGov_LinkingPanel = {
// Create the dialog itself
var dialog = LG.createDialog({
header:"Are you sure?",
- body:"This will delete the reconciliation data for the column \""+columnName+"\"",
+ body:"This will delete the reconciliation data for the column \""+columnName+"\".",
ok:function(){
log("OK clicked");
@@ -1450,8 +1450,6 @@ var LinkedGov_LinkingPanel = {
// Once all processes have finished
if(self.numberOfRunningProcesses == 0 && !self.hasBeenCancelled){
- log("Actually displaying results...");
-
/*
* Checks that the facets have been created once reconciliation
* has finished, so we can access the scores to display on the panel.
@@ -1902,11 +1900,17 @@ var LinkedGov_LinkingPanel = {
// Add the chosen value to the front of the array
// because it occurs more frequently than the previous
// value.
- arrayOfUnmatchedValues.splice(0,0,choices[j].v.l);
+ arrayOfUnmatchedValues.splice(0,0,{
+ name:choices[j].v.l,
+ count:choices[j].c
+ });
highest = choices[j].c;
} else {
// Add the value to the end of the array.
- arrayOfUnmatchedValues.push(choices[j].v.l);
+ arrayOfUnmatchedValues.push({
+ name:choices[j].v.l,
+ count:choices[j].c
+ });
}
}
@@ -1924,8 +1928,8 @@ var LinkedGov_LinkingPanel = {
// We use "col" to inherit CSS styling, it's actually
// a cell value - not a column name
var spanCol = $("<span />").addClass("value col")
- .data("value", arrayOfUnmatchedValues[i])
- .text(arrayOfUnmatchedValues[i]);
+ .data("value", arrayOfUnmatchedValues[i].name)
+ .text(arrayOfUnmatchedValues[i].name+" ("+arrayOfUnmatchedValues[i].count+")");
// We attach the column name to the input element
// so the click handler for the input box can pass on
@@ -1950,6 +1954,8 @@ var LinkedGov_LinkingPanel = {
}
}
+ ul.children("li").eq(ul.children("li").length-1).addClass("last");
+
// Insert the HTML into the correct result panel <div>
$(resultDiv).find("div.result-body").append(ul);
View
@@ -136,12 +136,12 @@ body.lg #suggest-pane
{
background: none repeat scroll 0 0 #FFFFFF;
border: 1px solid #CCCCCC;
- box-shadow: 5px 5px 5px #D3D3D3;
- display: none;
+ box-shadow: 0 8px 9px #777777;
font-size: 12px;
margin-top: 1px;
position: fixed;
- width: 240px;
+ width: 257px;
+ display:none;
}
body.lg #suggest-pane div.noresults
{
@@ -152,13 +152,13 @@ body.lg #suggest-pane div.noresults
}
body.lg #suggest-pane div.options
{
- background: none repeat scroll 0 0 #E7EEFF;
+ background: none repeat scroll 0 0 #FFFFE8;
border-bottom: 1px solid #CCCCCC;
float: none;
padding-bottom: 1px;
padding-top: 0;
text-align: center;
- width: 240px;
+ width: 257px;
}
body.lg #suggest-pane div.options a
{
@@ -200,15 +200,15 @@ body.lg #suggest-pane ul.fbs-list
overflow-x: hidden;
overflow-y: auto;
padding-top: 0;
- width: 240px;
+ width: 257px;
}
body.lg #suggest-pane ul.fbs-list li.fbs-item
{
border: none;
cursor: pointer;
list-style-type: none;
margin: 1px;
- padding: 2px 8px 1px 3px;
+ padding: 2px 4px 1px 3px;
}
body.lg #suggest-pane ul.fbs-list li.fbs-item .fbs-item-name
{
@@ -701,19 +701,32 @@ body.lg div#refine-tabs-typing div.linking-results div.result div.result-body di
}
body.lg div#refine-tabs-typing div.linking-results div.result div.result-body ul.selected-columns
{
- border: medium none;
- padding: 10px;
+ -moz-border-bottom-colors: none;
+ -moz-border-image: none;
+ -moz-border-left-colors: none;
+ -moz-border-right-colors: none;
+ -moz-border-top-colors: none;
+ border-style: solid none none;
+ border-width: 1px medium medium;
+ margin: 0;
+ padding: 0;
}
body.lg div#refine-tabs-typing div.linking-results div.result div.result-body ul.selected-columns li
{
- background: none repeat scroll 0 0 #FFFFFF;
- border: medium none;
+ background: none repeat scroll 0 0 #EBEEF8;
+ border-color: -moz-use-text-color -moz-use-text-color #B2BDDE;
+ border-style: none none solid;
+ border-width: medium medium 1px;
color: #333333;
list-style-type: none;
- margin-bottom: 10px;
+ margin-bottom: 1px;
margin-top: 0;
overflow: hidden;
- padding-left: 0;
+ padding: 5px 5px 10px;
+}
+body.lg div#refine-tabs-typing div.linking-results div.result div.result-body ul.selected-columns li.last {
+ border-bottom:none;
+ margin-bottom:0px;
}
body.lg div#refine-tabs-typing div.linking-results div.result div.result-body,body.lg div#refine-tabs-typing div.reconcile-panel div.linking-results div.result div.result-body.collapsed
{
@@ -750,9 +763,10 @@ body.lg div#refine-tabs-typing div.linking-results div.result div.ui-progressbar
}
body.lg div#refine-tabs-typing div.linking-results div.result span.col
{
- background: none repeat scroll 0 0 #F2F5FF;
+ background: none repeat scroll 0 0 transparent;
display: block;
float: left;
+ font-size: 12px;
padding: 4px 0 4px 3px;
width: 98%;
}
@@ -762,7 +776,7 @@ body.lg div#refine-tabs-typing div.linking-results div.result span.colOptions in
background-image: none;
font-size: 14px;
margin-top: 0;
- width: 96%;
+ width: 97%;
}
body.lg div#refine-tabs-typing div.linking-results div.result span.colOptions input.edited
{

0 comments on commit ce1329d

Please sign in to comment.