y595705120 1 ماه پیش
والد
کامیت
77b546ea59

+ 1 - 1
index.html

@@ -8,7 +8,7 @@
     <meta http-equiv="X-UA-Compatible" content="IE=9;IE=EDGE">
     <link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
     <!-- <meta name="referrer" content="origin"> -->
-    <script type="text/javascript" src="./static/config.js"></script>
+    <script type="text/javascript" src="./static/config.js?id=2"></script>
     <title>三明市城市建设项目服务中心</title>
   </head>
   <body style="margin:0px;">

+ 3 - 1
src/containers/center/market/index.vue

@@ -205,7 +205,7 @@
     </el-dialog>
 
 
-    <el-dialog :title="promise.showType==1?'温馨提示':'承诺书'" class="fc tc" :visible.sync="commitmentDialog">
+    <el-dialog :title="promiseType[promise.showType]" class="fc tc" :visible.sync="commitmentDialog">
         <div>
           <div>
             <div class="commitment-header"> {{promise.title}} </div>
@@ -302,6 +302,7 @@
         showExample: false,
         showImgDialog: false,
         showAllRzcodeDialog: false,
+        promiseType:{1:'温馨提示', 2:'承诺书',  3:'委 托 书'},
         buyForm: {
           marks: '',
           rzCode: '',
@@ -445,6 +446,7 @@
           let item = this.promiseList[i];
           if( name == item.type || item.type == type ){
             this.promise = Object.assign( this.promise, item);
+            console.log("promise", this.promise);
             isMatch = true
           } else if( !isMatch && item.type == '默认类型'){
             this.promise = Object.assign( this.promise, item);

+ 36 - 31
src/containers/center/market/trainIndex.vue

@@ -194,41 +194,19 @@
 
 
 
-    <el-dialog title="承诺书" class="fc tc" :visible.sync="commitmentDialog">
-
+    <el-dialog :title="promiseType[promise.showType]" class="fc tc" :visible.sync="commitmentDialog">
         <div>
-          <div v-if="type=='施工现场专业人员'">
-            <div class="commitment-header"> 致:三明市城市建设项目服务中心 </div>
+          <div>
+            <div class="commitment-header"> {{promise.title}} </div>
             <div class="tl commitment">
-                {{promise.promise_edu}}
+                {{promise.content}}
             </div>
             <div class="commitment-footer">
-              特此诺书!
-            </div>
-          </div>
-
-          <div v-else-if="type=='建筑施工企业特种作业人员'">
-            <div class="tl commitment">
-              {{promise.promise_special}}
-            </div>
-
-          </div>
-
-
-          <div v-else-if="type=='园林绿化技术工人'">
-            <div class="tl commitment">
-              {{promise.promise_plant}}
-            </div>
-          </div>
-
-          <div v-else>
-            <div class="tl commitment">
-              {{promise.promise_other}}
+              {{promise.footer}}
             </div>
           </div>
 
-
-          <div class="tl commitment-content mt20">
+          <div class="tl commitment-content mt20" v-if="promise.showType==2">
             <el-radio-group v-model="isCommitment">
               <el-row class="mt10">
                 <el-radio :label="true">本人作出上述承诺</el-radio>
@@ -239,12 +217,16 @@
             </el-radio-group>
           </div>
 
-          <span slot="footer" class="dialog-footer">
+          <span slot="footer" class="dialog-footer" v-if="promise.showType==2">
             <el-button @click="commitmentDialog = false">取 消</el-button>
             <el-button type="primary" :disabled="isCommitment?false:true" @click="buyCourseDialog=true">确 定</el-button>
           </span>
-        </div>
 
+          <div slot="footer" class="dialog-footer mt20" v-else>
+            <el-button @click="commitmentDialog = false">取 消</el-button>
+            <el-button type="primary"  @click="buyCourseDialog=true">继续购买</el-button>
+          </div>
+        </div>
     </el-dialog>
 
     <el-dialog append-to-body close-on-click-modal :visible.sync="showImgDialog" style="margin-top: 0px;" :width="width">
@@ -288,6 +270,8 @@
         width: "",
         type: '',
         list: [],
+        promiseType:{1:'温馨提示', 2:'承诺书',  3:'委 托 书'},
+        promiseList:[],
         nd: new Date().getFullYear()+'',
         ndList:[],
         allList:[],
@@ -407,6 +391,13 @@
         }
       }
     },
+    created(){
+      // 获取所有承诺书
+      httpServer("course.GetAllCoursePromise", {}).then((res) => {
+        if (res.code != 200) return;
+        this.promiseList = res.data.list;
+      });
+    },
     beforeDestroy() {
       if (this.timer) window.clearInterval(this.timer);
     },
@@ -483,13 +474,27 @@
       uploadBuyImg(url) {
         this.buyForm.buyImg = url;
       },
+      matchPromise( name ){
+        let type = this.type;
+        let isMatch = false
+        for( let i in this.promiseList){
+          let item = this.promiseList[i];
+          if( name == item.type || item.type == type ){
+            this.promise = Object.assign( this.promise, item);
+            console.log("promise", this.promise);
+            isMatch = true
+          } else if( !isMatch && item.type == '默认类型'){
+            this.promise = Object.assign( this.promise, item);
+          }
+        }
+      },
       goPay( item ) {
         this.buyForm = Object.assign(this.buyForm, item)
         this.buyForm.company = this.userInfo.company;
         this.buyForm.temp = item;
         this.buyForm.courseName = item.name;
         let isEdu = this.type == '施工现场专业人员';
-
+        this.matchPromise(item.name);
         // 绕开检查
         // this.stage = 2;
         // this.isCompanyPay = 1;

+ 1 - 13
src/containers/center/play/components/iCourseAnswerTest.vue

@@ -114,25 +114,13 @@
           answer2:'',
           answer3:'',
           answer4:'',
-        },
-        counter:{
-          1:150,
-          2:156,
-          3:149,
-          4:45
         }
       }
     },
-    props: ['info', 'extraXs', 'groupId'],
+    props: ['info', 'extraXs', 'groupId', 'counter'],
     mounted() {
       this.id = this.info.id || 0;
       this.index = this.extraXs.index1 || 0;
-
-      if ( this.groupId == 10){
-        this.counter = { 1:150, 2:156, 3:149,4:45}
-      }else{
-        this.counter = { 1:100, 2:400}
-      }
       this.loadAnswer();
     },
     watch: {

+ 16 - 1
src/containers/center/play/index.vue

@@ -79,7 +79,7 @@
         <el-dialog class="previewDialog" :visible.sync="testExamDalog"
           top="50px" width="1024px"
           @close="closeTestModel()">
-          <ICourseAnswerTest :info="info" :extraXs="extraXs" @updateExtraXs="updateExtraXs" :groupId="tpl.testGroupId"> </ICourseAnswerTest>
+          <ICourseAnswerTest :info="info" :extraXs="extraXs" @updateExtraXs="updateExtraXs" :counter="counter" :groupId="tpl.testGroupId"> </ICourseAnswerTest>
         </el-dialog>
       </div>
      </div>
@@ -145,6 +145,12 @@
         tpl:{},
         media:{},
         extraXs:{},
+        counter:{
+          1:150,
+          2:156,
+          3:149,
+          4:45,
+        },
         options:{
           controls:true,
           autoplay: true, // 如果true,浏览器准备好时开始回放。
@@ -235,7 +241,16 @@
           this.$message.errorMsg(" 完成学习才能专项练习", 2)
           return;
         }
+        let groupId = this.tpl.testGroupId
         this.testExamDalog = true;
+        if( groupId == 0 || groupId == 10) return;
+        httpServer('course.GetCourseExamInfo', {examId:groupId}).then( res=>{
+            if( res.code != 200) return;
+            this.counter[1] = res.data.judge||0;
+            this.counter[2] = res.data.single||0;
+            this.counter[3] = res.data.multi||0;
+            this.counter[4] = res.data.anli||0;
+        })
       },
       isStudyFinish(){
         let {getXs,totalXs} = this.info

+ 6 - 1
src/containers/center/setting/index.vue

@@ -132,7 +132,11 @@
             </el-form-item>
 
             <el-form-item label="最高学历" label-width='150px' class="mt30" prop="oldPass" >
-               <el-input placeholder="最高学历" v-model="userInfo.education " class="pass-input">
+              <el-select placeholder="选择学历" v-model="userInfo.education" class="pass-input" >
+                <el-option v-for="(item,index) in educationList" :value="item" :label="item" v-bind:key="index" />
+              </el-select>
+               <!-- <el-input placeholder="最高学历" v-model="userInfo.education " class="pass-input">
+                -->
                </el-input>
             </el-form-item>
 
@@ -242,6 +246,7 @@
         timer: false,
         count: 0,
         imgUrl:'',
+        educationList: window.baseConfig.educationList,
         passForm:{
           oldPass:'',
           newPass:'',

+ 5 - 3
src/containers/register/register.vue

@@ -47,13 +47,15 @@
 
             <span class="formver ng-scope" v-if="!is_ok_card(cardId)">
               <span class="p-ico ico-formver"></span>
-              <span class="p-ico ico-worm"></span>请输入18位身份证号
+              <span class="p-ico ico-worm"></span>请输入合法的份证号
             </span>
           </li>
 
           <li class="mt10">
             <span class="title"><em class="fvx">*</em>学历</span>
-            <input type="text" name="education" v-model="education" class="ui-ipt iptform" placeholder="输入学历" clearable>
+            <el-select placeholder="选择学历" v-model="education" class=" iptform" >
+              <el-option v-for="(item,index) in educationList" :value="item" :label="item" v-bind:key="index" />
+            </el-select>
           </li>
 
 
@@ -139,7 +141,7 @@
         name: '',
         passwordLevel: 'sick',
         password: '',
-
+        educationList: window.baseConfig.educationList,
         confirmPassword: '',
         phone: '',
         code: "",

+ 2 - 1
static/config.js

@@ -2,5 +2,6 @@ window.baseConfig = {
     title: '三明市城市建设项目服务中心',
     userSeatTitle:'福建省建设行业从业人员岗位考核考试',
     beian:'闽ICP备2121760号-1',
-    contact:'0598-5157296'
+    contact:'0598-5157296',
+    educationList: ["博士研究生", "硕士研究生", "大学本科", "大学专科", "中专", "高中", "初中及以下", "其他"]
 }