2025-05-30刘润玉复制代码恢复工程,修改了登录、工单、工作任务计划、排班、用户等组件vue。
| | |
| | | { |
| | | "name": "ProductionControl", |
| | | "name": "pms", |
| | | "version": "0.1.0", |
| | | "private": true, |
| | | "scripts": { |
| | |
| | | ><i class="el-icon-menu"></i><span>生产流程管理</span></el-menu-item |
| | | > |
| | | <el-menu-item index="/production/assembly" |
| | | ><i class="el-icon-menu"></i><span>组装任务计划</span></el-menu-item |
| | | ><i class="el-icon-menu"></i><span>生产任务计划</span></el-menu-item |
| | | > |
| | | </el-menu-item-group> |
| | | </el-submenu> |
| | |
| | | }, |
| | | meta: { |
| | | keepAlive: true, |
| | | title: '组装任务计划管理' |
| | | title: '生产任务计划管理' |
| | | } |
| | | }, |
| | | { |
| | |
| | | data() { |
| | | return { |
| | | form: { |
| | | phone: "admin", |
| | | password: "123456", |
| | | captcha: "1234", |
| | | //phone: "admin", |
| | | //password: "123456", |
| | | //captcha: "1234", |
| | | phone: "", |
| | | password: "", |
| | | captcha: "", |
| | | }, |
| | | rules: { |
| | | phone: [ |
| | |
| | | <div class="assembly viewWrap"> |
| | | <a ref="download" style="display: none" /> |
| | | <ProductList ref="productList"></ProductList> |
| | | <h2>组装任务计划管理</h2> |
| | | <h2>生产任务计划管理</h2> |
| | | <!-- 搜索功能区 --> |
| | | <div class="wrap"> |
| | | <div class="searchWrap"> |
| | |
| | | this.formData.endDate = null; |
| | | this.formData.status = null; |
| | | this.showFromData = true; |
| | | this.dialogTitle = "添加组装任务计划"; |
| | | this.dialogTitle = "添加生产任务计划"; |
| | | }, |
| | | // 关闭 |
| | | handleFormDataClose: function () { |
| | |
| | | this.formData.endDate = row.endDate; |
| | | this.formData.status = row.status; |
| | | this.showFromData = true; |
| | | this.dialogTitle = "编辑组装任务计划"; |
| | | this.dialogTitle = "编辑生产任务计划"; |
| | | this.onGetProcessData(); |
| | | }, |
| | | handleOrderIdChange: function () { |
| | |
| | | </el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="id" label="订单号"> </el-table-column> |
| | | <el-table-column prop="name" label="订单名称"> </el-table-column> |
| | | <el-table-column prop="projectName" label="项目名称"> </el-table-column> |
| | | <el-table-column prop="director" label="负责人" width="160"> </el-table-column> |
| | |
| | | </el-table-column> |
| | | <el-table-column type="index" label="序号"> </el-table-column> |
| | | <el-table-column prop="userName" label="姓名"> </el-table-column> |
| | | <el-table-column prop="userId" label="用户ID"> </el-table-column> |
| | | <el-table-column prop="scheduleDate" label="排班日期"> |
| | | </el-table-column> |
| | | <el-table-column prop="dt" label="任务条目"> |
| | | <el-table-column prop="scheduleDate" label="排班日期"></el-table-column> |
| | | <el-table-column prop="dt" label="工作任务数量"> |
| | | <template slot-scope="props"> |
| | | {{ props.row.relList.length }} |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="dt" label="创建时间" width="170"> |
| | | </el-table-column> |
| | | <el-table-column label="操作" width="150"> |
| | | <el-table-column prop="dt" label="创建时间"></el-table-column> |
| | | <el-table-column label="操作" width="180"> |
| | | <template slot-scope="scope"> |
| | | <el-button icon="el-icon-edit" @click.native.prevent="handleFormDataEdit(scope.row)" type="text" size="small"> |
| | | 编辑 |
| | |
| | | // 获取任务数据 |
| | | onGetPlanData: function () { |
| | | var that = this; |
| | | var data = { planName: "组装任务" }; |
| | | //var data = { planName: "生产任务" }; |
| | | var data = {}; |
| | | that |
| | | .$axiosAdmin({ |
| | | method: "post", |
| | |
| | | this.onGetSelectData(); |
| | | this.onGetStationData(); |
| | | }, |
| | | // 删除 |
| | | handleDelete: function (row) { |
| | | this.$confirm(`此操作将删除 ${row.userName} 排班 , 是否继续?`, "提示", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | this.$confirm(`此操作为危险操作 , 是否继续?`, "提示", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | this.onDelete(row); |
| | | }) |
| | | .catch(() => { |
| | | this.$message({ |
| | | type: "info", |
| | | message: "已取消", |
| | | }); |
| | | }); |
| | | }) |
| | | .catch(() => { |
| | | this.$message({ |
| | | type: "info", |
| | | message: "已取消", |
| | | }); |
| | | }); |
| | | }, |
| | | // 执行删除 |
| | | onDelete: function (row) { |
| | | var that = this; |
| | | var params = { |
| | | id: row.id, |
| | | }; |
| | | that |
| | | .$axiosAdmin({ |
| | | method: "get", |
| | | url: "production/schedule/delete", |
| | | params: params, |
| | | }) |
| | | .then((res) => { |
| | | if (res.success == true) { |
| | | that.$message({ |
| | | type: "success", |
| | | message: "删除成功", |
| | | }); |
| | | } else { |
| | | that.$alert(res.content, "提示", { |
| | | confirmButtonText: "确定", |
| | | }); |
| | | } |
| | | that.onGetTableData(); |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err); |
| | | }); |
| | | }, |
| | | // 添加工作内容 |
| | | handleAddRelListItem: function () { |
| | | this.formData.relList.push({ |
| | |
| | | <template> |
| | | <div class="user viewWrap"> |
| | | <a ref="download" style="display: none" /> |
| | | <h2>用户管理</h2> |
| | | <!-- 搜索功能区 --> |
| | | <div class="wrap"> |
| | |
| | | </div> |
| | | |
| | | <!-- 数据功能按钮区 --> |
| | | <div> |
| | | <el-button type="primary" style="margin-top: 20px; width: 100px;" icon="el-icon-plus" |
| | | @click="handleFormDataAdd">添加</el-button> |
| | | |
| | | <el-button type="primary" style="margin-top: 20px; width: 100px;" icon="el-icon-download" |
| | | @click="handleExport">导出</el-button> |
| | | </div> |
| | | |
| | | <!-- 数据表格区 --> |
| | | <el-table stripe :data="tableData" height="0" style="margin-top: 20px;"> |
| | | <el-table-column type="index" label="序号"> </el-table-column> |
| | |
| | | this.onGetRoleData(); |
| | | this.onGetDefaultPassword(); |
| | | }, |
| | | // 导出 |
| | | handleExport: function () { |
| | | var that = this; |
| | | that |
| | | .$axiosAdmin({ |
| | | method: "post", |
| | | responseType: "blob", |
| | | url: "base/user/export", |
| | | data: JSON.stringify({ |
| | | "type":"" |
| | | }) |
| | | }) |
| | | .then((res) => { |
| | | const blob = res; |
| | | that.$refs.download.href = window.URL.createObjectURL(new Blob([blob], {type:'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'})); |
| | | that.$refs.download.download = `用户信息.xlsx`; |
| | | that.$refs.download.click(); |
| | | }) |
| | | .catch((err) => { |
| | | console.log(err); |
| | | }); |
| | | }, |
| | | // 关闭 |
| | | handleFormDataClose: function () { |
| | | this.formData.id = null; |