| | |
| | | <el-form-item label="时间" prop="happenTime"> |
| | | <el-date-picker |
| | | v-model="dateRange" |
| | | style="width: 240px;" |
| | | style="width: 240px; |
| | | height: 35px; |
| | | border-radius: 16px 16px 16px 16px; |
| | | opacity: 0.5;" |
| | | value-format="yyyy-MM-dd" |
| | | type="daterange" |
| | | range-separator="-" |
| | |
| | | v-model="queryParams.name" |
| | | placeholder="请输入设备名称" |
| | | clearable |
| | | style="width: 240px" |
| | | style="width: 200px; |
| | | height: 35px; |
| | | border-radius: 16px 16px 16px 16px; |
| | | opacity: 0.5;" |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | |
| | | v-model="queryParams.buyer" |
| | | placeholder="请输入购买人" |
| | | clearable |
| | | style="width: 240px" |
| | | style="width: 200px; |
| | | height: 35px; |
| | | border-radius: 16px 16px 16px 16px; |
| | | opacity: 0.5;" |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | |
| | | v-model="queryParams.location" |
| | | placeholder="请输入存放地点" |
| | | clearable |
| | | style="width: 240px" |
| | | style="width: 200px; |
| | | height: 35px; |
| | | border-radius: 16px 16px 16px 16px; |
| | | opacity: 0.5;" |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | |
| | |
| | | v-model="queryParams.content" |
| | | placeholder="请输入事项内容" |
| | | clearable |
| | | style="width: 240px" |
| | | style="width: 200px; |
| | | height: 35px; |
| | | border-radius: 16px 16px 16px 16px; |
| | | opacity: 0.5;" |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | </el-form-item> |
| | |
| | | v-hasPermi="['family:note:export']" |
| | | >导入模板下载</el-button> |
| | | </el-col> |
| | | <el-col :span="1.2"> |
| | | <el-col :span="1.5"> |
| | | |
| | | <el-upload |
| | | action="" |
| | |
| | | > |
| | | <el-button size="mini" type="primary" |
| | | plain |
| | | icon="el-icon-plus" >导入</el-button> |
| | | icon="el-icon-top" >导入</el-button> |
| | | |
| | | </el-upload> |
| | | </el-col> |
| | |
| | | <el-table v-loading="loading" :data="equipmentList" :row-key="getRowId" ref="multipleTable" @selection-change="handleSelectionChange" :row-class-name="tableRowClassName" style="background: #FFEFF2; border-radius: 14px 14px 14px 14px;"> |
| | | <el-table-column type="selection" :reserve-selection="true" width="55" align="center" /> |
| | | <el-table-column fixed label="序号" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="120"/> |
| | | <el-table-column label="设备名称" prop="name" sortable width="120" /> |
| | | <el-table-column label="设备名称" prop="name" sortable width="150" /> |
| | | |
| | | <el-table-column label="时间" align="happenTime" sortable prop="happenTime" width="150"> |
| | | <el-table-column label="时间" align="happenTime" sortable prop="happenTime" width="140"> |
| | | <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '————'}}</template> |
| | | </el-table-column> |
| | | <el-table-column label="是否注销" align="center" sortable prop="status" width="120"> |
| | | <el-table-column label="是否注销" align="center" sortable prop="status" width="140"> |
| | | <template slot-scope="scope"> |
| | | {{ getSrc1(scope.row.status) }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="购买人" prop="buyer" sortable width="100" /> |
| | | <el-table-column label="购买人" prop="buyer" sortable width="140" /> |
| | | <el-table-column label="事项内容" prop="content" sortable :show-overflow-tooltip="true" width="150" /> |
| | | <el-table-column label="存放地点" prop="location" sortable width="100" /> |
| | | <el-table-column label="存放地点" prop="location" sortable width="120" /> |
| | | |
| | | <el-table-column label="备注" prop="remark" sortable width="100" > |
| | | <template slot-scope="scope">{{scope.row.remark? scope.row.remark: '————'}}</template> |
| | | </el-table-column> |
| | | |
| | | |
| | | |
| | | <el-table-column label="是否是本家庭记录" prop="ownData" sortable width="150px" > |
| | | <template slot-scope="scope">{{scope.row.ownData === 0 ? '否': '是'}}</template> |
| | | </el-table-column> |
| | | <el-table-column label="电子文件" prop="url" width="120" align="center"> |
| | | |
| | | <template slot-scope="scope" > |
| | |
| | | alt="" |
| | | style="width: 35px; height: 35px;" |
| | | fit="cover" |
| | | v-if="scope.row.url !== ',' " |
| | | v-if="!(scope.row.url === '' || scope.row.url === ',' || scope.row.url === null)" |
| | | > |
| | | <img |
| | | v-else |
| | | class="el-upload-list__item-thumbnail" |
| | | src="../../assets/images/deviceA.png" |
| | | alt="" |
| | | style="width: 35px; height: 35px;" |
| | | fit="cover" |
| | | v-if="scope.row.url === ','" |
| | | |
| | | ></div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> |
| | | <el-table-column label="操作" align="center" width="250" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope" v-if="scope.row.roleId !== 1"> |
| | | <el-button |
| | | <div class="button-container"> |
| | | <el-button |
| | | size="mini" |
| | | type="text" |
| | | icon="el-icon-edit" |
| | |
| | | <el-button size="mini" type="text" icon="el-icon-d-arrow-right" @click="handleCheck(scope.row)">查看详情</el-button> |
| | | |
| | | </el-dropdown> |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="发生时间" prop="happenTime"> |
| | | <el-date-picker |
| | | v-model='formDat.happenTime' |
| | | type='date' |
| | | placeholder='选择日期' |
| | | <el-date-picker v-model="formDat.happenTime" type="date" placeholder="请选择日期" |
| | | :editable="false" :clearable="false" :style="{width: '100%'}" value-format="yyyy-MM-dd" |
| | | ></el-date-picker> |
| | | </el-form-item> |
| | | |
| | |
| | | :http-request="requestUpload" |
| | | :file-list="fileList" |
| | | > |
| | | <i slot="default" class="el-icon-plus"></i> |
| | | <i slot="default" class="el-icon-plus"></i> |
| | | <div slot="file" slot-scope="{file}"> |
| | | <img |
| | | class="el-upload-list__item-thumbnail" |
| | |
| | | :http-request="requestUpload" |
| | | :show-file-list="true" |
| | | > |
| | | <el-button type="primary">上传</el-button> |
| | | <el-button type="primary">点击上传</el-button> |
| | | <div v-if="uploading" class="upload-status">正在上传...</div> |
| | | <template #tip> |
| | | <div class="el-upload__tip"> |
| | | </div> |
| | |
| | | // 日期范围 |
| | | dateRange: [], |
| | | // 数据范围选项 |
| | | fot:[".jpg",".jif"], |
| | | fot:['.bmp','.jpg','.jpeg','.png','.tif','.gif','.pcx','.tga','.exif','.fpx', |
| | | '.svg','.psd','.cdr','.pcd','.dxf','.ufo','.eps','.ai','.aw','.WMF','.webp','.apng'], |
| | | |
| | | fileList:[ |
| | | ], |
| | | fileListOther:[ |
| | |
| | | ], |
| | | dsb:true, |
| | | btn:false, |
| | | uploading: false, |
| | | formDat: { |
| | | // type: undefined, |
| | | content: undefined, |
| | |
| | | this.queryParams.happenEndTime = this.dateRange.length > 0 && this.dateRange[1] |
| | | // console.log(this.queryParams) |
| | | // listProperty(this.addDateRange(this.queryParams, this.dateRange)).then(response => { |
| | | let _this = this |
| | | listEquipment(this.queryParams).then(response => { |
| | | // alert(123) |
| | | // console.log(response.data) |
| | | this.equipmentList = response.data.data; |
| | | if(response.msg=="您没加入到对应的家庭,请联系管理员") |
| | | { |
| | | _this.$modal.msgSuccess("您没加入到对应的家庭,请联系管理员"); |
| | | _this.loading = false; |
| | | }else{ |
| | | _this.equipmentList = response.data.data; |
| | | |
| | | this.total = response.data.total; |
| | | this.loading = false; |
| | | _this.total = response.data.total; |
| | | _this.loading = false; |
| | | } |
| | | } |
| | | ); |
| | | }, |
| | |
| | | Object.keys(this.formDat).forEach(key => { |
| | | this.formDat[key] = ''; |
| | | }); |
| | | this.handleRemove(this.fileList[0]); |
| | | this.handleRemoveFile(this.fileListOther[0]); |
| | | for(let i = 0; i <= this.fileList.length; i++) |
| | | { |
| | | this.handleRemove(this.fileList[0]); |
| | | } |
| | | for(let i = 0; i < this.fileListOther.length; i++){ |
| | | this.handleRemoveFile(this.fileListOther[0]); |
| | | } |
| | | }, |
| | | requestUpload(params) |
| | | { |
| | |
| | | var formData = new FormData(); |
| | | formData.append('uploadFile', file); |
| | | let _this = this |
| | | |
| | | this.uploading = true; |
| | | uploadPic(formData).then(response => { |
| | | let pth = response.data.originalFilename.substr(response.data.originalFilename.length-4, response.data.originalFilename.length) |
| | | |
| | | this.uploading = false; |
| | | this.$modal.msgSuccess("上传成功"); |
| | | if(_this.fot.includes(pth) === true) |
| | | { |
| | | _this.fileList.push({name:response.data.fileName, "url":response.data.url}) |
| | |
| | | background: #FFEFF2; |
| | | |
| | | } |
| | | .el-table__cell { |
| | | font-size: 14px; /* 设置字体大小 */ |
| | | } |
| | | .button-container { |
| | | display: inline-flex; /* 设置按钮容器为行内元素 */ |
| | | } |
| | | </style> |