pnkx-admin-mongo/pnkx-app-apk/static/js/chunk-04d0cdaa.6b2693e2.js
2024-01-13 13:29:20 +08:00

1 line
4.5 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-04d0cdaa"],{"552c":function(t,e,i){"use strict";i("6b8b")},"6b8b":function(t,e,i){},"9fb1":function(t,e,i){"use strict";i.d(e,"e",(function(){return o})),i.d(e,"d",(function(){return n})),i.d(e,"c",(function(){return c})),i.d(e,"a",(function(){return r})),i.d(e,"f",(function(){return s})),i.d(e,"b",(function(){return l}));var a=i("b775");function o(t){return Object(a["a"])({url:"/bookkeeping/classification/list",method:"get",params:t})}function n(t){return Object(a["a"])({url:"/bookkeeping/classification/getLatelyTypeList",method:"get",params:t})}function c(t){return Object(a["a"])({url:"/bookkeeping/classification/"+t,method:"get"})}function r(t){return Object(a["a"])({url:"/bookkeeping/classification",method:"post",data:t})}function s(t){return Object(a["a"])({url:"/bookkeeping/classification",method:"put",data:t})}function l(t){return Object(a["a"])({url:"/bookkeeping/classification/"+t,method:"delete"})}},d132:function(t,e,i){"use strict";i.r(e);var a=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"add-classification"},[i("van-nav-bar",{attrs:{fixed:"","left-arrow":"","left-text":"返回",title:t.title+""+(t.typeParentName?""+t.typeParentName+"":""),"right-text":"提交"},on:{"click-left":function(e){return t.$router.go(-1)},"click-right":t.handleAdd}}),i("div",{staticClass:"page"},[i("van-cell-group",{attrs:{inset:""}},[i("van-cell",{staticClass:"cell-title",attrs:{title:"账户名"}}),i("van-field",{attrs:{placeholder:"请输入账户名"},model:{value:t.classificationForm.typeName,callback:function(e){t.$set(t.classificationForm,"typeName",e)},expression:"classificationForm.typeName"}}),i("van-cell",{attrs:{center:"",icon:"photo-o",title:"图标"},on:{click:function(e){return t.$router.replace("/selectClassificationFormIcon?typeLevel="+t.$route.query.typeLevel+"&typeDifference="+t.$route.query.typeDifference+"&typeParentId="+t.$route.query.typeParentId)}},scopedSlots:t._u([{key:"right-icon",fn:function(){return[t.iconFlag?i("svg-icon",{staticClass:"business-icon",attrs:{"icon-class":t.classificationForm.typeIcon||""}}):t._e(),i("van-icon",{attrs:{name:"arrow"}})]},proxy:!0}])}),i("van-cell",{attrs:{icon:"label-o",title:"备注"}}),i("van-field",{attrs:{rows:"2",autosize:"",type:"textarea",maxlength:"200","show-word-limit":"",placeholder:"请输入备注"},model:{value:t.classificationForm.remark,callback:function(e){t.$set(t.classificationForm,"remark",e)},expression:"classificationForm.remark"}})],1)],1)],1)},o=[],n=(i("99af"),i("9fb1")),c={name:"add",data:function(){return{typeParentName:"",classificationForm:{},iconFlag:!0,prefixTile:"新建"}},computed:{title:function(){var t="分类",e="0"===this.$route.query.typeLevel?"一级":"二级",i="0"===this.$route.query.typeDifference?"收入":"支出",a=this.prefixTile+e+i+t;return"1"===this.$route.query.typeLevel&&this.getLocal("typeParentName")?"".concat(a,"").concat(this.getLocal("typeParentName"),""):a}},mounted:function(){var t=this;this.getLocal("typeParentName")&&(this.typeParentName=this.getLocal("typeParentName")),this.$route.query.typeParentName&&(this.classificationForm.typeParentName=this.$route.query.typeParentName),this.$route.query.classificationId?(this.prefixTile="编辑",Object(n["c"])(this.$route.query.classificationId).then((function(e){t.classificationForm=e.data}))):(this.prefixTile="新增",this.getLocal("classificationForm")&&(this.classificationForm=this.getLocal("classificationForm"))),this.$route.query.iconName&&(this.iconFlag=!1,this.classificationForm.typeIcon=this.$route.query.iconName,this.iconFlag=!0)},methods:{handleAdd:function(){var t=this;this.classificationForm.typeName?this.classificationForm.typeIcon?this.classificationForm.id?Object(n["f"])(this.classificationForm).then((function(e){t.$toast("修改成功"),t.removeLocal("classificationForm"),t.classificationForm={},t.$router.go(-1)})):(this.classificationForm.typeLevel=this.$route.query.typeLevel,this.classificationForm.typeDifference=this.$route.query.typeDifference,this.classificationForm.typeParentId=this.$route.query.typeParentId,Object(n["a"])(this.classificationForm).then((function(e){t.$toast("新增成功"),t.removeLocal("classificationForm"),t.classificationForm={},t.$router.go(-1)}))):this.$toast("请选择分类图标"):this.$toast("请输入分类名称")}},destroyed:function(){this.setLocal("classificationForm",this.classificationForm)}},r=c,s=(i("552c"),i("2877")),l=Object(s["a"])(r,a,o,!1,null,"4d770394",null);e["default"]=l.exports}}]);