This repository has been archived by the owner on Jan 23, 2018. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
803 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<!-- | ||
DWA_Mobile | ||
Link http://www.desktop-web-analytics.com | ||
Link https://github.com/DesktopWebAnalytics | ||
Licence http://www.gnu.org/licenses/gpl-3.0-standalone.html GPL v3 or later | ||
--> | ||
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009" | ||
xmlns:s="library://ns.adobe.com/flex/spark" | ||
xmlns:states="views.states.*" | ||
actionBarVisible="false" currentState="loading" viewActivate="initView()"> | ||
<fx:Script> | ||
<![CDATA[ | ||
import com.dwa.common.profile.Profile; | ||
import com.dwa.common.reports.Reports; | ||
import mx.collections.XMLListCollection; | ||
import mx.core.FlexGlobals; | ||
private var profile:Profile; | ||
private var report:Reports; | ||
private var result:XMLListCollection; | ||
private function initView():void{ | ||
titleLabel.text = data as String; | ||
dateLabel.text = resourceManager.getString('piwik', 'General_DateRangeFromTo').replace('%s', shortDateFormatter.format(FlexGlobals.topLevelApplication.selectedStartDate)).replace('%s', shortDateFormatter.format(FlexGlobals.topLevelApplication.selectedEndDate)); | ||
profile = FlexGlobals.topLevelApplication.selectedProfile; | ||
report = new Reports(); | ||
report.addEventListener(Event.COMPLETE, resultCall); | ||
report.addEventListener(ErrorEvent.ERROR, error); | ||
report.getEntryPageTitles(profile, FlexGlobals.topLevelApplication.selectedPeriodDate, false); | ||
} | ||
private function resultCall(event:Event):void{ | ||
result = report.resultCollectionRow; | ||
compute(); | ||
clear(); | ||
} | ||
private function error(event:ErrorEvent):void{ | ||
trace("error: " + event.text); | ||
clear(); | ||
currentState = "error"; | ||
errorState.message(event.text); | ||
} | ||
private function clear():void{ | ||
report.removeEventListener(Event.COMPLETE, resultCall); | ||
report.removeEventListener(ErrorEvent.ERROR, error); | ||
report = null; | ||
} | ||
private function compute():void{ | ||
trace("page urls"); | ||
currentState = "tab"; | ||
list.dataProvider = result; | ||
} | ||
]]> | ||
</fx:Script> | ||
<fx:Declarations> | ||
<!-- Placer ici les éléments non visuels (services et objets de valeur, par exemple). --> | ||
|
||
<s:DateTimeFormatter id="shortDateFormatter" dateStyle="short" | ||
locale="{resourceManager.getString('piwik', 'General_Locale')}" | ||
timeStyle="none"/> | ||
|
||
</fx:Declarations> | ||
|
||
<s:states> | ||
<s:State name="loading"/> | ||
<s:State name="tab"/> | ||
<s:State name="error"/> | ||
</s:states> | ||
|
||
<s:layout> | ||
<s:VerticalLayout paddingBottom="5" paddingLeft="5" paddingRight="5" paddingTop="10"/> | ||
</s:layout> | ||
|
||
<s:Group width="100%"> | ||
<s:layout> | ||
<s:VerticalLayout horizontalAlign="center"/> | ||
</s:layout> | ||
<s:Label id="titleLabel"/> | ||
<s:Label id="dateLabel"/> | ||
</s:Group> | ||
|
||
<states:Loader includeIn="loading" width="100%" height="100%"/> | ||
|
||
<states:Error id="errorState" includeIn="error" width="100%" height="100%"/> | ||
|
||
<s:VGroup includeIn="tab" width="100%" height="100%"> | ||
<s:SkinnableContainer id="legend" width="100%" height="40"> | ||
<s:Label left="2" top="10" | ||
text="{resourceManager.getString('piwik', 'Actions_ColumnEntryPageTitle')}"/> | ||
<s:Label right="2" top="10" | ||
text="{resourceManager.getString('piwik', 'General_ColumnEntrances')}"/> | ||
</s:SkinnableContainer> | ||
|
||
<s:List id="list" width="100%" height="100%" itemRenderer="views.renderers.ListRendererEntry"/> | ||
</s:VGroup> | ||
|
||
</s:View> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<!-- | ||
DWA_Mobile | ||
Link http://www.desktop-web-analytics.com | ||
Link https://github.com/DesktopWebAnalytics | ||
Licence http://www.gnu.org/licenses/gpl-3.0-standalone.html GPL v3 or later | ||
--> | ||
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009" | ||
xmlns:s="library://ns.adobe.com/flex/spark" | ||
xmlns:views="views.*" | ||
xmlns:states="views.states.*" | ||
actionBarVisible="false" currentState="loading" viewActivate="initView()"> | ||
<fx:Script> | ||
<![CDATA[ | ||
import com.dwa.common.profile.Profile; | ||
import com.dwa.common.reports.Reports; | ||
import mx.collections.XMLListCollection; | ||
import mx.core.FlexGlobals; | ||
private var profile:Profile; | ||
private var report:Reports; | ||
private var result:XMLListCollection; | ||
private function initView():void{ | ||
titleLabel.text = data as String; | ||
dateLabel.text = resourceManager.getString('piwik', 'General_DateRangeFromTo').replace('%s', shortDateFormatter.format(FlexGlobals.topLevelApplication.selectedStartDate)).replace('%s', shortDateFormatter.format(FlexGlobals.topLevelApplication.selectedEndDate)); | ||
profile = FlexGlobals.topLevelApplication.selectedProfile; | ||
report = new Reports(); | ||
report.addEventListener(Event.COMPLETE, resultCall); | ||
report.addEventListener(ErrorEvent.ERROR, error); | ||
report.getEntryPageUrls(profile, FlexGlobals.topLevelApplication.selectedPeriodDate, false); | ||
} | ||
private function resultCall(event:Event):void{ | ||
result = report.resultCollectionRow; | ||
compute(); | ||
clear(); | ||
} | ||
private function error(event:ErrorEvent):void{ | ||
trace("error: " + event.text); | ||
clear(); | ||
currentState = "error"; | ||
errorState.message(event.text); | ||
} | ||
private function clear():void{ | ||
report.removeEventListener(Event.COMPLETE, resultCall); | ||
report.removeEventListener(ErrorEvent.ERROR, error); | ||
report = null; | ||
} | ||
private function compute():void{ | ||
trace("page urls"); | ||
currentState = "tab"; | ||
list.dataProvider = result; | ||
} | ||
]]> | ||
</fx:Script> | ||
<fx:Declarations> | ||
<!-- Placer ici les éléments non visuels (services et objets de valeur, par exemple). --> | ||
|
||
<s:DateTimeFormatter id="shortDateFormatter" dateStyle="short" | ||
locale="{resourceManager.getString('piwik', 'General_Locale')}" | ||
timeStyle="none"/> | ||
|
||
</fx:Declarations> | ||
|
||
<s:states> | ||
<s:State name="loading"/> | ||
<s:State name="tab"/> | ||
<s:State name="error"/> | ||
</s:states> | ||
|
||
<s:layout> | ||
<s:VerticalLayout paddingBottom="5" paddingLeft="5" paddingRight="5" paddingTop="10"/> | ||
</s:layout> | ||
|
||
<s:Group width="100%"> | ||
<s:layout> | ||
<s:VerticalLayout horizontalAlign="center"/> | ||
</s:layout> | ||
<s:Label id="titleLabel"/> | ||
<s:Label id="dateLabel"/> | ||
</s:Group> | ||
|
||
<states:Loader includeIn="loading" width="100%" height="100%"/> | ||
|
||
<states:Error id="errorState" includeIn="error" width="100%" height="100%"/> | ||
|
||
<s:VGroup includeIn="tab" width="100%" height="100%"> | ||
<s:SkinnableContainer id="legend" width="100%" height="40"> | ||
<s:Label left="2" top="10" | ||
text="{resourceManager.getString('piwik', 'Actions_ColumnEntryPageURL')}"/> | ||
<s:Label right="2" top="10" | ||
text="{resourceManager.getString('piwik', 'General_ColumnEntrances')}"/> | ||
</s:SkinnableContainer> | ||
|
||
<s:List id="list" width="100%" height="100%" itemRenderer="views.renderers.ListRendererEntry"/> | ||
</s:VGroup> | ||
|
||
</s:View> |
Oops, something went wrong.