contactPromoCollection.js 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343
  1. exports.ids = [55];
  2. exports.modules = {
  3. /***/ 256:
  4. /***/ (function(module, exports) {
  5. // Exports
  6. module.exports = {
  7. };
  8. /***/ }),
  9. /***/ 311:
  10. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  11. "use strict";
  12. __webpack_require__.r(__webpack_exports__);
  13. /* harmony import */ var _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_contactPromoCollection_vue_vue_type_style_index_0_id_e8620a10_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(256);
  14. /* harmony import */ var _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_contactPromoCollection_vue_vue_type_style_index_0_id_e8620a10_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_contactPromoCollection_vue_vue_type_style_index_0_id_e8620a10_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__);
  15. /* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_contactPromoCollection_vue_vue_type_style_index_0_id_e8620a10_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_contactPromoCollection_vue_vue_type_style_index_0_id_e8620a10_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
  16. /***/ }),
  17. /***/ 354:
  18. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  19. "use strict";
  20. // ESM COMPAT FLAG
  21. __webpack_require__.r(__webpack_exports__);
  22. // CONCATENATED MODULE: ./node_modules/babel-loader/lib??ref--2-0!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/@nuxt/components/dist/loader.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./pages/home/contactPromoCollection.vue?vue&type=template&id=e8620a10&scoped=true
  23. var render = function render() {
  24. var _vm = this,
  25. _c = _vm._self._c;
  26. return _c('div', {
  27. staticClass: "com-main com-width-1400 com-margin-auto"
  28. }, [_c('el-breadcrumb', {
  29. attrs: {
  30. "separator-class": "el-icon-arrow-right"
  31. }
  32. }, [_c('el-breadcrumb-item', {
  33. attrs: {
  34. "to": {
  35. path: '/'
  36. }
  37. }
  38. }, [_vm._v("Home")]), _vm._v(" "), _c('el-breadcrumb-item', [_vm._v(" Contact PromoCollection")])], 1), _vm._ssrNode(" <p class=\"title\" data-v-e8620a10>Contact PromoCollection</p> <div class=\"line\" data-v-e8620a10></div> <p class=\"des\" data-v-e8620a10>\n      We distribute through distributors only. If you\n are a registered distributor, please\n <span data-v-e8620a10>login</span> , otherwise, please fill out\n contact <br data-v-e8620a10>\n details below. One of our authorized distributors would contact you\n shortly.\n <span data-v-e8620a10>If you have a preferred distributor, please specify</span></p> "), _c('el-form', {
  39. ref: "ruleForm",
  40. staticClass: "demo-ruleForm",
  41. attrs: {
  42. "model": _vm.ruleForm,
  43. "rules": _vm.rules,
  44. "label-width": "0px"
  45. }
  46. }, [_c('el-form-item', {
  47. attrs: {
  48. "prop": "company"
  49. }
  50. }, [_c('el-input', {
  51. attrs: {
  52. "placeholder": "Company Name*",
  53. "clearable": ""
  54. },
  55. model: {
  56. value: _vm.ruleForm.company,
  57. callback: function ($$v) {
  58. _vm.$set(_vm.ruleForm, "company", $$v);
  59. },
  60. expression: "ruleForm.company"
  61. }
  62. })], 1), _vm._v(" "), _c('el-form-item', {
  63. attrs: {
  64. "prop": "contacts"
  65. }
  66. }, [_c('el-input', {
  67. attrs: {
  68. "placeholder": "Contact Person*",
  69. "clearable": ""
  70. },
  71. model: {
  72. value: _vm.ruleForm.contacts,
  73. callback: function ($$v) {
  74. _vm.$set(_vm.ruleForm, "contacts", $$v);
  75. },
  76. expression: "ruleForm.contacts"
  77. }
  78. })], 1), _vm._v(" "), _c('el-form-item', {
  79. attrs: {
  80. "prop": "phone"
  81. }
  82. }, [_c('el-input', {
  83. attrs: {
  84. "placeholder": "Phone*",
  85. "clearable": ""
  86. },
  87. model: {
  88. value: _vm.ruleForm.phone,
  89. callback: function ($$v) {
  90. _vm.$set(_vm.ruleForm, "phone", $$v);
  91. },
  92. expression: "ruleForm.phone"
  93. }
  94. })], 1), _vm._v(" "), _c('el-form-item', {
  95. attrs: {
  96. "prop": "address"
  97. }
  98. }, [_c('el-input', {
  99. attrs: {
  100. "placeholder": "Address",
  101. "clearable": ""
  102. },
  103. model: {
  104. value: _vm.ruleForm.address,
  105. callback: function ($$v) {
  106. _vm.$set(_vm.ruleForm, "address", $$v);
  107. },
  108. expression: "ruleForm.address"
  109. }
  110. })], 1), _vm._v(" "), _c('el-form-item', {
  111. attrs: {
  112. "prop": "state"
  113. }
  114. }, [_c('el-input', {
  115. attrs: {
  116. "placeholder": "State",
  117. "clearable": ""
  118. },
  119. model: {
  120. value: _vm.ruleForm.state,
  121. callback: function ($$v) {
  122. _vm.$set(_vm.ruleForm, "state", $$v);
  123. },
  124. expression: "ruleForm.state"
  125. }
  126. })], 1), _vm._v(" "), _c('el-form-item', {
  127. attrs: {
  128. "prop": "postcode"
  129. }
  130. }, [_c('el-input', {
  131. attrs: {
  132. "placeholder": "Post Code",
  133. "clearable": ""
  134. },
  135. model: {
  136. value: _vm.ruleForm.postcode,
  137. callback: function ($$v) {
  138. _vm.$set(_vm.ruleForm, "postcode", $$v);
  139. },
  140. expression: "ruleForm.postcode"
  141. }
  142. })], 1), _vm._v(" "), _c('el-form-item', {
  143. attrs: {
  144. "prop": "url"
  145. }
  146. }, [_c('el-input', {
  147. attrs: {
  148. "placeholder": "Website",
  149. "clearable": ""
  150. },
  151. model: {
  152. value: _vm.ruleForm.url,
  153. callback: function ($$v) {
  154. _vm.$set(_vm.ruleForm, "url", $$v);
  155. },
  156. expression: "ruleForm.url"
  157. }
  158. })], 1), _vm._v(" "), _c('el-form-item', {
  159. attrs: {
  160. "prop": "email"
  161. }
  162. }, [_c('el-input', {
  163. attrs: {
  164. "placeholder": "E-mail",
  165. "clearable": ""
  166. },
  167. model: {
  168. value: _vm.ruleForm.email,
  169. callback: function ($$v) {
  170. _vm.$set(_vm.ruleForm, "email", $$v);
  171. },
  172. expression: "ruleForm.email"
  173. }
  174. })], 1), _vm._v(" "), _c('el-form-item', {
  175. attrs: {
  176. "prop": "content"
  177. }
  178. }, [_c('el-input', {
  179. attrs: {
  180. "type": "textarea",
  181. "rows": 5,
  182. "placeholder": "Content",
  183. "clearable": ""
  184. },
  185. model: {
  186. value: _vm.ruleForm.content,
  187. callback: function ($$v) {
  188. _vm.$set(_vm.ruleForm, "content", $$v);
  189. },
  190. expression: "ruleForm.content"
  191. }
  192. })], 1), _vm._v(" "), _c('el-form-item', [_c('el-button', {
  193. attrs: {
  194. "disabled": _vm.disabledFlag
  195. },
  196. on: {
  197. "click": function ($event) {
  198. return _vm.submitForm('ruleForm');
  199. }
  200. }
  201. }, [_vm._v("\n " + _vm._s(_vm.butonContent) + "\n ")])], 1)], 1)], 2);
  202. };
  203. var staticRenderFns = [];
  204. // CONCATENATED MODULE: ./pages/home/contactPromoCollection.vue?vue&type=template&id=e8620a10&scoped=true
  205. // EXTERNAL MODULE: external "vuex"
  206. var external_vuex_ = __webpack_require__(6);
  207. // CONCATENATED MODULE: ./node_modules/babel-loader/lib??ref--2-0!./node_modules/@nuxt/components/dist/loader.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./pages/home/contactPromoCollection.vue?vue&type=script&lang=js
  208. /* harmony default export */ var contactPromoCollectionvue_type_script_lang_js = ({
  209. data() {
  210. return {
  211. ruleForm: {
  212. company: "",
  213. contacts: "",
  214. phone: "",
  215. address: "",
  216. state: "",
  217. postcode: "",
  218. url: "",
  219. email: "",
  220. content: ""
  221. },
  222. rules: {
  223. company: [{
  224. required: true,
  225. message: "Please enter your Company Name",
  226. trigger: "blur"
  227. }],
  228. contacts: [{
  229. required: true,
  230. message: "Please enter your Contact Person",
  231. trigger: "blur"
  232. }],
  233. phone: [{
  234. required: true,
  235. message: "Please enter your Phone Number",
  236. trigger: "blur"
  237. }]
  238. },
  239. time: 60,
  240. timer: null,
  241. butonContent: "Submit",
  242. disabledFlag: false
  243. };
  244. },
  245. watch: {
  246. time: {
  247. handler(newValue) {
  248. if (newValue == 0) {
  249. this.disabledFlag = false;
  250. } else {
  251. this.disabledFlag = true;
  252. }
  253. }
  254. }
  255. },
  256. methods: {
  257. ...Object(external_vuex_["mapMutations"])(["openDialog"]),
  258. Login() {
  259. this.openDialog();
  260. },
  261. submitForm(formName) {
  262. this.$refs[formName].validate(valid => {
  263. if (valid) {
  264. this.timer = setInterval(() => {
  265. if (this.time == 0) {
  266. this.butonContent = "Submit";
  267. clearInterval(this.timer);
  268. } else {
  269. this.butonContent = "Submit " + this.time + " s";
  270. this.time--;
  271. }
  272. }, 1000);
  273. this.$axios.post("/uk-api/others/visitor", this.ruleForm).then(res => {
  274. if (res.code == 1) {
  275. this.$notify({
  276. title: "success",
  277. message: "Your request has been sent to your nominated e mail address.",
  278. type: "success"
  279. });
  280. this.$router.push('/');
  281. }
  282. }).catch(() => {
  283. // this.$message.error(error.response.data.msg);
  284. });
  285. } else {
  286. console.log("error submit!!");
  287. return false;
  288. }
  289. });
  290. }
  291. }
  292. });
  293. // CONCATENATED MODULE: ./pages/home/contactPromoCollection.vue?vue&type=script&lang=js
  294. /* harmony default export */ var home_contactPromoCollectionvue_type_script_lang_js = (contactPromoCollectionvue_type_script_lang_js);
  295. // EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
  296. var componentNormalizer = __webpack_require__(2);
  297. // CONCATENATED MODULE: ./pages/home/contactPromoCollection.vue
  298. function injectStyles (context) {
  299. var style0 = __webpack_require__(311)
  300. if (style0.__inject__) style0.__inject__(context)
  301. }
  302. /* normalize component */
  303. var component = Object(componentNormalizer["a" /* default */])(
  304. home_contactPromoCollectionvue_type_script_lang_js,
  305. render,
  306. staticRenderFns,
  307. false,
  308. injectStyles,
  309. "e8620a10",
  310. "375fdd27"
  311. )
  312. /* harmony default export */ var contactPromoCollection = __webpack_exports__["default"] = (component.exports);
  313. /***/ })
  314. };;
  315. //# sourceMappingURL=contactPromoCollection.js.map