From d9b2c4b780340d2d2e8ca1a328034f19092fcddb Mon Sep 17 00:00:00 2001
From: wuxw <928255095@qq.com>
Date: 星期三, 10 七月 2019 17:57:08 +0800
Subject: [PATCH] 提交breadcrumb功能
---
WebService/src/main/resources/static/js/vc-core.js | 38 +++++++++++++++++++++++++++++++++++---
1 files changed, 35 insertions(+), 3 deletions(-)
diff --git a/WebService/src/main/resources/static/js/vc-core.js b/WebService/src/main/resources/static/js/vc-core.js
index 7fd7422..08bfd2f 100644
--- a/WebService/src/main/resources/static/js/vc-core.js
+++ b/WebService/src/main/resources/static/js/vc-core.js
@@ -4,8 +4,40 @@
@param vmOptions Vue鍙傛暟
**/
(function(vc,vmOptions){
+ console.log("vmOptions:",vmOptions);
+ vc.component = new Vue(vmOptions);
+})(window.vc,window.vc.vmOptions);
- var vm = new Vue(vmOptions);
- window.vc.component = vm;
-})(window.vc,window.vc.vmOptions);
\ No newline at end of file
+/**
+ vc鐩戝惉浜嬩欢
+**/
+(function(vc){
+ /**
+ 浜嬩欢鐩戝惉
+ **/
+ vc.on = function(_componentName,_value,_callback){
+ vc.component.$on(_componentName+'_'+_value,_callback);
+ };
+
+ /**
+ 浜嬩欢瑙﹀彂
+ **/
+ vc.emit = function(_componentName,_value,_param){
+ vc.component.$emit(_componentName+'_'+_value,_param);
+ };
+
+})(window.vc);
+
+/**
+ * vue瀵硅薄 鎵ц鍒濆鍖栨柟娉�
+ */
+(function(vc){
+ vc.initEvent.forEach(function(eventMethod){
+ eventMethod();
+ });
+ vc.initMethod.forEach(function(callback){
+ callback();
+ });
+})(window.vc);
+
--
Gitblit v1.8.0