Selaa lähdekoodia

Merge branch 'Dev' into 'Test'

Dev

See merge request crowd-2019/crowd-test-service-front!34
guochao 5 vuotta sitten
vanhempi
commit
1e67b2c8de

+ 1 - 1
src/components/authen/AuthenticationIndex.vue

@@ -24,7 +24,7 @@
         <el-col :span="6">
           <el-card :body-style="{ padding: '0px' }" style="cursor: pointer;">
             <i class="el-icon-s-tools image" style="color:#909399;" @click="toAgencyAuthentication"></i>
-            <div style="text-align: center;font-size: 12px"><span>认证为测评机构,可以接任务</span></div>
+            <div style="text-align: center;font-size: 12px"><span>认证为测评机构,可以接任务</span></div>
             <div @click="toAgencyAuthentication" style="padding: 14px;text-align: center;font-size: 20px">
               <span>机构认证</span>
             </div>

+ 18 - 7
src/components/authen/AuthenticationManage.vue

@@ -103,7 +103,7 @@
                 fit="scale-down"></el-image>
             </span>
           </el-form-item>
-          <el-form-item label="统一社会信用代码:" v-if="authInfoDetail.type == 'enterprise'">
+          <el-form-item label="统一信用代码:" v-if="authInfoDetail.type == 'enterprise'">
             <span>{{authInfoDetail.unifiedSocialCreditCode}}</span>
           </el-form-item>
 
@@ -111,10 +111,12 @@
             <span>{{authInfoDetail.evaluationAgencyName}}</span>
           </el-form-item>
           <el-form-item label="机构能力:" v-if="authInfoDetail.type == 'agency'">
-            <span>{{authInfoDetail.evaluationAgencyAbilityList}}</span>
+            <span v-for="item in authInfoDetail.evaluationAgencyAbilityList"> <el-tag>{{item}}</el-tag>
+            </span>
           </el-form-item>
           <el-form-item label="机构资源:" v-if="authInfoDetail.type == 'agency'">
-            <span>{{authInfoDetail.evaluationAgencyResourceList}}</span>
+            <span v-for="item in authInfoDetail.evaluationAgencyResourceList"> <el-tag>{{item.type}} ( {{item.name}} ) :&nbsp; [总数:{{item.totalNum}} ,可用数量:{{item.availableNum}}]</el-tag>
+            </span>
           </el-form-item>
           <el-form-item label="机构Logo:" v-if="authInfoDetail.type == 'agency'">
             <span>
@@ -331,25 +333,34 @@
                 this.hideLoading()
                 notify('error', '获取个人认证信息出错:' + error.data)
             },
-            getCurrentEnterpriseAuthInfoSuccess () {
+            getCurrentEnterpriseAuthInfoSuccess (res) {
                 this.hideLoading()
                 this.authInfoDetail.enterpriseName = res.enterpriseName
                 this.authInfoDetail.legalPersonName = res.legalPersonName
                 this.authInfoDetail.businessLicensePhoto = res.businessLicensePhoto
+                this.authInfoDetail.bankAccount = res.bankAccount
+                this.authInfoDetail.address = res.address
+                this.authInfoDetail.applyTime = res.applyTime
+                this.authInfoDetail.unifiedSocialCreditCode = res.unifiedSocialCreditCode
+                this.showAuthDialog()
             },
-            getCurrentEnterpriseAuthInfoFail () {
+            getCurrentEnterpriseAuthInfoFail (error) {
                 this.hideLoading()
                 notify('error', '获取企业认证信息出错:' + error.data)
             },
-            getCurrentAgencyAuthInfoSuccess () {
+            getCurrentAgencyAuthInfoSuccess (res) {
                 this.hideLoading()
+              this.authInfoDetail.bankAccount = res.bankAccount
+              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.showAuthDialog()
             },
-            getCurrentAgencyAuthInfoFail () {
+            getCurrentAgencyAuthInfoFail (error) {
                 this.hideLoading()
                 notify('error', '获取机构认证信息出错:' + error.data)
             }

+ 8 - 8
src/components/commons/Header.vue

@@ -104,7 +104,7 @@
                   </el-link>
                 </router-link>
               </el-dropdown-item>
-              <el-dropdown-item v-if="user.authStatus.text == '审核通过' && user.userVO.authType=='agency'">
+              <el-dropdown-item v-if="user.authStatus.text == '审核通过' &&  !this.user.personalAuthVO && this.user.agencyVO">
                 <router-link :to="{ name: 'Agency',params:{userId:user.userVO.id}}">
                   <el-link icon="el-icon-edit" :underline="false">
                     修改机构信息
@@ -475,24 +475,24 @@ export default {
       //this.getAuthInfo()
     },
     handleClickAuthPass () {
-      if (this.user.userVO.authType == 'agency') {
+      if (this.user.personalAuthVO) {
         this.$router.push({
-          name: 'AgencyAuthentication',
+          name: 'IndividualAuthentication',
           params: {userId: this.user.userVO.id}
         })
-      }
-      if (this.user.userVO.authType == 'enterprise') {
+      }else if (this.user.agencyVO) {
         this.$router.push({
-          name: 'EnterpriseAuthentication',
+          name: 'AgencyAuthentication',
           params: {userId: this.user.userVO.id}
         })
       }
-      if (this.user.userVO.authType == 'personal') {
+      else if (this.user.enterpriseAuthVO) {
         this.$router.push({
-          name: 'IndividualAuthentication',
+          name: 'EnterpriseAuthentication',
           params: {userId: this.user.userVO.id}
         })
       }
+
       //this.getAuthInfo()
     },
     handleClickAuthChecking () {

+ 1 - 1
src/components/project/AnalyseDemand.vue

@@ -41,7 +41,7 @@
         </el-form-item>
         <el-form-item>
           <div class="btn btn-medium btn-info" @click="submitForm('analyseDemand')">提交</div>
-          <div class="btn btn-medium" @click="resetForm('analyseDemand')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('analyseDemand')">重置</div>-->
           <div class="btn btn-medium" @click="back()">返回</div>
         </el-form-item>
       </el-form>

+ 12 - 22
src/components/project/Project.vue

@@ -170,7 +170,7 @@
             </el-form-item>
             <el-form-item v-if="isModifyMode">
               <div class="btn btn-small btn-info" @click="submitForm('project')">确认修改</div>
-              <div class="btn btn-small" @click="resetForm('project')">重置</div>
+              <!--<div class="btn btn-small" @click="resetForm('project')">重置</div>-->
               <div class="btn btn-small" @click="cancelMode('project')">取消</div>
             </el-form-item>
             <el-form-item v-if="!isModifyMode">
@@ -183,7 +183,7 @@
                 提交项目
               </el-button>
               <el-button v-if="projectOperationControl.receive" type="primary" size="mini" @click="receiveProject()">
-                接项目
+                接项目
               </el-button>
               <el-button v-if="projectOperationControl.reject" type="danger" size="mini" @click="rejectProject()">
                 拒绝项目
@@ -782,33 +782,23 @@ export default {
       notify('error', '删除失败:'+error)
     },
     beforeApkUpload (file) {
-      const isAPK = file.type === 'application/vnd.android.package-archive'
-      const isDMG = file.type === 'application/octet-stream'
-
-      if (!isAPK && !isDMG) {
-        this.$message.error('上传安装包只能是 APK 或 DMG 格式!')
-      }
-      return isAPK || isDMG
+      return true;
+      //const fileTypeList = ['dmg', 'exe', 'apk']
+      //return checkFileType(file, fileTypeList, this.beforeFileUploadError)
     },
     beforeFileUpload (file) {
-      console.log(file)
-      const isPDF = file.type === 'application/pdf'
-      const isDOC = file.type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'
-      const isEXCEL = file.type === 'application/vnd.ms-excel'
-      const isXLS = file.type === 'application/x-xls'
-      const isTXT = file.type === 'text/plain'
-      const isXLSX = file.type === 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
-      //console.log(file)
-      if (!(isDOC || isEXCEL || isPDF || isTXT || isXLS || isXLSX)) {
-        this.$message.error('上传文件只能是 PDF 、 DOC 、DOCX 、XLS、TXT、XLSX 格式!')
-      }
-      return isDOC || isEXCEL || isPDF || isTXT || isXLS || isXLSX
+      return true;
+      //const fileTypeList = ['pdf', 'xls', 'xlsx', 'doc', 'docx', 'txt']
+      //return checkFileType(file, fileTypeList, this.beforeFileUploadError)
+    },
+    beforeFileUploadError () {
+      this.$message.error('上传文件只能是 PDF 、 DOC 、DOCX 、XLS、TXT、XLSX 格式!')
     },
     analyseDemand () {
       this.$router.push({name: 'AnalyseDemand'})
     },
     handleAccept (index, id) {
-      console.log('接')
+      console.log('接收')
     },
     handleReject (index, id) {
       console.log('拒绝')

+ 7 - 5
src/components/project/ProjectCreate.vue

@@ -120,7 +120,7 @@
         </el-form-item>
         <el-form-item>
           <div class="btn btn-medium btn-info" v-on:click="submitForm('project')">立即申请</div>
-          <div class="btn btn-medium" @click="resetForm('project')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('project')">重置</div>-->
         </el-form-item>
       </el-form>
     </div>
@@ -414,15 +414,17 @@ export default {
       this.project.budget = ''
     },
     beforeApkUpload (file) {
-      const fileType = ['exe', 'apk', 'dmg']
-      return checkFileType(file, fileType, this.beforeApkUploadError)
+      return true;
+      //const fileType = ['exe', 'apk', 'dmg']
+      //return checkFileType(file, fileType, this.beforeApkUploadError)
     },
     beforeApkUploadError () {
       this.$message.error('上传文件只能是exe,dmg,apk格式!')
     },
     beforeFileUpload (file) {
-      const fileTypeList = ['pdf', 'xls', 'xlsx', 'doc', 'docx', 'txt']
-      return checkFileType(file, fileTypeList, this.beforeFileUploadError)
+      return true;
+      //const fileTypeList = ['pdf', 'xls', 'xlsx', 'doc', 'docx', 'txt']
+      //return checkFileType(file, fileTypeList, this.beforeFileUploadError)
     },
     beforeFileUploadError () {
       this.$message.error('上传文件只能是 PDF 、 DOC 、DOCX 、XLS、TXT、XLSX 格式!')

+ 3 - 1
src/components/report/ProjectReport.vue

@@ -65,7 +65,7 @@
         </el-form-item>
         <el-form-item v-if="isModifyMode">
           <div class="btn btn-medium btn-info" @click="submitForm('report')">确认修改</div>
-          <div class="btn btn-medium" @click="resetForm('report')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('report')">重置</div>-->
           <div class="btn btn-medium" @click="cancelCreate('report')">取消</div>
         </el-form-item>
       </el-form>
@@ -197,6 +197,7 @@ export default {
       //return this.$confirm(`确定移除 ${file.name}?`)
     },
     beforeFileUpload (file) {
+      /*
       console.log(file)
       const isPDF = file.type === 'application/pdf'
       const isDOC = file.type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'
@@ -209,6 +210,7 @@ export default {
         this.$message.error('上传文件只能是 PDF 、 DOC 、DOCX 、XLS、TXT、XLSX 格式!')
       }
       return isDOC || isEXCEL || isPDF || isTXT || isXLS || isXLSX
+      */
     },
     back () {
       this.$router.push({

+ 1 - 1
src/components/report/ProjectReportCreate.vue

@@ -67,7 +67,7 @@
         </el-form-item>
         <el-form-item>
           <div class="btn btn-medium btn-info" @click="submitForm('report')">提交</div>
-          <div class="btn btn-medium" @click="resetForm('report')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('report')">重置</div>-->
           <div class="btn btn-medium" @click="cancelCreate('report')">取消</div>
         </el-form-item>
       </el-form>

+ 4 - 1
src/components/report/TaskReport.vue

@@ -63,7 +63,7 @@
         </el-form-item>
         <el-form-item v-if="isModifyMode">
           <div class="btn btn-medium btn-info" @click="submitForm('report')">确认修改</div>
-          <div class="btn btn-medium" @click="resetForm('report')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('report')">重置</div>-->
           <div class="btn btn-medium" @click="cancelCreate('report')">取消</div>
         </el-form-item>
       </el-form>
@@ -194,6 +194,8 @@ export default {
       //return this.$confirm(`确定移除 ${file.name}?`)
     },
     beforeFileUpload (file) {
+      return true;
+      /*
       console.log(file)
       const isPDF = file.type === 'application/pdf'
       const isDOC = file.type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'
@@ -206,6 +208,7 @@ export default {
         this.$message.error('上传文件只能是 PDF 、 DOC 、DOCX 、XLS、TXT、XLSX 格式!')
       }
       return isDOC || isEXCEL || isPDF || isTXT || isXLS || isXLSX
+      */
     },
     back () {
       this.$router.push({

+ 3 - 1
src/components/report/TaskReportCreate.vue

@@ -48,7 +48,7 @@
         </el-form-item>
         <el-form-item>
           <div class="btn btn-medium btn-info" @click="submitForm('report')">提交</div>
-          <div class="btn btn-medium" @click="resetForm('report')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('report')">重置</div>-->
           <div class="btn btn-medium" @click="cancelCreate('report')">取消</div>
         </el-form-item>
       </el-form>
@@ -176,6 +176,7 @@ export default {
       //return this.$confirm(`确定移除 ${file.name}?`)
     },
     beforeFileUpload (file) {
+      /*
       console.log(file)
       const isPDF = file.type === 'application/pdf'
       const isDOC = file.type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'
@@ -188,6 +189,7 @@ export default {
         this.$message.error('上传文件只能是 PDF 、 DOC 、DOCX 、XLS、TXT、XLSX 格式!')
       }
       return isDOC || isEXCEL || isPDF || isTXT || isXLS || isXLSX
+      */
     },
     loadData () {
     },

+ 1 - 1
src/components/task/Task.vue

@@ -112,7 +112,7 @@
         </el-form-item>
         <el-form-item v-if="isModifyMode">
           <div class="btn btn-small btn-info" @click="updateTask()">确认修改</div>
-          <div class="btn btn-small" @click="resetForm()">重置</div>
+          <!--<div class="btn btn-small" @click="resetForm()">重置</div>-->
           <div class="btn btn-small" @click="cancelMode()">取消</div>
         </el-form-item>
         <el-form-item v-if="!isModifyMode">

+ 1 - 1
src/components/task/TaskCreate.vue

@@ -84,7 +84,7 @@
         </el-form-item>
         <el-form-item>
           <div class="btn btn-medium btn-info" @click="submitForm('task')">立即创建</div>
-          <div class="btn btn-medium" @click="resetForm('task')">重置</div>
+          <!--<div class="btn btn-medium" @click="resetForm('task')">重置</div>-->
           <div class="btn btn-medium" @click="cancelCreate('task')">取消</div>
         </el-form-item>
       </el-form>

+ 2 - 2
tool4deploy/conf.d/nginx.conf

@@ -3,7 +3,7 @@ server {
         server_name  crowd.test.mooctest.net;
         root /usr/share/nginx/html;
         #charset koi8-r;
-
+        client_max_body_size 100m;
         #access_log  logs/host.access.log  main;
 
         location / {
@@ -25,4 +25,4 @@ server {
         location = /50x.html {
             root   html;
         }
- }
+ }