views

Removing a view from Eclipse Window -> Show views

我的未来我决定 提交于 2019-12-11 13:25:59
问题 We have an application in which some views only work when attached to certain perspectives. We want to remove those views from the Window -> Show View dialog so that users cannot add them to perspectives where they don't work. Any ideas on how to do this either programmatically or declaratively? I have tried using <visibleWhen /> , but the views are still showing in the dialog: <view class="com.mycompany.ViewClass" id="com.mycompany.ViewId" name="View Name" restorable="true"> <visibleWhen>

Calling multiple views in CouchApp query

☆樱花仙子☆ 提交于 2019-12-11 11:59:31
问题 I need to search the CouchDB based on several criteria entered in a form. Name, an array of Tags and so on. I would then need various views to index on these fields. Ultimately, all the results will be collated in data.js and provided to mustache.html. Say there are 3 views - docsByName, docsByTags, docsById. What I don't know is, how to query all these views in query.js. Can this be done and how ? Or should the approach be of that to write one view that makes multiple emits for each search

Angular ui-router variable in nested view

*爱你&永不变心* 提交于 2019-12-11 11:49:08
问题 I'm currently working on an app where I have multiple nested views, they sort of look like this: - ui-view - ui-view="header" - ui-view="nav" - ui-view="body" My states are defined as follows: .state('index', { url: '', // default route templateUrl: 'welcome.html' }) .state('app', { abstract: true, templateUrl: 'app.template.html' // This template contains the 3 different ui-views }) // I'm using a different state here so I can set the navigation and header by default .state('in-app', {

Django: link to url in template when function is in a view in another directory?

老子叫甜甜 提交于 2019-12-11 11:29:13
问题 I'm trying to display comments in a template like this: {{ url note.note }} {{ url note.note_by }} My problem is that my template is in another directory from where the view that "requests" the notes are. How do I link to a view in another directory (or more specifically; the note.note inside a function in a views.py in another directory)? In the views.py in the SAME directory as the template, I am linking to the template like this: def blah(request): return render(request, 'site/blah.html')

play2 using main project views/controllers/models in submodule/subproject and inversely

不问归期 提交于 2019-12-11 11:25:54
问题 I have: main project sub project called "shopping" I would like to use views from main project inside the subproject. My code of sub project controller: package controllers.shopping; public class Application extends Controller { public static Result index() { return ok(views.html.confirmation.render("ok")); } } And my main build file lazy val shopping = project.in(file("modules/shopping")) val main = project.in(file(".")) .dependsOn(shopping).aggregate(shopping) My model class in submodule

Undefined Variable error in View

孤街醉人 提交于 2019-12-11 10:13:52
问题 My controller is in this question: how to add pagination to this But now, i'm getting undefined variable in my view, View has an input <input name='query'/> which i receive it in controller as, $query = $this->input->get('query'); Now, i am trying to pass the same query string back into my view inside the link of pagination. <a href="<php echo base_url(); ?>main/search/query=<?php echo $query; ?>&off=<?php echo $off=5;">1</a> $off works but not $query . But i'm NOT saving the $query to the

Finding Overlap date ranges between startdate and enddate in couch Db or cloudant

妖精的绣舞 提交于 2019-12-11 09:08:43
问题 Hello I am building a reservation app using database as couchDb. I have several reservation documents and each of them has roomId, start date and end date. Now when user creates a meeting request with roomId, start date and end date, I need to search for overlaps time ranges between the start time and endtime in the existing reservations and create a reservations only when there is no conflict. Along with this I also need to check for roomid. The requirement is similar to Determine Whether

How to implement seasonal logos in Drupal?

怎甘沉沦 提交于 2019-12-11 08:57:33
问题 I know this can probably be done with CCK and a view, and maybe a logo content type. But I was wondering if anybody knows of the BEST way to do the following (perhaps there is a module that does this already): I want SEASONAL displays of my logo. I.e. If I create a CHRISTMAS version of my logo, with for example a a christmas hat in the logo, this must be shown on Christmas, or 7 days before christmas. This 7 days must be changeable on a PER LOGO basis. I.e. I might want to show christmas logo

Django error: create_user() takes at least 2 arguments (3 given)

断了今生、忘了曾经 提交于 2019-12-11 08:34:39
问题 I'm a newbie with Django, sorry for the silly question, but I get this error when I try to do the user registration : create_user() takes at least 2 arguments (3 given) in the line user = User.objects.create_user(user=form['username'], first_name=form['first_name'], last_name=form['last_name'], password=form['password'], email=form['email']) My views.py is the following: def register(request): context = RequestContext(request) # check if the request contains POST data # this happens when a

PHP Select SQL view no output

▼魔方 西西 提交于 2019-12-11 08:21:35
问题 I creating a php file that pulls a view from an SQL database. Can someone let me know why this isn't working? It seems to be timing out. I am not getting a connection error, either. Thank you in advance. <?php require ('mysqli_connect.php'); $sql = "SELECT * FROM testview ;"; $result = mysqli_query($dbc,$sql); // Check connection if ($dbc->connect_error) { die("Connection failed: " . $dbc->connect_error); } $result=mysqli_query($sql); if ($result->num_rows > 0) { echo "<table><tr><th>userID<