Posts

Featured post

jsf - How to order SelectItems in custom renderer extending MyFaces HtmlMenuRenderer -

i´m trying migrate custom component render selectonemenu on myfaces 2.0, need use library because 8.5 moved mojarra 1.2 myfaces 2.0 implementation. in mojarra 1.2, extended com.sun.faces.renderkit.html_basic.menurenderer had method renderoptions receives parameters facescontext context, uicomponent component, list<selectitem> listselectitems , myfaces haven´t similar method. this method used order items before render (mojarra 1.2): @override protected void renderoptions(facescontext context, uicomponent component, list<selectitem> listselectitems) throws ioexception { cobisselectonemenuuicomponent uicomponent = (cobisselectonemenuuicomponent) component; string order = uicomponent.getorder(); if (order == null || order.isempty()) { order = default_order; } if (order.equals("asc")) { collections.sort(listselectitems, comparatorselectitemlabel); } else { if (order.equals("desc")) {

Android : Making Listview full screen -

<linearlayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" tools:context=".mainactivity"> <edittext android:layout_margintop="5dp" android:layout_width="match_parent" android:layout_height="50dp" android:background="@drawable/location_edittext" android:id="@+id/locationeditext" android:textsize="15sp" android:textcolor="#999" android:paddingleft="15dp" /> <com.example.ravi_gupta.slider.viewpagercustomduration android:layout_width="wrap_content" android:layout_height="0dp" android:id="@+id/viewpager" android:scrollbarstyle="outsideoverlay" android:layout_weight="0.5&quo

java - WebServiceException : Class do not have a property of the name debug -

i generated java proxy classes using 'xjc'. getting "do not have property of name debug" webservice exception when deploy application production environment. however, in staging environment works fine. referring same web-service both environments, endpoint url & wsdl same. any appreciated. built on java 6, deployed on jboss 6.x here client code using call webservices. ==========client code=========== processaccountsiteunitwsd service = new processaccountsiteunitwsd(); final processaccountsiteunitwsdporttype port = service.getgesfdcpwaccountsiteunitserviceswebservicesproviderprocessaccountsiteunitwsdport(); final bindingprovider hb = ((bindingprovider) port); hb.getrequestcontext().put(bindingprovider.endpoint_address_property, resources.getstring("endpoint_address")); hb.getrequestcontext().put(bindingprovider.username_property,

sql server - SQL, get max id of column -

i've got table in ms sql server management studio +------+-----------+-------- | id | client id | bla bla blaaaa +------+-----------+-------- | 1 | 1 | ....... | 2 | 2 | ....... | 3 | 3 | ....... | 4 | 8 | ....... | 5 | 9 | ....... | 6 | 15 | ....... | 7 | 1 | ....... | 8 | 16 | ....... | 9 | 2 | ....... | 10 | 9 | ....... | 12 | 12 | ....... +------+-----------+-------- i need unique [client id] max value of [id], this +------+-----------+-------- | id | client id | bla bla blaaaa +------+-----------+-------- | 3 | 3 | ....... | 4 | 8 | ....... | 6 | 15 | ....... | 7 | 1 | ....... | 8 | 16 | ....... | 9 | 2 | ....... | 10 | 9 | ....... | 12 | 12 | ....... +------+-----------+-------- i tried code, doesn't work .. can me? select * table 1 inner join table 2 o

c# - How to share session between a MVC project and a WCF project? -

i have angular-webapi-mvc-wcf solution. i want share user session between mvc , wcf projects. possible? also, want share authentication mechanism, mean, want user authenticated once on mvc project using formauthentication, , let wcf know when user authenticated without envolving other technologie. i have solution mvc , wcf app reside on same project(dll), , on context can share authentication , session data. so, in order share session, should move svc files wcf mvc project? way? all projects share same db, solve without having store session data on db level. thanks info if wcf layer on same app pool, can check aspxauth cookie (forms auth cookie name configurable) , can use methods in formsauthentication class/namespace decode cookie user in wcf layer. if configure forms auth cookie domain cookie can host wcf layer in different app pool/iis site long it's on same domain main site. both sites receive cookie. that cookie drives forms authentication. if fo

javascript - How to Hide Date Menu from Datepicker in yii2 -

basically in datetimepicker widget date choose first time, how can hide date option widget , filter according time. tried not working want hide remove button [ 'attribute'=>'time', 'label'=>'time', 'format'=>'raw', 'value'=>function($data){ return date('h:i:s',strtotime($data->time)); }, 'filter'=> datetimepicker::widget([ 'model' => $searchmodel, 'attribute' => 'time', 'clientoptions' => [ 'autoclose' => true, 'format' => 'hh:ii', 'showon' =&

ios - How to call the -(void)update:(CCTime)delta method in Objective-C -

is there way call -(void)update:(cctime)delta method in objective-c? know (using sprite builder) can create scene , have attached custom class when scene loaded through ccbreader, class's update method automatically called. i loading scene through code without custom class still update method "start" (for lack of better word.) there way this? call scheduleupdate from, example, onenter method. [self scheduleupdate]; however if using cocos2d-objc or cocos2d-spritebuilder version 3.0 or later, update: methods scheduled automatically. https://github.com/cocos2d/cocos2d-objc/blob/v3.0/cocos2d/ccnode.m#l1190 -(cctimer *) schedule:(sel)selector interval:(cctime)interval repeat: (nsuinteger) repeat delay:(cctime) delay { nsassert(selector != nil, @"selector must non-nil"); nsassert(selector != @selector(update:) && selector != @selector(fixedupdate:), @"the update: , fixedupdate: methods scheduled automatically.");