| | |
| | | VUE_APP_API_BASE_URL=http://api.iczer.com |
| | | VUE_APP_ROLE_LIST=admin.roleList |
| | | VUE_APP_DEPARTMENT_LIST=admin.departmentList |
| | | VUE_APP_DOWNLOAD_FLAG=admin.downloadFlag |
| | | VUE_APP_PROJECT_MANAGER_LIST= admin.projectManagerList |
| | | VUE_APP_GENERAL_MANAGER_LIST = admin.generalManagerList |
| | |
| | | }, |
| | | methods: { |
| | | ...mapMutations('account', ['setUser', 'setPermissions', 'setRoles', 'setRoleList', |
| | | 'setDepartmentList', 'setDownloadFlag', 'setProjectManagerList', 'setGeneralManagerList']), |
| | | 'setDepartmentList', 'setProjectManagerList', 'setGeneralManagerList']), |
| | | onSubmit (e) { |
| | | let vm = this; |
| | | e.preventDefault() |
| | |
| | | this.logging = false |
| | | const loginRes = res.data |
| | | if (loginRes.code >= 0) { |
| | | const {user, permissions, roles, roleList, departmentList, downloadFlag} = this.getData(loginRes.data2, loginRes.data3); |
| | | const {user, permissions, roles, roleList, departmentList } = this.getData(loginRes.data2, loginRes.data3); |
| | | this.setUser(user); |
| | | this.setPermissions(permissions); |
| | | this.setRoles(roles); |
| | | this.setRoleList(roleList); |
| | | this.setDepartmentList(departmentList); |
| | | this.setDownloadFlag(downloadFlag); |
| | | this.getUserByRoleId(1002); |
| | | this.getUserByRoleId(1003); |
| | | |
| | |
| | | item.value = item.id; |
| | | return item; |
| | | }), |
| | | downloadFlag: data.dloadFlag, |
| | | departmentList: data3.departs.map(item=>{ |
| | | item.key = item.departId; |
| | | item.label = item.departName; |
| | |
| | | <a-card> |
| | | <template v-if="record.subCode"> |
| | | <a-button @click="dwgReview(record.dwgUrl)">预览</a-button> |
| | | <a-button v-if="downloadFlag" @click="downloadLog(record)" |
| | | <a-button @click="downloadLog(record)" |
| | | >下载</a-button |
| | | > |
| | | </template> |
| | |
| | | YcList, |
| | | }, |
| | | computed: { |
| | | ...mapGetters("account", ["downloadFlag"]), |
| | | }, |
| | | methods: { |
| | | getInfo() { |
| | |
| | | <template v-if="record.dwgUrl"> |
| | | <a-divider type="vertical"></a-divider> |
| | | <a @click="dwgReview(record.dwgUrl)">预览</a> |
| | | <template v-if="downloadFlag"> |
| | | <template> |
| | | <a-divider type="vertical"></a-divider> |
| | | <a @click="downloadLog(record)">下载</a> |
| | | </template> |
| | |
| | | return this.isAdd ? "批量增加关联关系" : "批量解除关联关系"; |
| | | }, |
| | | ...mapGetters("setting", ["affixed"]), |
| | | ...mapGetters("account", ["downloadFlag"]), |
| | | }, |
| | | components: { |
| | | AdvanceTable, |
| | |
| | | <files-table slot="content" :list="otherDoc"></files-table> |
| | | <a-button type="primary">其他附件</a-button> |
| | | </a-popover> |
| | | <a-button type="primary" v-if="downloadFlag" @click="zipDownload" |
| | | <a-button type="primary" @click="zipDownload" |
| | | >bom下载</a-button |
| | | > |
| | | <a-button |
| | | type="primary" |
| | | v-if="downloadFlag && softwareList.length" |
| | | v-if="softwareList.length" |
| | | @click="showSoftwareDownload" |
| | | >软件下载</a-button |
| | | > |
| | |
| | | FilesTable, |
| | | }, |
| | | computed: { |
| | | ...mapGetters("account", ["downloadFlag"]), |
| | | ...mapGetters("setting", ["affixed"]), |
| | | }, |
| | | watch: { |
| | |
| | | <a-space direction="vertical" slot="content"> |
| | | <a-button type="primary" @click="edit(record)">编辑</a-button> |
| | | <a-button |
| | | v-if="downloadFlag" |
| | | |
| | | type="primary" |
| | | @click="download(record)" |
| | | >下载</a-button |
| | |
| | | }, |
| | | computed: { |
| | | ...mapGetters("account", [ |
| | | "downloadFlag", |
| | | "roles", |
| | | "projectManagerList", |
| | | "generalManagerList", |
| | |
| | | <span class="title">软件中心</span> |
| | | </template> |
| | | <template slot="action" slot-scope="{ record }"> |
| | | <template v-if="downloadFlag"> |
| | | <template > |
| | | <a @click="download(record)">下载</a> |
| | | </template> |
| | | </template> |
| | |
| | | }, |
| | | }, |
| | | computed: { |
| | | ...mapGetters("account", ["downloadFlag"]), |
| | | }, |
| | | mounted() { |
| | | this.searchData(); |
| | |
| | | </a-select> |
| | | </a-form-model-item> |
| | | </a-col> |
| | | <a-col :span="24"> |
| | | <a-form-model-item |
| | | label="下载权限" |
| | | :labelCol="{ span: 8 }" |
| | | :wrapperCol="{ span: 15, offset: 1 }" |
| | | prop="downloadF" |
| | | > |
| | | <a-switch :default-checked="!!info.dloadFlag" @change="changeDload"> |
| | | <a-icon slot="checkedChildren" type="check" /> |
| | | <a-icon slot="unCheckedChildren" type="close" /> |
| | | </a-switch> |
| | | </a-form-model-item> |
| | | </a-col> |
| | | </a-row> |
| | | </a-layout-content> |
| | | </a-layout> |
| | |
| | | drole: { |
| | | roleName: "", |
| | | }, |
| | | dloadFlag: 0, |
| | | desc: "4165465", |
| | | }; |
| | | function getBase64(file) { |
| | |
| | | }, |
| | | submit() { |
| | | let formData = new FormData(); |
| | | let { id, tel, phone, departId, faceId, roleId, name, dloadFlag } = this.info; |
| | | let { id, tel, phone, departId, faceId, roleId, name } = this.info; |
| | | let params = {}; |
| | | let operation; |
| | | if (this.isEdit) { |
| | | operation = editUser; |
| | | params = { id, tel, phone, departId, faceId, roleId, dloadFlag }; |
| | | params = { id, tel, phone, departId, faceId, roleId }; |
| | | } else { |
| | | operation = addUser; |
| | | params = { name, tel, phone, departId, faceId, roleId, dloadFlag }; |
| | | params = { name, tel, phone, departId, faceId, roleId }; |
| | | } |
| | | let json = JSON.stringify(params); |
| | | // console.log(json); |
| | |
| | | resetFields() { |
| | | this.$refs.formRef.resetFields(); |
| | | }, |
| | | changeDload(checked) { |
| | | // console.log(checked, 99) |
| | | this.info.dloadFlag = checked * 1; |
| | | } |
| | | }, |
| | | |
| | | mounted() { |
| | |
| | | } |
| | | }, |
| | | computed: { |
| | | ...mapGetters('account', ['roles', "roleList", "departmentList", "downloadFlag"]), |
| | | ...mapGetters('account', ['roles', "roleList", "departmentList"]), |
| | | ...mapGetters("setting", ["affixed", "minHeight"]), |
| | | }, |
| | | mounted() { |
| | |
| | | routesConfig: null, |
| | | roleList: null, |
| | | departmentList: null, |
| | | downloadFlag: null, |
| | | projectManagerList: null, // 项目经理列表 |
| | | generalManagerList: null, // 总经理列表 |
| | | }, |
| | |
| | | } |
| | | return state.roleList; |
| | | }, |
| | | downloadFlag: state=>{ |
| | | const downloadFlag = localStorage.getItem(process.env.VUE_APP_DOWNLOAD_FLAG); |
| | | state.downloadFlag = downloadFlag; |
| | | return state.downloadFlag == 1?true:false; |
| | | }, |
| | | projectManagerList: state=>{ |
| | | if(!state.projectManagerList) { |
| | | try { |
| | |
| | | setDepartmentList(state, departmentList) { |
| | | state.departmentList = departmentList; |
| | | localStorage.setItem(process.env.VUE_APP_DEPARTMENT_LIST, JSON.stringify(departmentList)); |
| | | }, |
| | | setDownloadFlag(state, downloadFlag) { |
| | | state.downloadFlag = downloadFlag; |
| | | localStorage.setItem(process.env.VUE_APP_DOWNLOAD_FLAG, downloadFlag); |
| | | }, |
| | | setProjectManagerList(state, projectManagerList) { |
| | | state.projectManagerList = projectManagerList; |