|
- (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/center/consumer/edit"],{158:function(e,t,n){"use strict";n.r(t);var o=n(159),i=n.n(o);for(var s in o)"default"!==s&&function(e){n.d(t,e,(function(){return o[e]}))}(s);t["default"]=i.a},159:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n={data:function(){return{form:{name:"",sex:"1",phone:"",chatNo:"",level:"1",remarks:""},selectform:{level:"A",stage:"",demand:"",area:"",budget:"",fouce:"",soure:""},levelshow:!1,customerId:"",levellist:[{value:1,label:"A"},{value:2,label:"B"},{value:3,label:"C"},{value:4,label:"D"}],allList:[],dataCode:""}},onLoad:function(t){var n=e.getStorageSync("weapp_session_userInfo_data"),o=n.dataCode;this.dataCode=o,console.log(t),this.customerId=t.id,this.getdetail()},methods:{Edittag:function(e,t,n,o){0==this.allList[n].children[o].selected?this.allList[n].children[o].selected=1:this.allList[n].children[o].selected=0,this.$forceUpdate()},sourecheck:function(e){this.sourelist[e].checked=!this.sourelist[e].checked,this.$forceUpdate()},demandcheck:function(e){this.demandlist[e].checked=!this.demandlist[e].checked,this.$forceUpdate()},areacheck:function(e){this.arealist[e].checked=!this.arealist[e].checked,this.$forceUpdate()},levelshowCallback:function(e){this.selectform.level=e[0].label,this.form.level=e[0].value},getdetail:function(){var e=this;this.$u.get("customer/findById?",{id:this.customerId}).then((function(t){e.form=t;var n=e.levellist.findIndex((function(e){return e.value==t.level}));-1!=n?e.selectform.level=e.levellist[n].label:(e.selectform.level="A",e.form.level=1),e.getListByType()}))},getListByType:function(){var e=this;this.$u.get("/matchKeywords/findPersonalMatchData",{customerId:this.customerId}).then((function(t){t.forEach((function(e){e.children.map((function(e){0==e.isInterval?e.label=e.name+e.unit+"-"+e.endName+e.unit:e.label=e.name,e.value=e.id}))})),e.allList=t}))},submit:function(){var t={},n=[];""!=this.form.name?""!=this.form.phone?this.form.phone.length<5?e.showToast({icon:"none",title:"手机号码不能小于5位"}):this.form.phone.length>11?e.showToast({icon:"none",title:"手机号码不能大于11位"}):(this.allList.map((function(e){e.children.map((function(e){0==e.selected&&n.push(e.keywordsId)}))})),n=n.join(","),t=this.form,t.keywordIds=n,console.log(t),this.$u.post("customer/update",t).then((function(t){e.showToast({title:"操作成功",icon:"none",success:function(){e.navigateBack()}})}))):e.showToast({title:"请输入手机号",icon:"none"}):e.showToast({title:"请输入客户姓名",icon:"none"})}}};t.default=n}).call(this,n(0)["default"])},160:function(e,t,n){},213:function(e,t,n){"use strict";var o;n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return o}));try{o={uSelect:function(){return n.e("uview-ui/components/u-select/u-select").then(n.bind(null,582))}}}catch(c){if(-1===c.message.indexOf("Cannot find module")||-1===c.message.indexOf(".vue"))throw c;console.error(c.message),console.error("1. 排查组件名称拼写是否正确"),console.error("2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"),console.error("3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件")}var i=function(){var e=this,t=e.$createElement;e._self._c;e._isMounted||(e.e0=function(t){e.form.sex=1},e.e1=function(t){e.form.sex=2},e.e2=function(t){e.levelshow=!0})},s=[];i._withStripped=!0},425:function(e,t,n){"use strict";(function(e){n(3);o(n(2));var t=o(n(426));function o(e){return e&&e.__esModule?e:{default:e}}wx.__webpack_require_UNI_MP_PLUGIN__=n,e(t.default)}).call(this,n(0)["createPage"])},426:function(e,t,n){"use strict";n.r(t);var o=n(213),i=n(158);for(var s in i)"default"!==s&&function(e){n.d(t,e,(function(){return i[e]}))}(s);n(427);var c,l=n(1),a=Object(l["a"])(i["default"],o["b"],o["c"],!1,null,"25b333c2",null,!1,o["a"],c);a.options.__file="pages/center/consumer/edit.vue",t["default"]=a.exports},427:function(e,t,n){"use strict";var o=n(160),i=n.n(o);i.a}},[[425,"common/runtime","common/vendor"]]]);
- //# sourceMappingURL=../../../../.sourcemap/mp-weixin/pages/center/consumer/edit.js.map
|