Explorar el Código

Merge branch 'feature-2.0' of ssh://git.mooctest.com:1022/crowd-2019/crowd-test-service-front into feature-2.0

wangJJ hace 5 años
padre
commit
fdce18f977

+ 1 - 1
config/prod.env.js

@@ -3,6 +3,6 @@ module.exports = {
   NODE_ENV: '"production"',
   ENV_CONFIG: "'prod'",
   API_ROOT: '"//www.cofortest.com"',
-  LOGIN_URL:'"http://user.cofortest.com/page/login?redirect=http%3a%2f%2fwww.cofortest.com%2f%23%2fmine"',
+  LOGIN_URL:'"http://user.cofortest.com/page/login?redirect=http%3a%2f%2fwww.cofortest.com%2f%23%2fhome"',
   REGISTER_URL: '"http://user.cofortest.com/page/register"'
 }

+ 1 - 1
config/test.env.js

@@ -3,6 +3,6 @@ module.exports = {
   NODE_ENV: '"test"',
   ENV_CONFIG: "'test'",
   API_ROOT: '"//crowd.mooctest.net:8083"',
-  LOGIN_URL:'"http://user.mooctest.net:8081/page/login?redirect=http%3a%2f%2fcrowd.mooctest.net:8083%2f%23%2fmine"',
+  LOGIN_URL:'"http://user.mooctest.net:8081/page/login?redirect=http%3a%2f%2fcrowd.mooctest.net:8083%2f%23%2fhome"',
   REGISTER_URL: '"http://user.mooctest.net:8081/page/register"'
 }

+ 24 - 24
src/components/authen/AuthenticationManage.vue

@@ -98,8 +98,8 @@
           </el-form-item>
           <el-form-item label="角色:" v-if="authInfoDetail.type == 'personal'">
             <el-checkbox-group v-model="authInfoDetail.roleList" disabled>
-              <el-checkbox :label="0">发包</el-checkbox>
-              <el-checkbox :label="1">接包</el-checkbox>
+              <el-checkbox :label="1">发包</el-checkbox>
+              <el-checkbox :label="0">接包</el-checkbox>
             </el-checkbox-group>
 <!--            <span>{{authInfoDetail.roleList}}</span>-->
           </el-form-item>
@@ -183,8 +183,8 @@
 
           <el-form-item label="企业角色:" v-if="authInfoDetail.type == 'agency'">
             <el-checkbox-group v-model="authInfoDetail.roleList" disabled>
-              <el-checkbox :label="0">发包</el-checkbox>
-              <el-checkbox :label="1">接包</el-checkbox>
+              <el-checkbox :label="1">发包</el-checkbox>
+              <el-checkbox :label="0">接包</el-checkbox>
             </el-checkbox-group>
             <!--            <span>{{authInfoDetail.roleList}}</span>-->
           </el-form-item>
@@ -439,26 +439,26 @@
             },
             getCurrentAgencyAuthInfoSuccess (res) {
                 this.hideLoading()
-              this.authInfoDetail.bankAccount = res.bankAccount
-              this.authInfoDetail.legalPersonName = res.legalPersonName
-              this.authInfoDetail.businessLicensePhoto = res.businessLicensePhoto
-              this.authInfoDetail.address = res.address
-              this.authInfoDetail.applyTime = res.applyTime
-              this.authInfoDetail.evaluationAgencyName = res.evaluationAgencyName
-              this.authInfoDetail.evaluationAgencyAbilityList = res.evaluationAgencyAbilityList
-              this.authInfoDetail.evaluationAgencyResourceList = res.evaluationAgencyResourceList
-              this.authInfoDetail.agencyPhoto = res.agencyPhoto
-              this.authInfoDetail.updateTime = res.updateTime
-              this.authInfoDetail.checkTime = res.checkTime
-              this.authInfoDetail.explain = res.explain
-              this.authInfoDetail.gender = res.gender
-              this.authInfoDetail.idCardNum = res.idCardNum
-              this.authInfoDetail.idCardBackPhoto = res.idCardBackPhoto
-              this.authInfoDetail.idCardDeadTime = res.idCardDeadTime
-              this.authInfoDetail.idCardPositivePhoto = res.idCardPositivePhoto
-              this.authInfoDetail.isAuthentication = res.isAuthentication
-              this.authInfoDetail.isDeleted = res.isDeleted
-              this.authInfoDetail.roleList = res.roleList
+              this.authInfoDetail.bankAccount = res.data.bankAccount
+              this.authInfoDetail.legalPersonName = res.data.legalPersonName
+              this.authInfoDetail.businessLicensePhoto = res.data.businessLicensePhoto
+              this.authInfoDetail.address = res.data.address
+              this.authInfoDetail.applyTime = res.data.applyTime
+              this.authInfoDetail.evaluationAgencyName = res.data.evaluationAgencyName
+              this.authInfoDetail.evaluationAgencyAbilityList = res.data.evaluationAgencyAbilityList
+              this.authInfoDetail.evaluationAgencyResourceList = res.data.evaluationAgencyResourceList
+              this.authInfoDetail.agencyPhoto = res.data.agencyPhoto
+              this.authInfoDetail.updateTime = res.data.updateTime
+              this.authInfoDetail.checkTime = res.data.checkTime
+              this.authInfoDetail.explain = res.data.explain
+              this.authInfoDetail.gender = res.data.gender
+              this.authInfoDetail.idCardNum = res.data.idCardNum
+              this.authInfoDetail.idCardBackPhoto = res.data.idCardBackPhoto
+              this.authInfoDetail.idCardDeadTime = res.data.idCardDeadTime
+              this.authInfoDetail.idCardPositivePhoto = res.data.idCardPositivePhoto
+              this.authInfoDetail.isAuthentication = res.data.isAuthentication
+              this.authInfoDetail.isDeleted = res.data.isDeleted
+              this.authInfoDetail.roleList = res.data.roleList
               this.showAuthDialog()
             },
             getCurrentAgencyAuthInfoFail (error) {

+ 1 - 1
src/components/commons/Header2.0.vue

@@ -3,7 +3,7 @@
     <div class="container">
         <div class="nav-location pull-left">
           <i class="el-icon-location-outline" style="margin-right: 5px"></i>
-          <span style="line-height: 34px" v-if="!city">{{city}}</span>
+          <span style="line-height: 34px" v-if="!city && city != ''">{{city}}</span>
           <span style="line-height: 34px" v-else>暂无</span>
         </div>
         <div class="nav-list pull-right">

+ 1 - 0
src/js/api.js

@@ -59,6 +59,7 @@ export default {
     GET_INDIVIDUAL_AUTHENTICATION_INFO: '/api/user/{userId}/personalAuth',
     GET_ENTERPRISE_AUTHENTICATION_INFO: '/api/user/{userId}/enterpriseAuth',
     GET_AGENCY_AUTHENTICATION_INFO: '/api/user/{userId}/agency',
+    GET_AGENCY_AUTHENTICATION_INFO_COMMON: '/api/user/{userId}/agency/common',
     GET_ALL_HANDLING_AUTH_INFO: '/api/user/authentication/handling',
     GET_ALL_HANDLED_AUTH_INFO: '/api/user/authentication/handled',
     PASS_AGENCY_AUTH:'/api/user/{userId}/agency/status/accept',

+ 2 - 0
src/js/index.js

@@ -6,6 +6,7 @@ import {
   getAllHandlingAuthInfo,
   getAuthUrls,
   getCurrentAgencyAuthInfo,
+  getAgencyAuthInfoCommon,
   getCurrentAuthenInfo,
   getCurrentEnterpriseAuthInfo,
   getCurrentIndividualAuthenInfo,
@@ -105,6 +106,7 @@ export {
   getCurrentIndividualAuthenInfo,
   getCurrentEnterpriseAuthInfo,
   getCurrentAgencyAuthInfo,
+  getAgencyAuthInfoCommon,
   checkPassAuth,
   checkRejectAuth,
   updateAgencyResourceAndAbility

+ 9 - 0
src/js/userService.js

@@ -148,6 +148,15 @@ export const getCurrentAgencyAuthInfo = (userId, getCurrentEnterpriseAuthInfoSuc
     getCurrentEnterpriseAuthInfoFail(error)
   })
 }
+
+export const getAgencyAuthInfoCommon = (userId, getCurrentEnterpriseAuthInfoSuccess, getCurrentEnterpriseAuthInfoFail) => {
+  Http.get(Apis.USER.GET_AGENCY_AUTHENTICATION_INFO_COMMON.replace('{userId}', userId)).then((res) => {
+    getCurrentEnterpriseAuthInfoSuccess(res)
+  }).catch((error) => {
+    getCurrentEnterpriseAuthInfoFail(error)
+  })
+}
+
 export const getCurrentAuthenInfo = () => {
   const individualData = {
     type: '个人',//企业、机构、个人

+ 6 - 6
src/pages/DetailPage/AgencyDetail.vue

@@ -38,7 +38,7 @@
         <el-form-item label="接包数量" prop="taskCount" v-if="this.type == 0">
           <span>{{authentication.taskCount}}</span>
         </el-form-item>
-        <el-form-item label="审核通过时间" prop="checkTime">
+        <el-form-item label="认证时间" prop="checkTime">
           <span>{{dateFormat(new Date(authentication.checkTime),'yyyy-MM-dd HH:mm:ss')}}</span>
         </el-form-item>
 
@@ -57,7 +57,7 @@
     getAllReportTypes,
     defaultValue,
     storageGet,
-    getCurrentAgencyAuthInfo,
+    getAgencyAuthInfoCommon,
     getAllAgencyResourceTypes,
     getAllServiceTypes,
   } from '@/js/index'
@@ -76,7 +76,7 @@
         authentication: {
           mobile: '',
           evaluationAgencyName: '',
-          bankAccount: '',
+          // bankAccount: '',
           address: '',
           evaluationAgencyAbilityList: [],
           evaluationAgencyResourceList: [],
@@ -108,7 +108,7 @@
       //加载数据
       getAuthInfo() {
         this.showLoading()
-        getCurrentAgencyAuthInfo(this.userId, this.getAuthInfoSuccess, this.getAuthInfoFail)
+        getAgencyAuthInfoCommon(this.userId, this.getAuthInfoSuccess, this.getAuthInfoFail)
       },
       getAuthInfoSuccess(res) {
         this.hideLoading()
@@ -116,11 +116,11 @@
         this.authentication.evaluationAgencyName = res.data.evaluationAgencyName == null ? '暂未填写' : res.data.evaluationAgencyName
         this.authentication.evaluationAgencyAbilityList = res.data.evaluationAgencyAbilityList == null ? [] : res.data.evaluationAgencyAbilityList
         this.authentication.evaluationAgencyResourceList = res.data.evaluationAgencyResourceList == null ? [] : res.data.evaluationAgencyResourceList
-        this.authentication.bankAccount = res.data.bankAccount == null ? '暂未填写' : res.data.bankAccount
+        // this.authentication.bankAccount = res.data.bankAccount == null ? '暂未填写' : res.data.bankAccount
         this.authentication.address = res.data.address == null ? '暂未填写' : res.data.address
         this.authentication.authStatus = res.data.authStatus
         this.authentication.legalPersonName = res.data.legalPersonName == null ? '暂未填写' : res.data.legalPersonName
-        this.authentication.explain = res.data.explain
+        // this.authentication.explain = res.data.explain
         this.authentication.taskCount = res.data.taskCount
         this.authentication.checkTime = res.data.checkTime
       },

+ 2 - 1
src/pages/DetailPage/CrowdDetail.vue

@@ -135,7 +135,8 @@
                 }
             },
             handleSearchData(){
-                this.getCrowdProject();
+              this.activePage = 1;
+              this.getCrowdProject();
             },
             handlePageChange(index){
                 this.activePage = index;

+ 1 - 1
src/pages/DetailPage/UserDetail.vue

@@ -12,7 +12,7 @@
         <el-form-item label="性别" prop="count" v-if="this.gender != null &&  this.gender != ''">
           <span>{{user.gender}}</span>
         </el-form-item>
-        <el-form-item label="省市" prop="address" v-if="this.address != null &&  this.address != ''">
+        <el-form-item label="地址" prop="address">
           <span class="badge">{{user.address}}</span>
         </el-form-item>
         <el-form-item label="接包次数" prop="count">

+ 1 - 0
src/pages/HomepageSearch/ResourceList.vue

@@ -149,6 +149,7 @@
                 }
             },
             handleSearchData() {
+
                 if(this.searchType == 0){
                     this.$router.push({name: 'Square', params: {searchVal: this.searchVal, searchType: "project", currTab: "project"}});
                 }else if(this.searchType == 1){

+ 1 - 0
src/pages/Square/PopularProjectAndTaskList.vue

@@ -213,6 +213,7 @@
             },
             handleSearchData(){
                 console.log("this.searchVal  "  + this.searchVal)
+                this.activePage = 1;
                 if(this.currTab == 'project'){
                     this.getHotProject();
                 }else{

+ 1 - 1
src/pages/Square/Square2.0.vue

@@ -160,7 +160,7 @@
         // 正常点击众测广场跳转过来
         else{
             this.searchVal = this.$route.params.searchVal;
-            this.searchType = this.$route.params.searchType;
+            this.searchType = 'project';
             this.currTab = "squareHome"
             this.getData();
         }

+ 9 - 7
src/pages/Square/SquareCard.vue

@@ -25,7 +25,7 @@
         </el-col>
         <el-col :span="12" class=" test-btn">
           <el-button type="primary" round size="mini" class="pull-right" v-if="card.applicationType"
-                     @click="goToProjectDetail(card.code)">我要众测
+                     @click="goToProjectDetail(card.code)">查看详情
           </el-button>
           <el-button type="primary" round size="mini" class="pull-right" v-else
                      @click="goToTaskDetail(card.projectId, card.code)">我要众测
@@ -71,13 +71,15 @@
       goToProjectDetail(id) {
         if (!this.isLogin) {
           notify('warning', '请登录后访问');
-        } else if (this.isLogin) {
-          Http.get(Apis.USER.IS_PART.replace('{userId}', this.user.id)).then((res) => {
-            this.$router.push({name: 'Project', params: {projectId: id}})
-          }).catch((error) => {
-            notify('error', error.data)
-          })
         }
+        // else if (this.isLogin) {
+        //   Http.get(Apis.USER.IS_PART.replace('{userId}', this.user.id)).then((res) => {
+        //     this.$router.push({name: 'Project', params: {projectId: id}})
+        //   }).catch((error) => {
+        //     notify('error', error.data)
+        //   })
+        // }
+        this.$router.push({name: 'Project', params: {projectId: id}})
       },
       goToTaskDetail(projectId, taskId) {
         if (!this.isLogin) {

+ 3 - 3
src/pages/UserCenter/EnterpriseAuth.vue

@@ -101,8 +101,8 @@
         </el-form-item>
         <el-form-item label="认证权限" prop="roleList">
           <el-checkbox-group v-model="enterpriseForm.roleList" :disabled="!canEdit">
-            <el-checkbox :label="0">发包</el-checkbox>
-            <el-checkbox :label="1">接包</el-checkbox>
+            <el-checkbox :label="1">发包</el-checkbox>
+            <el-checkbox :label="0">接包</el-checkbox>
           </el-checkbox-group>
         </el-form-item>
       </el-form>
@@ -168,7 +168,7 @@
       <button class="enterprise-btn previousBtn" style="cursor: pointer" @click="active--" v-if="active>0">上一步</button>
       <button class="enterprise-btn nextBtn" style="cursor: pointer" @click="nextStep" v-if="active===0">下一步</button>
       <button class="enterprise-btn nextBtn" style="cursor: pointer" @click="submitEnterpriseAuth" v-if="active===1 && authType === 0">提交审核</button>
-      <button class="enterprise-btn nextBtn" style="cursor: pointer" @click="submitEnterpriseAuth" v-if="active===1 && authStatus.text =='审核中'">修改审核</button>
+      <button class="enterprise-btn nextBtn" style="cursor: pointer" @click="submitEnterpriseAuth" v-if="active===1 && (authStatus.text =='审核中' || authStatus.text == '认证失败')">修改审核</button>
     </div>
   </div>
 </template>

+ 2 - 2
src/pages/UserCenter/IndividualAuth.vue

@@ -47,8 +47,8 @@
       </el-form-item>
       <el-form-item label="认证权限" prop="roleList">
         <el-checkbox-group v-model="individualForm.roleList" :disabled="!canEdit">
-          <el-checkbox :label="0">发包</el-checkbox>
-          <el-checkbox :label="1">接包</el-checkbox>
+          <el-checkbox :label="1">发包</el-checkbox>
+          <el-checkbox :label="0">接包</el-checkbox>
         </el-checkbox-group>
       </el-form-item>
     </el-form>