惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

V2EX - 技术
V2EX - 技术
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Latest news
Latest news
T
The Exploit Database - CXSecurity.com
博客园 - 三生石上(FineUI控件)
WordPress大学
WordPress大学
L
Lohrmann on Cybersecurity
aimingoo的专栏
aimingoo的专栏
B
Blog
T
Threat Research - Cisco Blogs
罗磊的独立博客
Application and Cybersecurity Blog
Application and Cybersecurity Blog
P
Proofpoint News Feed
P
Palo Alto Networks Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
宝玉的分享
宝玉的分享
博客园 - 司徒正美
Google DeepMind News
Google DeepMind News
Blog — PlanetScale
Blog — PlanetScale
T
Tor Project blog
阮一峰的网络日志
阮一峰的网络日志
Last Week in AI
Last Week in AI
Martin Fowler
Martin Fowler
酷 壳 – CoolShell
酷 壳 – CoolShell
Recorded Future
Recorded Future
D
DataBreaches.Net
Y
Y Combinator Blog
大猫的无限游戏
大猫的无限游戏
IT之家
IT之家
B
Blog RSS Feed
Scott Helme
Scott Helme
P
Proofpoint News Feed
V
Vulnerabilities – Threatpost
A
Arctic Wolf
Help Net Security
Help Net Security
L
LINUX DO - 最新话题
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Vercel News
Vercel News
AWS News Blog
AWS News Blog
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
S
Schneier on Security
Hacker News: Ask HN
Hacker News: Ask HN
N
Netflix TechBlog - Medium
L
LangChain Blog
博客园 - 叶小钗
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
M
MIT News - Artificial intelligence
N
News and Events Feed by Topic
Webroot Blog
Webroot Blog
W
WeLiveSecurity

博客园 - 阿炬

Claude Code 老是提示找不到文件的解决方案 目标设定与积极反馈:如何通过小目标激励自己 阿布思考法 win11环境下执行yarn build,提示:'mv' 不是内部或外部命令,也不是可运行的程序 如何在关闭远程桌面后继续自动化程序 解决Mac下ERROR: Cannot connect to the Docker daemon at unix:///Users/qq/.orbstack/run/docker.sock. Is the docker daemon running? Visual Studo for Mac 快捷键 取消api返回结果中data对象默认Json首字母小写 Pega里Flow图元 NPOI导入sheet,并复制多行数据 用PC windows作为Mac macos的扩展屏 能改变你一生的顶级逻辑层次 《从偶然到必然》思维导图第1、2章 macbook m1 无法启动mysql服务,提示Can‘t connect to local MySQL server through socket ‘/tmp/mysql.sock‘ mac VS提示 SDK package not found "Microsoft.NET.SDK 解决方法 MacOS Monterey 一键重置系统 macbook m1 键盘进灰导致个别按键不灵敏解决方法 DataGrip连接sqlserver,提示驱动程序无法通过使用安全套接字层(SSL)加密与 SQL Server 建立安全连接的解决方法 .net6环境下RestSharp获取gbk网页乱码的解决方案 macbook air m1笔记本使用体验和心得(01)
amis中月份选择组件,如何设定值为月末最后一天
阿炬 · 2024-01-08 · via 博客园 - 阿炬

需求:选择月份,表单提交时,提交的值是月末最后一天

{
    "type": "page",
    "id": "u:f4d759761b40",
    "asideResizor": false,
    "themeCss": {
      "baseControlClassName": {
        "boxShadow:default": " 0px 0px 0px 0px transparent"
      },
      "bodyControlClassName": {
        "boxShadow:default": " 0px 0px 0px 0px transparent"
      },
      "headerControlClassName": {
        "boxShadow:default": " 0px 0px 0px 0px transparent"
      },
      "toolbarControlClassName": {
        "boxShadow:default": " 0px 0px 0px 0px transparent"
      },
      "asideControlClassName": {
        "boxShadow:default": " 0px 0px 0px 0px transparent"
      }
    },
    "body": [
      {
        "id": "u:b156da001a16",
        "type": "form",
        "title": "表单",
        "mode": "horizontal",
        "dsType": "api",
        "feat": "Insert",
        "body": [
          {
            "type": "input-month",
            "label": "日期",
            "name": "mydate",
            "id": "u:dcb628073830",
            "placeholder": "请选择月份",
            "valueFormat": "YYYY-MM-DD",
            "displayFormat": "YYYY-MM",
            "minDate": "",
            "maxDate": "",
            "value": "",
            "onEvent": {
              "change": {
                "weight": 0,
                "actions": [
                  {
                    "ignoreError": false,
                    "script": "setTimeout(function () {\n  let date = new Date( context.props.formStore.data.mydate);\n  let year = date.getFullYear();\n  let month = date.getMonth() + 1;\n  let l = new Date(year, month, 0).getDate();\n  let lastday = year +\"-\"+ month+\"-\" + l;\n\n  context.props.formStore.setValues({ lastday: lastday });\n\n  console.log(context.props.data.mydate);\n},500)\n\n",
                    "actionType": "custom"
                  }
                ]
              }
            },
            "autoFill": {
            }
          },
          {
            "type": "input-text",
            "label": "月末",
            "name": "lastday",
            "id": "u:53abff2c83bb",
            "value": ""
          }
        ],
        "actions": [
          {
            "type": "button",
            "label": "提交",
            "onEvent": {
              "click": {
                "actions": [
                  {
                    "actionType": "submit",
                    "componentId": "u:b156da001a16"
                  }
                ]
              }
            },
            "level": "primary",
            "id": "u:8d07bb3f10f5"
          }
        ],
        "resetAfterSubmit": true,
        "debug": true
      }
    ]
  }