| | |
| | | :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" |
| | | @change="handleTableChange"> |
| | | |
| | | <template slot="avatarslot" slot-scope="text, record, index"> |
| | | <template slot="avatarslot" slot-scope="text, record"> |
| | | <div class="anty-img-wrap"> |
| | | <a-avatar shape="square" :src="getAvatarView(record.avatar)" icon="user"/> |
| | | </div> |
| | |
| | | import UserRecycleBinModal from './modules/UserRecycleBinModal' |
| | | import JSuperQuery from '@/components/jeecg/JSuperQuery' |
| | | import JThirdAppButton from '@/components/jeecgbiz/thirdApp/JThirdAppButton' |
| | | import {mapActions} from 'vuex' |
| | | |
| | | export default { |
| | | name: "UserList", |
| | |
| | | title: '车间', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'productionName' |
| | | dataIndex: 'productionName', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '状态', |
| | |
| | | { |
| | | title: '操作', |
| | | dataIndex: 'action', |
| | | scopedSlots: {customRender: 'action'}, |
| | | scopedSlots: { customRender: 'action' }, |
| | | align: "center", |
| | | width: 80 |
| | | } |
| | | }, |
| | | |
| | | |
| | | ], |
| | | isDepartType:'', |
| | | superQueryFieldList: [ |
| | | { type: 'input', value: 'username', text: '用户账号', }, |
| | | { type: 'input', value: 'realname', text: '用户姓名', }, |
| | |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; |
| | | } |
| | | }, |
| | | methods: { |
| | | created() { |
| | | this.queryTreeData() |
| | | }, |
| | | methods: { |
| | | ...mapActions(['QueryDepartTree']), |
| | | queryTreeData() { |
| | | this.QueryDepartTree().then(res => { |
| | | if (res.success) { |
| | | this.isDepartType = res.result[0].value |
| | | if(this.isDepartType == -1){ |
| | | this.columns=[ |
| | | { |
| | | title: '用户账号', |
| | | align: "center", |
| | | dataIndex: 'username', |
| | | width: 120, |
| | | sorter: true |
| | | }, |
| | | { |
| | | title: '用户姓名', |
| | | align: "center", |
| | | width: 100, |
| | | dataIndex: 'realname', |
| | | }, |
| | | { |
| | | title: '头像', |
| | | align: "center", |
| | | width: 80, |
| | | dataIndex: 'avatar', |
| | | scopedSlots: {customRender: "avatarslot"} |
| | | }, |
| | | |
| | | // { |
| | | // title: '性别', |
| | | // align: "center", |
| | | // width: 80, |
| | | // dataIndex: 'sex_dictText', |
| | | // sorter: true |
| | | // }, |
| | | // { |
| | | // title: '生日', |
| | | // align: "center", |
| | | // width: 100, |
| | | // dataIndex: 'birthday' |
| | | // }, |
| | | // { |
| | | // title: '手机号码', |
| | | // align: "center", |
| | | // width: 100, |
| | | // dataIndex: 'phone' |
| | | // }, |
| | | { |
| | | title: '车间', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'productionName', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '状态', |
| | | align: "center", |
| | | width: 80, |
| | | dataIndex: 'status_dictText' |
| | | }, |
| | | { |
| | | title: '操作', |
| | | dataIndex: 'action', |
| | | scopedSlots: { customRender: 'action' }, |
| | | align: "center", |
| | | width: 80 |
| | | }, |
| | | |
| | | |
| | | ] |
| | | }else{ |
| | | this.columns= [ |
| | | { |
| | | title: '用户账号', |
| | | align: "center", |
| | | dataIndex: 'username', |
| | | width: 120, |
| | | sorter: true |
| | | }, |
| | | { |
| | | title: '用户姓名', |
| | | align: "center", |
| | | width: 100, |
| | | dataIndex: 'realname', |
| | | }, |
| | | { |
| | | title: '头像', |
| | | align: "center", |
| | | width: 80, |
| | | dataIndex: 'avatar', |
| | | scopedSlots: {customRender: "avatarslot"} |
| | | }, |
| | | |
| | | // { |
| | | // title: '性别', |
| | | // align: "center", |
| | | // width: 80, |
| | | // dataIndex: 'sex_dictText', |
| | | // sorter: true |
| | | // }, |
| | | // { |
| | | // title: '生日', |
| | | // align: "center", |
| | | // width: 100, |
| | | // dataIndex: 'birthday' |
| | | // }, |
| | | // { |
| | | // title: '手机号码', |
| | | // align: "center", |
| | | // width: 100, |
| | | // dataIndex: 'phone' |
| | | // }, |
| | | { |
| | | title: '部门', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'orgCodeTxt' |
| | | }, |
| | | { |
| | | title: '车间', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'productionName', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '班组', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'teamId_dictText' |
| | | }, |
| | | { |
| | | title: '状态', |
| | | align: "center", |
| | | width: 80, |
| | | dataIndex: 'status_dictText' |
| | | }, |
| | | { |
| | | title: '操作', |
| | | dataIndex: 'action', |
| | | scopedSlots: { customRender: 'action' }, |
| | | align: "center", |
| | | width: 80 |
| | | } |
| | | |
| | | |
| | | ] |
| | | } |
| | | |
| | | } else { |
| | | // this.$message.warn(res.message) |
| | | this.$notification.warning({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | } |
| | | }).finally(() =>{ |
| | | }) |
| | | }, |
| | | getAvatarView: function (avatar) { |
| | | return getFileAccessHttpUrl(avatar) |
| | | }, |
| | |
| | | } |
| | | frozenBatch({ids: id, status: status}).then((res) => { |
| | | if (res.success) { |
| | | that.$message.success(res.message); |
| | | that.$notification.success({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | that.loadData(); |
| | | } else { |
| | | that.$message.warning(res.message); |
| | | that.$notification.warning({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | } |
| | | }); |
| | | }, |