"use strict";
/*
 * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
 * This devtool is neither made for production nor for readable output files.
 * It uses "eval()" calls to create a separate source file in the browser devtools.
 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
 * or disable the default devtool with "devtool: false".
 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
 */
(self["webpackChunknocode_component"] = self["webpackChunknocode_component"] || []).push([[604],{

/***/ "./src/control/mobile/RefBill/RefBillReadonly.less":
/*!*********************************************************!*\
  !*** ./src/control/mobile/RefBill/RefBillReadonly.less ***!
  \*********************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\"text\":\"_7hth3Wfp_text\"});\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/RefBill/RefBillReadonly.less?");

/***/ }),

/***/ "./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.less":
/*!*****************************************************************!*\
  !*** ./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.less ***!
  \*****************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\"popup_body\":\"D2uvtrIA_popup_body\",\"org_info\":\"aYJTSKTE_org_info\",\"organization\":\"_3mIYmgcN_organization\",\"item\":\"x8pGkqfS_item\",\"title\":\"tIkx0VPm_title\",\"list\":\"UZyfhDne_list\",\"page\":\"ghNioCPY_page\",\"user_info\":\"Ef77mT7u_user_info\",\"avatar\":\"_8U-jn1Ug_avatar\",\"origin\":\"_00nsNgYE_origin\",\"org_Info\":\"_2jnKO7VQ_org_Info\",\"headTitle\":\"sPSqBVga_headTitle\",\"hidden\":\"AVFhz5E2_hidden\",\"org_Info_loading\":\"xwSSaRqa_org_Info_loading\"});\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.less?");

/***/ }),

/***/ "./src/control/mobile/RefBill/index.less":
/*!***********************************************!*\
  !*** ./src/control/mobile/RefBill/index.less ***!
  \***********************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\"ref-bill-option\":\"_54fTl+Yu_ref-bill-option\",\"ref-bill-option-title\":\"I-f6aEiv_ref-bill-option-title\",\"ref-bill-option-desc\":\"z8gANQMR_ref-bill-option-desc\",\"ref-bill-option-empty\":\"c4n62y0z_ref-bill-option-empty\",\"ref-bill-extra\":\"B+v0ytCg_ref-bill-extra\"});\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/RefBill/index.less?");

/***/ }),

/***/ "./src/control/mobile/Attachment/index.tsx":
/*!*************************************************!*\
  !*** ./src/control/mobile/Attachment/index.tsx ***!
  \*************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ \"../../node_modules/core-js/modules/es.object.to-string.js\");\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ \"../../node_modules/core-js/modules/web.dom-collections.for-each.js\");\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/keys */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/keys.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/filter */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/filter.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/define-properties */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/define-properties.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/define-property */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/define-property.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8__);\n/* harmony import */ var _babel_runtime_corejs3_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/defineProperty */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/defineProperty.js\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! kd_libs/react */ \"webpack/container/remote/kd_libs/react\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(kd_libs_react__WEBPACK_IMPORTED_MODULE_10__);\n/* harmony import */ var _FieldItemWrapper__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../FieldItemWrapper */ \"./src/control/mobile/FieldItemWrapper/index.tsx\");\n/* harmony import */ var _base_mobile__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @/base/mobile */ \"./src/base/mobile/index.ts\");\n/* harmony import */ var _utils_mobTools__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @/utils/mobTools */ \"./src/utils/mobTools.tsx\");\n/* harmony import */ var _control_hooks_useAttachmentHooks__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @/control/hooks/useAttachmentHooks */ \"./src/control/hooks/useAttachmentHooks.ts\");\n\n\n\n\n\n\n\n\n\n\nfunction ownKeys(e, r) { var t = _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2___default()(e); if ((_babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default())) { var o = _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default()(e); r && (o = _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4___default()(o).call(o, function (r) { return _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5___default()(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0,_babel_runtime_corejs3_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_9__[\"default\"])(e, r, t[r]); }) : (_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6___default()) ? _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7___default()(e, _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6___default()(t)) : ownKeys(Object(t)).forEach(function (r) { _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8___default()(e, r, _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5___default()(t, r)); }); } return e; }\n\n\n\n// import { KDContext } from '@/utils/context'\n// import { debounce, downloadFile } from '@/utils'\n\n// import { useFieldProps } from '@/control/hooks/useFieldProps'\n// import { UPDATE_CONTROL_STATES, INVOKE_CONTROL_METHOD } from '@/constants/sysActionName'\n\n// import styles from './index.less'\n// import { Icon } from 'kdesign-mobile'\n// import produce from '@/utils/immerTools'\n// import { debounce } from '@/utils'\n\n// 免登分享时需要拼接上免登分享Id\n// const ATTACHMENT_ACTION = `${window.__domainurl__ || ''}nocode/v2/nocode_sys/attachment`\n// // 拼接免登分享ID\n// const getFullUrl = (path:string) => {\n//   const str = path.includes('?') ? '&' : '?'\n//   const shareParam = window.NOCODE_SHARE_ID ? `${str}noCodeShareId=${window.NOCODE_SHARE_ID}` : ''\n//   return path + shareParam\n// }\n\nfunction KDAttachment(props) {\n  // const { controlMeta, value, invokeData, onChange } = props\n  // const { model } = useContext(KDContext)\n  // const { readonly, disabled, hidden, required, rules } = useFieldProps(controlMeta)\n  // const [datas, setDatas] = useState<any[]>([]) // 文件列表\n  // // const titleRef = useRef(model.getControlText(controlMeta.caption))\n  // const [labelText, setLabelText] = useState('') // 文件列表\n  // const { pageId, id, uploadNum, fileMaxSize, attachmentFileType, displayCount, uploadPrompt } = controlMeta\n  // // const beforeRef = useRef(false) // 上传前标识，避免多文件上传时多次触发\n  // const fieldRef = useRef<any>(null) // 上传前标识，避免多文件上传时多次触\n  // // const baseUrl = useRef(model.getFileServer('attachment')) // 图片路径\n  // const uploadRef = useRef(new Map())\n\n  // // 上传前执行，并同步信息到服务器\n  // const beforeUpload = useCallback((file, list) => {\n  //   const result = uploadAttachmentVerify(file, list, controlMeta)\n  //   if (result) beforeAsyn(list)\n  //   return result\n  // }, [])\n\n  // // 同步上传信息\n  // const beforeAsyn = useCallback(debounce((list:any[]) => {\n  //   // [{\"key\":\"attachmentpanel\",\"methodName\":\"beforeUpload\",\"args\":[[{\"uid\":\"rc-upload-1665492200338-3\",\"name\":\"nginx路由配置.docx\",\"size\":17445,\"type\":\"application/vnd.openxmlformats-officedocument.wordprocessingml.document\"}]],\"postData\":[{},[]]}]\n  //   const args:any[] = []\n  //   list.forEach((item:any) => {\n  //     if (checkAttachmentType(item, attachmentFileType) && !checkSize(item, fileMaxSize) && !checkEmpty(item)) {\n  //       args.push({ uid: item.uid, name: item.name, size: item.size, type: item.type })\n  //     }\n  //   })\n  //   model.batchInvoke('beforeUpload', pageId, id, [args], [])\n  // }, 50), [])\n\n  // // change事件, 更新\n  // const handleChange = useCallback(({ file, fileList }) => {\n  //   // console.log('onChange', file)\n  //   const errText = controlMeta.mi && fileList.length === 0 ? '值不能为空' : ''\n  //   fieldRef.current.setValidateMessage(errText)\n  //   const newList = fileList.filter((item:any) => item.status !== 'notStart')\n  //   if (file.status === 'done' && file.response.status) {\n  //     const { lastModified, uid, name, type, size } = file\n  //     const param = {\n  //       status: 'success',\n  //       url: file.response.data.url,\n  //       uploadTime: Date.now()\n  //     }\n  //     const info = { lastModified, uid, name, type, size, ...param }\n  //     uploadRef.current.set(file.uid, info)\n  //     const uploadList = newList.filter((item:any) => item.status === 'uploading')\n  //     if (uploadList.length === 0) {\n  //       if (onChange) { // 附件单据体内需要使用单据体提供onchange事件\n  //         onChange([...uploadRef.current.values()])\n  //       } else {\n  //         updateDatas([...uploadRef.current.values()])\n  //       }\n  //     }\n  //   } else if (file.status === 'error' || (file.status === 'done' && !file?.response.status)) {\n  //     showToast(`${file.name}上传失败，请重新上传`)\n  //     model.batchInvoke('uploadResult', pageId, id, [[{ uid: file.uid, description: '禁止上传非法文件。', status: 'error' }]], [{}, []])\n  //   }\n  //   setDatas(newList)\n  // }, [onChange, id])\n\n  // // 同步上传成功内容到服务端\n  // const updateDatas = useCallback((files:any[]) => {\n  //   model.batchInvoke('updateValue', pageId, '', [], [{}, [{ k: id, v: files }]])\n  // }, [])\n\n  // // 下载\n  // const onDownload = useCallback((info:any) => {\n  //   const config = model.getConfig(pageId)\n  //   const file = uploadRef.current.get(info.uid)\n  //   const options = {\n  //     params: '1',\n  //     appId: config.appId,\n  //     fId: config.formId,\n  //     fileName: file.name\n  //   }\n  //   const url = `${getFullUrl(file.url)}&kd_cs_ticket=${model.Global.token}`\n  //   downloadFile(url, options)\n  // }, [])\n\n  // // 删除\n  // const onRemove = useCallback((file:any) => {\n  //   const newData = datas.filter((item:any) => item.uid !== file.uid)\n  //   if (controlMeta.mi && !newData.length) {\n  //     fieldRef.current.setValidateMessage('值不能为空')\n  //   }\n  //   // if (file.status === 'success') {\n  //   // }\n  //   model.batchInvoke('beforeRemove', pageId, id, [{ uid: file.uid }], [])\n  //   setDatas([...newData])\n  //   return true\n  // }, [datas])\n\n  // // 修改文件名\n  // // [{\"key\":\"attachmentfield\",\"methodName\":\"rename\",\"args\":[\"rc-upload-1673230355197-6\",\"999.jpg\"],\"postData\":[{},[]]}]\n  // const onChangeFileName = useCallback((info:any) => {\n  //   const file = datas.filter((item:any) => item.uid === info.uid)[0]\n  //   file.name = info.name\n  //   if (file.status === 'success') {\n  //     const obj = uploadRef.current.get(info.uid)\n  //     obj.name = info.name\n  //     uploadRef.current.set(info.uid, obj)\n  //     // updateDatas([...uploadRef.current.values()])\n  //     model.batchInvoke('rename', pageId, id, [info.uid, info.name], [{}, []])\n  //   }\n  //   showToast('重命名成功', 0)\n  //   setDatas([...datas])\n  // }, [datas])\n\n  // useEffect(() => {\n  //   const label = !displayCount || readonly || disabled ? '' : `(${uploadRef.current.size}/${uploadNum?.max || 1})`\n  //   setLabelText(label)\n  // }, [displayCount, readonly, disabled, uploadNum, uploadRef.current])\n\n  // // 监听系统U指令-回调\n  // const updateValue = useCallback((info:any) => {\n  //   // console.log('updateValue', info)\n  //   if (!Array.isArray(info.v)) {\n  //     setDatas([])\n  //     return\n  //   }\n  //   const map = new Map()\n  //   info.v.forEach((item:any) => {\n  //     const name = model.getControlText(item.name)\n  //     map.set(item.uid, { ...item, name }) // 缓存已经上传成功的列表\n  //   })\n  //   let arr = []\n  //   if (datas.length) { // 有数据时\n  //     arr = datas.map((item:any) => {\n  //       return map.has(item.uid) ? map.get(item.uid) : item\n  //     })\n  //   } else { // 无数据时\n  //     arr = [...map.values()]\n  //   }\n  //   uploadRef.current = map\n  //   setDatas(arr)\n  //   // 建立索引，并转换文件名\n  //   // info.v.forEach((item:any) => {\n  //   //   const name = model.getControlText(item.name)\n  //   //   uploadRef.current.set(item.uid, { ...item, name }) // 缓存已经上传成功的列表\n  //   // })\n  //   // if (datas.length) { // 存在列表，更新列表, 同时更新URL\n  //   //   const keys = [...uploadRef.current.keys()]\n  //   //   const data = datas.map((item:any) => {\n  //   //     return keys.includes(item.uid) ? uploadRef.current.get(item.uid) : item\n  //   //     // if (keys.includes(item.uid)) {\n  //   //     //   const file = uploadRef.current.get(item.uid)\n  //   //     //   return { ...file, url: (baseUrl.current + file.url) }\n  //   //     // }\n  //   //   })\n  //   //   setDatas(data)\n  //   // } else {\n  //   //   setDatas([...uploadRef.current.values()])\n  //   // }\n  // }, [])\n\n  // /**\n  //  * 控件内部指令\n  //  */\n  // const controlMethod = useCallback((info) => {\n  //   const { args, methodname } = info[0]\n  //   switch (methodname) {\n  //     case 'beforeRemove': // 删除\n  //       const { canRemove } = args[0]\n  //       if (canRemove) {\n  //         const files:any[] = []\n  //         uploadRef.current.forEach((item:any, key:string) => {\n  //           const { lastModified, name, size, status, type, uid, url, uploadTime } = item\n  //           if (key === args[0].uid) {\n  //             files.push({ lastModified, name, size, status, type, uid, url, uploadTime, delete: true })\n  //           } else {\n  //             files.push({ lastModified, name, size, status, type, uid, url, uploadTime })\n  //           }\n  //         })\n  //         model.batchInvoke('updateValue', pageId, '', [], [{}, [{ k: id, v: files }]])\n  //         uploadRef.current.delete(args[0].uid)\n  //       }\n  //       break\n  //   }\n  // }, [datas])\n  // // 监听值变化\n  // useEffect(() => {\n  //   if (value && value?.[0] !== datas) {\n  //     updateValue({ k: id, v: value })\n  //   }\n  // }, [value])\n\n  // // 监听表格转发的指令\n  // useEffect(() => {\n  //   if (invokeData) {\n  //     controlMethod([invokeData])\n  //   }\n  // }, [invokeData])\n\n  // model.useUpdateControlStates(controlMeta, updateValue)\n  // model.useInvokeControlMethod(controlMeta, controlMethod)\n\n  // // useEffect(() => {\n  // //   // 监听系统U指令\n  // //   const rmUpdateListener = model.addControlAction(UPDATE_CONTROL_STATES, pageId, id, updateValue)\n  // //   const rmMethodListener = model.addControlAction(INVOKE_CONTROL_METHOD, pageId, id, controlMethod)\n  // //   return () => {\n  // //     rmUpdateListener?.()\n  // //     rmMethodListener?.()\n  // //   }\n  // // }, [datas])\n\n  // // console.log('KDAttachment', controlMeta)\n  // const notice = uploadPrompt ? `请上传小于${fileMaxSize}M的${attachmentFileType?.replaceAll('.', '')}文件，文件个数不少于${uploadNum?.min || 0}个，不多于${uploadNum?.max || 1}个` : ''\n\n  var _useAttachmentHooks = (0,_control_hooks_useAttachmentHooks__WEBPACK_IMPORTED_MODULE_14__[\"default\"])(_objectSpread(_objectSpread({}, props), {}, {\n      uploadAttachmentVerify: _utils_mobTools__WEBPACK_IMPORTED_MODULE_13__.uploadAttachmentVerify,\n      showInfo: _utils_mobTools__WEBPACK_IMPORTED_MODULE_13__.showToast\n    })),\n    action = _useAttachmentHooks.action,\n    disabled = _useAttachmentHooks.disabled,\n    readonly = _useAttachmentHooks.readonly,\n    handleChange = _useAttachmentHooks.handleChange,\n    onDownload = _useAttachmentHooks.onDownload,\n    onChangeFileName = _useAttachmentHooks.onChangeFileName,\n    beforeUpload = _useAttachmentHooks.beforeUpload,\n    handleRemove = _useAttachmentHooks.handleRemove,\n    attachmentFileType = _useAttachmentHooks.attachmentFileType,\n    uploadNum = _useAttachmentHooks.uploadNum,\n    notice = _useAttachmentHooks.notice,\n    previewType = _useAttachmentHooks.previewType,\n    labelText = _useAttachmentHooks.labelText,\n    required = _useAttachmentHooks.required,\n    hidden = _useAttachmentHooks.hidden,\n    fieldRef = _useAttachmentHooks.fieldRef,\n    datas = _useAttachmentHooks.datas,\n    rules = _useAttachmentHooks.rules;\n  if (hidden) return null;\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().createElement(_FieldItemWrapper__WEBPACK_IMPORTED_MODULE_11__[\"default\"], {\n    ref: fieldRef,\n    subTitle: labelText,\n    controlMeta: _objectSpread(_objectSpread({}, props.controlMeta), {}, {\n      labelDirection: 'v'\n    }),\n    required: required\n    // rules={rules}\n  }, (datas === null || datas === void 0 ? void 0 : datas.length) === 0 && readonly ? /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().createElement((kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().Fragment), null, \"-\") : /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().createElement(_base_mobile__WEBPACK_IMPORTED_MODULE_12__.Attachment, {\n    multiple: true,\n    action: action,\n    data: {\n      action: 'upload',\n      tempstorage: false\n    },\n    fileList: datas,\n    disabled: disabled,\n    readonly: readonly,\n    onChange: handleChange,\n    onDownload: onDownload,\n    onChangeFileName: onChangeFileName,\n    beforeUpload: beforeUpload,\n    onRemove: handleRemove,\n    accept: attachmentFileType,\n    uploadNum: uploadNum,\n    noticeInfo: notice,\n    previewType: previewType\n  }));\n}\n/* harmony default export */ __webpack_exports__[\"default\"] = ((0,kd_libs_react__WEBPACK_IMPORTED_MODULE_10__.memo)(KDAttachment));\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/Attachment/index.tsx?");

/***/ }),

/***/ "./src/control/mobile/Picture/index.tsx":
/*!**********************************************!*\
  !*** ./src/control/mobile/Picture/index.tsx ***!
  \**********************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ \"../../node_modules/core-js/modules/es.object.to-string.js\");\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ \"../../node_modules/core-js/modules/web.dom-collections.for-each.js\");\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/keys */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/keys.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/filter */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/filter.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/define-properties */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/define-properties.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/define-property */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/define-property.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8__);\n/* harmony import */ var _babel_runtime_corejs3_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/defineProperty */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/defineProperty.js\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! kd_libs/react */ \"webpack/container/remote/kd_libs/react\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(kd_libs_react__WEBPACK_IMPORTED_MODULE_10__);\n/* harmony import */ var _FieldItemWrapper__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../FieldItemWrapper */ \"./src/control/mobile/FieldItemWrapper/index.tsx\");\n/* harmony import */ var _base_mobile__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @/base/mobile */ \"./src/base/mobile/index.ts\");\n/* harmony import */ var _utils_mobTools__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @/utils/mobTools */ \"./src/utils/mobTools.tsx\");\n/* harmony import */ var _control_hooks_usePictureHooks__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @/control/hooks/usePictureHooks */ \"./src/control/hooks/usePictureHooks.ts\");\n\n\n\n\n\n\n\n\n\n\nfunction ownKeys(e, r) { var t = _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2___default()(e); if ((_babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default())) { var o = _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default()(e); r && (o = _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_4___default()(o).call(o, function (r) { return _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5___default()(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0,_babel_runtime_corejs3_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_9__[\"default\"])(e, r, t[r]); }) : (_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6___default()) ? _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_7___default()(e, _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_6___default()(t)) : ownKeys(Object(t)).forEach(function (r) { _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_8___default()(e, r, _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_5___default()(t, r)); }); } return e; }\n\n\n\n// import { KDContext } from '@/utils/context'\n\n// import { useFieldProps } from '@/control/hooks/useFieldProps'\n// import { UPDATE_CONTROL_STATES } from '@/constants/sysActionName'\n\n// import styles from './index.less'\n\n/**\n * 附件-KD层\n * @param props\n */\n\n// const shareParam = window.NOCODE_SHARE_ID ? `?noCodeShareId=${window.NOCODE_SHARE_ID}` : ''\n// const PICTURE_ACTION = `${window.__domainurl__ || ''}nocode/v2/nocode_sys/image${shareParam}`\n\n// const getFullUrl = (baseUrl:string, path:string) => {\n//   return baseUrl + (path[0] === '/' ? path.slice(1) : path) + shareParam\n// }\n\nfunction KDPicture(props) {\n  // const { controlMeta, value, onChange } = props\n  // const { model } = useContext(KDContext)\n  // const { readonly, disabled, hidden, required, rules } = useFieldProps(controlMeta)\n  // const {\n  //   pageId, id, pictureDefValue, imageFileType, fileMaxSize, uploadNum, ops,\n  //   enablePreview, buttonText, displayCount, uploadPrompt\n  // } = controlMeta\n\n  // const uploadRef = useRef(new Map()) // 记录每个文件上传时间\n  // const fieldRef = useRef<any>(null) // 用于显示错误提示\n  // const baseUrl = useRef(model.getFileServer('picture'))\n  // // const titleRef = useRef(model.getControlText(controlMeta.caption))\n  // const [labelText, setLabelText] = useState('') // 文件列表\n\n  // // 将字符串数据转成数组\n  // const transformData = useCallback((str:string) => {\n  //   if (!str) return []\n  //   return JSON.parse(str).map((item:any) => {\n  //     uploadRef.current.set(item.uid, { ...item }) // 保存未变更的URL地址\n  //     const url = getFullUrl(baseUrl.current, item.url) // 变更URL\n  //     return { ...item, url }\n  //   })\n  // }, [])\n  // const [datas, setDatas] = useState<any[]>(transformData(pictureDefValue))\n\n  // 上传前执行图片校验\n  var beforeUpload = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_10__.useCallback)(function (file, list) {\n    return (0,_utils_mobTools__WEBPACK_IMPORTED_MODULE_13__.uploadPictureVerify)(file, list, props.controlMeta);\n  }, [props.controlMeta]);\n\n  // // change事件, 更新\n  // const handleChange = useCallback(({ file, fileList }) => {\n  //   const errText = controlMeta.mi && fileList.length === 0 ? '值不能为空' : ''\n  //   fieldRef.current.setValidateMessage(errText)\n  //   let newList = fileList.filter((item:any) => item.status !== 'notStart')\n  //   if (file.status === 'done' && file.response.status) {\n  //     const { uid, name, size } = file\n  //     const data = {\n  //       url: file.response.data.url,\n  //       status: 'success',\n  //       uploadTime: Date.now()\n  //     }\n  //     uploadRef.current.set(file.uid, { uid, name, size, ...data }) // Map存储已上传的文件信息\n  //     const str = JSON.stringify([...(uploadRef.current.values())])\n  //     if (onChange) {\n  //       onChange(str)\n  //     } else {\n  //       const updateData = { k: id, r: 0, v: str }\n  //       const uploadList = newList.filter((item:any) => item.status === 'uploading')\n  //       console.log('onChange', uploadRef.current.size, uploadList.length)\n  //       if (uploadList.length === 0) {\n  //         model.batchInvoke('updateValue', pageId, '', [], [{}, [updateData]])\n  //       }\n  //       // model.setPostData(pageId, id, str)\n  //     }\n  //     newList = newList.map((item:any) => {\n  //       if (item.uid === uid) item.status = 'success'\n  //       return item\n  //     })\n  //   }\n  //   setDatas([...newList])\n  // }, [])\n\n  // // 删除\n  // const onRemove = useCallback((file:any) => {\n  //   const newData = datas.filter((item:any) => item.uid !== file.uid)\n  //   const newFile = uploadRef.current.get(file.uid) // 上传成功列表\n  //   setDatas([...newData])\n  //   if (newFile) { // 上传成功文件,更新postData\n  //     uploadRef.current.delete(file.uid)\n  //     const str = uploadRef.current.size > 0 ? JSON.stringify([...uploadRef.current.values()]) : ''\n  //     if (onChange) return onChange(str)\n  //     const postValue = { k: id, r: 0, v: str }\n  //     model.batchInvoke('updateValue', pageId, '', [], [{}, [postValue]])\n  //     // model.setPostData(pageId, id, str) // 走postData\n  //   }\n  //   return true\n  // }, [datas])\n\n  // // 监听系统U指令-回调\n  // const updateValue = (info:any) => {\n  //   // console.log('updateValue', info, datas)\n  //   try {\n  //     setDatas(transformData(info.v))\n  //   } catch (error) { // info.v 的值可能为null也可能为 '******'\n  //     setDatas([])\n  //   }\n  // }\n\n  // // useEffect(() => {\n  // //   // 监听系统U指令\n  // //   const rmUpdateListener = model.addControlAction(UPDATE_CONTROL_STATES, pageId, id, updateValue)\n  // //   return () => {\n  // //     rmUpdateListener?.()\n  // //   }\n  // // }, [datas])\n  // model.useUpdateControlStates(controlMeta, updateValue)\n\n  // useEffect(() => {\n  //   updateValue({ k: id, v: value })\n  // }, [value])\n\n  // useEffect(() => {\n  //   // updatevalue之后会U指令更新uploadRef及datas，可能会更新不及时，所以侦听datas\n  //   const label = !displayCount || readonly || disabled ? '' : `(${uploadRef.current.size}/${uploadNum?.max || 1})`\n  //   setLabelText(label)\n  // }, [displayCount, readonly, disabled, uploadNum, datas])\n\n  // // console.log('KDPicture', controlMeta)\n  // const num = uploadNum || {} // 最大/最小上传数量\n  // const typeArr = imageFileType.split(',').map((item:any) => ops[item])\n  // const notice = uploadPrompt ? `请上传小于${fileMaxSize}M的${typeArr.join('、')}文件，文件个数不少于${num?.min || 0}个，不多于${num?.max || 1}个。` : ''\n  var _usePictureHooks = (0,_control_hooks_usePictureHooks__WEBPACK_IMPORTED_MODULE_14__[\"default\"])(props),\n    action = _usePictureHooks.action,\n    notice = _usePictureHooks.notice,\n    labelText = _usePictureHooks.labelText,\n    datas = _usePictureHooks.datas,\n    readonly = _usePictureHooks.readonly,\n    disabled = _usePictureHooks.disabled,\n    hidden = _usePictureHooks.hidden,\n    required = _usePictureHooks.required,\n    rules = _usePictureHooks.rules,\n    enablePreview = _usePictureHooks.enablePreview,\n    buttonText = _usePictureHooks.buttonText,\n    fieldTitleRef = _usePictureHooks.fieldTitleRef,\n    baseUrl = _usePictureHooks.baseUrl,\n    limit = _usePictureHooks.limit,\n    accept = _usePictureHooks.accept,\n    onRemove = _usePictureHooks.onRemove,\n    handleChange = _usePictureHooks.handleChange;\n  if (hidden) return null;\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().createElement(_FieldItemWrapper__WEBPACK_IMPORTED_MODULE_11__[\"default\"], {\n    ref: fieldTitleRef,\n    subTitle: labelText,\n    controlMeta: _objectSpread(_objectSpread({}, props.controlMeta), {}, {\n      labelDirection: 'v'\n    }),\n    required: required\n  }, (datas === null || datas === void 0 ? void 0 : datas.length) === 0 && readonly ? /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().createElement((kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().Fragment), null, \"-\") : /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_10___default().createElement(_base_mobile__WEBPACK_IMPORTED_MODULE_12__.Picture, {\n    multiple: true,\n    baseUrl: baseUrl,\n    action: action,\n    data: {\n      action: 'upload',\n      tempstorage: false\n    },\n    disabled: disabled,\n    readonly: readonly,\n    fileList: datas,\n    uploadNum: limit,\n    onChange: handleChange,\n    onRemove: onRemove,\n    beforeUpload: beforeUpload,\n    accept: accept,\n    enablePreview: enablePreview,\n    buttonText: buttonText,\n    noticeInfo: notice\n  }));\n}\n/* harmony default export */ __webpack_exports__[\"default\"] = ((0,kd_libs_react__WEBPACK_IMPORTED_MODULE_10__.memo)(KDPicture));\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/Picture/index.tsx?");

/***/ }),

/***/ "./src/control/mobile/RefBill/RefBillReadonly.tsx":
/*!********************************************************!*\
  !*** ./src/control/mobile/RefBill/RefBillReadonly.tsx ***!
  \********************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/slicedToArray */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/slicedToArray.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/map */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/map.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! kd_libs/react */ \"webpack/container/remote/kd_libs/react\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(kd_libs_react__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _constants_sysActionName__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/constants/sysActionName */ \"./src/constants/sysActionName.js\");\n/* harmony import */ var _RefBillUsrOrCompanyInfo__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./RefBillUsrOrCompanyInfo */ \"./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.tsx\");\n/* harmony import */ var _RefBillReadonly_less__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./RefBillReadonly.less */ \"./src/control/mobile/RefBill/RefBillReadonly.less\");\n/* harmony import */ var _base_hooks_useDebounce__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/base/hooks/useDebounce */ \"./src/base/hooks/useDebounce.ts\");\n\n\n\n\n// import Popup from '@/base/mobile/Popup'\n\n\n\nvar RefBillReadonly = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.memo)(function (_ref) {\n  var _data$, _data$3;\n  var meta = _ref.meta,\n    model = _ref.model,\n    multi = _ref.multi,\n    onRef = _ref.onRef,\n    data = _ref.data;\n  var pageId = meta.pageId,\n    id = meta.id,\n    gridId = meta.gridId,\n    caption = meta.caption;\n  // const { caption } = model.getConfig(pageId)\n  (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useImperativeHandle)(onRef, function () {\n    return {\n      showCompany: showCompany,\n      showStaffModal: showStaffModal\n    };\n  }, []);\n  var _useState = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useState)(false),\n    _useState2 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__[\"default\"])(_useState, 2),\n    selectedPopupVisible = _useState2[0],\n    setPopupVisible = _useState2[1];\n  var _useState3 = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useState)({}),\n    _useState4 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__[\"default\"])(_useState3, 2),\n    datas = _useState4[0],\n    setData = _useState4[1];\n  var _useState5 = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useState)(''),\n    _useState6 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__[\"default\"])(_useState5, 2),\n    opentype = _useState6[0],\n    setOpentype = _useState6[1];\n  // 打开员工信息弹窗\n  var showStaffModal = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useCallback)(function (data) {\n    setOpentype('user');\n    setData(data);\n    setPopupVisible(true);\n  }, []);\n\n  // 打开部门信息弹窗\n  var showCompany = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useCallback)(function (org) {\n    setOpentype('org');\n    setData(org);\n    setPopupVisible(true);\n  }, []);\n\n  // 打开关联表单详情\n  var showForm = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_2__.useCallback)(function (pkId) {\n    if (!pkId) return;\n    var param = [pkId];\n    var realId = id;\n    if (gridId) {\n      // 表格内时\n      param.push(id);\n      realId = gridId;\n    }\n    model.batchInvoke(_constants_sysActionName__WEBPACK_IMPORTED_MODULE_3__.SHOW_REF_BILL_INFO, pageId, realId, [param]);\n  }, [pageId, id, gridId]);\n  var closeHandle = function closeHandle() {\n    setData({});\n    setPopupVisible(false);\n  };\n  var debunceText = (0,_base_hooks_useDebounce__WEBPACK_IMPORTED_MODULE_6__[\"default\"])(showForm);\n  // const SetDom = (type: string) => {\n  //   if (type === 'user') {\n  //     return <UserBody data={datas} title='用户信息' />\n  //   } else if (type === 'org') {\n  //     return <CompanyBody org={datas} title='组织信息' />\n  //   }\n  // }\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_2___default().createElement(\"div\", {\n    className: _RefBillReadonly_less__WEBPACK_IMPORTED_MODULE_5__[\"default\"].text\n  }, multi ? data === null || data === void 0 ? void 0 : _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1___default()(data).call(data, function (val, index) {\n    return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_2___default().createElement(\"span\", {\n      key: val.value\n    }, window.NOCODE_SHARE_ID ? val.label : /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_2___default().createElement(\"a\", {\n      onClick: function onClick() {\n        return debunceText(val.value);\n      }\n    }, val.label), index !== data.length - 1 ? ',' : '');\n  }) : window.NOCODE_SHARE_ID ? ((_data$ = data[0]) === null || _data$ === void 0 ? void 0 : _data$.label) || '-' : /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_2___default().createElement(\"a\", {\n    onClick: function onClick() {\n      var _data$2;\n      return debunceText((_data$2 = data[0]) === null || _data$2 === void 0 ? void 0 : _data$2.value);\n    }\n  }, ((_data$3 = data[0]) === null || _data$3 === void 0 ? void 0 : _data$3.label) || '-'), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_2___default().createElement(_RefBillUsrOrCompanyInfo__WEBPACK_IMPORTED_MODULE_4__[\"default\"], {\n    visible: selectedPopupVisible,\n    type: opentype,\n    data: datas,\n    title: model.getControlText(caption),\n    onClose: closeHandle\n  }));\n});\nRefBillReadonly.displayName = 'RefBillReadonly';\n/* harmony default export */ __webpack_exports__[\"default\"] = (RefBillReadonly);\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/RefBill/RefBillReadonly.tsx?");

/***/ }),

/***/ "./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.tsx":
/*!****************************************************************!*\
  !*** ./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.tsx ***!
  \****************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/slicedToArray */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/slicedToArray.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/map */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/map.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_set_timeout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/set-timeout */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/set-timeout.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_set_timeout__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_set_timeout__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.array.join.js */ \"../../node_modules/core-js/modules/es.array.join.js\");\n/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.function.name.js */ \"../../node_modules/core-js/modules/es.function.name.js\");\n/* harmony import */ var core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! core-js/modules/es.regexp.exec.js */ \"../../node_modules/core-js/modules/es.regexp.exec.js\");\n/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var core_js_modules_es_string_search_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! core-js/modules/es.string.search.js */ \"../../node_modules/core-js/modules/es.string.search.js\");\n/* harmony import */ var core_js_modules_es_string_search_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_string_search_js__WEBPACK_IMPORTED_MODULE_6__);\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! kd_libs/react */ \"webpack/container/remote/kd_libs/react\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(kd_libs_react__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var _base_mobile_Popup__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/base/mobile/Popup */ \"./src/base/mobile/Popup/index.tsx\");\n/* harmony import */ var _base_web__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @/base/web */ \"./src/base/web/index.ts\");\n/* harmony import */ var kd_libs_kdesign1__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! kd_libs/kdesign1 */ \"webpack/container/remote/kd_libs/kdesign1\");\n/* harmony import */ var kd_libs_kdesign1__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(kd_libs_kdesign1__WEBPACK_IMPORTED_MODULE_10__);\n/* harmony import */ var _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./RefBillUsrOrCompanyInfo.less */ \"./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.less\");\n\n\n\n\n\n\n\n\n// import { UserBody, CompanyBody } from './RefBillReadonly'\n\n\n\n\n\n/**\n * 关联表单只读模式增加查看按钮\n * 三种类型：普通|人员|组织\n * 分别对应不同弹窗\n */\nvar UserBody = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.memo)(function (_ref) {\n  var _context;\n  var data = _ref.data,\n    title = _ref.title;\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].popup_body\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].headTitle\n  }, title), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].user_info\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u5458\\u5DE5\\u7F16\\u53F7\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, (data === null || data === void 0 ? void 0 : data.number) || '-')), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u59D3\\u540D\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, (data === null || data === void 0 ? void 0 : data.name) || '-')), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u5934\\u50CF\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].avatar\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(_base_web__WEBPACK_IMPORTED_MODULE_9__.Avatar, {\n    src: data === null || data === void 0 ? void 0 : data.avatar\n  }))), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u6027\\u522B\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, (data === null || data === void 0 ? void 0 : data.gender) || '-')), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u751F\\u65E5\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, (data === null || data === void 0 ? void 0 : data.birthday) || '-')), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u624B\\u673A\\u53F7\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, (data === null || data === void 0 ? void 0 : data.phone) || '-')), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u90AE\\u7BB1\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, (data === null || data === void 0 ? void 0 : data.email) || '-')), (data === null || data === void 0 ? void 0 : data.orgs) && (data === null || data === void 0 ? void 0 : data.orgs.length) > 0 && /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].item\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].title\n  }, \"\\u6240\\u5C5E\\u7EC4\\u7EC7\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", null, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"table\", {\n    cellSpacing: 1,\n    cellPadding: 1\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"tr\", null, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"th\", null, \"\\u6240\\u5C5E\\u7EC4\\u7EC7\\u7F16\\u7801\"), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"th\", null, \"\\u7EC4\\u7EC7\\u540D\\u79F0\")), data === null || data === void 0 ? void 0 : _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_1___default()(_context = data.orgs).call(_context, function (item, index) {\n    return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"tr\", {\n      key: item.orgId + index\n    }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"td\", null, item.orgNum), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"td\", null, item.orgName));\n  }))))));\n});\nvar CompanyBody = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.memo)(function (_ref2) {\n  var org = _ref2.org,\n    title = _ref2.title;\n  var _ref3 = org || {},\n    id = _ref3.id,\n    number = _ref3.number;\n  var url = [window.__domainurl__ || '', 'nocode/m/user/company/', id, '/', number].join('') + window.location.search;\n  var _useState = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.useState)(false),\n    _useState2 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__[\"default\"])(_useState, 2),\n    loading = _useState2[0],\n    setLoading = _useState2[1];\n  var setLoad = function setLoad() {\n    _babel_runtime_corejs3_core_js_stable_set_timeout__WEBPACK_IMPORTED_MODULE_2___default()(function () {\n      return setLoading(true);\n    }, 1000);\n  };\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement((kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().Fragment), null, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].headTitle\n  }, title), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: loading ? _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].hidden : _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].org_Info_loading\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(kd_libs_kdesign1__WEBPACK_IMPORTED_MODULE_10__.Spin, null)), /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"div\", {\n    className: !loading ? _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].hidden : ''\n  }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(\"iframe\", {\n    src: url,\n    className: _RefBillUsrOrCompanyInfo_less__WEBPACK_IMPORTED_MODULE_11__[\"default\"].org_Info,\n    onLoad: setLoad\n  })));\n});\nvar RefBillUsrOrCompanyInfo = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.memo)(function (_ref4) {\n  var visible = _ref4.visible,\n    title = _ref4.title,\n    type = _ref4.type,\n    data = _ref4.data,\n    onClose = _ref4.onClose;\n  var _useState3 = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.useState)(false),\n    _useState4 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_0__[\"default\"])(_useState3, 2),\n    popupVisible = _useState4[0],\n    setPopupVisible = _useState4[1];\n  (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.useEffect)(function () {\n    setPopupVisible(visible);\n  }, [visible]);\n  var closeHandle = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_7__.useCallback)(function () {\n    if (onClose) return onClose === null || onClose === void 0 ? void 0 : onClose();\n    setPopupVisible(false);\n  }, [onClose]);\n  var SetDom = function SetDom(type) {\n    if (type === 'user') {\n      return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(UserBody, {\n        data: data,\n        title: title || '人员信息'\n      });\n    } else if (type === 'org') {\n      return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(CompanyBody, {\n        org: data,\n        title: title || '组织信息'\n      });\n    }\n  };\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_7___default().createElement(_base_mobile_Popup__WEBPACK_IMPORTED_MODULE_8__[\"default\"], {\n    visible: popupVisible,\n    lockScroll: false,\n    closeable: true,\n    onClose: closeHandle,\n    bodyStyle: {\n      height: 'auto',\n      minHeight: 180\n    }\n  }, type !== '' && SetDom(type));\n});\nRefBillUsrOrCompanyInfo.displayName = 'RefBillUsrOrCompanyInfo';\n/* harmony default export */ __webpack_exports__[\"default\"] = (RefBillUsrOrCompanyInfo);\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/RefBill/RefBillUsrOrCompanyInfo.tsx?");

/***/ }),

/***/ "./src/control/mobile/RefBill/index.tsx":
/*!**********************************************!*\
  !*** ./src/control/mobile/RefBill/index.tsx ***!
  \**********************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.object.to-string.js */ \"../../node_modules/core-js/modules/es.object.to-string.js\");\n/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/web.dom-collections.for-each.js */ \"../../node_modules/core-js/modules/web.dom-collections.for-each.js\");\n/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/keys */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/keys.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_5__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/define-properties */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/define-properties.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_6__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/object/define-property */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/object/define-property.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_7__);\n/* harmony import */ var _babel_runtime_corejs3_helpers_toArray__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/toArray */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/toArray.js\");\n/* harmony import */ var _babel_runtime_corejs3_helpers_toConsumableArray__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/toConsumableArray */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/toConsumableArray.js\");\n/* harmony import */ var _babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/slicedToArray */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/slicedToArray.js\");\n/* harmony import */ var _babel_runtime_corejs3_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @babel/runtime-corejs3/helpers/defineProperty */ \"../../node_modules/@babel/runtime-corejs3/helpers/esm/defineProperty.js\");\n/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! core-js/modules/es.array.join.js */ \"../../node_modules/core-js/modules/es.array.join.js\");\n/* harmony import */ var core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_join_js__WEBPACK_IMPORTED_MODULE_12__);\n/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! core-js/modules/es.object.keys.js */ \"../../node_modules/core-js/modules/es.object.keys.js\");\n/* harmony import */ var core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_object_keys_js__WEBPACK_IMPORTED_MODULE_13__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/symbol */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/symbol.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_slice__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/slice */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/slice.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_slice__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_slice__WEBPACK_IMPORTED_MODULE_16__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/filter */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/filter.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_14__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_includes__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/includes */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/includes.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_includes__WEBPACK_IMPORTED_MODULE_17___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_includes__WEBPACK_IMPORTED_MODULE_17__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/map */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/map.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18__);\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_concat__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! @babel/runtime-corejs3/core-js-stable/instance/concat */ \"../../node_modules/@babel/runtime-corejs3/core-js-stable/instance/concat.js\");\n/* harmony import */ var _babel_runtime_corejs3_core_js_stable_instance_concat__WEBPACK_IMPORTED_MODULE_19___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_corejs3_core_js_stable_instance_concat__WEBPACK_IMPORTED_MODULE_19__);\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! kd_libs/react */ \"webpack/container/remote/kd_libs/react\");\n/* harmony import */ var kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default = /*#__PURE__*/__webpack_require__.n(kd_libs_react__WEBPACK_IMPORTED_MODULE_20__);\n/* harmony import */ var _utils_context__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! @/utils/context */ \"./src/utils/context.ts\");\n/* harmony import */ var _FieldItemWrapper__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ../FieldItemWrapper */ \"./src/control/mobile/FieldItemWrapper/index.tsx\");\n/* harmony import */ var _base_mobile__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! @/base/mobile */ \"./src/base/mobile/index.ts\");\n/* harmony import */ var _constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! @/constants/sysActionName */ \"./src/constants/sysActionName.js\");\n/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! @/utils */ \"./src/utils/index.ts\");\n/* harmony import */ var _control_hooks_useFieldProps__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! @/control/hooks/useFieldProps */ \"./src/control/hooks/useFieldProps.tsx\");\n/* harmony import */ var kd_libs_kdesignm1__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! kd_libs/kdesignm1 */ \"webpack/container/remote/kd_libs/kdesignm1\");\n/* harmony import */ var kd_libs_kdesignm1__WEBPACK_IMPORTED_MODULE_27___default = /*#__PURE__*/__webpack_require__.n(kd_libs_kdesignm1__WEBPACK_IMPORTED_MODULE_27__);\n/* harmony import */ var _index_less__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./index.less */ \"./src/control/mobile/RefBill/index.less\");\n/* harmony import */ var kd_libs_lodash__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! kd_libs/lodash */ \"webpack/container/remote/kd_libs/lodash\");\n/* harmony import */ var kd_libs_lodash__WEBPACK_IMPORTED_MODULE_29___default = /*#__PURE__*/__webpack_require__.n(kd_libs_lodash__WEBPACK_IMPORTED_MODULE_29__);\n/* harmony import */ var _RefBillReadonly__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./RefBillReadonly */ \"./src/control/mobile/RefBill/RefBillReadonly.tsx\");\n/* harmony import */ var _base_hooks_useDebounce__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! @/base/hooks/useDebounce */ \"./src/base/hooks/useDebounce.ts\");\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nfunction ownKeys(e, r) { var t = _babel_runtime_corejs3_core_js_stable_object_keys__WEBPACK_IMPORTED_MODULE_2___default()(e); if ((_babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default())) { var o = _babel_runtime_corejs3_core_js_stable_object_get_own_property_symbols__WEBPACK_IMPORTED_MODULE_3___default()(e); r && (o = _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_14___default()(o).call(o, function (r) { return _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_4___default()(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0,_babel_runtime_corejs3_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_11__[\"default\"])(e, r, t[r]); }) : (_babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_5___default()) ? _babel_runtime_corejs3_core_js_stable_object_define_properties__WEBPACK_IMPORTED_MODULE_6___default()(e, _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptors__WEBPACK_IMPORTED_MODULE_5___default()(t)) : ownKeys(Object(t)).forEach(function (r) { _babel_runtime_corejs3_core_js_stable_object_define_property__WEBPACK_IMPORTED_MODULE_7___default()(e, r, _babel_runtime_corejs3_core_js_stable_object_get_own_property_descriptor__WEBPACK_IMPORTED_MODULE_4___default()(t, r)); }); } return e; }\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nvar UPDATE_SELECT_DATA = _babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15___default()('更新下拉数据');\nvar SET_VALUE = _babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15___default()('设置下拉选中值');\nvar SET_OPTIONS = _babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15___default()('设置下拉选项');\nvar SET_VALUE_OPTIONS = _babel_runtime_corejs3_core_js_stable_symbol__WEBPACK_IMPORTED_MODULE_15___default()('根据u指令设置下拉选项');\nvar REF_BILL_CLS = 'ref-bill-option';\nvar INIT_REF_BILL_DATA = {\n  value: '',\n  options: [],\n  valueOptions: [] // 根据u指令转换而成的options\n};\nvar refBillReducer = function refBillReducer(state, action) {\n  var type = action.type,\n    payload = action.payload;\n  switch (type) {\n    case UPDATE_SELECT_DATA:\n      // 主要用于U指令更新\n      return _objectSpread(_objectSpread({}, state), payload);\n    case SET_VALUE:\n      return _objectSpread(_objectSpread({}, state), {}, {\n        value: payload\n      });\n    case SET_OPTIONS:\n      return _objectSpread(_objectSpread({}, state), {}, {\n        options: payload\n      });\n    case SET_VALUE_OPTIONS:\n      return _objectSpread(_objectSpread({}, state), {}, {\n        valueOptions: payload\n      });\n  }\n};\n\n// 超过20条，点击Select直接打开F7\nvar MaxSelected = 20;\n\n/**\n * 关联单据-KD层\n * @param props\n * @returns\n */\nfunction KDRefBill(_ref) {\n  var cellValue = _ref.value,\n    controlMeta = _ref.controlMeta,\n    onChange = _ref.onChange,\n    onSearch = _ref.onSearch;\n  var _useContext = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useContext)(_utils_context__WEBPACK_IMPORTED_MODULE_21__.KDContext),\n    model = _useContext.model;\n  var _useReducer = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useReducer)(refBillReducer, INIT_REF_BILL_DATA),\n    _useReducer2 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_10__[\"default\"])(_useReducer, 2),\n    refBillData = _useReducer2[0],\n    dispatchRefBillData = _useReducer2[1];\n  var _useState = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useState)(0),\n    _useState2 = (0,_babel_runtime_corejs3_helpers_slicedToArray__WEBPACK_IMPORTED_MODULE_10__[\"default\"])(_useState, 2),\n    loadDataStatus = _useState2[0],\n    setLoadDataStatus = _useState2[1]; // 0正在加载数据 1数据加载完成\n\n  var options = refBillData.options,\n    value = refBillData.value,\n    label = refBillData.label,\n    valueOptions = refBillData.valueOptions;\n  var pageId = controlMeta.pageId,\n    id = controlMeta.id,\n    ShowClearButton = controlMeta.ShowClearButton,\n    rowIndex = controlMeta.rowIndex,\n    gridId = controlMeta.gridId,\n    multi = controlMeta.multi,\n    propsDisplay = controlMeta.propsDisplay,\n    refbilltype = controlMeta.refbilltype;\n  var _useFieldProps = (0,_control_hooks_useFieldProps__WEBPACK_IMPORTED_MODULE_26__.useFieldProps)(controlMeta),\n    readonly = _useFieldProps.readonly,\n    placeholder = _useFieldProps.placeholder,\n    disabled = _useFieldProps.disabled,\n    hidden = _useFieldProps.hidden,\n    required = _useFieldProps.required,\n    rules = _useFieldProps.rules;\n  var isMulti = multi === 1;\n  var refBillText = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useRef)(null);\n  var selectRef = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useRef)();\n  var optionVisibleRef = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useRef)(false);\n  var handleConfirm = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (v) {\n    dispatchRefBillData({\n      type: SET_VALUE,\n      payload: v\n    });\n    if (onChange) return onChange(v);\n    postValueToServer(v);\n  }, [dispatchRefBillData, onChange]);\n  var handleChange = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (v, option) {\n    if (isMulti && optionVisibleRef.current) return v;\n    if (isMulti && !optionVisibleRef.current) handleConfirm(v || []);\n    dispatchRefBillData({\n      type: SET_VALUE,\n      payload: v\n    });\n    if (onChange) return onChange(v);\n    postValueToServer(v);\n  }, [dispatchRefBillData, onChange, isMulti]);\n\n  // 将值更新到服务器\n  var postValueToServer = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (v) {\n    var data = {\n      k: id,\n      r: 0,\n      v: v\n    };\n    model.batchInvoke('updateValue', pageId, '', [], [{}, [data]]);\n    model.batchInvoke(_constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.SET_ITEM_BY_ID_FROM_CLIENT, pageId, id, [[v, 0]]);\n  }, []);\n\n  // 查询下拉选项的数据\n  var loadOptions = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function () {\n    var key = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n    model.batchInvoke(_constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.GET_LOOK_UP_LIST, pageId, id, [['%', key, '%', value === null || value === void 0 ? void 0 : _babel_runtime_corejs3_core_js_stable_instance_slice__WEBPACK_IMPORTED_MODULE_16___default()(value).call(value, 0, MaxSelected), 1, 0]]);\n  }, [value]);\n  var debounceLoadOptions = (0,_base_hooks_useDebounce__WEBPACK_IMPORTED_MODULE_31__[\"default\"])(loadOptions);\n\n  // 下拉面板显示/隐藏的回调\n  var onVisibleChange = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (visible) {\n    optionVisibleRef.current = visible;\n    if (visible) {\n      // 打开弹窗时，只显示已选options\n      var data = value ? Array.isArray(value) ? value : [value] : [];\n      var payload = _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_14___default()(options).call(options, function (op) {\n        return _babel_runtime_corejs3_core_js_stable_instance_includes__WEBPACK_IMPORTED_MODULE_17___default()(data).call(data, op.value);\n      });\n      dispatchRefBillData({\n        type: SET_OPTIONS,\n        payload: payload\n      });\n      setLoadDataStatus(0);\n      debounceLoadOptions();\n    }\n  }, [debounceLoadOptions, value, options]);\n\n  // u指令\n  var updateValue = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (info) {\n    if (Array.isArray(info.v)) {\n      var _context;\n      var data = _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18___default()(_context = info.v).call(_context, function (item) {\n        return getOptionItem(item);\n      });\n      var vals = _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18___default()(data).call(data, function (item) {\n        return item.value;\n      });\n      var newVal = isMulti ? vals : vals.join();\n      dispatchRefBillData({\n        type: UPDATE_SELECT_DATA,\n        payload: {\n          value: newVal,\n          options: data,\n          valueOptions: data\n        }\n      });\n      if (!(0,kd_libs_lodash__WEBPACK_IMPORTED_MODULE_29__.isEqual)(value, newVal) && !readonly) {\n        model.batchInvoke(_constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.GET_LOOK_UP_LIST, pageId, id, [['%', '', '%', newVal || '', 1, 0]]);\n      }\n    } else {\n      // null 或者 '******' 的情况\n      dispatchRefBillData({\n        type: UPDATE_SELECT_DATA,\n        payload: {\n          value: isMulti ? [] : '',\n          options: []\n        }\n      });\n    }\n  }, [value, readonly]);\n  /**\n   * F7添加关联表单记录\n   */\n  var onAddRecord = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)((0,_utils__WEBPACK_IMPORTED_MODULE_25__.debounce)(function () {\n    model.batchInvoke('addNewRef', pageId, id, [[propsDisplay]]);\n  }), [propsDisplay, pageId, id]);\n  /**\n   * 添加数据后，指令刷新F7弹窗数据\n   */\n  var refreshRefList = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (info) {\n    var _context2;\n    var id = info.pkId;\n    var value = isMulti ? _babel_runtime_corejs3_core_js_stable_instance_concat__WEBPACK_IMPORTED_MODULE_19___default()(_context2 = []).call(_context2, (0,_babel_runtime_corejs3_helpers_toConsumableArray__WEBPACK_IMPORTED_MODULE_9__[\"default\"])(selectRef.current.value), [id]) : id;\n    handleConfirm(value);\n    debounceLoadOptions();\n  }, [isMulti, handleConfirm]);\n\n  // 模糊搜索回来的数据格式化成下拉选项的值\n  var setSelectOptions = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (info) {\n    var _info$data;\n    var options = info === null || info === void 0 || (_info$data = info.data) === null || _info$data === void 0 ? void 0 : _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18___default()(_info$data).call(_info$data, function (item) {\n      var _item = (0,_babel_runtime_corejs3_helpers_toArray__WEBPACK_IMPORTED_MODULE_8__[\"default\"])(item),\n        param = _item[0],\n        other = _babel_runtime_corejs3_core_js_stable_instance_slice__WEBPACK_IMPORTED_MODULE_16___default()(_item).call(_item, 1);\n      var obj = param ? JSON.parse(param) : {};\n      var option = getOptionItem(other);\n      return _objectSpread(_objectSpread({}, option), {}, {\n        disabled: obj._state_ === 'disabled'\n      });\n    });\n    dispatchRefBillData({\n      type: SET_OPTIONS,\n      payload: options\n    });\n    setLoadDataStatus(1);\n  }, [setLoadDataStatus]);\n\n  // 控件事件\n  var invokeMethod = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (info) {\n    var _refBillText$current, _refBillText$current2;\n    var _info$ = info[0],\n      methodname = _info$.methodname,\n      args = _info$.args;\n    switch (methodname) {\n      case _constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.SET_LOOK_UP_LIST_VALUE:\n        setSelectOptions(args[0]);\n        break;\n      case _constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.REFBILL_RESET_VALUE:\n        // console.log('REFBILL_RESET_VALUE', args)\n        updateValue({\n          v: args[0]\n        });\n        break;\n      case _constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.SHOW_REF_BILL_USER_INFO:\n        // console.log('updateUserInfo', args)\n        (_refBillText$current = refBillText.current) === null || _refBillText$current === void 0 || _refBillText$current.showStaffModal(args[0]);\n        break;\n      case _constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.SHOW_REF_BILL_ORG_INFO:\n        // console.log('updateOrgInfo', args)\n        (_refBillText$current2 = refBillText.current) === null || _refBillText$current2 === void 0 || _refBillText$current2.showCompany(args[0]);\n        break;\n      case _constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.REFBILL_REFRESH_REF_LIST:\n        // console.log('REFBILL_REFRESH_REF_LIST', args)\n        refreshRefList(args[0]);\n        break;\n      default:\n        break;\n    }\n  }, [updateValue, setLoadDataStatus, setSelectOptions]);\n  var handleGridEvents = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (info) {\n    var args = info.args;\n    if (args[0].k !== id || args[0].r !== rowIndex) return; // 判断行列\n    invokeMethod([info]);\n  }, [invokeMethod]);\n\n  /**\n   * 选项数据格式化\n   */\n  var getOptionItem = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (item) {\n    // const arr = (item?.slice(2) || []).filter(Boolean)\n    // const des = arr.length > 0 ? arr.join('｜') : ''\n    var _item2 = (0,_babel_runtime_corejs3_helpers_toArray__WEBPACK_IMPORTED_MODULE_8__[\"default\"])(item),\n      value = _item2[0],\n      label = _item2[1],\n      other = _babel_runtime_corejs3_core_js_stable_instance_slice__WEBPACK_IMPORTED_MODULE_16___default()(_item2).call(_item2, 2);\n    var des = _babel_runtime_corejs3_core_js_stable_instance_map__WEBPACK_IMPORTED_MODULE_18___default()(other).call(other, function (item) {\n      return item || '-';\n    });\n    return {\n      label: label || '-',\n      value: value,\n      des: des.join('｜')\n    };\n  }, []);\n\n  // 自定义option渲染\n  var renderOption = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (item) {\n    var label = item.label,\n      des = item.des;\n    return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(\"div\", {\n      className: _index_less__WEBPACK_IMPORTED_MODULE_28__[\"default\"][REF_BILL_CLS]\n    }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(\"div\", {\n      className: _index_less__WEBPACK_IMPORTED_MODULE_28__[\"default\"][\"\".concat(REF_BILL_CLS, \"-title\")]\n    }, label), des && /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(\"div\", {\n      className: _index_less__WEBPACK_IMPORTED_MODULE_28__[\"default\"][\"\".concat(REF_BILL_CLS, \"-desc\")]\n    }, des));\n  }, []);\n\n  // 自定义搜索方法\n  var filterOption = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)(function (inputVal, item) {\n    return true;\n  }, []);\n\n  // 模糊搜索\n  var handleSearch = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useCallback)((0,_utils__WEBPACK_IMPORTED_MODULE_25__.debounce)(function (inputVal) {\n    if (onSearch) return onSearch(inputVal);\n    model.batchInvoke(_constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.GET_LOOK_UP_LIST, pageId, id, [['%', inputVal, '%', '', 1, 0]]);\n  }, 500), [onSearch]);\n  model.useUpdateControlStates(controlMeta, updateValue);\n  model.useInvokeControlMethod(controlMeta, invokeMethod);\n  // useEffect(() => {\n  //   const rmUpdateListener = model.addControlAction(UPDATE_CONTROL_STATES, pageId, id, updateValue)\n  //   const rmSetListValueListener = model.addControlAction(INVOKE_CONTROL_METHOD, pageId, id, invokeMethod)\n  //   return () => {\n  //     rmUpdateListener?.()\n  //     rmSetListValueListener?.()\n  //   }\n  // }, [updateValue])\n\n  (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useEffect)(function () {\n    if (cellValue && (cellValue === null || cellValue === void 0 ? void 0 : cellValue[0]) !== value) {\n      updateValue({\n        k: id,\n        v: cellValue\n      });\n    }\n  }, [cellValue]);\n  (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useEffect)(function () {\n    var _context3, _context4;\n    var rmSetListValueListener = model.addEventListener(_babel_runtime_corejs3_core_js_stable_instance_concat__WEBPACK_IMPORTED_MODULE_19___default()(_context3 = _babel_runtime_corejs3_core_js_stable_instance_concat__WEBPACK_IMPORTED_MODULE_19___default()(_context4 = \"\".concat(_constants_sysActionName__WEBPACK_IMPORTED_MODULE_24__.TABLE_CUSTOMER_CONTROL_METHOD, \"-\")).call(_context4, pageId, \"-\")).call(_context3, gridId), handleGridEvents);\n    return function () {\n      rmSetListValueListener === null || rmSetListValueListener === void 0 || rmSetListValueListener();\n    };\n  }, []);\n  var selectData = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useMemo)(function () {\n    if (!value) return [];\n    return _babel_runtime_corejs3_core_js_stable_instance_filter__WEBPACK_IMPORTED_MODULE_14___default()(valueOptions).call(valueOptions, function (op) {\n      return _babel_runtime_corejs3_core_js_stable_instance_includes__WEBPACK_IMPORTED_MODULE_17___default()(value).call(value, op.value);\n    });\n  }, [value, valueOptions]);\n\n  // const readonlyValue = useMemo(() => {\n  //   if (!value) return ''\n  //   if (Array.isArray(value)) {\n  //     return value.length ? value.map(v => options.find((op: any) => op.value === v)?.label || '-').join(',') : ''\n  //   }\n  //   return options.find((op: any) => op.value === value)?.label || ''\n  // }, [value, options])\n\n  var notFoundContent = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useMemo)(function () {\n    if (loadDataStatus === 0) {\n      return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(\"div\", {\n        className: _index_less__WEBPACK_IMPORTED_MODULE_28__[\"default\"][\"\".concat(REF_BILL_CLS, \"-empty\")]\n      }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(kd_libs_kdesignm1__WEBPACK_IMPORTED_MODULE_27__.Spin, {\n        name: \"Spin\"\n      }));\n    }\n    return undefined;\n  }, [loadDataStatus]);\n\n  // 扩展按钮\n  var extraButton = (0,kd_libs_react__WEBPACK_IMPORTED_MODULE_20__.useMemo)(function () {\n    var _context5;\n    var showBtn = _babel_runtime_corejs3_core_js_stable_instance_includes__WEBPACK_IMPORTED_MODULE_17___default()(_context5 = ['bos_user', 'bos_adminorg']).call(_context5, refbilltype);\n    return !showBtn ? /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(\"div\", {\n      className: _index_less__WEBPACK_IMPORTED_MODULE_28__[\"default\"]['ref-bill-extra']\n    }, /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(_base_mobile__WEBPACK_IMPORTED_MODULE_23__.BtnField, {\n      major: true,\n      type: \"text\",\n      onClick: onAddRecord,\n      icon: {\n        prefix: 'ncicon',\n        type: 'zengjia-yuan'\n      }\n    }, \"\\u65B0\\u589E\\u8BB0\\u5F55\")) : null;\n  }, [refbilltype, onAddRecord]);\n  if (hidden) return null;\n  return /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(_FieldItemWrapper__WEBPACK_IMPORTED_MODULE_22__[\"default\"], {\n    controlMeta: controlMeta,\n    required: required,\n    rules: rules\n  }, readonly ? /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(_RefBillReadonly__WEBPACK_IMPORTED_MODULE_30__[\"default\"], {\n    data: selectData,\n    multi: isMulti,\n    onRef: refBillText,\n    meta: controlMeta,\n    model: model\n  }) : /*#__PURE__*/kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().createElement(_base_mobile__WEBPACK_IMPORTED_MODULE_23__.Select, {\n    ref: selectRef,\n    value: value,\n    renderSearch: true,\n    multiple: isMulti,\n    allowClear: ShowClearButton,\n    placeholder: placeholder,\n    disabled: disabled,\n    options: options || [],\n    onChange: handleChange,\n    onVisibleChange: onVisibleChange,\n    notFoundContent: notFoundContent,\n    renderOption: renderOption,\n    filterOption: filterOption,\n    onSearch: handleSearch,\n    onConfirm: handleConfirm,\n    maxTagCount: 5,\n    extra: extraButton\n  }));\n}\n/* harmony default export */ __webpack_exports__[\"default\"] = (kd_libs_react__WEBPACK_IMPORTED_MODULE_20___default().memo(KDRefBill));\n\n//# sourceURL=webpack://nocode-component/./src/control/mobile/RefBill/index.tsx?");

/***/ })

}]);