问题标签 [chained]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
4 回答
6971 浏览

windows-installer - 链接 msi/Bootstrapper/先决条件?

我有一些组件 MSI 包需要一起安装以形成最终应用程序。

问题是:可以更新组成包的组件,并且可以在 http 文件服务器上重新启动该组件。我应该采取什么方法?

我正在编写的安装程序是“主”安装程序。它需要能够读取其客户端计算机上安装的每个组件的版本,以便仅在该一个组件上执行升级。

此外,如果第一次安装应用程序,安装程序将下载并安装所有必需的组件。

我正在使用 Installshield 2009。

我已经查看了链接的 MSI,但主安装程序是空的。因为它需要尽可能轻巧。

我不知道如何编写引导程序应用程序,我的公司更喜欢我使用 installshield 来编写安装程序。

我已经研究过 - 显然先决条件并不意味着要卸载。


我相信我可以通过更改版本号来进行小更新,从而允许下载仅下载它需要的组件而不下载整个安装程序 - 目前我正在实施您建议的方式(sascha),我的公司将正在使用通过 InstallShield 提供的 FLEXnet 连接服务。我提到的“组件”(我们的开发人员喜欢使用的一个术语)在概念上类似于 InstallShield 的组件概念。但是,我已经修改了要由功能封装的“组件”,这样在构建版本时,我可以选择将每个“功能”包装在 cab 文件中。

这听起来很令人困惑——即使对我来说也是如此。

我已经诉诸功能<组件(包括服务)

我的公司拒绝让我使用除 Installshield 之外的任何其他安装程序。我的猜测是,为了在遥远的将来更新先决条件要求,需要编写一个新的安装程序,并将应用程序作为主要升级重新发布。这对我来说很有意义。

Perermtate,我认为没有办法卸载预先安装的先决条件,这是有道理的,因为可能需要先决条件作为其他应用程序的平台,毕竟“先决条件”是应用程序的第 3 方组件.

感谢您的所有回复!

0 投票
4 回答
8357 浏览

tfs - 如何链接 TFS 构建?

我有一个场景,我想从另一个调用一个 TFS 构建,第一个执行构建,第二个执行暂存。这将允许我为同一个解决方案执行多个自定义登台。

我知道,我可以在第二个构建中使用 exec 任务完成此任务,并调用 tfsbuild.exe 将第一个构建定义中的构建排队。但是想知道是否有人知道更好的方法?

0 投票
1 回答
2573 浏览

javascript - javascript - 同一表单上的多个依赖/级联/链接选择框

我正在通过 jquery 和 json 填充选择框选项,但我不确定如何在我的表单中处理相同链接选择框的多个实例。

因为选择框仅在需要时呈现,所以某些记录将有十组链接选择框,而其他记录则只需要一个。如何生成唯一选择以支持辅助选择选项的自动填充?

这是我正在使用的代码,我提前感谢您提供的任何见解。

acd2json.php

0 投票
2 回答
2153 浏览

jquery - 在链式选择框上应用 jquery 选择框样式

我在我的页面中创建了一对链式选择框。第二个选择框填充了一组值,具体取决于第一个框的选定值。

使两个选择框像这样工作的脚本使用 PHP 和 JavaScript。这是我正在使用的代码:

形式

javascript代码

php 代码 (findCountry.php)

我想要做的是在这些选择框上应用 jQuery 选择框样式。我还没有成功地做到这一点。问题是 jQuery 隐藏了正常的选择框并用列表替换它。此外,刷新选择框的内容后,jquery 无法将其重新构造为列表。您可以在这里查看 jQuery 代码

我可以做些什么来结合这些技术吗?我已经尝试了一百万件事,但没有任何效果。你能帮我么?

0 投票
1 回答
443 浏览

jquery - 尝试创建一个在后端使用 JSON 的 6 级组合框

我一直在查看很多组合框,但还没有看到在后端使用 JSON 的组合框或超过六个字段的组合框。我试图使用 http://www.appelsiini.net/2010/jquery-chained-selects作为资源,但在后端实现 JSON 时遇到问题。有人介意帮我一把吗?

0 投票
1 回答
563 浏览

scala - Scala 中链式包子句背后的动机是什么?

正如 Martin Odersky 在 Scala网站上所描述的,在 Scala 2.8 中引入了链式包子句。我不太明白这背后的直觉。

以下是 Scala 书中嵌套包的示例:

这个嵌套包的用例是有意义的,因为我们可以在同一个文件中使用多个嵌套包,但是新语法实现了与以前相同的功能,但没有括号。在简洁的 Scala 代码之间分离出包会不会很困难?

如果我理解错误或者我误解了这个概念,请告诉我。

0 投票
1 回答
2632 浏览

cakephp - how to create a chain select form in cakephp

My business directory application calls for 3 chained select boxes, and I'm using cakephp to build this application.

The hierarchy and order of choices for the sections is this:

1 - business group

2 - business type

3 - city (included in table customer)

The relationships are:

  • customer HABTM business types

  • business groups have many business types

  • business types have one business group, HABTM customers

I have searched for jquery plugins that help with this, and found one by Remy Sharp, but it doesn't have the more complex relationships I have. http://remysharp.com/2007/09/18/auto-populate-multiple-select-boxes/

What I imagine happening is the first selection box (business groups) is pre-populated and once a selection is made, an event listener send a message that filters the second selection box, and the same for the third.

What I don't know is how to structure the search action based on the event listener.

Any advice or am I way off base?

As always, I come to the well for help.

Much appreciated. Paul


Thanks very much Nick, I've read many of your posts I really appreciate your response.

I've followed your instructions but have run into problems. I've tried my best to resolve them but haven't figured it out.

This is what I've done so far:

1) created 'chained' actions in both the business_type and business_directory (renamed customer to business directory, which is more appropriate.)

business type chained action:

#xA;

business directory chained action:

#xA;

I did find that with a HABTM relationship, using find 'list' didn't create the join query, whereas find 'all' did.

2) I then created a search action in the business directory and corresponding view.

For the business groups I created a getList action to populate the option list in the search form:

#xA;

In the search view, I've added the javascript for the chain select:

#xA;

And the form:

create('business_directories', array('action'=>'/search_results')); ?> input('business_group_id', array( 'type' => 'select', 'id' => 'businessGoup', 'empty' => '-- Select Business Group --', 'multiple' => true, 'options' => $this->requestAction('/business_groups/getList' ), 'label' => 'Business Group')); ?> input('business_type.id', array( 'type' => 'select', 'id' => 'businessType', 'empty' => '-- Select Business Type --', 'multiple' => true, 'options' => 'none selected', 'label' => 'Business Type')); ?> input('business_directories.id', array( 'type' => 'select', 'id' => 'businessDirectoryCity', 'empty' => '-- Select City --', 'multiple' => true, 'options' => 'options', 'label' => 'City')); ?> end('Search'); ?>

When I test the business type chain function, /business_types/chained/1, everything works.

But when I test the search view, I get a javascript alert error. Then when I check firebug, I get the following two errors:

Warning (2): Missing argument 1 for BusinessTypesController::chained() [APP\controllers\business_types_controller.php, line 71]

Notice (8): Undefined variable: business_group_id [APP\controllers\business_types_controller.php, line 73]

Any additional help with this is very much appreciated.

Thanks, Paul

0 投票
1 回答
490 浏览

django - 关于 Django 管理页面中的级联外键

我的模型如下:

我已经在 admin.py 中注册了它们

我的问题是:在django的管理界面中,当我添加价格时,我可以从下拉列表中选择一个电话,但是电话太多了,所以我想先选择制造商,然后从制造商的电话中选择电话. 我怎样才能做到这一点。非常感谢。

0 投票
1 回答
243 浏览

jquery - 是否可以在 jquery 中提交表单并使用相关表单加载另一个相关页面?

所以,我在asp中有4页。

第一个从用户那里获取数据并将其保存在会话变量中。

第二个用于上传图片。

第三个用于裁剪该图片(并保存裁剪的图像)。

第四个是确认页面,将数据保存到数据库中。

是否可以使用 jquery 从不同页面“链接”所有这些表单?你知道如何做到这一点的任何教程吗?

我在网上找到的只是提交表单,然后打开响应消息。我想在页面中加载另一个表单,而不刷新页面,或者可能在叠加层内完成所有操作。

谢谢。

0 投票
2 回答
12789 浏览

codeigniter - 使用关联数组的多个 LIKE db 查询 - 但都来自相同的列名......?

我正在尝试使用 CodeIgniter 的活动记录类查询我的数据库。我有许多博客文章存储在一个表中。该查询用于搜索功能,该功能将提取所有分配有特定类别的帖子。因此,表格的“类别”列将列出该帖子的所有类别,不按特定顺序排列,用逗号分隔,例如:政治、历史、社会学。等等

如果用户选择政治和历史,则应返回具有这两个类别的所有帖子的标题。

因此,查询的类别列表将是数组 $cats。我以为这行得通-

通过产生这个:

(这将产生 - 'WHERE categories LIKE '%Politics%' AND categories LIKE '%History%')

但它不起作用,它似乎只产生第一个语句。我猜的问题是每个链接查询的列名都是相同的。CI 用户指南中似乎没有任何关于此的内容(http://codeigniter.com/user_guide/database/active_record.html),因为他们似乎假设每个链接语句将用于不同的列名.

当然,不可能在一个语句中使用关联数组,因为它必须包含重复的键——在这种情况下,每个键都必须是“类别”......