Comments (4)
包含关系?
from amis.
包含关系?
包含关系和并列关系,我都想知道怎么传比较好。
比如form中有几个item依赖同一个api
本来想的是用service包一下这几个item,但是发现这样的话,这几个item的数据没法给到外层form中。
感觉service会阻止数据像上层传递?
然后只能写成:
const nestApi = (apiArray, main) => {
let result = main;
apiArray.forEach(api => {
result = {
type: 'service',
api,
body: result,
name: api.name
}
});
return result;
}
// 把所有的依赖的api都套在最外层
…
body: [
nestApi([nlpGetDeatilApi, initWithDataApi, nlpGetConfApi, clusterApiFromJobId], getMainForm(opt))
],
…
感觉这么写虽然实现功能了,但是太ugly了,想请教一下正常应该咋把service里面包的数据和外层的数据绑定,以便实现类似外层form提交时候,可以正常校验和提交service里面包住的部分这样的功能。
from amis.
你可能用错了,service 底下要用 controls 而不是用 body 包东西。
https://baidu.github.io/amis/linkpage/form2
from amis.
你可能用错了,service 底下要用 controls 而不是用 body 包东西。
... ... 啊 原来这样啊 谢谢
from amis.
Related Issues (20)
- Service 的 websocket 如何实现局部数据更新? HOT 1
- headless-ui for amis
- 签名控件 HOT 1
- vite+vue3生产环境下charts资源找不到,本地打包时候没问题 HOT 3
- 配置在onEvent里的action组件,redirect不生效
- text addon配置打开iframe,src为带text值的变量时,打开iframe未更新最新值
- Input-group 下 input-text 的 clearable 图标不显示
- input-table组件中columns中字段被包一层的时候,其在form中行数据中字段必填属性在表单提交时没有触发校验 HOT 4
- API responseData 映射模板字符串获取不到值 HOT 2
- 在sdk.js方式中thirds这个目录在很多cdn中不提供, 可否提供配置项将monaco地址放在windows或schema里
- each生成的同name的list-select不能联动
- CRUD 更新数据动作流程不符合预期
- Image图片组件有两个属性不生效
- 请问上传文件的时侯是否提供记录文件在本地的路径名字? HOT 1
- 我想要实现通过按键选择本地目录,然后获取目录的地址
- 自定义组件无法获取ref
- 是否支持类似手机号脱敏的配置,可以配置隐藏几位,以及点击显示或隐藏 HOT 1
- 本地 npm run build 报错 无法构建出产物 HOT 3
- lerna.json里面为啥不包含amis-theme-editor-helper HOT 2
- amis-admin还更新吗?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from amis.