|
|
@@ -37,20 +37,31 @@
|
|
|
<router-link :to="'/oilsupplier/goodsaptitude/' + scope.row.Id + '/operation'">
|
|
|
<el-button type="primary" plain title="编辑" size="mini">编辑</el-button>
|
|
|
</router-link>
|
|
|
-
|
|
|
- <el-popover placement="top" title="提示">
|
|
|
- <el-alert
|
|
|
- title=""
|
|
|
- description="确认要删除吗?"
|
|
|
- type="warning"
|
|
|
- :closable="false">
|
|
|
- </el-alert>
|
|
|
- <br/>
|
|
|
- <div style="text-align: right; margin: 0">
|
|
|
- <el-button type="primary" size="mini" @click="deleteEntity(scope.row)">删除</el-button>
|
|
|
- </div>
|
|
|
- <el-button slot="reference" type="primary" plain title="删除" style="margin-left:3px" size="mini">删除</el-button>
|
|
|
- </el-popover>
|
|
|
+ <el-dropdown @command="MoreCmdClick">
|
|
|
+ <el-button size="mini" type="primary" plain>
|
|
|
+ 更多<i class="el-icon-arrow-down el-icon--right"></i>
|
|
|
+ </el-button>
|
|
|
+ <el-dropdown-menu slot="dropdown">
|
|
|
+ <el-dropdown-item :command="GetCommand('Set', scope.row)">审核部门</el-dropdown-item>
|
|
|
+ <el-dropdown-item :command="GetCommand('Delete', scope.row)">删除数据</el-dropdown-item>
|
|
|
+ </el-dropdown-menu>
|
|
|
+ </el-dropdown>
|
|
|
+ <!--<el-button size="small" type="text" style="margin-left:3px" title="审批部门" @click="deptSet(scope.row)">-->
|
|
|
+ <!--<i class="icon icon-users"></i>-->
|
|
|
+ <!--</el-button>-->
|
|
|
+ <!--<el-popover placement="top" title="提示" v-model="scope.row.deleteConfirmFlag">-->
|
|
|
+ <!--<el-alert-->
|
|
|
+ <!--title=""-->
|
|
|
+ <!--description="确认要删除吗?"-->
|
|
|
+ <!--type="warning"-->
|
|
|
+ <!--:closable="false">-->
|
|
|
+ <!--</el-alert>-->
|
|
|
+ <!--<br/>-->
|
|
|
+ <!--<div style="text-align: right; margin: 0">-->
|
|
|
+ <!--<el-button type="primary" size="mini" @click="deleteEntity(scope.row)">删除</el-button>-->
|
|
|
+ <!--</div>-->
|
|
|
+ <!--<el-button slot="reference" type="primary" plain title="删除" style="margin-left:3px" size="mini">删除</el-button>-->
|
|
|
+ <!--</el-popover>-->
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
|
|
|
@@ -483,14 +494,19 @@
|
|
|
<el-button size="mini" type="primary" @click="handleSearch">查 询</el-button>
|
|
|
</span>
|
|
|
</el-dialog>
|
|
|
-
|
|
|
+ <el-dialog title="设置审批部门" :visible.sync="deptsetVisible">
|
|
|
+ <el-tree style="border: 0" show-checkbox node-key="id" :data="operationOrganizeData" :props="organizeProps" ref="operationOriganizeTree">
|
|
|
+ </el-tree>
|
|
|
+ <div slot="footer">
|
|
|
+ <el-button @click="deptsetVisible = false">取消</el-button>
|
|
|
+ <el-button type="primary" @click="saveApprovalDept()">确定</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
- import {
|
|
|
- mapGetters
|
|
|
- } from 'vuex';
|
|
|
- import api from '@/api/oilsupplier/goodsaptitude';
|
|
|
+ import { mapGetters } from 'vuex'
|
|
|
+ import api from '@/api/oilsupplier/goodsaptitude'
|
|
|
|
|
|
export default {
|
|
|
computed: {
|
|
|
@@ -500,23 +516,24 @@
|
|
|
},
|
|
|
name: 'oilgoodsaptitude',
|
|
|
|
|
|
- data() {
|
|
|
+ data () {
|
|
|
return {
|
|
|
+ deptsetVisible: false,
|
|
|
dialogVisible: false,
|
|
|
- //列表数据
|
|
|
+ // 列表数据
|
|
|
entityList: [],
|
|
|
- //分页参数
|
|
|
+ // 分页参数
|
|
|
size: 10,
|
|
|
currentPage: 1,
|
|
|
currentItemCount: 0,
|
|
|
- //列表排序
|
|
|
+ // 列表排序
|
|
|
Column: {
|
|
|
Order: '',
|
|
|
Prop: ''
|
|
|
},
|
|
|
- //查询时间
|
|
|
+ // 查询时间
|
|
|
CreateOn: [new Date(new Date().getTime() - 30 * 24 * 60 * 60 * 1000), new Date()],
|
|
|
- //查询项
|
|
|
+ // 查询项
|
|
|
searchFormReset: {},
|
|
|
searchForm: {
|
|
|
Id: '',
|
|
|
@@ -583,425 +600,475 @@
|
|
|
CreateBy: '',
|
|
|
ModifiedOn: '',
|
|
|
ModifiedUserId: '',
|
|
|
- ModifiedBy: '',
|
|
|
+ ModifiedBy: ''
|
|
|
|
|
|
},
|
|
|
tableColumns: [
|
|
|
|
|
|
{
|
|
|
- prop: "Code",
|
|
|
+ prop: 'Code',
|
|
|
label: '编码',
|
|
|
width: 120,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Name",
|
|
|
+ prop: 'Name',
|
|
|
label: '名称',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Code1",
|
|
|
+ prop: 'Code1',
|
|
|
label: '大类编码',
|
|
|
width: 120,
|
|
|
sort: true
|
|
|
},
|
|
|
{
|
|
|
- prop: "Name1",
|
|
|
+ prop: 'Name1',
|
|
|
label: '大类名称',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Code2",
|
|
|
+ prop: 'Code2',
|
|
|
label: '中类编码',
|
|
|
width: 120,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Name2",
|
|
|
+ prop: 'Name2',
|
|
|
label: '中类名称',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Code3",
|
|
|
+ prop: 'Code3',
|
|
|
label: '小类编码',
|
|
|
width: 120,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Name3",
|
|
|
+ prop: 'Name3',
|
|
|
label: '小类名称',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Code4",
|
|
|
+ prop: 'Code4',
|
|
|
label: '品名编码',
|
|
|
width: 120,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Name4",
|
|
|
+ prop: 'Name4',
|
|
|
label: '品名名称',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "GoodsLevel",
|
|
|
+ prop: 'GoodsLevel',
|
|
|
label: '物资级别',
|
|
|
width: 100,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "GoodsDesc",
|
|
|
+ prop: 'GoodsDesc',
|
|
|
label: '产品说明',
|
|
|
width: 100,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "Standard",
|
|
|
+ prop: 'Standard',
|
|
|
label: '标准备案',
|
|
|
width: 100,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "CompanyType",
|
|
|
+ prop: 'CompanyType',
|
|
|
label: '供应商类型',
|
|
|
width: 100,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F01",
|
|
|
+ prop: 'F01',
|
|
|
label: '营业执照',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F02",
|
|
|
+ prop: 'F02',
|
|
|
label: '组织机构代码证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F03",
|
|
|
+ prop: 'F03',
|
|
|
label: '税务登记证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F04 ",
|
|
|
+ prop: 'F04 ',
|
|
|
label: '银行开户许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F05",
|
|
|
+ prop: 'F05',
|
|
|
label: '质量管理体系认证证书',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F06",
|
|
|
+ prop: 'F06',
|
|
|
label: '环境管理体系认证证书',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F07",
|
|
|
+ prop: 'F07',
|
|
|
label: '职业健康安全管理体系认证证书',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F08",
|
|
|
+ prop: 'F08',
|
|
|
label: '软件企业认定证书',
|
|
|
width: 160,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F09",
|
|
|
+ prop: 'F09',
|
|
|
label: '安全生产许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F10",
|
|
|
+ prop: 'F10',
|
|
|
label: '陆上石油天然气安全生产许可证',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F11",
|
|
|
+ prop: 'F11',
|
|
|
label: '海洋石油作业安全生产许可证',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F12",
|
|
|
+ prop: 'F12',
|
|
|
label: '辐射安全许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F13",
|
|
|
+ prop: 'F13',
|
|
|
label: '石油工程技术服务企业资质证书',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F14",
|
|
|
+ prop: 'F14',
|
|
|
label: '物业服务企业资质证书',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F15",
|
|
|
+ prop: 'F15',
|
|
|
label: '工业清洗企业资质证书',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F16",
|
|
|
+ prop: 'F16',
|
|
|
label: '建设项目环境影响评价资格证书',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F17",
|
|
|
+ prop: 'F17',
|
|
|
label: '消防设施维护保养资质证书',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F18",
|
|
|
+ prop: 'F18',
|
|
|
label: '安全评价机构资质证书',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F19",
|
|
|
+ prop: 'F19',
|
|
|
label: '工程咨询招标代理机构资质证书',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F20",
|
|
|
+ prop: 'F20',
|
|
|
label: '工程监督资质证书',
|
|
|
width: 160,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F21",
|
|
|
+ prop: 'F21',
|
|
|
label: '土地开发资格证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F22",
|
|
|
+ prop: 'F22',
|
|
|
label: '房屋预售资格证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F23",
|
|
|
+ prop: 'F23',
|
|
|
label: '保安服务许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F24",
|
|
|
+ prop: 'F24',
|
|
|
label: '道路运输经营许可证',
|
|
|
width: 180,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F25",
|
|
|
+ prop: 'F25',
|
|
|
label: '机动车维修经营许可证',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F26",
|
|
|
+ prop: 'F26',
|
|
|
label: '道路危险货物运输许可证',
|
|
|
width: 200,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F27",
|
|
|
+ prop: 'F27',
|
|
|
label: '特种设备安装改造维修许可证',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F28",
|
|
|
+ prop: 'F28',
|
|
|
label: '建筑安全许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F29",
|
|
|
+ prop: 'F29',
|
|
|
label: '防火许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F30",
|
|
|
+ prop: 'F30',
|
|
|
label: '印刷经营许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F31",
|
|
|
+ prop: 'F31',
|
|
|
label: '餐饮服务许可证',
|
|
|
width: 150,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F32",
|
|
|
+ prop: 'F32',
|
|
|
label: '劳务派遣经营许可证',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F33",
|
|
|
+ prop: 'F33',
|
|
|
label: '人力资源服务许可证',
|
|
|
width: 180,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F34",
|
|
|
+ prop: 'F34',
|
|
|
label: '国家实验室认可证书',
|
|
|
width: 180,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F35",
|
|
|
+ prop: 'F35',
|
|
|
label: '海洋石油专业设备检验检测机构证书',
|
|
|
width: 270,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F36",
|
|
|
+ prop: 'F36',
|
|
|
label: '安全生产检验检测证书',
|
|
|
width: 190,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F37",
|
|
|
+ prop: 'F37',
|
|
|
label: '液化气钢瓶检验证书',
|
|
|
width: 180,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F38",
|
|
|
+ prop: 'F38',
|
|
|
label: '国家电网承试承装承修许可证',
|
|
|
width: 250,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F39",
|
|
|
+ prop: 'F39',
|
|
|
label: '建筑企业资质证书',
|
|
|
width: 170,
|
|
|
sort: true
|
|
|
},
|
|
|
|
|
|
{
|
|
|
- prop: "F40",
|
|
|
+ prop: 'F40',
|
|
|
label: '中油集团监造许可',
|
|
|
width: 170,
|
|
|
sort: true
|
|
|
},
|
|
|
{
|
|
|
- prop: "Remark",
|
|
|
+ prop: 'Remark',
|
|
|
label: '备注',
|
|
|
width: 100,
|
|
|
sort: true
|
|
|
- },
|
|
|
+ }
|
|
|
|
|
|
- ]
|
|
|
+ ],
|
|
|
+ organizeProps: {
|
|
|
+ value: 'id',
|
|
|
+ label: 'name',
|
|
|
+ children: 'children'
|
|
|
+ },
|
|
|
+ operationOrganizeData: []
|
|
|
}
|
|
|
},
|
|
|
- created() {
|
|
|
- //查询条件初始值备份
|
|
|
- Object.assign(this.searchFormReset, this.searchForm);
|
|
|
- //查询列表
|
|
|
- this.initDatas();
|
|
|
- //this.getDictOptions()
|
|
|
+ created () {
|
|
|
+ // 查询条件初始值备份
|
|
|
+ Object.assign(this.searchFormReset, this.searchForm)
|
|
|
+ // 查询列表
|
|
|
+ this.initDatas()
|
|
|
+ // this.getDictOptions()
|
|
|
},
|
|
|
methods: {
|
|
|
- initDatas() {
|
|
|
- //分页及列表条件
|
|
|
+ saveApprovalDept () {
|
|
|
+ let organizeids = []
|
|
|
+ let organize = this.$refs.operationOriganizeTree.getCheckedNodes()
|
|
|
+ organize.forEach(row => {
|
|
|
+ organizeids.push(row.id)
|
|
|
+ })
|
|
|
+ console.log(organizeids, 'organizeids')
|
|
|
+
|
|
|
+ api.addOrganize(this.selecteclassid, organizeids, this.$axios).then(res => {
|
|
|
+ if (res.data.code === 0) {
|
|
|
+ this.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ this.deptsetVisible = false
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
+ console.log(res.data)
|
|
|
+ }).catch(err => {
|
|
|
+ console.log(err)
|
|
|
+ })
|
|
|
+ },
|
|
|
+ deptSet (val) {
|
|
|
+ this.deptsetVisible = true
|
|
|
+ this.selecteclassid = val.Id
|
|
|
+ // request
|
|
|
+ this.$axios.get('goodsaptitude/getdepartment?id=' + this.selecteclassid, {})
|
|
|
+ .then(res => {
|
|
|
+ console.log(res.data, '===')
|
|
|
+ // response
|
|
|
+ this.operationOrganizeData = window.toolfun_gettreejson(res.data.Organize, 'id', 'pId', 'id,name,scope')
|
|
|
+ if (!res.data.SelectedOrganize) {
|
|
|
+ res.data.SelectedOrganize = []
|
|
|
+ }
|
|
|
+ this.$refs.operationOriganizeTree.setCheckedKeys(res.data.SelectedOrganize, true)
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ console.log(err)
|
|
|
+ })
|
|
|
+ },
|
|
|
+ initDatas () {
|
|
|
+ // 分页及列表条件
|
|
|
let params = {
|
|
|
_currentPage: this.currentPage,
|
|
|
_size: this.size,
|
|
|
Order: this.Column.Order,
|
|
|
- Prop: this.Column.Prop,
|
|
|
+ Prop: this.Column.Prop
|
|
|
}
|
|
|
let myCreateOn = []
|
|
|
// 解析时间
|
|
|
- if (this.CreateOn.length == 2) {
|
|
|
+ if (this.CreateOn.length === 2) {
|
|
|
this.CreateOn[1].setHours(23)
|
|
|
this.CreateOn[1].setMinutes(59)
|
|
|
this.CreateOn[1].setSeconds(59)
|
|
|
myCreateOn.push(this.formatDateTime(this.CreateOn[0]))
|
|
|
myCreateOn.push(this.formatDateTime(this.CreateOn[1]))
|
|
|
}
|
|
|
- //查询条件
|
|
|
+ // 查询条件
|
|
|
Object.assign(params, this.searchForm)
|
|
|
- //访问接口
|
|
|
+ // 访问接口
|
|
|
api.getList(myCreateOn.join(','), params, this.$axios).then(res => {
|
|
|
this.entityList = res.data.items
|
|
|
this.currentItemCount = res.data.currentItemCount
|
|
|
@@ -1010,74 +1077,95 @@
|
|
|
})
|
|
|
},
|
|
|
|
|
|
- getDictOptions() {
|
|
|
+ getDictOptions () {
|
|
|
api.getDictList(this.$axios).then(res => {
|
|
|
- //this.dictOptions.customerList = res.data.items['customerList']
|
|
|
- //this.dictOptions.projectList = res.data.items['projectList']
|
|
|
+ // this.dictOptions.customerList = res.data.items['customerList']
|
|
|
+ // this.dictOptions.projectList = res.data.items['projectList']
|
|
|
|
|
|
}).catch(err => {
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
|
|
|
- searchCommand(command) {
|
|
|
- if (command == 'search') {
|
|
|
+ MoreCmdClick (cmd) {
|
|
|
+ if (cmd.Command === 'Set') {
|
|
|
+ this.deptSet(cmd.row)
|
|
|
+ } else if (cmd.Command === 'Delete') {
|
|
|
+ this.deleteEntity(cmd.row)
|
|
|
+ }
|
|
|
+ },
|
|
|
+ GetCommand (cmdType, row) {
|
|
|
+ let cmd = {}
|
|
|
+ cmd.Command = cmdType
|
|
|
+ cmd.row = row
|
|
|
+ return cmd
|
|
|
+ },
|
|
|
+
|
|
|
+ searchCommand (command) {
|
|
|
+ if (command === 'search') {
|
|
|
this.dialogVisible = true
|
|
|
- } else if (command == 'clear') {
|
|
|
+ } else if (command === 'clear') {
|
|
|
this.clearSearch()
|
|
|
}
|
|
|
},
|
|
|
- //列表排序功能
|
|
|
- orderby(column) {
|
|
|
- if (column.order == 'ascending') {
|
|
|
+ // 列表排序功能
|
|
|
+ orderby (column) {
|
|
|
+ if (column.order === 'ascending') {
|
|
|
this.Column.Order = 'asc'
|
|
|
- } else if (column.order == 'descending') {
|
|
|
+ } else if (column.order === 'descending') {
|
|
|
this.Column.Order = 'desc'
|
|
|
}
|
|
|
this.Column.Prop = column.prop
|
|
|
this.initDatas()
|
|
|
},
|
|
|
- clearSearch() {
|
|
|
- Object.assign(this.searchForm, this.searchFormReset);
|
|
|
- //this.searchForm = this.searchFormReset;
|
|
|
+ clearSearch () {
|
|
|
+ Object.assign(this.searchForm, this.searchFormReset)
|
|
|
+ // this.searchForm = this.searchFormReset;
|
|
|
this.CreateOn = ''
|
|
|
this.initDatas()
|
|
|
},
|
|
|
- handleSearch() {
|
|
|
- this.currentPage = 1;
|
|
|
- this.dialogVisible = false;
|
|
|
- this.initDatas();
|
|
|
+ handleSearch () {
|
|
|
+ this.currentPage = 1
|
|
|
+ this.dialogVisible = false
|
|
|
+ this.initDatas()
|
|
|
},
|
|
|
- handleCurrentChange(value) {
|
|
|
+ handleCurrentChange (value) {
|
|
|
this.currentPage = value
|
|
|
this.initDatas()
|
|
|
},
|
|
|
- handleSizeChange(value) {
|
|
|
+ handleSizeChange (value) {
|
|
|
this.size = value
|
|
|
this.currentPage = 1
|
|
|
this.initDatas()
|
|
|
},
|
|
|
- deleteEntity(row) {
|
|
|
- row.deleteConfirmFlag = false;
|
|
|
- api.deleteEntity(row.Id, this.$axios).then(res => {
|
|
|
- if (res.data.code === 0) {
|
|
|
- this.initDatas();
|
|
|
- this.$message({
|
|
|
- type: 'success',
|
|
|
- message: res.data.message
|
|
|
- });
|
|
|
-
|
|
|
- } else {
|
|
|
- this.$message({
|
|
|
- type: 'warning',
|
|
|
- message: res.data.message
|
|
|
- });
|
|
|
- }
|
|
|
+ deleteEntity (row) {
|
|
|
+ // row.deleteConfirmFlag = false
|
|
|
+ this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ api.deleteEntity(row.Id, this.$axios).then(res => {
|
|
|
+ if (res.data.code === 0) {
|
|
|
+ this.initDatas()
|
|
|
+ this.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
+ }).catch(err => {
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
}).catch(err => {
|
|
|
console.error(err)
|
|
|
- });
|
|
|
+ })
|
|
|
},
|
|
|
-
|
|
|
+
|
|
|
transferStr (val) {
|
|
|
if (val === '1') {
|
|
|
return '是'
|
|
|
@@ -1088,7 +1176,7 @@
|
|
|
}
|
|
|
},
|
|
|
|
|
|
- jstimehandle(val) {
|
|
|
+ jstimehandle (val) {
|
|
|
if (val === '') {
|
|
|
return '----'
|
|
|
} else if (val === '0001-01-01T08:00:00+08:00') {
|
|
|
@@ -1101,18 +1189,17 @@
|
|
|
}
|
|
|
},
|
|
|
|
|
|
- formatDateTime(date) {
|
|
|
- var y = date.getFullYear();
|
|
|
- var m = date.getMonth() + 1;
|
|
|
- m = m < 10 ? ('0' + m) : m;
|
|
|
- var d = date.getDate();
|
|
|
- d = d < 10 ? ('0' + d) : d;
|
|
|
- var h = date.getHours();
|
|
|
- var minute = date.getMinutes();
|
|
|
- minute = minute < 10 ? ('0' + minute) : minute;
|
|
|
- return y + '-' + m + '-' + d + ' ' + h + ':' + minute;
|
|
|
+ formatDateTime (date) {
|
|
|
+ var y = date.getFullYear()
|
|
|
+ var m = date.getMonth() + 1
|
|
|
+ m = m < 10 ? ('0' + m) : m
|
|
|
+ var d = date.getDate()
|
|
|
+ d = d < 10 ? ('0' + d) : d
|
|
|
+ var h = date.getHours()
|
|
|
+ var minute = date.getMinutes()
|
|
|
+ minute = minute < 10 ? ('0' + minute) : minute
|
|
|
+ return y + '-' + m + '-' + d + ' ' + h + ':' + minute
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
</script>
|