1 line
3.9 KiB
JavaScript
1 line
3.9 KiB
JavaScript
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/index/groupCompany/contract/addPaymentPlan"],{3010:function(t,n,e){},"5c7b":function(t,n,e){"use strict";e.d(n,"b",(function(){return i})),e.d(n,"c",(function(){return o})),e.d(n,"a",(function(){}));var i=function(){var t=this.$createElement;this._self._c},o=[]},"5f8f":function(t,n,e){"use strict";(function(t){Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i=e("76dd"),o={components:{selectCustomer:function(){Promise.all([e.e("common/vendor"),e.e("components/selectCustomer")]).then(function(){return resolve(e("5bcd"))}.bind(null,e)).catch(e.oe)},selectContract:function(){e.e("components/selectContract").then(function(){return resolve(e("e630"))}.bind(null,e)).catch(e.oe)}},data:function(){return{noClick:!0,type:[],index:null,info:null,customer_id:"",contract_id:"",num:"",money:"",return_date:"",return_type:"",remind:"",remarks:"",customerList:[],customerObj:{},contractList:[],contractIndex:null,contractObj:{},isRequired:!1}},onLoad:function(t){t.kehuid&&(this.customer_id=t.kehuid,this.contract_id=t.id),this.getKehu()},onShow:function(){this.getType()},onUnload:function(){},methods:{changeRequired:function(t){this.isRequired=t.detail.value},getKehu:function(){var t=this;(0,i.netPrevCustomer)().then((function(n){t.customerList=n.data,t.customer_id&&(t.customerList.forEach((function(n,e){n.id==t.customer_id&&(t.customerObj=n)})),t.getContract())}))},changeCustomer:function(t){this.$refs.customerChild.init()},sureCustomer:function(t){this.customerObj=t,this.contractObj={}},getContract:function(){var t=this,n={customer_id:this.customerObj.id?this.customerObj.id:this.customer_id};(0,i.netContractList)(n).then((function(n){t.contractList=n.data,t.contract_id&&t.contractList.forEach((function(n,e){n.id==t.contract_id&&(t.contractObj=n)}))}))},changeContract:function(){this.$refs.contractChild.init(this.customerObj.id)},sureContract:function(t){this.contractObj=t},getType:function(){var t=this;(0,i.netSelect)().then((function(n){t.type=n.data["回款方式"]}))},changeType:function(t){this.return_type=this.type[t.detail.value]},changeTime:function(t){this.return_date=t.detail.value},saveFollow:function(){var n=this.money,e=this.return_date,o=this.return_type,c=this.remind,r=this.remarks,s=(this.info,this.num);if(this.customerObj.id)if(this.contractObj.id)if(n)if(s)if(e)if(o)if(c){var u={customer_id:this.customerObj.id?this.customerObj.id:"",contract_id:this.contractObj.id?this.contractObj.id:"",money:n,return_date:e,return_type:o,remind:c,remarks:r,num:s};(0,i.netAddPlan)(u).then((function(n){t.showToast({title:n.msg,icon:"none"}),setTimeout((function(){t.navigateBack({delta:1})}),2e3)}))}else t.showToast({title:"请填写提前几天提醒",icon:"none"});else t.showToast({title:"请选择计划回款方式",icon:"none"});else t.showToast({title:"请选择计划回款日期",icon:"none"});else t.showToast({title:"请输入计划回款期数",icon:"none"});else t.showToast({title:"请输入计划回款金额",icon:"none"});else t.showToast({title:"请选择关联合同",icon:"none"});else t.showToast({title:"请选择关联客户",icon:"none"})}}};n.default=o}).call(this,e("543d")["default"])},"9cbd":function(t,n,e){"use strict";var i=e("3010"),o=e.n(i);o.a},d589:function(t,n,e){"use strict";e.r(n);var i=e("5f8f"),o=e.n(i);for(var c in i)["default"].indexOf(c)<0&&function(t){e.d(n,t,(function(){return i[t]}))}(c);n["default"]=o.a},f2c7:function(t,n,e){"use strict";e.r(n);var i=e("5c7b"),o=e("d589");for(var c in o)["default"].indexOf(c)<0&&function(t){e.d(n,t,(function(){return o[t]}))}(c);e("9cbd");var r=e("f0c5"),s=Object(r["a"])(o["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],void 0);n["default"]=s.exports},fc93:function(t,n,e){"use strict";(function(t,n){var i=e("4ea4");e("8886");i(e("66fd"));var o=i(e("f2c7"));t.__webpack_require_UNI_MP_PLUGIN__=e,n(o.default)}).call(this,e("bc2e")["default"],e("543d")["createPage"])}},[["fc93","common/runtime","common/vendor"]]]); |