Procházet zdrojové kódy

增加添加访客记录流程页面

duckweed před 6 roky
rodič
revize
90107a6e57

+ 15 - 15
WebService/src/main/java/com/java110/web/core/VcCreateProcessor.java

@@ -72,7 +72,7 @@ public class VcCreateProcessor extends AbstractElementTagProcessor {
 
 
             js = dealJs(js, tag);
             js = dealJs(js, tag);
             js = dealJsAddComponentCode(js, tag);
             js = dealJsAddComponentCode(js, tag);
-            js = "<script type=\"text/javascript\" "+DIV_PROPERTY_COMPONENT+"=\""+componentName+"\">//<![CDATA[ \n" + js + "//]]>\n</script>";
+            js = "<script type=\"text/javascript\" " + DIV_PROPERTY_COMPONENT + "=\"" + componentName + "\">//<![CDATA[ \n" + js + "//]]>\n</script>";
             htmlModel.add(modelFactory.createText(js));
             htmlModel.add(modelFactory.createText(js));
         }
         }
 
 
@@ -116,11 +116,11 @@ public class VcCreateProcessor extends AbstractElementTagProcessor {
             return js;
             return js;
         }
         }
 
 
-        tmpProTypes = tmpProTypes.contains("\r")? tmpProTypes.replace("\r", "") : tmpProTypes;
+        tmpProTypes = tmpProTypes.contains("\r") ? tmpProTypes.replace("\r", "") : tmpProTypes;
 
 
         String[] tmpType = tmpProTypes.contains("\n")
         String[] tmpType = tmpProTypes.contains("\n")
-                        ? tmpProTypes.split("\n")
-                        : tmpProTypes.split(",");
+                ? tmpProTypes.split("\n")
+                : tmpProTypes.split(",");
         StringBuffer propsJs = new StringBuffer("\nvar $props = {};\n");
         StringBuffer propsJs = new StringBuffer("\nvar $props = {};\n");
         for (String type : tmpType) {
         for (String type : tmpType) {
             if (StringUtils.isEmpty(type) || !type.contains(":")) {
             if (StringUtils.isEmpty(type) || !type.contains(":")) {
@@ -140,9 +140,9 @@ public class VcCreateProcessor extends AbstractElementTagProcessor {
                 throw new TemplateProcessingException("组件[" + componentName + "]未配置组件属性" + attrKey);
                 throw new TemplateProcessingException("组件[" + componentName + "]未配置组件属性" + attrKey);
             }
             }
             String vcType = tag.getAttributeValue(attrKey);
             String vcType = tag.getAttributeValue(attrKey);
-            if(!tag.hasAttribute(attrKey) && types[1].contains("=")) {
+            if (!tag.hasAttribute(attrKey) && types[1].contains("=")) {
                 vcType = dealJsPropTypesDefault(types[1]);
                 vcType = dealJsPropTypesDefault(types[1]);
-            }else if (types[1].contains("vc.propTypes.string")) {
+            } else if (types[1].contains("vc.propTypes.string")) {
                 vcType = "'" + vcType + "'";
                 vcType = "'" + vcType + "'";
             }
             }
             propsJs.append("$props." + attrKey + "=" + vcType + ";\n");
             propsJs.append("$props." + attrKey + "=" + vcType + ";\n");
@@ -160,16 +160,16 @@ public class VcCreateProcessor extends AbstractElementTagProcessor {
     }
     }
 
 
 
 
-    private String dealJsPropTypesDefault(String typeValue){
-         int startPos = typeValue.indexOf("=") + 1;
-         int endPos = typeValue.length();
-         if(typeValue.contains(",")){
-             endPos = typeValue.indexOf(",");
-         }else if(typeValue.contains("//")){
-             endPos = typeValue.indexOf("//");
-         }
+    private String dealJsPropTypesDefault(String typeValue) {
+        int startPos = typeValue.indexOf("=") + 1;
+        int endPos = typeValue.length();
+        if (typeValue.contains(",")) {
+            endPos = typeValue.indexOf(",");
+        } else if (typeValue.contains("//")) {
+            endPos = typeValue.indexOf("//");
+        }
 
 
-         return typeValue.substring(startPos,endPos);
+        return typeValue.substring(startPos, endPos);
     }
     }
 
 
     /**
     /**

+ 3 - 3
WebService/src/main/resources/components/appPackage/view-app-info/viewAppInfo.html

@@ -4,11 +4,11 @@
             <div class="ibox-title">
             <div class="ibox-title">
                 <h5>应用信息</h5>
                 <h5>应用信息</h5>
                 <div class="ibox-tools" style="top:10px;">
                 <div class="ibox-tools" style="top:10px;">
-                    <button type="button" v-if="viewAppInfo.index != 2" class="btn btn-primary btn-sm" style="margin-right:10px;"  v-on:click="_openSelectAppInfoModel()">
-                        <i class="glyphicon glyphicon-search"></i> 选择应用</button>
+<!--                    <button type="button" v-if="viewAppInfo.index != 2" class="btn btn-primary btn-sm" style="margin-right:10px;"  v-on:click="_openSelectAppInfoModel()">-->
+<!--                        <i class="glyphicon glyphicon-search"></i> 选择应用</button>-->
 
 
                     <button type="button" v-if="viewAppInfo.index != 2 && viewAppInfo.needShowAddAppButton== 'true'" class="btn btn-primary btn-sm" v-on:click="_openAddAppInfoModel()">
                     <button type="button" v-if="viewAppInfo.index != 2 && viewAppInfo.needShowAddAppButton== 'true'" class="btn btn-primary btn-sm" v-on:click="_openAddAppInfoModel()">
-                        <i class="glyphicon glyphicon-plus"></i> 添加应用</button>
+                        <i class="glyphicon glyphicon-plus"></i> 添加访客</button>
                 </div>
                 </div>
             </div>
             </div>
             <div class="ibox-content">
             <div class="ibox-content">

+ 7 - 9
WebService/src/main/resources/components/visitInfoPackage/add-visit-space/addVisitSpace.html

@@ -5,27 +5,25 @@
     </div>
     </div>
 
 
     <!-- 选择 应用信息 -->
     <!-- 选择 应用信息 -->
-    <div v-if="hireParkingSpaceInfo.index == 0">
+    <div v-if="newVisitInfo.index == 0">
 
 
         <!-- 选择停车位 -->
         <!-- 选择停车位 -->
-        <vc:create name="viewSelectParkingSpace"
+        <vc:create name="viewVisitInfo"
                    callBackComponent="addVisitSpace"
                    callBackComponent="addVisitSpace"
                    callBackFunction="notify"
                    callBackFunction="notify"
         ></vc:create>
         ></vc:create>
     </div>
     </div>
-    <div v-if="hireParkingSpaceInfo.index == 1">
+    <div v-if="newVisitInfo.index == 1">
         <vc:create name="viewOwnerInfo"
         <vc:create name="viewOwnerInfo"
                    callBackListener="addVisitSpace"
                    callBackListener="addVisitSpace"
                    callBackFunction="notify"
                    callBackFunction="notify"
         ></vc:create>
         ></vc:create>
     </div>
     </div>
-    <div v-if="hireParkingSpaceInfo.index == 2">
+    <div v-if="newVisitInfo.index == 2">
         <vc:create name="addCar"
         <vc:create name="addCar"
                    callBackComponent="addVisitSpace"
                    callBackComponent="addVisitSpace"
                    callBackFunction="notify"
                    callBackFunction="notify"
-        >
-
-        </vc:create>
+        ></vc:create>
     </div>
     </div>
 
 
 
 
@@ -34,11 +32,11 @@
         <div class="col-md-10"></div>
         <div class="col-md-10"></div>
         <div class="col-md-2 " style="margin-bottom:10px; text-align:right">
         <div class="col-md-2 " style="margin-bottom:10px; text-align:right">
             <button type="button" class="btn btn-secondary" v-on:click="_prevStep()">上一步</button>
             <button type="button" class="btn btn-secondary" v-on:click="_prevStep()">上一步</button>
-            <button v-if="hireParkingSpaceInfo.index != 3" type="button" class="btn btn-primary"
+            <button v-if="newVisitInfo.index != 3" type="button" class="btn btn-primary"
                     style="margin-left:10px;"
                     style="margin-left:10px;"
                     v-on:click="_nextStep()">下一步
                     v-on:click="_nextStep()">下一步
             </button>
             </button>
-            <button v-if="hireParkingSpaceInfo.index == 3" type="button" class="btn btn-primary"
+            <button v-if="newVisitInfo.index == 3" type="button" class="btn btn-primary"
                     style="margin-left:10px;"
                     style="margin-left:10px;"
                     v-on:click="_addVisitFinish()">出租
                     v-on:click="_addVisitFinish()">出租
             </button>
             </button>

+ 31 - 42
WebService/src/main/resources/components/visitInfoPackage/add-visit/addVisit.html

@@ -1,57 +1,46 @@
-<div id = "addAppModel" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true" >
+<div id="addNewVisitModel" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel"
+     aria-hidden="true">
     <div class="modal-dialog modal-lg">
     <div class="modal-dialog modal-lg">
         <div class="modal-content">
         <div class="modal-content">
             <div class="modal-body">
             <div class="modal-body">
-                <h3 class="m-t-none m-b ">添加应用</h3>
+                <h3 class="m-t-none m-b ">添加访客</h3>
                 <div class="ibox-content">
                 <div class="ibox-content">
                     <div>
                     <div>
                         <div>
                         <div>
-                            <!--<div class="form-group row">
-                                <label class="col-sm-2 col-form-label">楼名称</label>
-                                <div class="col-sm-10"><input v-model="addFloorInfo.name" type="text" placeholder="必填,请填写名称" class="form-control"></div>
-                            </div>
+                         
+
                             <div class="form-group row">
                             <div class="form-group row">
-                                <label class="col-sm-2 col-form-label">楼编号</label>
-                                <div class="col-sm-10"><input v-model="addFloorInfo.floorNum" type="email" placeholder="必填,请填写编号" class="form-control"></div>
+                                <label class="col-sm-2 col-form-label">访客姓名</label>
+                                <div class="col-sm-10">
+                                    <input v-model="viewVisitInfo.name" type="text" placeholder="必填,请填写应用名称"
+                                           class="form-control">
+                                </div>
                             </div>
                             </div>
                             <div class="form-group row">
                             <div class="form-group row">
-                                <label class="col-sm-2 col-form-label">备注</label>
-                                <div class="col-sm-10"><input v-model="addFloorInfo.remark" type="tel" placeholder="可填,请填写备注" class="form-control"></div>
-                            </div>-->
-
+                                <label class="col-sm-2 col-form-label">性别</label>
+                                <div class="col-sm-10">
+                                    <select class="custom-select" v-model="viewVisitInfo.visitGender">
+                                        <option selected  disabled value="">必填,请选择性别</option>
+                                        <option value="0">男</option>
+                                        <option value="1">女</option>
+                                    </select>
+                                </div>
+                            </div>
                             <div class="form-group row">
                             <div class="form-group row">
-         <label class="col-sm-2 col-form-label">应用名称</label>
-         <div class="col-sm-10">
-           <input v-model="addAppInfo.name"                   type="text" placeholder="必填,请填写应用名称" class="form-control">
-         </div>
-</div>
-<div class="form-group row">
-         <label class="col-sm-2 col-form-label">秘钥</label>
-         <div class="col-sm-10">
-           <input v-model="addAppInfo.securityCode"                   type="text" placeholder="选填,请填写秘钥" class="form-control">
-         </div>
-</div>
-<div class="form-group row">
-         <label class="col-sm-2 col-form-label">白名单</label>
-         <div class="col-sm-10">
-           <input v-model="addAppInfo.whileListIp"                   type="text" placeholder="选填,请填写白名单" class="form-control">
-         </div>
-</div>
-<div class="form-group row">
-         <label class="col-sm-2 col-form-label">黑名单</label>
-         <div class="col-sm-10">
-           <input v-model="addAppInfo.blackListIp"                   type="text" placeholder="选填,请填写黑名单" class="form-control">
-         </div>
-</div>
-<div class="form-group row">
-         <label class="col-sm-2 col-form-label">备注</label>
-         <div class="col-sm-10">
-<textarea  placeholder="选填,请填写备注" class="form-control" v-model="addAppInfo.remark"></textarea>         </div>
-</div>
+                                <label class="col-sm-2 col-form-label">访客联系方式</label>
+                                <div class="col-sm-10">
+                                    <input v-model="viewVisitInfo.phoneNumber" type="text" placeholder="必填,请填写访客联系方式"
+                                           class="form-control">
+                                </div>
+                            </div>
 
 
                             <div class="ibox-content">
                             <div class="ibox-content">
-                                <button class="btn btn-primary float-right" type="button" v-on:click="saveAppInfo()" ><i class="fa fa-check"></i>&nbsp;保存</button>
-                                <button type="button" class="btn btn-warning float-right" style="margin-right:20px;" data-dismiss="modal">取消</button>
+                                <button class="btn btn-primary float-right" type="button" v-on:click="_addNewVisitInfo()"><i
+                                        class="fa fa-check"></i>&nbsp;保存
+                                </button>
+                                <button type="button" class="btn btn-warning float-right" style="margin-right:20px;"
+                                        data-dismiss="modal">取消
+                                </button>
                             </div>
                             </div>
                         </div>
                         </div>
                     </div>
                     </div>

+ 46 - 91
WebService/src/main/resources/components/visitInfoPackage/add-visit/addVisit.js

@@ -1,132 +1,87 @@
-(function (vc) {
+/**
+ 权限组
+ **/
+(function(vc){
 
 
     vc.extends({
     vc.extends({
         propTypes: {
         propTypes: {
             callBackListener: vc.propTypes.string, //父组件名称
             callBackListener: vc.propTypes.string, //父组件名称
             callBackFunction: vc.propTypes.string //父组件监听方法
             callBackFunction: vc.propTypes.string //父组件监听方法
         },
         },
-        data: {
-            addAppInfo: {
-                appId: '',
-                name: '',
-                securityCode: '',
-                whileListIp: '',
-                blackListIp: '',
-                remark: '',
-
+        data:{
+            viewVisitInfo:{
+                index:0,
+                flowComponent:'visit',
+                needShowAddAppButton:'true'
             }
             }
         },
         },
-        _initMethod: function () {
+        _initMethod:function(){
 
 
         },
         },
-        _initEvent: function () {
-            vc.on('addApp', 'openAddAppModal', function () {
-                $('#addAppModel').modal('show');
+        _initEvent:function(){
+            vc.on('addVisit','openAddVisitAppModal',function(_app){
+                $("#addNewVisitModel").modal("show");
             });
             });
+
+            // vc.on('viewVisitInfo', 'onIndex', function(_index){
+            //     vc.component.viewVisitInfo.index = _index;
+            // });
+
         },
         },
-        methods: {
+        methods:{
             addAppValidate() {
             addAppValidate() {
                 return vc.validate.validate({
                 return vc.validate.validate({
-                    addAppInfo: vc.component.addAppInfo
+                    viewVisitInfo: vc.component.viewVisitInfo
                 }, {
                 }, {
-                    'addAppInfo.name': [
+                    'viewVisitInfo.name': [
                         {
                         {
                             limit: "required",
                             limit: "required",
                             param: "",
                             param: "",
-                            errInfo: "应用名称不能为空"
-                        },
-                        {
-                            limit: "maxin",
-                            param: "2,50",
-                            errInfo: "应用名称必须在2至50字符之间"
-                        },
-                    ],
-                    'addAppInfo.securityCode': [
-                        {
-                            limit: "maxLength",
-                            param: "64",
-                            errInfo: "秘钥太长超过64位"
-                        },
+                            errInfo: "访客姓名不能为空"
+                        }
                     ],
                     ],
-                    'addAppInfo.whileListIp': [
+                    'viewVisitInfo.visitGender': [
                         {
                         {
-                            limit: "maxLength",
-                            param: "200",
-                            errInfo: "白名单内容不能超过200"
-                        },
+                            limit: "required",
+                            param: "",
+                            errInfo: "访客性别不能为空"
+                        }
                     ],
                     ],
-                    'addAppInfo.blackListIp': [
+                    'viewVisitInfo.phoneNumber': [
                         {
                         {
-                            limit: "maxLength",
-                            param: "200",
-                            errInfo: "黑名单内容不能超过200"
+                            limit: "required",
+                            param: "",
+                            errInfo: "访客手机号不能为空"
                         },
                         },
-                    ],
-                    'addAppInfo.remark': [
                         {
                         {
-                            limit: "maxLength",
-                            param: "200",
-                            errInfo: "备注内容不能超过200"
+                            limit: "phone",
+                            param: "",
+                            errInfo: "访客手机号不正确"
                         },
                         },
-                    ],
+                    ]
+
 
 
 
 
                 });
                 });
             },
             },
-            saveAppInfo: function () {
+
+            _addNewVisitInfo(){
                 if (!vc.component.addAppValidate()) {
                 if (!vc.component.addAppValidate()) {
                     vc.message(vc.validate.errInfo);
                     vc.message(vc.validate.errInfo);
 
 
                     return;
                     return;
                 }
                 }
-
                 vc.component.addAppInfo.communityId = vc.getCurrentCommunity().communityId;
                 vc.component.addAppInfo.communityId = vc.getCurrentCommunity().communityId;
-
-                //不提交数据将数据 回调给侦听处理
-                if (vc.notNull($props.callBackListener)) {
-                    vc.emit($props.callBackListener, $props.callBackFunction, vc.component.addAppInfo);
-                    $('#addAppModel').modal('hide');
-                    return;
-                }
-
-                vc.http.post(
-                    'addApp',
-                    'save',
-                    JSON.stringify(vc.component.addAppInfo),
-                    {
-                        emulateJSON: true
-                    },
-                    function (json, res) {
-                        //vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
-                        if (res.status == 200) {
-                            //关闭model
-                            $('#addAppModel').modal('hide');
-                            vc.component.clearAddAppInfo();
-                            vc.emit('appManage', 'listApp', {});
-
-                            return;
-                        }
-                        vc.message(json);
-
-                    },
-                    function (errInfo, error) {
-                        console.log('请求失败处理');
-
-                        vc.message(errInfo);
-
-                    });
+                vc.emit($props.callBackListener, $props.callBackFunction, vc.component.viewVisitInfo);
+                $('#addAppModel').modal('hide');
+            },
+            _openAddAppInfoModel(){
+                vc.emit('addApp','openAddAppModal',{});
             },
             },
-            clearAddAppInfo: function () {
-                vc.component.addAppInfo = {
-                    name: '',
-                    securityCode: '',
-                    whileListIp: '',
-                    blackListIp: '',
-                    remark: '',
+            _loadAppInfoData:function(){
 
 
-                };
             }
             }
         }
         }
     });
     });
 
 
-})(window.vc);
+})(window.vc);

+ 20 - 17
WebService/src/main/resources/components/visitInfoPackage/view-visit-info/viewVisitInfo.html

@@ -2,12 +2,12 @@
     <div class="col-lg-12">
     <div class="col-lg-12">
         <div class="ibox ">
         <div class="ibox ">
             <div class="ibox-title">
             <div class="ibox-title">
-                <h5>应用信息</h5>
+                <h5>新增访客</h5>
                 <div class="ibox-tools" style="top:10px;">
                 <div class="ibox-tools" style="top:10px;">
-                    <button type="button" v-if="viewAppInfo.index != 2" class="btn btn-primary btn-sm" style="margin-right:10px;"  v-on:click="_openSelectAppInfoModel()">
-                        <i class="glyphicon glyphicon-search"></i> 选择访客</button>
+<!--                    <button type="button" v-if="viewVisitInfo.index != 2" class="btn btn-primary btn-sm" style="margin-right:10px;"  v-on:click="_openSelectAppInfoModel()">-->
+<!--                        <i class="glyphicon glyphicon-search"></i> 选择访客</button>-->
 
 
-                    <button type="button" v-if="viewAppInfo.index != 2 && viewAppInfo.needShowAddAppButton== 'true'" class="btn btn-primary btn-sm" v-on:click="_openAddAppInfoModel()">
+                    <button type="button" v-if="viewVisitInfo.index == 0 && viewVisitInfo.needShowAddAppButton== 'true'" class="btn btn-primary btn-sm" v-on:click="_openAddVisitInfoModel()">
                         <i class="glyphicon glyphicon-plus"></i> 添加访客</button>
                         <i class="glyphicon glyphicon-plus"></i> 添加访客</button>
                 </div>
                 </div>
             </div>
             </div>
@@ -16,19 +16,19 @@
                     <div class="col-sm-4">
                     <div class="col-sm-4">
                         <div class="form-group">
                         <div class="form-group">
                             <label class="col-form-label" >访客ID:</label>
                             <label class="col-form-label" >访客ID:</label>
-                            <label class="">{{viewAppInfo.appId}}</label>
+                            <label class="">{{viewVisitInfo.appId}}</label>
                         </div>
                         </div>
                     </div>
                     </div>
                     <div class="col-sm-4">
                     <div class="col-sm-4">
                         <div class="form-group">
                         <div class="form-group">
                             <label class="col-form-label">访客姓名:</label>
                             <label class="col-form-label">访客姓名:</label>
-                            <label class="">{{viewAppInfo.name}}</label>
+                            <label class="">{{viewVisitInfo.name}}</label>
                         </div>
                         </div>
                     </div>
                     </div>
                     <div class="col-sm-4">
                     <div class="col-sm-4">
                         <div class="form-group">
                         <div class="form-group">
                             <label class="col-form-label" >访客联系方式:</label>
                             <label class="col-form-label" >访客联系方式:</label>
-                            <label class="">{{viewAppInfo.securityCode}}</label>
+                            <label class="">{{viewVisitInfo.securityCode}}</label>
                         </div>
                         </div>
                     </div>
                     </div>
 
 
@@ -39,13 +39,13 @@
                     <div class="col-sm-4">
                     <div class="col-sm-4">
                         <div class="form-group">
                         <div class="form-group">
                             <label class="col-form-label" >访客性别:</label>
                             <label class="col-form-label" >访客性别:</label>
-                            <label class="">{{viewAppInfo.whileListIp}}</label>
+                            <label class="">{{viewVisitInfo.whileListIp}}</label>
                         </div>
                         </div>
                     </div>
                     </div>
                     <div class="col-sm-4">
                     <div class="col-sm-4">
                         <div class="form-group">
                         <div class="form-group">
                             <label class="col-form-label" >访客到访事由:</label>
                             <label class="col-form-label" >访客到访事由:</label>
-                            <label class="">{{viewAppInfo.blackListIp}}</label>
+                            <label class="">{{viewVisitInfo.blackListIp}}</label>
                         </div>
                         </div>
                     </div>
                     </div>
 <!--                   viewVisitInfo-->
 <!--                   viewVisitInfo-->
@@ -54,14 +54,17 @@
         </div>
         </div>
     </div>
     </div>
 
 
-    <vc:create name="addApp"
-               callBackListener="viewAppInfo"
-               callBackFunction="chooseApp"
-    ></vc:create>
-
+<!--    <vc:create name="addApp"-->
+<!--               callBackListener="viewVisitInfo"-->
+<!--               callBackFunction="chooseApp"-->
+<!--    ></vc:create>-->
 
 
-    <vc:create name="chooseApp"
-               emitChooseApp="viewAppInfo"
-               emitLoadData="viewAppInfo"
+    <vc:create name="addVisit"
+               callBackListener="viewVisitInfo"
+               callBackFunction="addNewVisit"
     ></vc:create>
     ></vc:create>
+<!--    <vc:create name="chooseApp"-->
+<!--               emitChooseApp="viewVisitInfo"-->
+<!--               emitLoadData="viewVisitInfo"-->
+<!--    ></vc:create>-->
 </div>
 </div>

+ 9 - 19
WebService/src/main/resources/components/visitInfoPackage/view-visit-info/viewVisitInfo.js

@@ -1,25 +1,13 @@
-/**
-    权限组
-**/
+
 (function(vc){
 (function(vc){
 
 
     vc.extends({
     vc.extends({
-        propTypes: {
-           callBackListener:vc.propTypes.string, //父组件名称
-           callBackFunction:vc.propTypes.string, //父组件监听方法
-           needShowAddAppButton:vc.propTypes.string = 'true' // 是否显示添加应用button
-        },
+
         data:{
         data:{
-            viewAppInfo:{
+            viewVisitInfo:{
                 index:0,
                 index:0,
                 flowComponent:'visit',
                 flowComponent:'visit',
-                appId:"",
-                name:"",
-                securityCode:"",
-                whileListIp:"",
-                blackListIp:"",
-                remark:"",
-                needShowAddAppButton:$props.needShowAddAppButton
+                needShowAddAppButton:'true'
             }
             }
         },
         },
         _initMethod:function(){
         _initMethod:function(){
@@ -27,7 +15,7 @@
             vc.component._loadAppInfoData();
             vc.component._loadAppInfoData();
         },
         },
         _initEvent:function(){
         _initEvent:function(){
-            vc.on('viewAppInfo','chooseApp',function(_app){
+            vc.on('viewVisitInfo','addNewVisit',function(_app){
                 vc.copyObject(_app, vc.component.viewAppInfo);
                 vc.copyObject(_app, vc.component.viewAppInfo);
                 vc.emit($props.callBackListener,$props.callBackFunction,vc.component.viewAppInfo);
                 vc.emit($props.callBackListener,$props.callBackFunction,vc.component.viewAppInfo);
             });
             });
@@ -36,6 +24,7 @@
                 vc.component.viewAppInfo.index = _index;
                 vc.component.viewAppInfo.index = _index;
             });
             });
 
 
+
         },
         },
         methods:{
         methods:{
 
 
@@ -43,8 +32,9 @@
                 alert("打开查询访客模态框");
                 alert("打开查询访客模态框");
                 // vc.emit('chooseApp','openChooseAppModel',{});
                 // vc.emit('chooseApp','openChooseAppModel',{});
             },
             },
-            _openAddAppInfoModel(){
-                // vc.emit('addApp','openAddAppModal',{});
+            _openAddVisitInfoModel(){
+                vc.emit('addVisit','openAddVisitAppModal',{});
+                // $("#addNewVisitModel").model("show");
             },
             },
             _loadAppInfoData:function(){
             _loadAppInfoData:function(){
 
 

+ 1 - 1
WebService/src/main/resources/components/visitInfoPackage/visit-manage/visitManage.js

@@ -56,7 +56,7 @@
                 );
                 );
             },
             },
             _openAddVisitModal: function () {
             _openAddVisitModal: function () {
-                vc.jumpToPage("/flow/viewVisitInfo")
+                vc.jumpToPage("/flow/addNewOneVisit")
                 // vc.emit('addApp','openAddAppModal',{});
                 // vc.emit('addApp','openAddAppModal',{});
             },
             },
             _openEditVisitModel: function (_app) {
             _openEditVisitModel: function (_app) {

+ 4 - 0
WebService/src/main/resources/static/js/vc-core.js

@@ -17,14 +17,18 @@
             事件监听
             事件监听
      **/
      **/
     vc.on = function(_componentName,_value,_callback){
     vc.on = function(_componentName,_value,_callback){
+        // console.log(_componentName+'_'+_value+" 进入");
         vc.component.$on(_componentName+'_'+_value,_callback);
         vc.component.$on(_componentName+'_'+_value,_callback);
+        // console.log(_componentName+'_'+_value);
     };
     };
 
 
     /**
     /**
             事件触发
             事件触发
     **/
     **/
     vc.emit = function(_componentName,_value,_param){
     vc.emit = function(_componentName,_value,_param){
+        console.log(_componentName+'_'+_value+" 进入");
         vc.component.$emit(_componentName+'_'+_value,_param);
         vc.component.$emit(_componentName+'_'+_value,_param);
+        console.log(_componentName+'_'+_value);
     };
     };
 
 
 })(window.vc);
 })(window.vc);

+ 38 - 0
WebService/src/main/resources/views/addNewOneVisit.html

@@ -0,0 +1,38 @@
+<!DOCTYPE html>
+<html lang="en"
+      xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:th="http://www.thymeleaf.org"
+      xmlns:vc="http://www.thymeleaf.org">
+<head>
+    <meta charset="UTF-8"/>
+    <title>新增访客|java110</title>
+    <vc:create name="commonTop"></vc:create>
+    <link href="/css/jquery.step.css" rel="stylesheet"/>
+    <script src="/js/jquery.step.min.js" ></script>
+</head>
+<body>
+<vc:create name="bodyTop"></vc:create>
+<div id="wrapper">
+    <vc:create name="menu"></vc:create>
+
+
+    <div id="page-wrapper" class="gray-bg dashbard-1">
+        <div class="row border-bottom">
+            <vc:create name="nav"></vc:create>
+        </div>
+        <div class="wrapper wrapper-content" style="padding-bottom: 0px;">
+            <vc:create name="breadcrumb"></vc:create>
+        </div>
+        <!-- id="component" -->
+        <div class="wrapper wrapper-content animated fadeInRight">
+            <vc:create name="addVisitSpace"></vc:create>
+        </div>
+
+        <vc:create name="copyright"></vc:create>
+
+    </div>
+</div>
+
+<vc:create name="commonBottom"></vc:create>
+</body>
+</html>