You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
16 KiB
1 line
16 KiB
4 months ago
|
(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-5fce7663"],{"524f":function(t,e,n){"use strict";var r={components:{app:function(){return n.e("chunk-147b2ccc").then(n.bind(null,"739f"))},routine:function(){return n.e("chunk-4db24115").then(n.bind(null,"23b33"))},wechat:function(){return n.e("chunk-917eefda").then(n.bind(null,"1402"))},work:function(){return n.e("chunk-144127b6").then(n.bind(null,"629a"))}}},u=n("2a95"),o=n("e069"),c=n("b6bd"),i=n("2f62");function a(t){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function s(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function d(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?s(Object(n),!0).forEach((function(e){f(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function f(t,e,n){return(e=function(t){var e=function(t,e){if("object"!=a(t)||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e||"default");if("object"!=a(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==a(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var l={name:"fromSubmit",mixins:[r],components:{useComponent:function(){return n.e("chunk-95da0e3c").then(n.bind(null,"05f7"))}},provide:function(){return{type:this.type,guideButton:this.guideButton}},props:{rules:{type:Array,default:function(){return[]}},validate:{type:Object,default:function(){return{}}},butName:{type:String,default:"提交"},field:{type:String,default:function(){return""+Math.random()}},url:{type:String,default:""},method:{type:String,default:"POST"},buttonHide:{type:Boolean,default:!0},on:{type:Object,default:function(){return{}}}},data:function(){return{submitValue:{},disabled:!1,loading:!1,errorsValidate:[],guideTitle:this.$parent.title,type:this.$parent.typeMole||this.$parent.type,guideShow:!1}},computed:{guideButton:function(){return["app","wechat","work"].includes(this.type)}},watch:{rules:{handler:function(){this.submitValue=this.getRuleValue(this.rules)},deep:!0}},mounted:function(){var t=this;this.submitValue=this.getRuleValue(this.rules),this.setCopyrightShow({value:!1}),this.bus.$on("settingGuideShow",(function(){t.guideShow=!0})),this.$once("hook:beforeDestroy",(function(){t.setCopyrightShow({value:!0}),t.bus.$off("settingGuideShow")}))},destroyed:function(){this.setCopyrightShow({value:!0})},methods:d(d({},Object(i.d)("admin/layout",["setCopyrightShow","isMobile","menuCollapse"])),{},{changeValue:function(t){this.submitValue[t.field]=t.value,this.rules=this.setRuleValue(this.rules,t.field,t.value)},setRuleValue:function(t,e,n){var r=this;return t.map((function(t){void 0!==t.field&&t.field===e&&(t.value=n),"object"===a(t.options)&&t.options.map((function(t){void 0!==t.componentsModel&&(t.componentsModel=r.setRuleValue(t.componentsModel,e,n))})),"object"===a(t.control)&&t.control.map((function(t){void 0!==t.componentsModel&&(t.componentsModel=r.setRuleValue(t.componentsModel,e,n))})),"object"===a(t.componentsModel)&&(t.componentsModel=r.setRuleValue(t.componentsModel,e,n))})),t},getRuleValue:function(t){var e=this,n={};return t.map((function(t){if(void 0!==t.field&&(n[t.field]=t.value),"object"===a(t.options)&&t.options.map((function(t){if(void 0!==t.componentsModel){var r=e.getRuleValue(t.componentsModel);Object.assign(n,r)}})),"object"===a(t.control)&&t.control.map((function(t){if(void 0!==t.componentsModel){var r=e.getRuleValue(t.componentsModel);Object.assign(n,r)}})),"object"===a(t.componentsModel)){var r=e.get
|