linwenling
2023-04-11 25ddd158fa9be7784c5b513bd3f7f8290e372b7f
ruoyi-ui/src/views/bignote/index.vue
@@ -38,7 +38,7 @@
          v-model="queryParams.address"
          placeholder="请输入地点"
          clearable
          style="width: 197px;
          style=" width:197px;
height: 30px;
background: #FFFFFF;
border-radius: 14px 14px 14px 14px;
@@ -51,7 +51,7 @@
      <el-form-item label="时间">
        <el-date-picker
          v-model="dateRange"
          style=" width: 197px;
          style="width:  197px;
height: 30px;
background: #FFFFFF;
border-radius: 14px 14px 14px 14px;
@@ -65,12 +65,12 @@
        ></el-date-picker>
      </el-form-item>
      <el-form-item>
        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
        <el-button size="mini" @click="handleQuery" style=" width: 65px; height: 32px;background: #FFDDE3;
          border-radius: 6px 6px 6px 6px;opacity:1; " >搜索</el-button>
        <el-button  size="mini" @click="resetQuery" style=" width: 65px; height: 32px;background: #FFDDE3;
          border-radius: 6px 6px 6px 6px;opacity:1; " >重置</el-button>
      </el-form-item>
    </el-form>
    <div style="width: 72px;
height: 24px;
@@ -118,7 +118,7 @@
    </el-row>
    <!-- 序号、时间、人物、地点、大事标题、电子文件、备注 -->
    <!-- 这里有个familyList数组 是在data()中定义的 -->
    <el-table v-loading="loading"  :data="familyList" @selection-change="handleSelectionChange" >
    <el-table v-loading="loading"  :data="familyList" @selection-change="handleSelectionChange"  :row-class-name="tableRowClassName">
      <el-table-column type="selection" width="55"  align="center" />
      <el-table-column label="序号" prop="id" sortable width="120" />
@@ -132,7 +132,7 @@
      <el-table-column label="大事标题" prop="title" sortable :show-overflow-tooltip="true" width="150" />
      <el-table-column label="备注" prop="remark" sortable width="100" />
      <el-table-colum label="电子文件" prop="fujian" sortable width="100"/>
      <!-- <el-table-colum label="电子文件" prop="url" sortable width="100"/> -->
      <el-table-column label="家庭号" prop="familyId" sortable width="100" />
      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
        <template slot-scope="scope" v-if="scope.row.roleId !== 1">
@@ -164,6 +164,7 @@
      :page.sync="queryParams.pageNum"
      :limit.sync="queryParams.pageSize"
      @pagination="getList"
      style="background: #FEF7FC;"
    />
    <!-- 添加或修改资产信息配置对话框 -->
@@ -318,7 +319,7 @@
      dsb:true,
      btn:false,
      formDat: {
        type: undefined,
        // type: undefined,
        title: undefined,
        location: undefined,
        holder: undefined,
@@ -391,29 +392,25 @@
    },
    //隔行变色
    tableRowClassName({ row, rowIndex }) {
      if (rowIndex % 2 == 0) {
        return "statistics-warning-row1";
      } else {
        return "statistics-warning-row";
      }
    },
    //   methods: {
    //   tableRowClassName({row, rowIndex}) {
    //     if (rowIndex === 1)  //=>这里可以改成 rowIndex%2=== 1,后面直接else即可达到隔行变色效果。
    //     {
    //       return 'warning-row';
    //     } else if (rowIndex === 3) {
    //       return 'success-row';
    //     }
    //     return '';
    //   }
    // },
    /** 查询角色列表 */
    //列表显示家大事记
    getList() {
      this.loading = true;
       console.log(this.queryParams)
      console.log(this.queryParams)
      //  listProperty(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
      listFamilyevent(this.queryParams).then(response => {
         //    console.log(response.data.data)
          //  alert(123)
          //   console.log(response.data)
          this.familyList = response.data.data;
          this.total = response.data.total;
@@ -458,7 +455,6 @@
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
@@ -486,8 +482,7 @@
    /** 查看详细信息 */
    handleCheck(row){
      const id = row.id;
      this.$router.push("/family1/bignote/familyeventInfo/" + id);
      this.$router.push("/family/zfEvent/bignote/familyeventInfo/" + id);
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
@@ -495,7 +490,7 @@
      let jd = true
      this.$router.push({
        path:"/family1/bignote/familyeventInfo/" + id,
        path:"/family/zfEvent/bignote/familyeventInfo/" + id,
        query:{
          detail:jd
        }
@@ -570,3 +565,13 @@
  }
};
</script>
<style>
.el-table__row.statistics-warning-row {
  background: #E0EEFE;
}
.el-table__row.statistics-warning-row1 {
  background: #FFEFF2;
}
</style>