Posts

Showing posts from August, 2011

python - use django create database scheme or use powerdesigner create database scheme -

i ready start new project django,and invloves operations database.i have 2 way scheme: use powerdesigner design database scheme , output sql,then use python manage.py inspectdb generate models. design model use python manage.py makemigrations , python manage.py migrate database scheme. does explain 2 ways' difference , how should choose? from inspectdb's documentation: use if have legacy database you’d use django. script inspect database , create model each table within it. its better if have working db , want use django on it. has limitations like: if inspectdb cannot map column’s type model field type, it’ll use textfield , insert python comment 'this field type guess.' next field in generated model. if database column name python reserved word (such 'pass', 'class' or 'for'), inspectdb append '_field' attribute name. example, if table has column 'for', generated model have fi

rdf_loader_run stuck and Virtuoso server doesn't respond to queries -

i've run these commands: ld_add('/path/datasets/dbpedia/2015-04/dbpedia_2015-04.owl', 'http://dbpedia.org/resource/classes#'); rdf_loader_run(); ld_dir_all('/path/datasets/dbpedia/2015-04/importedgraphs/dbpedia.org', '*.*', 'http://dbpedia.org'); that ran successfully, ran: rdf_loader_run(); it's been 48 hours on corei7 machine 24gb ram, virtuoso server not using cpu, , doesn't respond queries such as: select * db.dba.load_list; ...in instances of isql-vt . size of files in /var/lib/virtuoso-opensource-6.1/db/ not increasing. the problem was using old version of virtuoso, upgrading 7.2 suggested in comments solved. didn't have problem on macbook, seems while homebrew installs latest version default, apt-get doesn't in ubuntu , need install latest version.

winforms - Capture data grid event from one user control to another -

i working on windows forms application. application contains main container load user controls @ run time. i have 1 user control contains data grid. have user control contains data grid , tab control. what need when row selected in grid view 1 (of user control 1) based on id of selected row fatch value data base , bind data gridview 2 (of user control 2). , default first row of gridview 2 selected , based on selected row data populated in tab control (of user control 2). can please provide me basic code of event creation, raising , handling between user control. in advance. try either of these approaches: hierarchical data binding hierarchical data binding dataset

Adding new rows to the grid -

i initialise ag-grid like: <ag-grid-ng2 [rowdata]="records"></ag-grid-ng2> after adding new items records array, rows in ag-grid remain not updeted. have call setrowdata(records). slow , ag-grid loses state (like focused cell). is there way have rows in ag-grid refreshed during changing data in rowdata . no, there no other way. grid expects rowdata immutable, means have replace array [rowdata] property picked up. way around this, do, call api.setrowdata() method, forces grid treat rowdata new set of data.

ruby on rails - Authentication: Custom or Third Party -

i'm creating app in ruby on rails , have research devise, omniauth, , creating own custom version. my question is: scenarios in use 1 of 3 choices above? my take: - omniauth can provide quick registration through third party apis, require additional permissions access additional data - devise provides core functionality can customized based on applications needs - custom may extreme scenarios which, currently, not need ** i'm leaning towards devise provides core , allows me add onto that additional considerations: - application needs sign in , access basic information for: location, language i18n, etc - application financial transactions (if you're paid member, et al). going question: based on above, devise seem better choice? omniauth provide these features? when should use 1 versus other? thanks devise , omniauth different things - , used together. devise provides full authentication package views, controllers , routes allow users sign up, edit

c# - Implement searching in a generic repository with Linq Expressions -

i working entity framework , code first. here simple example show case. public class personefmodel { public int id { get; set; } public string vorname { get; set; } public string nachname { get; set; } } public class efcontext : dbcontext { public dbset<person> personen { get; set; } } to independent implementation of data access wrote abstraction layer repositories. public class person { public int id { get; set; } public string vorname { get; set; } public string nachname { get; set; } } public interface igenericrepository<t> { int count { get; } void add(t item); void delete(t item); void update(t item); t getdata(int id); ienumerable<t> getdata(); ienumerable<t> getdata(int offset, int count); ienumerable<t> find(expression<func<t,bool>> predicate); ienumerable<t> find(ienumerable<expression<func<t, bool>>> predicates); } person , perso

php - Polymer 1.0 Iron-form Post error 404 not found -

working polymer 1.0, try implement iron-form element, when use method "get" it's working, when try make "post" same file on same path error occurs 404 not found. my custom element (contact-form): <dom-module id="contact-form"> <template> <div class="horizontal center-center layout"> <link rel="import" href="add.php"> <div> <div class="horizontal-saction> <form is="iron-form" id="form" method="post" content-type="application/json" action="add.php"> <paper-input name="name" label="name" requiered></paper-input> <br><br> <paper-button raised onclick="sumitform()">submit</paper-button> </form> </div> </div> </div> </template

mongodb - How to return all documents where an array field's size is greater than a given number? -

i have document { "_id": objectid('56a77bfae0ce9f6a738cb2b7'), "nameidentity": [ { "givennameone": "latanya", "givennamethree": "bizor", "lastname": "bizor", "sourcereferenceid": [ { "sourcereferenceid": "56a77bfae0ce9f6a738cb2b5", "sourcename": "a" }, { "sourcereferenceid": "56a77bfae0ce9f6a738cb2b5", "sourcename": "b" } ] } ] } nameidentity array , sourcereferenceid nested array inside nameidentity. trying documents sourcereferenceid size greater 2. used aggregation : db.entity.aggregate( [ { $project: { nameidentity_count: {$size: "$nam

html - How to hide Parse.com URL properly in activation email? -

i have integrated parse.com app, managed signup , login app parse.com backend. i enabled settings --> email --> email settings --> verify user emails new users receive email activation link like: https://www.parse.com/apps/testemaillogin/verify_email?token=c6mdk6pbgegdfgh1bompj&username=name%40email.com parse.com provides hide parse.com urls: by uploading attached file server , entering address below, can hide parse.com users. page iframe parse lets domain front-end our back-end. <!doctype html> <html> <!-- page passthrough frame used host parse.com experience server. if choose use feature, sure tell parse put page in app settings page. in general, there should no reason edit contents of page --> <head> <style type='text/css'> html { height: 100%; } .chromeless { width: 100%; height: 100%; left: 0px; top: 0px; border: 0px;

Sphinx get agent schema -

it's first question, forgive errors:). framework i'm using yii2 , @ beginning of requests, have problem of receiving answer of distributed index agent in sphinx command: describe `10.0.0.22:9312:indexname`; i get: error 1064 (42000): sphinxql: syntax error, unexpected $undefined, expecting ident (or 49 other tokens) near '`10.0.0.22:9312:indexname`' my distributed conf: index indexname { type = distributed agent = 10.0.13.24:9312|10.0.0.22:9312:indexname ha_strategy = noerrors } other conf: index indexname { type = rt path = /var/lib/sphinxsearch/data/indexname rt_field = code rt_field = title rt_field = article rt_field = docket rt_attr_uint = code rt_attr_string = title rt_attr_string = article rt_attr_string = docket morphology = lemmatize_ru, stem_enru charset_table = 0..9, u+410..u+42f->u+430..u+44f, u+430..

CSS float content changes parent position -

why button float:left or float:right content changes button vertical position? example http://jsfiddle.net/8ff6dhou/ <button>aaa</button> <button><div style="float:left">bbb</div></button> <button><div style="float:right">ccc</div></button> <button>ddd</button> why 4 buttons not @ same vertical position? how fix this? add vertical-align button. button{vertical-align:top;}

php - Count the number of days from Twitter XML -

i'm using twitter api recent tweets xml file website. have tweets displaying on page can't show how many days have passed since displaying tweet. i've tried solutions answered here same problem didn't work me. date , time xml file given folows: <statuses type="array"> <status> <created_at>sat mar 23 18:43:16 +0000 2013</created_at> </status> </statuses> i'm retrieving data this: <?php $xmldata = 'https://api.twitter.com/1/statuses/user_timeline.xml?screen_name=ablazedigital'; $open = fopen($xmldata, 'r'); $content = stream_get_contents($open); fclose($open); $xml = new simplexmlelement($content); ?> <?php echo $xml->status[0]->created_at; ?> how can make function php reads follwing date "sat mar 23 18:43:16 +0000 2013" , tells how many days have passed present day? $now = new datetime('now'); $pagetime = new datetime('sat mar

python 2.7 - Removing Duplicate Tag Content Using BeautifulSoup -

Image
i made script getting every h1 tag 76 pages of website. in process program copy specific line "current affairs january 2015" line present in every page. can edit code print 1 time ? here's code: from bs4 import beautifulsoup bs import urllib in range(2,77): url1="http://currentaffairs.gktoday.in/month/current-affairs-january-2015/"+"page/"+str(i) soup = bs(urllib.urlopen(url1)) link in soup.findall('h1'): print link.string thanks in advance. from bs4 import beautifulsoup bs import urllib in range(2,77): url1="http://currentaffairs.gktoday.in/month/current-affairs-january-2015/"+"page/"+str(i) soup = bs(urllib.urlopen(url1)) ulinks = soup.findall('h1') index, item in enumerate(ulinks): if == 2: print(item.string) if != 2: if index != 0:

ruby - Vagrant up wit puppet => install compass -

is there has experience installing compass via puppet on vagrant box? if i'm installing compass via following puppet command ( http://www.thisprogrammingthing.com/2013/installing-ruby-gems-in-puppet/ ): package { ['sass', 'compass']: ensure => 'installed', provider => 'gem', } the sass package installed in few seconds. compass package installed takes 30 minutes install. , that's bit anoying if want destroy , box on regular base. i use vagrantbox => puppetlabs/centos-7.2-64-puppet i installed following needed centos packages: "rubygems", "ruby-devel" is there solution? thx! i found solution. if tried same scenario on localhost succeeded in 1 minute. compared gem version , gem version on puppet older version. now i'm first executing: /bin/gem update --system

How can I join two SQL tables, putting a value from the 2nd table into a column in the 1st? -

Image
i've no idea start this! have 2 tables, 1 shows company mobile phone bill in detail, this: and table shows line rental, this: i want "merge" 2 tables, line rental value shown in call cost column, value "line rental" shown in call class column, , bill date shown in date column: try this select user,callcost,callclass,date 1sttable union select user,linerental,'line rental',billdate 2ndtable

html - Round up to the nearest quarter hour - JavaScript -

i'm trying create select element time shown: <strong>time:</strong> <select name="hours" id="hours"> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> <option value="7">7</option> <option value="8">8</option> <option value="9">9</option> <option value="10">10</option> <option value="11">11</option> <option value="12">12</option>

c# - Bind Rect Width and Height in xaml -

i trying bind width , height of rect in viewport this: <visualbrush.viewport> <rect width="{binding path=mywidth}" height="{binding path=myheight}"/> </visualbrush.viewport> my binding works fine elsewhere here following error message: a 'binding' cannot set on 'width' property of type 'rect'. 'binding' can set on dependencyproperty of dependencyobject. edit understand error message. question how work around it. how bind height , width of rect? use multibinding this: <visualbrush.viewport> <multibinding> <multibinding.converter> <local:rectconverter/> </multibinding.converter> <binding path="mywidth"/> <binding path="myheight"/> </multibinding> </visualbrush.viewport> with multi-value converter this: public class rectconverter : imultivalueconverter {

c++ - Attach disabled display device with WinAPI -

my problem enabling disabled monitor changedisplaysettingsex . guess not rocket science after digging still looks impossible. found way disable secondary displays basing on microsoft code sample found here . while needed basic tweaking work, re-attaching never worked. trying was: 1. initialize displaydevice bool foundsecondarydisp = false; dword dispnum = 0; display_device displaydevice; long result; tchar sztemp[200]; int = 0; devmode defaultmode; zeromemory(&displaydevice, sizeof(displaydevice)); displaydevice.cb = sizeof(displaydevice); 2. find devices while (enumdisplaydevices(null, dispnum, &displaydevice, 0)) { zeromemory(&defaultmode, sizeof(devmode)); defaultmode.dmsize = sizeof(devmode); //point 3 goes here } 3. detect detached device if (!(displaydevice.stateflags & display_device_attached_to_desktop)) 4. enable device devmode devmode; zeromemory(&devmode, sizeof(de

spring boot - consul properties in xml configuration -

i trying use consul centralised configuration spring application. when use annotation based configuration example 1 works perfectly. //example 1 @configuration @enableconsulpropertysource({"root/api/defaults", "root/global/defaults"}) public class applicationconfiguration { @value("httpclient.pool.maxtotal") private int maxtotal; @value("httpclient.pool.defaultmaxperroute") private int maxperroute; ... } however not find way use consul properties directly in xml. <bean id="properties" class="org.springframework.somebeantoenableconsulinxmlconfig"> <property name="locations"> <list> <value>root/api/defaults</value> <value>root/global/defaults</value> </list> </property> </bean> ... <bean name="http.client" class="com.xxx.httpclient"> <property na

mysql - Sql query how to make it faster? -

i have sql query. possible change somehow query, has better performance, same result? query working, slow, , don't have idea on improving performance. select keyword, query url_alias ua join product p on (p.manufacturer_id = convert(substring_index(ua.query,'=',-1),unsigned integer)) join oc_product_to_storebk ps on (p.product_id = ps.product_id) , ua.query 'manufacturer_id=%' , ps.store_id= '9' group ua.keyword table structure: url_alias +-----------------------------------------------+ | url_alias_id | query | keyword | +--------------+---------------------+----------+ | 1 | manufacturer_id=100 | test | +--------------+---------------------+----------+ product +-----------------+------------+ | manufacturer_id | product_id | +-----------------+------------+ | 100 | 1000 | +-----------------+------------+ oc_product_to_storebk +-----------

php - Embedding a single object in form -

i've manage create form embedded in form think i'm not doing right. here's code category class category { private $id; private $name; /** * @orm\onetomany(targetentity="category", mappedby="category") */ private $subcategorues; public function __construct() { $this->subcategorues = new \doctrine\common\collections\arraycollection(); } public function getid() { return $this->id; } public function setname($name) { $this->name = $name; return $this; } public function getname() { return $this->name; } public function addsubcategorue(\appbundle\entity\category $subcategorues) { $this->subcategorues[] = $subcategorues; return $this; } public function removesubca

Adding external cpp files to Android Studio JNI -

i have android project setup in android studio. i'm using ndk , jni have cpp/h files in jni folder. can use them , fine. have folder somewhere in harddrive (which not under android project root folder) more cpp files. in android.mk added path both local (jni folder) files , external files directory path. compiles , works fine. issue i'm having how link cpp files in external folder can edit them inside android studio or @ least see functions , member names. edit files in notepad++ save , go android studio call methods etc. the external folder folder cpp files inside. it's not module, not have build.gradle or that. is i'm asking possbile? hope question clear enough. appreciated! thanks

Google Sheets apps script running every 5 minutes but pauses over night -

Image
i have google apps script suppose run every 5 minutes, i've noticed every night @ around 11pm, pauses , won't start running again until 7:55am. (gmt) does know why stop running overnight? found out urlfetchapp using quota ijay said. i found out adding in logger of everytime script runs, add timestamp. now optimised urlfetchapp run!

java - Spring HttpSecurity - Filter Dependency Injection -

in web application, have created custom filter adding current login details org.slf4j.mdc . application uses spring boot , spring security configured purely using annotations. here relevant parts of spring configuration, @configuration @enablewebsecurity public class securityconfiguration extends websecurityconfigureradapter{ @inject private customfilter customfilter; // @override protected void configure(httpsecurity http) throws exception { http.addfilter(customfilter); } } the above code doesn't work. exception caused by: java.lang.illegalargumentexception: can not set com.example.web.filter.customfilter field com.example.config.securityconfiguration.customfilter com.sun.proxy.$proxy202 @ sun.reflect.unsafefieldaccessorimpl.throwsetillegalargumentexception(unsafefieldaccessorimpl.java:164) [rt.jar:1.7.0_25] @ sun.reflect.unsafefieldaccessorimpl.throwsetillegalargumentexception(unsafefieldaccessorimpl.java:168) [rt.jar:1.7.0_2

jquery - Javascript - clearing everything inside a div -

i have div: <div id="socialuserlist"> //some content here, htmltags, text, etc. </div> now, want inside of div wiped out. trying this: $("#socialuserlist").innerhtml = ''; but reason doesn't want work. why? the normal javascript method: document.getelementbyid('socialuserlist').innerhtml = ''; in jquery: $('#socialuserlist').html(''); pure javascript , jquery go hand in hand, so: from pure javascript jquery: var socialuserlist = document.getelementbyid('socialuserlist'); console.log($(socialuserlist).html()); from jquery pure javascript: var socialuserlist = $('#socialuserlist'); console.log(socialuserlist[0].innerhtml);

python - POST list to django restapi -

i trying post list of strings data unable receive list on server gave me last element of list con = ["71qweq74520", "8324wqe57", "81ewqewq166"] received con = 81ewqewq166 code receive @ server api:- @csrf_exempt @api_view(['post']) def getuser(request): if request.method == 'post': if isapivalid(request): params in request.post: print params,request.post[params] #this prints last element of array/lis python scirpt post:- con = ["71qweq74520", "8324wqe57", "81ewqewq166"] data = { 'apikey':apikey, 'sig':sig ,'con': con} data2 = json.dumps(data) #hostname = '127.0.0.1:8000' hostname = 'xx.xx.xx.xx' method = 'method' task = 'getuser' url = 'http://'+ hostname + '/' + method + task r = requests.post(url, data=data) #r = requests.post(url, data=data2) fails how can post

excel - Trying to automate a process of sorting one column, all the way from "D:D" to "ZZ:ZZ" -

in short, have 5 hundred or columns, of sort alphabetically (with headers). although may have easier solution involving highlighting entire dataset , doing custom sort of sort.... i've taken stab @ writing script it. have far is: sub columnsort() dim rng range dim long dim acell range = 0 set rng = range("d:d") while <= 5000 rng.offset(0, i).sort order1:=xlascending, header:=xlyes = + 1 end wend end sub you can see reasoning, line rng.offset(0, i).sort order1:xlascending, header: =xlyes giving me error. correct syntax use particular problem? there better way this? thanks, here's example of how sort columns 1-500 individually: dim col integer dim r range dim ws worksheet set ws = activesheet col = 1 500 set r = cells(1, col).entirecolumn ws .sort.sortfields.clear .sort.sortfields.add key:=r, _ sorton:=xlsortonvalues, order:=xlascending, dataoption:=xlsortnormal ws.sort .setran

android - How can make "share via" intent EXCEPT my app list on it -

i'm working on text base app can share parts other apps in share via , accept shared text apps. when want share data, app appeared in share via screen, how can remove app screen,though want when other app share text , in "share via" screen , app should place there. here codes : intent sharingintent = new intent(android.content.intent.action_send); sharingintent.settype("text/plain"); string sharebody = "here share content"; sharingintent.putextra(android.content.intent.extra_text, sharebody); startactivity(intent.createchooser(sharingintent, "share via")); and also: <activity android:name=".testactivity" android:label="@string/app_name"> <intent-filter> <action android:name="android.intent.action.main" /> <category android:name="android.intent.category.launcher" /&g

rx java - Understanding RxJava: Differences between Runnable callback -

i'm trying understand rxjava , i'm sure question nonsense... have code using rxjava: public observable<t> getdata(int id) { if (dataalreadyloaded()) { return observable.create(new observable.onsubscribe<t>(){ t data = getdatafrommemory(id); subscriber.onnext(data); }); } return observable.create(new observable.onsubscribe<t>(){ @override public void call(subscriber<? super string> subscriber) { t data = getdatafromremoteservice(id); subscriber.onnext(data); } }); } and, instance, use way: action1<string> action = new action<string>() { @override public void call(string s) { //do s } }; getdata(3).subscribe(action); and callback implements runnable : public void getdata(int id, myclassrunnable callback) { if (dataalreadyloaded()) { t data = getdatafrommemory(id); callback.setdata(data

android - Card.io: WebViewActivity destroyed on getting result -

i have implemented card.io android sdk in special way: have webview, button implemented. button has special url. when url catched webviewclient in shouldoverrideurlloading method, card.io scanner intent called: if( stringutils.contains( url, "activity_scan_activity://scan_activity" ) ) { intent scanactivity = new intent(nativebridgeactivity, cardioactivity.class); scanactivity.putextra(cardioactivity.extra_require_expiry, true); // default: false scanactivity.putextra(cardioactivity.extra_require_cvv, false); // default: false scanactivity.putextra(cardioactivity.extra_require_postal_code, false); scanactivity.putextra(cardioactivity.extra_hide_cardio_logo, true); scanactivity.putextra(cardioactivity.extra_scan_expiry, true); scanactivity.putextra(cardioactivity.extra_require_cardholder_name, true); scanactivity.putextra(cardioactivity.extra_suppress_confirmation, false

lua - way to set dynamic pattern matcher -

please question pattern ^u.meta(\.|$) not working expected has expected behavior need. changes in pattern ^u.meta(\.|$) or in lua '^u%.meta%f[\0.]' or '^u%.meta%f[%z.]' , change need u.meta can user defined variable. , pattern should generic/dynamic match set in variable. for example: -- should return 'u.meta', , pattern should match local pattern = 'u.meta' print(string.match("u.meta.admin", '^u%.meta%f[\0.]')) -- u.meta -- should return 'nil', , pattern should fail local pattern = 'u.meta' print(string.match("u.domain.admin", '^u%.meta%f[\0.]')) -- nil -- should return 'anything.anything', , pattern should match local pattern = 'anything.anything' print(string.match("anything.anything.something", '^anything%.anything%f[\0.]') -- anything.anything -- should return nil, , pattern should fail local pattern = 'anything.anything' print(string.mat

php - Cannot select from table, but I can insert and create? -

i have extremely weird issue mysql. can insert into, , create tables. cannot select , not display error when try, echos line "error: " getdiff("validtable"); function getdiff($regnr) { global $servername, $username, $password, $dbname; // create connection $conn = new mysqli($servername, $username, $password, $dbname); // check connection if ($conn->connect_error) { die("connection failed: " . $conn->connect_error); } //todo $sql = "select * $regnr order id limit 1"; $result = $conn->query($sql); if ($result === true) { echo "done"; } else { $error = $result->error; echo "error: " . $error; } $conn->close(); } but when insert db using this $query = "create table if not exists $regnr ( `id` mediumint not null auto_increment, `mail` int not null , `price` int not null , `views` int not null , `the_date` date not nu

internet explorer - Gdrive file get JS doesn't work in ie -

i using code retrive file google drive picker. on ie browser return error on call. function downloadfile(file, callback) { if (file.downloadurl) { var accesstoken = gapi.auth.gettoken().access_token; var xhr = new xmlhttprequest(); xhr.open('get', file.downloadurl); xhr.setrequestheader('authorization', 'bearer ' + accesstoken); xhr.onload = function() { callback(xhr.responsetext); }; xhr.onerror = function() { callback(null); }; xhr.send(); } else { callback(null); }} in chrome , firefox works ok, in ie 11 , + returns "access denied". error print screen if you're using ie6 or old browsers, you'll need use specific rpc_relay file , place in same domain of application , modify creation code. supporting older browsers download file: https://www.google.com/ajax/picker/resources/rpc_relay.html . place file somewhere in same domain application. modify picker creation c

java - Trying to update my apk programmatically results in parse error -

i need update application without google play. uploaded apk server downloaded when needed. it's downloaded fine following code, when installation intent started it's throwing: "parse error: there problem parsing package" if try run downloaded apk manually, still gives same error. but, if transfer apk usb , run it, installs smoothly. problem not apk itself. here task class: class update implements runnable { @override public void run() { ftpclient ftpclient = new ftpclient(); try { ftpclient.connect(inetaddress.getbyname("mysite.com")); ftpclient.login("mysite.com", "123456")); ftpclient.enterlocalpassivemode(); string remotefile1 = "/httpdocs/program/app-release.apk"; string downpath = getexternalstoragepublicdirectory(directory_downloads).getabsolutepath(); file myapk = new file(downpath + "/app-release.apk");

events - How to disable javascript code from a javascript module? -

i have joomla module javascript listener, waiting mouse hover area. want disable listener, can in firebug clicking disable code option, want more permanent javascripty approach. code minimized , it's hard read, can code firebug, is: (function (a){a=new domevent(a,j.getwindow());i.call(j,a)===false&&a.stop()}) is there javascript code can disable line of code? thank you. if have jquery try jquery('yourelement').off('hover mouseover'); or jquery('document').on('hover mouseover', '#yourlement', function(event){event.preventdefault();return false;})

How can i display a JIRA wallboard in a html website? -

if copy jira wallboard url , paste iframe content not displayed because need login permission see jira wallboard. how can display urls cross browser protected login? i came across openid authentication dont understand word. regards 151 you can open system dashboard anonymous users (people not logged in) bypass requirement login: edit "browse projects" permission include group "anyone" (issues -> permission schemes) , edit permission scheme of projects content included in system dashboard. can edit system dashboard in system -> system dashboard (under heading user interface). unfortunately @ moment seems there's problems viewing wallboards or dashboards in jira 7, can see if works you.

android - java.lang.VerifyError when initial LocationServices -

i update google play service sdk (rev 29) in android sdk manager recently. found apk build after sdk updated crash during initial googleapiclient. here code use. mgoogleapiclient = new googleapiclient.builder(this) .addconnectioncallbacks(this) .addonconnectionfailedlistener(this) .addapi(locationservices.api) .build(); and here log of call stack e/androidruntime: fatal exception: main process: com.xxxxxxx.xxxxx, pid: 3855 java.lang.verifyerror: rejecting class com.google.android.gms.location.internal.zzd because failed compile-time verification (declaration of 'com.google.android.gms.location.internal.zzd' appears in /data/app/com.xxxxxx.xxxx-2/base.apk) @ com.google.android.gms.location.locationservices.(unknown source) the google play service version use com.google.android.gms:play-services-location:8.3.0 i tr

javascript - Filter source array based on the current filter and put its certain values to the ng-repeat item -

i have array called schedules contains flight schedules info. when user selects departure , arrival cities array being filtered selected cities , outputs flights in table. table contains columns return flight data source array schedules don't have. there value ret_flight_num . i want load return's flight data current row , still don't know how implement this. suggestions? var app = angular.module('flight-schedule', []); app.controller('selectctrl', function($scope) { $scope.flights = [ { city: 'ashgabat', destinations: ['almaty', 'amritsar'] }, { city: 'amritsar', destinations: ['ashgabat'] }, { city: 'almaty', destinations: ['ashgabat'] } ]; $scope.schedules = [{ "city_from": "ashgabat", "city_to": "almaty", "aviacompany": "türkmenhowaýo

javascript - Making a cross domain request with authentication header -

first of all, server (not mine) returns following headers: access-control-allow-origin: * access-control-allow-credentials: true i'm trying find out how pass request site authentication token. i'm running code on local apache server. this code: function get_data(){ var url = '$url'; var x = new xmlhttprequest(); x.open("get", url, true) if (x.readystate == 4 && x.status == 200) { var responsetext = x.responsetext; console.log(responsetext) }; x.setrequestheader("authentication", "bearer $token"); x.withcredentials = true x.send() } the console returns: xmlhttprequest cannot load $url. response preflight request doesn't pass access control check: no 'access-control-allow-origin' header present on requested resource. origin ' http://localhost ' therefore not allowed access. response had http status code 403. while reading on documentat

webview - Add exception to shouldOverrideUrlLoading in Android Studio? -

i've been trying figure out without luck far... basically, i've got standard webview app call shouldoverrideurlloading. here piece of code public boolean shouldoverrideurlloading(webview view, string url) { view.loadurl(url); return true; } but i'd add exception this. exception should be: if url not contain "scheppersonline", not open in webview in standard browser app. tried achieving doing: public boolean shouldoverrideurlloading(webview view, string url) { if (url.contains("scheppersonline.be")) { view.loadurl(url); return true; } else { return false; } } but doesn't seem work. i'm starting out coding, appreciated! :) logcat: 01-27 13:51:01.406 28229-28229/com.vanbilsen.bram.scheppersmechelen w/cr_bindingmanager: cannot call determinedvisibility() - never saw connection pid: 28229 01-27 13:51:01.422 28229-28229/com.vanbilsen.bram.scheppersmechelen i/chromium: [info:console(1)] "u

rest - How can i make sure that passing parameters don't have any cross site scripting contents -

i creating rest web services using spring & passing parameters method model class. my inputs parameters { "user_id": 23, "user_email_id": "q@q.c", "user_password": "fdsdsdf", "firstname": "<script>window.alert(‘surprise!’);</script>", "lastname": "kdfgkdf", "mobile_number": "1414141414", "user_status": 1, "isdeleted": 0, "created_by": 1, "profile_picturename": "kfksdjfhksjd", "address": "sfdsdfsd" } & rest controller method as @requestmapping(value = "/validate", method = requestmethod.post, consumes = mediatype.application_json_value, produces = mediatype.application_json_value) public object adduser(@valid @requestbody userinputmodel userinputmodel, bindingresult br, httpservletresponse response) throws exception { //l