039a43f.js.map 41 KB

1
  1. {"version":3,"sources":["webpack:///./utils/price.js","webpack:///./components/imageList.vue?e3a7","webpack:///./components/ExportDialog.vue?e65c","webpack:///./components/imageList.vue?8e91","webpack:///./components/ExportDialog.vue?df42","webpack:///./pages/home/myDetail/components/orderDetailPart.vue?c8b2","webpack:///./pages/home/myDetail/components/orderDetailPart.vue","webpack:///./pages/home/myDetail/components/orderDetailPart.vue?fea4","webpack:///./pages/home/myDetail/components/orderDetailPart.vue?6b26","webpack:///./components/imageList.vue","webpack:///./components/imageList.vue?4e61","webpack:///./components/imageList.vue?ef89","webpack:///./components/ExportDialog.vue","webpack:///./components/ExportDialog.vue?cc99","webpack:///./components/ExportDialog.vue?d9e9","webpack:///./pages/home/myDetail/components/orderDetailPart.vue?9381"],"names":["round","number","ratio","arguments","length","undefined","Math","value","parseFloat","toPrecision","multiply","module","exports","name","props","isShow","type","Boolean","default","hasUid","data","orderDetail","isLoading","packageTable","stepShow","urlDialogShow","shareDialogVisible","loginCount","shareForm","Link","Tracking_URL","stepConfig","Transshipment","computedStepDirection","computed","loginSuccess","this","$store","state","comCurrency","Currency","comOrderState","Order_Stage","comSampleState","Sample_Stage","watch","newVal","getOrderDetail","commit","beforeMount","window","addEventListener","judgeStepDirection","created","beforeDestroy","removeEventListener","methods","_objectSpread","mapMutations","openDialog","throttle","document","body","clientWidth","toggleStep","_this","path","id","userInfo","_this$$route$query","$route","query","crm","queryId","concat","accounts_id","_this$$route$params","params","user_id","uid","aid","_this$$route$params2","$axios","post","then","res","_this$orderDetail$shi","_this$orderDetail$sal","result","handleBranchLogic","shipping_tracking","_step","_iterator","_createForOfIteratorHelper","_loop","_items$test_pkg_detai","items","test_pkg_details","forEach","item","Courier","Tracking_No","Package_Status","s","n","done","err","e","f","sales_orders_details","$set","filter","product_Product_Code","map","catch","_this2","$router","push","setTimeout","transformNumber","Number","toFixed","formatStepDesc","date","isUnix","$utils","formatTime","toggleShow","row","showMore","openTracking_URL","url","component","_vm$orderDetail$crm_p","_vm","_c","_self","staticClass","directives","rawName","expression","_v","_s","Sales_Order_Title_Job_Name","user_logo","attrs","_e","on","$event","crm_pr_res","Job_Group","Reference","Sales_Order_Created","Expected_Delivery_Date","Payment_Status1","Order_Confirm","Sampling_Factory_Confirm","GZ_WH","International_transshipment","AU_WH","AU_WH_Client","Delivered","class","Sample_Factory_Confirmed","Sample_Dispatching","Sample_Delivered","Account_Name_name","Billing_Unit_Building_Name","Billing_Street","Billing_City","Billing_State","Billing_Code","Billing_Country","Shipping_Unit_Building_Name","Shipping_Street","Shipping_City","Shipping_State","Shipping_Code","Shipping_Country","staticStyle","background","color","fontWeight","scopedSlots","_u","key","fn","scope","nativeOn","product_name","domProps","product_description","list_price","amount","Tax","Discount","net_total","Sub_Total","Tax_Total","Total_Including_Discount","Total_Adjustment","Grand_Total","Subject","installComponents","ImageList","ExportDialog","components","ElImageViewer","Array","currentPre","showViewer","comImg","i","cdn_url","scroll","list","$refs","scrollLeft","closeViewer","handleViwer","ref","_l","index","title","String","sendbtnCext","isSendPdf","labelShow","emailForm","rules","labelWidth","visible","copyUrl","clipboard","Clipboard","$message","success","destroy","error","handleClose","$emit","val","model","callback","$$v","preventDefault"],"mappings":"gMAkBO,SAASA,EAAMC,GAAqB,IAAbC,EAAKC,UAAAC,OAAA,QAAAC,IAAAF,UAAA,GAAAA,UAAA,GAAG,IACpC,OAAOG,KAAKN,MALd,SAAkBO,GAChB,OAAOC,YAAYD,GADSJ,UAAAC,OAAA,QAAAC,IAAAF,UAAA,GAAAA,UAAA,GAAG,MACGM,YAAY,IAChD,CAGoBC,CAAST,EAAQC,IAAUA,CAC/C,C,sBCnBAS,EAAOC,QAAU,CAAC,C,sBCAlBD,EAAOC,QAAU,CAAC,C,mCCDlB,M,mCCAA,M,sBCCAD,EAAOC,QAAU,CAAC,C,wHCDlB,I,6pDAKe,OACbC,KAAM,kBACNC,MAAO,CACLC,OAAQ,CAENC,KAAMC,QACNC,SAAS,GAEXC,OAAQ,CACN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AAQX,EAAI8F,UAAU,MAAQ9F,EAAI+F,QAAQ/F,EAAIuF,GAAIvF,EAAI8F,WAAW,SAASa,EAAIxD,GAAK,OAAOlD,EAAG,eAAe,CAACkD,IAAIA,EAAIxC,MAAM,CAAC,MAAQX,EAAI6F,UAAY1C,EAAM,GAAG,cAAcnD,EAAIgG,WAAW,KAAK,KAAO7C,IAAM,CAAClD,EAAG,WAAW,CAACU,MAAM,CAAC,SAAW,IAAIiG,MAAM,CAAC3O,MAAO+H,EAAI8F,UAAU3C,GAAM0D,SAAS,SAAUC,GAAM9G,EAAIxB,KAAKwB,EAAI8F,UAAW3C,EAAK2D,EAAI,EAAExG,WAAW,oBAAoBL,EAAG,YAAY,CAAC2B,MAAMuB,EAAIxC,MAAM,CAAC,sBAAsBX,EAAI8F,UAAU3C,GAAK,KAAO,WAAWtC,GAAG,CAAC,MAAQ,SAASC,GAAgC,OAAxBA,EAAOiG,iBAAwB/G,EAAIkG,QAAQ/C,EAAI,IAAI,CAACnD,EAAIO,GAAG,gBAAgB,EAAE,IAAG,IAAI,EAC14B,GACsB,IEUpB,EACA,KACA,WACA,MAIa,UAAAT,U,0CCnBf,M","file":"039a43f.js","sourcesContent":["// 商品价格计算相关\nimport { times, plus, minus, divide } from 'number-precision'\n\n// 价格格式化\nexport function formatPrice(value, needSymbol = true) {\n // 不能在最后一步显示之前格式化999 111, 否则可能出现单价1买999个得到999价格被格式化成poa的情况\n if (value === 0) {\n return needSymbol ? '£0.00' : '0.00'\n } else {\n return needSymbol ? `£${value}` : `${value}`\n }\n}\n\n// 简单的乘法换算\nfunction multiply(value, ratio = 100) {\n return parseFloat((value * ratio).toPrecision(12))\n}\n// 小数处理, 四舍五入, 为toFixed做准备\nexport function round(number, ratio = 100) {\n return Math.round(multiply(number, ratio)) / ratio\n}\n\n/**\n * 将字符串简单转换成数字, 并可数倍转换. 注意, 这个适用于整数倍(商品件数), 非整数的不能用这个处理小数.\n * @param {*} value 目标值\n * @param {*} ratio 倍数, 默认1\n * @returns number | origin, 转换后的数字, 无法转成数字的返回原值\n */\nexport function transformNumber(value, ratio = 1) {\n const v = Number(value)\n if (Number.isNaN(v)) {\n return value\n } else {\n // 保留两位小数\n return divide(Math.trunc(times(times(v, ratio), 100)), 100)\n }\n}\n\n// unit 单个商品的, 没有乘数量. 因为含有111 999 这些极端值, 没有格式化输出之前直接乘回出问题的.\nexport const getUnit = function (buyNum, index, attributeList, basePriceList) {\n // 算出购买数量位于 价格阶梯的 哪个区间\n const candidate = Object.entries(attributeList).filter(\n item => buyNum >= item[1]\n )\n\n let key = 'website_qty1'\n if (candidate.length) {\n key = candidate.pop()[0]\n }\n\n return transformNumber(basePriceList[index][key], buyNum)\n}\n\n// 打印和附加价格 的steup之和. 商品基础价格现在没有setup了.\nexport const getSetup = function (buyNum, form, additionList) {\n const sum = Object.entries(form).reduce((total, current) => {\n let s = 0\n // 打印服务表单的数据跟附加服务表单的数据结构不一致, 以数字id字符串键名的是打印服务的数据\n if (/\\d+/.test(current[0]) && current[1].enable) {\n const temp = current[1].colorForm.filter(\n i => i.id === current[1].printService\n )\n let colorNumber = 1\n if (temp.length) {\n colorNumber = temp[0].colorNumber\n }\n\n const decoration = current[1].decorationList.filter(\n i => i.id === current[1].printService\n )\n let setup = 0\n if (decoration.length) {\n setup = plus(\n Number(decoration[0].website_setup),\n times(Number(decoration[0].supplier_setup), colorNumber - 1)\n )\n }\n s = plus(s, setup)\n } else if (current[1].length) {\n // 附加服务的表单数据, 有值说明该项有选中了附加服务\n const addition = additionList[current[0]].filter(addition =>\n current[1].includes(addition.id)\n )\n\n if (addition.length) {\n const temp = addition.reduce((t, c) => {\n let value = Number(c.website_setup)\n if ([5, 6].includes(c.website_setup_id)) {\n // 5是poa, 6是waived. 这种情况一般setup是留空的, 不留空大概是异常数据, 重置0保险一点.\n value = 0\n }\n return plus(t, Number.isNaN(value) ? 0 : value)\n }, 0)\n\n s = plus(s, temp)\n }\n }\n\n total = plus(total, s)\n return total\n }, 0)\n return transformNumber(sum)\n}\n\n// 打印价格的 阶梯基础价*购买数量.\nexport const getPrint = function (buyNum, form, attributeList) {\n // 算出购买数量位于 价格阶梯的 哪个区间\n const candidate = Object.entries(attributeList).filter(\n item => buyNum >= item[1]\n )\n const key = `website_qty${candidate.length}`\n const key2 = `supplier_qty${candidate.length}`\n\n // 如果其中一项为POA, 则‘和’都是POA\n const result = Object.entries(form).reduce((total, current) => {\n if (total === 'POA') {\n return total\n }\n let sum = 0\n if (/\\d+/.test(current[0]) && current[1].enable) {\n const temp = current[1].colorForm.filter(\n i => i.id === current[1].printService\n )\n let colorNumber = 1\n if (temp.length) {\n colorNumber = temp[0].colorNumber\n }\n\n const decoration = current[1].decorationList.filter(\n i => i.id === current[1].printService\n )\n // 打印价格的基础价. 其中数字111(代表'-') 和999(代表'POA')\n const p1 = transformNumber(decoration[0][key])\n if (p1 === 999 || p1 === 111 || typeof p1 !== 'number') {\n return 'POA'\n }\n // 打印价格的附加价\n const p2 = transformNumber(decoration[0][key2])\n if (p2 === 999 || p2 === 111 || typeof p2 !== 'number') {\n return 'POA'\n }\n let price = 0\n if (decoration.length) {\n price = plus(p1, times(p2, colorNumber - 1))\n }\n sum = plus(sum, price)\n }\n total = plus(total, sum)\n return total\n }, 0)\n\n return transformNumber(result, buyNum)\n}\n// 附加服务除了packing之外的总价\nexport const getAddon = function (buyNum, form, attributeList, additionList) {\n // 算出购买数量位于 价格阶梯的 哪个区间\n const candidate = Object.entries(attributeList).filter(\n item => buyNum >= item[1]\n )\n const key = `website_qty${candidate.length}`\n const result = Object.entries(form).reduce((total, current) => {\n if (total === 'POA') {\n return total\n }\n\n let sum = 0\n if (!/\\d+/.test(current[0]) && current[0] !== 'packaging') {\n sum = additionList[current[0]]\n .filter(item => current[1].includes(item.id))\n .reduce((t, c) => {\n if (t === 'POA') {\n return t\n }\n let temp = transformNumber(c[key])\n if (temp === 999 || temp === 111 || typeof temp !== 'number') {\n temp = 0\n return 'POA'\n }\n t = plus(t, temp)\n return t\n }, 0)\n }\n return plus(total, sum)\n }, 0)\n\n return transformNumber(result, buyNum)\n}\n// 附加服务中 packing 的价格\nexport const getPackaging = function (\n buyNum,\n form,\n attributeList,\n additionList\n) {\n // 算出购买数量位于 价格阶梯的 哪个区间\n const candidate = Object.entries(attributeList).filter(\n item => buyNum >= item[1]\n )\n const key = `website_qty${candidate.length}`\n const result = Object.entries(form).reduce((total, current) => {\n if (total === 'POA') {\n return total\n }\n\n let sum = 0\n if (!/\\d+/.test(current[0]) && current[0] === 'packaging') {\n sum = additionList[current[0]]\n .filter(item => current[1].includes(item.id))\n .reduce((t, c) => {\n if (t === 'POA') {\n return t\n }\n let temp = transformNumber(c[key])\n if (temp === 999 || temp === 111 || typeof temp !== 'number') {\n temp = 0\n return 'POA'\n }\n t = plus(t, temp)\n return t\n }, 0)\n }\n return plus(total, sum)\n }, 0)\n\n return transformNumber(result, buyNum)\n}\n\n// 运费计算. 从product页面抄过来的逻辑. +号是隐式类型转换\nexport const getFright = function (buyNum, config, freight, weight, ratio = 1) {\n // 单独批次数量的总重\n const totalWeight = Math.ceil(times(+weight.unit_w_local, buyNum))\n\n const expressFactor = plus(\n 1,\n divide(plus(+config.express_freight, +config.fuel), 100)\n )\n\n const AAEFactor = plus(\n 1,\n divide(plus(+config.bag_freight, +config.fuel), 100)\n )\n let frightCost = 0\n\n if (freight.type === 1) {\n if (totalWeight > 20) {\n const a1 = minus(totalWeight, 20)\n const a2 = times(a1, +freight.basic)\n const a3 = plus(+freight.pickup, a2)\n frightCost = times(a3, expressFactor)\n } else {\n frightCost = times(+freight.pickup, expressFactor)\n }\n } else if (freight.type === 2) {\n const a1 = times(totalWeight, +freight.basic)\n const a2 = plus(+freight.pickup, a1)\n frightCost = times(a2, AAEFactor)\n } else {\n frightCost = 0\n }\n return transformNumber(frightCost, ratio)\n}\n","// extracted by extract-css-chunks-webpack-plugin\nmodule.exports = {};","// extracted by extract-css-chunks-webpack-plugin\nmodule.exports = {};","export * from \"-!../node_modules/extract-css-chunks-webpack-plugin/dist/loader.js??ref--7-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--7-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/dist/cjs.js??ref--7-oneOf-1-2!../node_modules/sass-loader/dist/cjs.js??ref--7-oneOf-1-3!../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./imageList.vue?vue&type=style&index=0&id=d262f43e&prod&lang=scss&scoped=true\"","export * from \"-!../node_modules/extract-css-chunks-webpack-plugin/dist/loader.js??ref--7-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--7-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/dist/cjs.js??ref--7-oneOf-1-2!../node_modules/sass-loader/dist/cjs.js??ref--7-oneOf-1-3!../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./ExportDialog.vue?vue&type=style&index=0&id=1381fc6c&prod&lang=scss&scoped=true\"","// extracted by extract-css-chunks-webpack-plugin\nmodule.exports = {};","\nimport throttle from 'lodash.throttle'\nimport { mapMutations } from 'vuex'\nimport { round } from '@/utils/price.js'\n\nexport default {\n name: 'OrderDetailPart',\n props: {\n isShow: {\n // 订单分享页面隐藏元素\n type: Boolean,\n default: true,\n },\n hasUid: {\n type: Boolean,\n default: true,\n },\n },\n data() {\n return {\n orderDetail: {},\n isLoading: 1,\n packageTable: [],\n stepShow: false,\n urlDialogShow: false,\n shareDialogVisible: false,\n loginCount: 0,\n shareForm: {\n Link: '',\n },\n Tracking_URL: '',\n stepConfig: {\n 'Order Confirmed': 1,\n 'Factory Confirmed': 2,\n 'GZ WH': 3,\n Transshipment: 4,\n 'AU WH': 5,\n 'AUWH - Client': 6,\n 'Bulk Production Shipping': 6,\n 'Bulk Production Delivered': 7,\n 'Completed Sales Order': 7,\n 'Factory Process': 1,\n 'Sample Dispatching': 2,\n 'Sample Delivered': 3,\n },\n computedStepDirection: 'horizontal',\n }\n },\n computed: {\n loginSuccess() {\n return this.$store.state.loginSuccess\n },\n comCurrency() {\n return this.orderDetail.Currency\n },\n comOrderState() {\n if (this.orderDetail.Order_Stage === 'Cancelled') {\n return 0\n }\n return this.stepConfig[this.orderDetail.Order_Stage]\n },\n comSampleState() {\n return this.stepConfig[this.orderDetail.Sample_Stage]\n },\n },\n watch: {\n loginSuccess(newVal) {\n if (newVal) {\n this.getOrderDetail() // 当登录成功后调用获取订单详情\n this.$store.commit('setLoginSuccess', false)\n }\n },\n },\n beforeMount() {\n window.addEventListener('resize', this.judgeStepDirection, false)\n this.judgeStepDirection()\n },\n created() {\n this.getOrderDetail()\n },\n beforeDestroy() {\n window.removeEventListener('resize', this.judgeStepDirection, false)\n },\n methods: {\n ...mapMutations({ openDialog: 'openDialog' }),\n judgeStepDirection: throttle(function () {\n this.computedStepDirection =\n window.document.body.clientWidth >= 1000 ? 'horizontal' : 'vertical'\n }, 300),\n toggleStep() {\n this.stepShow = !this.stepShow\n },\n getOrderDetail() {\n let path = ''\n let data = {}\n if (this.isShow) {\n const { id } = this.$store.state.userInfo\n const { crm, id: queryId } = this.$route.query\n\n path = '/uk-api/crmdata/orders_detail'\n this.shareForm.Link = `https://www.trackship.com.au/orderShare/${id}/${crm}/${queryId}`\n data = { accounts_id: crm, id: queryId }\n } else {\n path = '/uk-api/crmdata/showOrdersDetail'\n if (this.hasUid) {\n const { uid, aid, id } = this.$route.params\n data = { user_id: uid, accounts_id: aid, id }\n } else {\n const { aid, id } = this.$route.params\n data = { accounts_id: aid, id }\n }\n }\n this.$axios\n .post(path, data)\n .then(res => {\n if (res.result === null) {\n this.handleBranchLogic()\n }\n this.orderDetail = res.result\n if (this.orderDetail.shipping_tracking?.length) {\n const isDelivered = true\n\n for (const items of this.orderDetail.shipping_tracking) {\n if (items.test_pkg_details?.length) {\n items.test_pkg_details.forEach(item => {\n item.Courier = items.Courier\n item.Tracking_No = items.Tracking_No\n item.Package_Status = items.Package_Status\n item.Tracking_URL = items.Tracking_URL\n })\n }\n }\n }\n if (this.orderDetail.sales_orders_details?.length) {\n if (this.isShow) {\n this.orderDetail.sales_orders_details.forEach(items => {\n this.$set(items, 'showMore', true)\n })\n } else {\n this.orderDetail.sales_orders_details =\n this.orderDetail.sales_orders_details\n .filter(item => {\n return (\n item.product_Product_Code !== 'PC Setup Service' &&\n item.product_Product_Code !== 'PC Freight'\n )\n })\n .map(item => {\n this.$set(item, 'showMore', true)\n return item\n })\n }\n }\n this.isLoading = 2\n })\n .catch(() => {\n this.handleBranchLogic()\n })\n },\n handleBranchLogic() {\n this.isLoading = 3\n if (this.loginCount) {\n this.$router.push('/')\n return\n }\n this.isShow &&\n setTimeout(() => {\n this.openDialog()\n this.loginCount = 1\n }, 1000)\n },\n transformNumber(value) {\n return round(Number(value)).toFixed(2)\n },\n formatStepDesc(date, isUnix = false) {\n return this.$utils.formatTime(date, 'DD/MM/YYYY', isUnix)\n },\n toggleShow(row) {\n row.showMore = !row.showMore\n },\n openTracking_URL(url) {\n this.Tracking_URL = url\n this.urlDialogShow = true\n },\n },\n}\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--2-0!../../../../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./orderDetailPart.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--2-0!../../../../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./orderDetailPart.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./orderDetailPart.vue?vue&type=template&id=0272884e&scoped=true\"\nimport script from \"./orderDetailPart.vue?vue&type=script&lang=js\"\nexport * from \"./orderDetailPart.vue?vue&type=script&lang=js\"\nimport style0 from \"./orderDetailPart.vue?vue&type=style&index=0&id=0272884e&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"0272884e\",\n null\n \n)\n\nexport default component.exports\n\n/* nuxt-component-imports */\ninstallComponents(component, {ImageList: require('/Users/wu67/Projects/uk_front/components/imageList.vue').default,ExportDialog: require('/Users/wu67/Projects/uk_front/components/ExportDialog.vue').default})\n","\nimport ElImageViewer from \"element-ui/packages/image/src/image-viewer\";\n\nexport default {\n components: { ElImageViewer },\n props: {\n data: {\n type: Array,\n default: () => {\n return []\n },\n }\n },\n data() {\n return {\n currentPre: 0,\n showViewer: false,\n }\n },\n computed: {\n comImg() {\n return this.data.map(i => i.cdn_url);\n }\n },\n methods: {\n scroll(amount) {\n const list = this.$refs.list;\n list.scrollLeft += amount * list.clientWidth;\n },\n closeViewer() {\n this.showViewer = false;\n },\n handleViwer(i) {\n this.currentPre = i;\n this.showViewer = true;\n }\n }\n};\n","import mod from \"-!../node_modules/babel-loader/lib/index.js??ref--2-0!../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./imageList.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../node_modules/babel-loader/lib/index.js??ref--2-0!../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./imageList.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./imageList.vue?vue&type=template&id=d262f43e&scoped=true\"\nimport script from \"./imageList.vue?vue&type=script&lang=js\"\nexport * from \"./imageList.vue?vue&type=script&lang=js\"\nimport style0 from \"./imageList.vue?vue&type=style&index=0&id=d262f43e&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"d262f43e\",\n null\n \n)\n\nexport default component.exports","\nimport Clipboard from 'clipboard';\nexport default {\n props: {\n title:{\n type:String,\n default: 'Send Email'\n },\n sendbtnCext:{\n type:String,\n default: 'SUBMIT REQUEST'\n },\n isSendPdf:{\n type:Boolean,\n default: false\n },\n labelShow:{\n type:Boolean,\n default: true\n },\n emailForm: {},\n rules: {},\n labelWidth: Number,\n visible: {\n type: Boolean,\n default: false\n },\n },\n methods:{\n copyUrl(key){\n let clipboard = new Clipboard(`.${key}`)\n clipboard.on('success', e => {\n this.$message.success(\"link copied to clipboard\") // 利用Element组件给予成功提示\n clipboard.destroy() // 释放内存 \n })\n clipboard.on('error', e => {\n this.$message.error('The browser does not support automatic replication') // 给予错误提示信息\n clipboard.destroy() // 释放内存\n })\n },\n handleClose(){\n this.$emit('update:visible', false)\n },\n }\n};\n","import mod from \"-!../node_modules/babel-loader/lib/index.js??ref--2-0!../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./ExportDialog.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../node_modules/babel-loader/lib/index.js??ref--2-0!../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./ExportDialog.vue?vue&type=script&lang=js\"","import { render, staticRenderFns } from \"./ExportDialog.vue?vue&type=template&id=1381fc6c&scoped=true\"\nimport script from \"./ExportDialog.vue?vue&type=script&lang=js\"\nexport * from \"./ExportDialog.vue?vue&type=script&lang=js\"\nimport style0 from \"./ExportDialog.vue?vue&type=style&index=0&id=1381fc6c&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"1381fc6c\",\n null\n \n)\n\nexport default component.exports","export * from \"-!../../../../node_modules/extract-css-chunks-webpack-plugin/dist/loader.js??ref--7-oneOf-1-0!../../../../node_modules/css-loader/dist/cjs.js??ref--7-oneOf-1-1!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/postcss-loader/dist/cjs.js??ref--7-oneOf-1-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--7-oneOf-1-3!../../../../node_modules/@nuxt/components/dist/loader.js??ref--0-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./orderDetailPart.vue?vue&type=style&index=0&id=0272884e&prod&lang=scss&scoped=true\""],"sourceRoot":""}