<template>
  <div class="app-container" v-if="isShow == 1">
    <div class="screen-container">
      <el-form :model="form" ref="form" :inline="false">
        <el-row :gutter="20">
          <el-col :xs="24" :ms="12" :lg="12">
            <el-form-item label="">
              <el-input
                v-model="input"
                placeholder="营销活动管理"
                size="small"
              ></el-input>
            </el-form-item>
          </el-col>

          <el-col :xs="24" :ms="12" :lg="12" class="tr">
            <el-form-item>
              <el-button type="primary" size="small">查询</el-button>
              <el-button size="small">重置</el-button>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>
    </div>
    <div class="btn-group">
      <el-row type="flex">
        <el-button type="primary" class="btn" size="small">导出</el-button>
        <el-button type="text" size="small">打印</el-button>
      </el-row>
    </div>
    <div class="mymain-container">
      <el-table :data="tableData" border style="width: 100%">
        <el-table-column fixed="left" label="操作" width="120" align="center">
          <template slot-scope="scope">
            <el-button type="text" size="small">编辑</el-button>
            <el-button type="text" size="small">删除</el-button>
          </template>
        </el-table-column>
        <el-table-column prop="name" label="状态" width="120" align="center">
        </el-table-column>
        <el-table-column prop="province" label="营销活动" align="center">
        </el-table-column>
        <el-table-column prop="city" label="生效时间" align="center">
        </el-table-column>
        <el-table-column prop="address" label="结束时间" align="center">
        </el-table-column>

        <el-table-column prop="zip" label="创建者" align="center">
        </el-table-column>
        <el-table-column prop="zip" label="创建时间" align="center">
        </el-table-column>
        <el-table-column prop="zip" label="更新者" align="center">
        </el-table-column>
        <el-table-column prop="zip" label="更新时间" align="center">
        </el-table-column>
      </el-table>
      <Pagination />
    </div>
  </div>
  <AddPolicy v-else-if="isShow == 2" />
  <AddCondition v-else-if="isShow == 3" />
  <Examine v-else-if="isShow == 4" />
  <AddModel v-else />
</template>

<script>
import AddPolicy from "./components/AddPolicy";
import AddModel from "./components/AddModel";
import Pagination from "@/components/Pagination";
import AddCondition from "./components/AddCondition";
import Examine from "./components/Examine";
export default {
  data() {
    return {
      input: "",
      isShow: 1,
      tableData: [
        {
          date: "2016-05-02",
          name: "王小虎",
          province: "上海",
          city: "普陀区",
          address: "上海市普陀区金沙江路 1518 弄",
          zip: 200333,
        },
        {
          date: "2016-05-04",
          name: "王小虎",
          province: "上海",
          city: "普陀区",
          address: "上海市普陀区金沙江路 1517 弄",
          zip: 200333,
        },
        {
          date: "2016-05-01",
          name: "王小虎",
          province: "上海",
          city: "普陀区",
          address: "上海市普陀区金沙江路 1519 弄",
          zip: 200333,
        },
        {
          date: "2016-05-03",
          name: "王小虎",
          province: "上海",
          city: "普陀区",
          address: "上海市普陀区金沙江路 1516 弄",
          zip: 200333,
        },
      ],
      form: {},
      options: {},
      value: "",
      imageUrl: "",
    };
  },
  components: {
    Examine,
    AddModel,
    AddPolicy,
    Pagination,
    AddCondition,
  },
};
</script>

<style lang="scss" scoped>
.btn {
  width: 80px;
}

.mpd {
  padding: 20px 0 0 0;
}

.select_height {
  width: 100%;
}
</style>
