Ver código fonte

前后:合同评价创建人才能提交审核;招标中标结果有效期为50年后

dubch 4 anos atrás
pai
commit
713401e4a9

+ 5 - 0
src/dashoo.cn/backend/api/controllers/oilcontract/contractReview.go

@@ -861,6 +861,11 @@ func (this *OilContractReviewController) UnitAuditEntity() {
 	conRev := contractReview.GetOilContractReviewService(utils.DBE)
 	var contractReviewEntity contractReview.OilContractReview
 	conRev.GetEntityById(Id, &contractReviewEntity)
+
+	if strconv.Itoa(contractReviewEntity.CreateUserId) != this.User.Id {
+		panic("该评价创建人才可提交审核!")
+	}
+
 	//检查是否可提交
 	//conRev.IsSupplierCertCanSubmit(strconv.Itoa(supplierCertEntity.SupplierId), certId)
 	//取出合同表

+ 30 - 5
src/dashoo.cn/frontend_web/src/components/oilsupplier/subfilelist2.vue

@@ -61,7 +61,7 @@
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
               <!-- <el-input v-model="SubfileForm.NeedFileType" placeholder="请输文件类型"></el-input> -->
-              <el-select style="width: 100%;" v-model="SubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable :disabled="IsMust">
+              <el-select style="width: 100%;" v-model="SubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable :disabled="IsMust" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -69,7 +69,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期" @change="pickerchange">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -251,6 +251,7 @@
           FileExt: ''
         },
         visible: false,
+        dateDisable: false,
         selfVisible: this.visible, // 避免vue双向绑定警告
 
         waituploads: [], // 等待上传的附件列表
@@ -272,6 +273,28 @@
       this.IsCompanyUser = this.authUser.Profile.IsCompanyUser
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.SubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.SubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       // 上传超过限制数
       uploadExceed (files, fileList) {
         if (fileList.length >= 5) {
@@ -303,9 +326,6 @@
         this.dialogImageUrl = file.url
         this.dialogVisible = true
       },
-      pickerchange () {
-        console.log(this.SubfileForm.EffectDate)
-      },
       getSupplierSceneFile () {
         let params = {
           SupplierId: this.SupplierId
@@ -560,6 +580,11 @@
       },
       openDialog (val) {
         this.IsMust = true
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.Title = '上传文件'
         this.SubfileForm.Id = val.Id
         this.SubfileForm.SupplierId = val.SupplierId

+ 13 - 2
src/dashoo.cn/frontend_web/src/pages/oilcontract/contract-basis/index.vue

@@ -109,12 +109,17 @@
           </template>
         </el-table-column>
         <el-table-column v-for="column in tableColumns" :key="column.Id"
-                         v-if="column.prop != 'CreateOn' && column.prop != 'SupplierName' && column.prop != 'SecondUnitName' && column.prop != 'ContractName' && column.prop != 'ContractNo' && column.prop != 'Status'" :prop="column.prop" sortable :min-width="140" :label="column.label" align="center" show-overflow-tooltip>
+                         v-if="column.prop != 'CreateBy' && column.prop != 'CreateOn' && column.prop != 'SupplierName' && column.prop != 'SecondUnitName' && column.prop != 'ContractName' && column.prop != 'ContractNo' && column.prop != 'Status'" :prop="column.prop" sortable :min-width="140" :label="column.label" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
             <div>{{ columnFun(scope.row[column.prop], column.prop) }}</div>
           </template>
         </el-table-column>
-
+        <el-table-column v-for="column in tableColumns" :key="column.Id"
+                         v-if="column.prop == 'CreateBy'"  :min-width="100" :label="column.label" align="center" show-overflow-tooltip>
+          <template slot-scope="scope">
+            <div>{{ scope.row[column.prop] }}</div>
+          </template>
+        </el-table-column>
         <!--<el-table-column prop="CreateOn" sortable min-width="150" label="生成时间" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
             {{ jstimehandle(scope.row.CreateOn+'') }}
@@ -439,6 +444,12 @@ export default {
           width: 100,
           sort: true
         },
+        {
+          prop: 'CreateBy',
+          label: '创建人',
+          width: 100,
+          sort: false
+        },
 
         {
           prop: 'ContractName',

+ 14 - 2
src/dashoo.cn/frontend_web/src/pages/oilcontract/contract-goods/index.vue

@@ -108,11 +108,17 @@
           </template>
         </el-table-column>
         <el-table-column v-for="column in tableColumns" :key="column.Id"
-                         v-if="column.prop != 'CreateOn' && column.prop != 'SupplierName' && column.prop != 'SecondUnitName' && column.prop != 'ContractName' && column.prop != 'ContractNo' && column.prop != 'Status'" :prop="column.prop" sortable :min-width="140" :label="column.label" align="center" show-overflow-tooltip>
+                         v-if="column.prop != 'CreateBy' && column.prop != 'CreateOn' && column.prop != 'SupplierName' && column.prop != 'SecondUnitName' && column.prop != 'ContractName' && column.prop != 'ContractNo' && column.prop != 'Status'" :prop="column.prop" sortable :min-width="140" :label="column.label" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
             <div>{{ columnFun(scope.row[column.prop], column.prop) }}</div>
           </template>
         </el-table-column>
+        <el-table-column v-for="column in tableColumns" :key="column.Id"
+                         v-if="column.prop == 'CreateBy'"  :min-width="100" :label="column.label" align="center" show-overflow-tooltip>
+          <template slot-scope="scope">
+            <div>{{ scope.row[column.prop] }}</div>
+          </template>
+        </el-table-column>
 
         <!--<el-table-column prop="CreateOn" sortable min-width="150" label="生成时间" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
@@ -431,10 +437,16 @@ export default {
         },
         {
           prop: 'SecondUnitName',
-          label: '项目建设单位',
+          label: '发起评价单位',
           width: 100,
           sort: true
         },
+        {
+          prop: 'CreateBy',
+          label: '创建人',
+          width: 100,
+          sort: false
+        },
 
         {
           prop: 'ContractName',

+ 13 - 2
src/dashoo.cn/frontend_web/src/pages/oilcontract/contract-service/index.vue

@@ -108,12 +108,17 @@
           </template>
         </el-table-column>
         <el-table-column v-for="column in tableColumns" :key="column.Id"
-                         v-if="column.prop != 'CreateOn' && column.prop != 'SupplierName' && column.prop != 'SecondUnitName' && column.prop != 'ContractName' && column.prop != 'ContractNo' && column.prop != 'Status'" :prop="column.prop" sortable :min-width="140" :label="column.label" align="center" show-overflow-tooltip>
+                         v-if="column.prop != 'CreateBy' && column.prop != 'CreateOn' && column.prop != 'SupplierName' && column.prop != 'SecondUnitName' && column.prop != 'ContractName' && column.prop != 'ContractNo' && column.prop != 'Status'" :prop="column.prop" sortable :min-width="140" :label="column.label" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
             <div>{{ columnFun(scope.row[column.prop], column.prop) }}</div>
           </template>
         </el-table-column>
-
+        <el-table-column v-for="column in tableColumns" :key="column.Id"
+                         v-if="column.prop == 'CreateBy'"  :min-width="100" :label="column.label" align="center" show-overflow-tooltip>
+          <template slot-scope="scope">
+            <div>{{ scope.row[column.prop] }}</div>
+          </template>
+        </el-table-column>
         <!--<el-table-column prop="CreateOn" sortable min-width="150" label="生成时间" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
             {{ jstimehandle(scope.row.CreateOn+'') }}
@@ -438,6 +443,12 @@ export default {
           width: 100,
           sort: true
         },
+        {
+          prop: 'CreateBy',
+          label: '创建人',
+          width: 100,
+          sort: false
+        },
 
         {
           prop: 'ContractName',

+ 31 - 4
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/bassicoperation.vue

@@ -882,7 +882,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -915,7 +915,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable>
+              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -923,8 +923,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
-              </el-date-picker>
+              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期"></el-date-picker>
             </el-form-item>
           </el-col>
           <el-col :span="24">
@@ -1161,6 +1160,7 @@ import Viewer from 'v-viewer'
         firOptions: [],
         newVisible: false,
         saveLoading: false,
+        dateDisable: false,
         newSubfileForm: {
           Id: '',
           SupplierId: '',
@@ -1669,6 +1669,28 @@ import Viewer from 'v-viewer'
       this.isAccess()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.newSubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.newSubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       isAccess () {
         this.getAuditStepCodeByStatus()
         let params = {
@@ -2042,6 +2064,11 @@ import Viewer from 'v-viewer'
       },
       openDialog (val) {
         this.IsMust = true
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.Title = '资质变更'
         this.waituploads = []
         this.SubfileForm.Id = val.Id

+ 31 - 4
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/goodsoperation.vue

@@ -1023,7 +1023,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1055,7 +1055,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%">
+              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -1063,8 +1063,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
-              </el-date-picker>
+              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" :disabled="dateDisable" type="date" placeholder="请选择有效日期"></el-date-picker>
             </el-form-item>
           </el-col>
           <el-col :span="24">
@@ -1775,6 +1774,7 @@
             trigger: 'blur'
           }]
         },
+        dateDisable: false,
         SubfileForm: {
           Id: '',
           SupplierId: '',
@@ -1841,6 +1841,28 @@
       this.isAccess()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.newSubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.newSubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       isAccess () {
         this.getAuditStepCodeByStatus()
         let params = {
@@ -2211,6 +2233,11 @@
       },
       openDialog (val) {
         this.IsMust = true
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.Title = '资质变更'
         this.waituploads = []
         this.SubfileForm.Id = val.Id

+ 31 - 3
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/operation.vue

@@ -795,7 +795,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -828,7 +828,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%">
+              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%"  @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -836,7 +836,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" :disabled="dateDisable"  placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1078,6 +1078,7 @@ import Viewer from 'v-viewer'
         saveLoading: false,
         firOptions: [],
         newVisible: false,
+        dateDisable: false,
         newSubfileForm: {
           Id: '',
           SupplierId: '',
@@ -1583,6 +1584,28 @@ import Viewer from 'v-viewer'
       this.isAccess()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.newSubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.newSubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       isAccess () {
         this.getAuditStepCodeByStatus()
         console.log('步骤code', this.auditstepcode)
@@ -1978,6 +2001,11 @@ import Viewer from 'v-viewer'
       },
       openDialog (val) {
         this.IsMust = true
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.Title = '资质变更'
         this.waituploads = []
         this.SubfileForm.Id = val.Id

+ 30 - 2
src/dashoo.cn/frontend_web/src/pages/oilsupplier/infochangech/_opera/operation.vue

@@ -794,7 +794,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select style="width: 100%" v-model="SubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable :disabled="IsMust">
+              <el-select style="width: 100%" v-model="SubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable :disabled="IsMust" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -802,7 +802,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1111,6 +1111,7 @@
       }
       return {
         saveLoading: false,
+        dateDisable: false,
         OperTypeCopy: '',
         OperTypeOptions: [],
         accessedType: [], // 已准入的类别:物资类、服务类、基建类
@@ -1578,6 +1579,28 @@
       // this.getAccessCardNo()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.SubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.SubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       getAccessedType () {
         if (this.supplierId > 0) {
           api.GetAccessedType(this.supplierId, this.$axios)
@@ -2365,6 +2388,11 @@
       },
       openDialog (val) {
         this.IsMust = true
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.Title = '资质变更'
         this.waituploads = []
         this.SubfileForm.Id = val.Id

+ 31 - 3
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/basisdataopera.vue

@@ -626,7 +626,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -871,7 +871,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%">
+              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -879,7 +879,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1126,6 +1126,7 @@
         SupplierCertId: 0,
         subfileList1: [],
         visible: false,
+        dateDisable: false,
         dynamicTableColumns: [],
         flag: '',
         editbtn: true,
@@ -1583,6 +1584,28 @@
       //this.getsubfile()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.newSubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.newSubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       delFile (row) {
         let confirmmsg = '此操作将彻底删除该数据, 是否继续?'
         this.$confirm(confirmmsg, '提示', {
@@ -2208,6 +2231,11 @@
       },
       openDialog (val) {
         this.SubfileForm.Id = val.Id
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.SubfileForm.SupplierId = val.SupplierId
         this.SubfileForm.SupplierTypeCode = val.SupplierTypeCode
         if (val.SupplierCertSubId == 0) {

+ 31 - 3
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/goodsdataopera.vue

@@ -700,7 +700,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1065,7 +1065,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%">
+              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" filterable style="width: 100%" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -1073,7 +1073,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1392,6 +1392,7 @@
           IsDelete: 0,
           FileUrlList: []
         },
+        dateDisable : false,
         newSubfileForm: {
           Id: '',
           SupplierId: '',
@@ -1825,6 +1826,28 @@
       // this.getsubfile()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.newSubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.newSubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       // =======================================
       getsubfile () {
         let _this = this
@@ -2723,6 +2746,11 @@
       },
       openDialog (val) {
         this.SubfileForm.Id = val.Id
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.SubfileForm.SupplierId = val.SupplierId
         this.SubfileForm.SupplierTypeCode = val.SupplierTypeCode
         if (val.SupplierCertSubId == 0) {

+ 31 - 3
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/techdataopera.vue

@@ -623,7 +623,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -873,7 +873,7 @@
         <el-row>
           <el-col :span="12">
             <el-form-item label="资质名称" prop="NeedFileType">
-              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" filterable size="medium" style="width: 100%">
+              <el-select v-model="newSubfileForm.NeedFileType" placeholder="请输文件类型" filterable size="medium" style="width: 100%" @change="changeFile">
                 <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
                 </el-option>
               </el-select>
@@ -881,7 +881,7 @@
           </el-col>
           <el-col :span="12">
             <el-form-item label="有效日期" prop="EffectDate">
-              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
+              <el-date-picker style="width: 100%" v-model="newSubfileForm.EffectDate" type="date" :disabled="dateDisable" placeholder="请选择有效日期">
               </el-date-picker>
             </el-form-item>
           </el-col>
@@ -1144,6 +1144,7 @@
         SupplierCertId: 0,
         subfileList1: [],
         visible: false,
+        dateDisable: false,
         dynamicTableColumns: [],
         flag: '',
         editbtn: true,
@@ -1594,6 +1595,28 @@
       // this.getsubfile()
     },
     methods: {
+      addDate () {
+        let date = new Date()
+        let year = date.getFullYear() + 50
+        let month = date.getMonth() + 1
+        let day = date.getDate()
+        if (month < 10) {
+          month = "0" + month
+        }
+        if (day < 10) {
+          day = "0" + day
+        }
+        return year + "-" + month + "-" + day
+      },
+      changeFile (fileName) {
+        if (fileName === "招标中标结果") {
+          this.newSubfileForm.EffectDate = this.addDate() + "T08:00:00+08:00"
+          this.dateDisable = true
+        } else {
+          this.newSubfileForm.EffectDate = ""
+          this.dateDisable = false
+        }
+      },
       getCountryList (val) {
         let tmpJson = JSON.parse(val)
         this.countryListOptions = []
@@ -2667,6 +2690,11 @@
       },
       openDialog (val) {
         this.SubfileForm.Id = val.Id
+        if (val.NeedFileType === "招标中标结果") {
+          this.dateDisable = true
+        } else {
+          this.dateDisable = false
+        }
         this.SubfileForm.SupplierId = val.SupplierId
         this.SubfileForm.SupplierTypeCode = val.SupplierTypeCode
         if (val.SupplierCertSubId == 0) {