{"action":"created","issue":{"url":"https://api.github.com/repos/youzan/zanui-weapp/issues/109","repository_url":"https://api.github.com/repos/youzan/zanui-weapp","labels_url":"https://api.github.com/repos/youzan/zanui-weapp/issues/109/labels{/name}","comments_url":"https://api.github.com/repos/youzan/zanui-weapp/issues/109/comments","events_url":"https://api.github.com/repos/youzan/zanui-weapp/issues/109/events","html_url":"https://github.com/youzan/zanui-weapp/issues/109","id":287440003,"number":109,"title":"在 debug 模式关闭的情况下，Field 依然会打印表单信号","user":{"login":"bestony","id":13283837,"avatar_url":"https://avatars1.githubusercontent.com/u/13283837?v=4","gravatar_id":"","url":"https://api.github.com/users/bestony","html_url":"https://github.com/bestony","followers_url":"https://api.github.com/users/bestony/followers","following_url":"https://api.github.com/users/bestony/following{/other_user}","gists_url":"https://api.github.com/users/bestony/gists{/gist_id}","starred_url":"https://api.github.com/users/bestony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bestony/subscriptions","organizations_url":"https://api.github.com/users/bestony/orgs","repos_url":"https://api.github.com/users/bestony/repos","events_url":"https://api.github.com/users/bestony/events{/privacy}","received_events_url":"https://api.github.com/users/bestony/received_events","type":"User","site_admin":false},"labels":[{"id":524043848,"url":"https://api.github.com/repos/youzan/zanui-weapp/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-01-10T13:51:06Z","updated_at":"2018-03-11T12:37:32Z","closed_at":"2018-03-11T12:37:32Z","author_association":"NONE","body":"### ISSUE 类型\r\n\r\n提交 Bug\r\n\r\n### ISSUE 问题描述\r\n\r\n在 Debug 状态为 False  时，依然会打印具体事件。\r\n\r\n### 可行的解决方案\r\n\r\n1. 默认情况下不输出相关事件\r\n2. 在提供的参考 demo 中对事件进行打印\r\n3. 通过 app.json/app.js 中的参数进行判断是否打印相关信息。\r\n\r\n### 如何复现 Bug\r\n\r\n调用 Field 组件，参考代码\r\n_query.js_\r\n```javascript\r\nconst { Field, extend } = require('../../zan/index');\r\nPage(extend({}, Field, {\r\n  data: {\r\n  }, \r\n  formSubmit:function(e){\r\n    console.error(e.detail.value);\r\n  },\r\n  handleZanFieldChange({ componentId, detail }) {\r\n    /*\r\n     * componentId 即为在模板中传入的 componentId\r\n     * 用于在一个页面上使用多个 tab 时，进行区分\r\n     * detail 即输入框中的内容\r\n     */\r\n    /*\r\n     * 处理函数可以直接 return 一个字符串，将替换输入框的内容。\r\n     */\r\n  },\r\n  // 输入框聚焦时触发\r\n  handleZanFieldFocus({ componentId, detail }) { },\r\n  // 输入框失焦时触发\r\n  handleZanFieldBlur({ componentId, detail }) { },\r\n}));\r\n```\r\n_query.xml_\r\n```xml\r\n<view class=\"doc-title zan-hairline--bottom zan-hairline--bottom\">论文查询</view>\r\n\r\n<import src=\"../../zan/field/index.wxml\" />\r\n<form bindsubmit=\"formSubmit\">\r\n\r\n  <template is=\"zan-field\" data=\"{{ title: '作者名',name : 'author', inputType:'text', type: 'input', placeholder: '请输入作者姓名' }}\"></template>\r\n\r\n  <template is=\"zan-field\" data=\"{{ title: '电话号码',name : 'phone', inputType:'text', type: 'input', placeholder: '请输入您留下的电话号码' }}\"></template>\r\n\r\n  <view class=\"zan-btns\">\r\n    <button class=\"zan-btn zan-btn--primary\" formType=\"submit\">提交信息</button>\r\n    <button class=\"zan-btn\" formType=\"reset\">重置数据</button>\r\n  </view>\r\n</form>\r\n```\r\n\r\n\r\n### Bug 截图 \r\n\r\n![](https://ws2.sinaimg.cn/large/006tNc79gy1fnbuo9vqf0j317a06gmxm.jpg)\r\n\r\n![default](https://user-images.githubusercontent.com/13283837/34776016-3f24e32e-f650-11e7-97de-074e0938032f.gif)\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/youzan/zanui-weapp/issues/comments/372112242","html_url":"https://github.com/youzan/zanui-weapp/issues/109#issuecomment-372112242","issue_url":"https://api.github.com/repos/youzan/zanui-weapp/issues/109","id":372112242,"user":{"login":"pangxie1991","id":5961240,"avatar_url":"https://avatars0.githubusercontent.com/u/5961240?v=4","gravatar_id":"","url":"https://api.github.com/users/pangxie1991","html_url":"https://github.com/pangxie1991","followers_url":"https://api.github.com/users/pangxie1991/followers","following_url":"https://api.github.com/users/pangxie1991/following{/other_user}","gists_url":"https://api.github.com/users/pangxie1991/gists{/gist_id}","starred_url":"https://api.github.com/users/pangxie1991/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pangxie1991/subscriptions","organizations_url":"https://api.github.com/users/pangxie1991/orgs","repos_url":"https://api.github.com/users/pangxie1991/repos","events_url":"https://api.github.com/users/pangxie1991/events{/privacy}","received_events_url":"https://api.github.com/users/pangxie1991/received_events","type":"User","site_admin":false},"created_at":"2018-03-11T12:37:32Z","updated_at":"2018-03-11T12:37:32Z","author_association":"MEMBER","body":"下个版本就会清理掉多余的日志信息"}}
{"actor":{"display_login":"pangxie1991"}}