1.优化代码2.修改实施部提出的bug3.生产开报工外协列表自动弹窗实现部分
| | |
| | | params: data |
| | | }) |
| | | } |
| | | // 生产开报工:发料/收料时获取外协下拉列表 |
| | | export function MesOrderStepSelectWX(data) { |
| | | return request({ |
| | | url: 'DeviceManager/MesOrderStepSelectWX', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | |
| | | import ScrollPane from './ScrollPane' |
| | | import path from 'path' |
| | | import { getCookie } from '@/utils/auth' |
| | | import $ from 'jquery' |
| | | |
| | | export default { |
| | | components: { ScrollPane }, |
| | |
| | | } |
| | | }, |
| | | isActive(route) { |
| | | if (this.$route.path === '/scgl/sckbg') { |
| | | const time = setInterval(() => { |
| | | this.$nextTick(() => { |
| | | $("input[name='produceCode']")[0].focus() |
| | | $("input[name='WXproduceCode']")[0].focus() |
| | | clearInterval(time) |
| | | }) |
| | | }) |
| | | } |
| | | return route.path === this.$route.path |
| | | }, |
| | | isAffix(tag) { |
| | |
| | | background: #fff; |
| | | border-bottom: 1px solid #d8dce5; |
| | | box-shadow: 0 1px 3px 0 rgba(0, 0, 0, .12), 0 0 3px 0 rgba(0, 0, 0, .04); |
| | | |
| | | .tags-view-wrapper { |
| | | .tags-view-item { |
| | | display: inline-block; |
| | |
| | | font-size: 12px; |
| | | margin-left: 5px; |
| | | margin-top: 4px; |
| | | |
| | | &:first-of-type { |
| | | margin-left: 15px; |
| | | } |
| | | |
| | | &:last-of-type { |
| | | margin-right: 15px; |
| | | } |
| | | |
| | | &.active { |
| | | background-color:$main_color; |
| | | color: #fff; |
| | | border-color:$main_color; |
| | | |
| | | &::before { |
| | | content: ''; |
| | | background: #fff; |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | .contextmenu { |
| | | margin: 0; |
| | | background: #fff; |
| | |
| | | font-weight: 400; |
| | | color: #333; |
| | | box-shadow: 2px 2px 3px 0 rgba(0, 0, 0, .3); |
| | | |
| | | li { |
| | | margin: 0; |
| | | padding: 7px 16px; |
| | | cursor: pointer; |
| | | |
| | | &:hover { |
| | | background: #eee; |
| | | } |
| | |
| | | text-align: center; |
| | | transition: all .3s cubic-bezier(.645, .045, .355, 1); |
| | | transform-origin: 100% 50%; |
| | | |
| | | &:before { |
| | | transform: scale(.6); |
| | | display: inline-block; |
| | | vertical-align: -3px; |
| | | } |
| | | |
| | | &:hover { |
| | | background-color: #b4bccc; |
| | | color: #fff; |
| | |
| | | return { RightCode: res.data[0], numvalue: res.data[1] } |
| | | } |
| | | } |
| | | |
| | | // 递归清除数组每个元素下的children为空的数组 |
| | | const clearAllChildren = (items, childrenName = 'children') => { |
| | | for (let i = 0; i < items.length; i++) { |
| | | const item = items[i] |
| | | // 当前对象存在children |
| | | if (item && item[childrenName]) { |
| | | // children为空数组时删除 |
| | | if (item[childrenName].length === 0) { |
| | | delete item[childrenName] |
| | | } else { |
| | | // 递归当前children数组 |
| | | clearAllChildren(item[childrenName], childrenName) |
| | | } |
| | | } |
| | | } |
| | | return items |
| | | } |
| | | |
| | | export default clearAllChildren |
| | |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getRoleTypeSearch2" |
| | | > |
| | | <el-option |
| | | v-for="item in RoleTypeCodeArr2" |
| | |
| | | <el-table |
| | | :data="tableData" |
| | | border |
| | | |
| | | stripe |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | :style="{width: 100+'%',height:tableHeight+'px'}" |
| | | highlight-current-row |
| | | :header-cell-style="this.$headerCellStyle" |
| | |
| | | :options="StuOrgArr" |
| | | :props="defaultProps" |
| | | style="width: 200px;" |
| | | @focus="getUserOrganization" |
| | | @change="dialogCascaderChange" |
| | | /> |
| | | |
| | |
| | | }, |
| | | created() { |
| | | this.getRoleSearch() |
| | | this.getRoleTypeSearch2() |
| | | this.getUserOrganization() |
| | | // this.getRoleTypeSearch2() |
| | | // this.getUserOrganization() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | pcIsSelected2 = true |
| | | |
| | | const interval = setInterval(() => { |
| | | if ($('input:checkbox').length > 0) { |
| | | if ($("input[name='PC']").length > 0) { |
| | | waitFlag = true |
| | | } |
| | | if (waitFlag) { |
| | |
| | | appIsSelected2 = true |
| | | |
| | | const interval = setInterval(() => { |
| | | if ($('input:checkbox').length > 0) { |
| | | if ($("input[name='APP']").length > 0) { |
| | | waitFlag = true |
| | | } |
| | | if (waitFlag) { |
| | |
| | | appIsSelected2 = true |
| | | |
| | | const interval = setInterval(() => { |
| | | if ($('input:checkbox').length > 0) { |
| | | if ($("input[name='PC']").length > 0) { |
| | | waitFlag = true |
| | | } |
| | | if (waitFlag) { |
| | |
| | | const currentCode = this.dialogFormRight.rightCurrentCode// 权限操作端code |
| | | // 1.第一种情况 半叶为零 全叶为零 |
| | | if (checkedKeys.length === 0 && halfCheckedKeys.length === 0) { |
| | | console.log('1.第一种情况 半叶为零 全叶为零') |
| | | console.log('1.第一种情况 半叶为零 全叶为零1111') |
| | | this.dialogFormRight.rightOperationArr.forEach((item, index) => { |
| | | if (item.code === currentCode) { |
| | | item.isSelected2 = false |
| | | |
| | | this.$nextTick(() => { |
| | | $('input:checkbox').eq(index).prop('checked', false)// 自定义单选框回显 |
| | | if (item.name === 'PC') { |
| | | $("input[name='PC']").eq(0).prop('checked', false)// 自定义单选框回显 |
| | | } |
| | | if (item.name === 'APP') { |
| | | $("input[name='APP']").eq(0).prop('checked', false)// 自定义单选框回显 |
| | | } |
| | | // $("input[name='APP']").eq(0).prop('checked', false)// 自定义单选框回显 |
| | | // $('input:checkbox').eq(index).prop('checked', false)// 自定义单选框回显 |
| | | }) |
| | | } |
| | | }) |
| | |
| | | if (item.code === currentCode) { |
| | | item.isSelected2 = true |
| | | this.$nextTick(() => { |
| | | $('input:checkbox').eq(index).prop('checked', true)// 自定义单选框回显 |
| | | if (item.name === 'PC') { |
| | | $("input[name='PC']").eq(0).prop('checked', true)// 自定义单选框回显 |
| | | } |
| | | if (item.name === 'APP') { |
| | | $("input[name='APP']").eq(0).prop('checked', true)// 自定义单选框回显 |
| | | } |
| | | // $('input:checkbox').eq(index).prop('checked', true)// 自定义单选框回显 |
| | | }) |
| | | } |
| | | }) |
| | |
| | | if (item.code === currentCode) { |
| | | item.isSelected2 = true |
| | | this.$nextTick(() => { |
| | | $('input:checkbox').eq(index).prop('checked', true)// 自定义单选框回显 |
| | | if (item.name === 'PC') { |
| | | $("input[name='PC']").eq(0).prop('checked', true)// 自定义单选框回显 |
| | | } |
| | | if (item.name === 'APP') { |
| | | $("input[name='APP']").eq(0).prop('checked', true)// 自定义单选框回显 |
| | | } |
| | | // $('input:checkbox').eq(index).prop('checked', true)// 自定义单选框回显 |
| | | }) |
| | | } |
| | | }) |
| | |
| | | <el-table |
| | | :data="tableData" |
| | | border |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | stripe |
| | | highlight-current-row |
| | | :header-cell-style="this.$headerCellStyle" |
| | |
| | | popper-class="elCascader" |
| | | :options="StuOrgArr" |
| | | :props="defaultProps" |
| | | @focus="getUserOrganization" |
| | | @change="cascaderChange" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="工资类型" style=" display: flex;"> |
| | | <el-select v-model="form.wagetype" :popper-append-to-body="false" filterable style="width: 200px" placeholder="请选择"> |
| | | <el-option |
| | | |
| | | v-for="item in wagetypeArr" |
| | | :key="item.value" |
| | | :label="item.label" |
| | |
| | | :data="tableData" |
| | | border |
| | | stripe |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | highlight-current-row |
| | | :style="{width: 100+'%',height:tableHeight+'px'}" |
| | | :header-cell-style="this.$headerCellStyle" |
| | |
| | | prop="mobile" |
| | | label="联系方式" |
| | | sortable="custom" |
| | | /> |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div v-if="row.mobile===''">/</div> |
| | | <div v-else>{{ row.mobile }}</div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="email" |
| | | label="电子邮箱" |
| | | sortable="custom" |
| | | /> |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div v-if="row.email===''">/</div> |
| | | <div v-else>{{ row.email }}</div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="" |
| | | label="在职状态" |
| | |
| | | key="cascaderKey" |
| | | filterable |
| | | popper-class="elCascader" |
| | | :options="StuOrgArr" |
| | | :options="StuOrgArr2" |
| | | :props="defaultProps" |
| | | style="width: 200px;" |
| | | @change="dialogCascaderChange" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="所属班组" prop="groupcode"> |
| | | <el-select |
| | | v-model="dialogForm.groupcode" |
| | | :popper-append-to-body="false" |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in usergroupArr" |
| | | :key="item.group_code" |
| | | :label="item.group_name" |
| | | :value="item.group_code" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="工资类型" prop="wagetype"> |
| | | <el-select |
| | |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="联系方式"> |
| | | <el-form-item label="联系方式" prop="Mobile"> |
| | | <el-input v-model="dialogForm.Mobile" style="width: 200px" /> |
| | | </el-form-item> |
| | | <el-form-item label="电子邮箱"> |
| | | <el-form-item label="电子邮箱" prop="Email"> |
| | | <el-input v-model="dialogForm.Email" style="width: 200px" /> |
| | | </el-form-item> |
| | | </el-form> |
| | |
| | | } from '@/api/jcsz' |
| | | import { getCookie } from '@/utils/auth' |
| | | import $ from 'jquery' |
| | | import clearAllChildren from '@/utils/global' |
| | | import { MesOrderStepReportSelectUserGroup } from '@/api/scgl' |
| | | |
| | | const SER_HZ = /^[\u4e00-\u9fa5]+$/ |
| | | export default { |
| | |
| | | } |
| | | } |
| | | } |
| | | const validateMobile = (rule, value, callback) => { |
| | | if (!value) { |
| | | callback() |
| | | // return callback(new Error('请输入电话号码')) |
| | | } else { |
| | | const mobile = /^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/ // 长号 |
| | | const mobile2 = /^[0-9]{6}$/ // 短号 |
| | | if (mobile.test(value) || mobile2.test(value)) { |
| | | callback() |
| | | // return callback(new Error('电话号码不符合规则')) |
| | | } else { |
| | | return callback(new Error('电话号码不符合规则')) |
| | | // callback() |
| | | } |
| | | } |
| | | } |
| | | const validateEmail = (rule, value, callback) => { |
| | | if (!value) { |
| | | callback() |
| | | // return callback(new Error('请输入电子邮箱')) |
| | | } else { |
| | | const email = /^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(.[a-zA-Z0-9_-]+)+$/ |
| | | if (email.test(value)) { |
| | | callback() |
| | | } else { |
| | | return callback(new Error('电子邮箱不符合规则')) |
| | | } |
| | | } |
| | | } |
| | | |
| | | return { |
| | | isFullscreen: false, |
| | | mainHeight: 0, |
| | |
| | | rows: 20 // 每页多少条 |
| | | }, |
| | | StuOrgArr: [], // 所属组织数组 |
| | | StuOrgArr2: [], // 所属组织数组 对话框 |
| | | defaultProps: { |
| | | checkStrictly: true, |
| | | value: 'code', |
| | |
| | | StuOrg: '', |
| | | Mobile: '', |
| | | Email: '', |
| | | groupcode: '', |
| | | Operator: '', |
| | | OperType: '', |
| | | wagetype: '' |
| | | }, |
| | | usergroupArr: [], // 生产班组数组 |
| | | wagetypeArr: [ |
| | | { value: '2', label: '计件制' }, |
| | | { value: '1', label: '计时制' } |
| | |
| | | ], |
| | | wagetype: [ |
| | | { required: true, message: '请选择工资类型', trigger: ['blur', 'change'] } |
| | | ], |
| | | groupcode: [ |
| | | { required: true, message: '请选择所属班组', trigger: ['blur', 'change'] } |
| | | ], |
| | | Mobile: [ |
| | | { required: false, validator: validateMobile, trigger: ['blur', 'change'] } |
| | | ], |
| | | Email: [ |
| | | { required: false, validator: validateEmail, trigger: ['blur', 'change'] } |
| | | ] |
| | | |
| | | }, |
| | | dialogVisibleRoles: false, |
| | | dialogFormRoles: { |
| | |
| | | }, |
| | | created() { |
| | | this.getUserSearch() |
| | | this.getUserOrganization() |
| | | // this.getUserOrganization() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | // 获取所属组织 |
| | | async getUserOrganization() { |
| | | const { data: res } = await UserOrganization() |
| | | this.StuOrgArr = res |
| | | this.StuOrgArr = clearAllChildren(res) |
| | | }, |
| | | // 获取所属组织对话框 |
| | | async getUserOrganization2() { |
| | | const { data: res } = await UserOrganization() |
| | | this.StuOrgArr2 = clearAllChildren(res) |
| | | }, |
| | | // 导入按钮 |
| | | upload() { |
| | |
| | | dialogCascaderChange(val) { |
| | | this.dialogForm.StuOrg = val[val.length - 1] |
| | | }, |
| | | // 获取下拉生产班组 |
| | | async getMesOrderStepReportSelectUserGroup() { |
| | | const { data: res } = await MesOrderStepReportSelectUserGroup() |
| | | this.usergroupArr = res |
| | | }, |
| | | // 新增按钮 |
| | | add(operation) { |
| | | this.operation = operation |
| | | this.dialogVisible = true |
| | | this.getUserOrganization2() |
| | | this.getMesOrderStepReportSelectUserGroup() |
| | | }, |
| | | // 修改按钮 |
| | | edit(operation, row) { |
| | |
| | | this.dialogForm.UserCode = row.usercode |
| | | this.dialogForm.UserName = row.username |
| | | this.dialogForm.Password = row.password |
| | | this.dialogForm.groupcode = row.group_code |
| | | this.dialogForm.Enable = row.enable |
| | | this.dialogForm.StuOrg = row.stu_torgcode |
| | | this.$refs.dialogCascader.checkedValue = row.stu_torgcode |
| | |
| | | this.dialogForm.Email = row.email |
| | | this.dialogForm.wagetype = row.wagetype |
| | | }) |
| | | this.getMesOrderStepReportSelectUserGroup() |
| | | this.getUserOrganization2() |
| | | }, |
| | | // 删除按钮 |
| | | async del(id) { |
| | |
| | | this.dialogForm.StuOrg = '' |
| | | this.dialogForm.Mobile = '' |
| | | this.dialogForm.Email = '' |
| | | this.dialogForm.groupcode = '' |
| | | this.dialogForm.wagetype = '' |
| | | this.$refs.dialogForm.clearValidate() |
| | | }, |
| | |
| | | StuOrg: Array.isArray(this.$refs.dialogCascader.checkedValue) ? this.$refs.dialogCascader.checkedValue[this.$refs.dialogCascader.checkedValue.length - 1] : this.$refs.dialogCascader.checkedValue, |
| | | Mobile: this.dialogForm.Mobile, |
| | | Email: this.dialogForm.Email, |
| | | groupcode: this.dialogForm.groupcode, |
| | | wagetype: this.dialogForm.wagetype, |
| | | OperType: this.operation === 'add' ? 'Add' : 'Update', |
| | | Operator: getCookie('admin') |
| | |
| | | this.workingTableData.splice(index, 1) |
| | | } |
| | | }) |
| | | // this.getUserGroupSearch() |
| | | this.getMesOrderStepReportSelectUserGroup() |
| | | }, |
| | | // 生产班组排序 |
| | | sortChangeOfWorking({ column, prop, order }) { |
| | |
| | | stripe |
| | | :style="{width: 100+'%',height:tableHeight+'px'}" |
| | | highlight-current-row |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | :header-cell-style="this.$headerCellStyle" |
| | | :cell-style="this.$cellStyle" |
| | | @sort-change="sortChange" |
| | |
| | | prop="parentorg_name" |
| | | label="上级单位" |
| | | sortable="custom" |
| | | /> |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div v-if="row.parentorg_name===null">/</div> |
| | | <div v-else>{{ row.parentorg_name }}</div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="lm_user" |
| | | label="创建人员" |
| | |
| | | <el-input v-model="form.DeviceName" placeholder="请输入" style="width: 200px" /> |
| | | </el-form-item> |
| | | <el-form-item label="使用状态" style=" display: flex;"> |
| | | <el-select v-model="form.Status" :popper-append-to-body="false" filterable style="width: 200px" placeholder="请选择"> |
| | | <el-select |
| | | v-model="form.Status" |
| | | :popper-append-to-body="false" |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in StatusArr" |
| | | :key="item.value" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="所属车间" style=" display: flex;"> |
| | | <el-select v-model="form.WorkShop" :popper-append-to-body="false" filterable style="width: 200px" placeholder="请选择"> |
| | | <el-select |
| | | v-model="form.WorkShop" |
| | | :popper-append-to-body="false" |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getWorkShopSelect" |
| | | > |
| | | <el-option |
| | | v-for="item in WorkShopArr" |
| | | :key="item.code" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item filterable label="设备类型" style="display: flex;"> |
| | | <el-select v-model="form.DeviceType" :popper-append-to-body="false" style="width: 200px" placeholder="请选择" @change="deviceTypeChange"> |
| | | <el-select |
| | | v-model="form.DeviceType" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | filterable |
| | | placeholder="请选择" |
| | | @focus="getDeviceTypeSelect" |
| | | @change="deviceTypeChange" |
| | | > |
| | | <el-option |
| | | v-for="item in DeviceTypeArr" |
| | | :key="item.code" |
| | |
| | | <el-form-item label="设备组" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.DeviceGroup" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | :disabled="form.DeviceType===''" |
| | | style="width: 200px" |
| | |
| | | <el-table |
| | | :data="tableData" |
| | | border |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | stripe |
| | | highlight-current-row |
| | | :style="{width: 100+'%',height:(tableHeight-50)+'px'}" |
| | |
| | | <el-input v-model="dialogForm.devicename" style="width: 200px" /> |
| | | </el-form-item> |
| | | <el-form-item label="设备类型" prop="devicetypecode"> |
| | | <el-select v-model="dialogForm.devicetypecode" :popper-append-to-body="false" style="width: 200px" placeholder="请选择" @change="devicetypecodeChange"> |
| | | <el-select |
| | | v-model="dialogForm.devicetypecode" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | filterable |
| | | @change="devicetypecodeChange" |
| | | > |
| | | <el-option |
| | | v-for="item in DeviceTypeArr" |
| | | :key="item.code" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="设备组" prop="devicegroupcode"> |
| | | <el-select v-model="dialogForm.devicegroupcode" :popper-append-to-body="false" :disabled="dialogForm.devicetypecode===''" style="width: 200px" placeholder="请选择"> |
| | | <el-select |
| | | v-model="dialogForm.devicegroupcode" |
| | | :popper-append-to-body="false" |
| | | :disabled="dialogForm.devicetypecode===''" |
| | | style="width: 200px" |
| | | filterable |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in DeviceGroupDialogArr" |
| | | :key="item.code" |
| | |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="所属车间" prop="workshopcode"> |
| | | <el-select v-model="dialogForm.workshopcode" :popper-append-to-body="false" style="width: 200px" placeholder="请选择" @change="workshopcodeChange"> |
| | | <el-select |
| | | v-model="dialogForm.workshopcode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @change="workshopcodeChange" |
| | | > |
| | | <el-option |
| | | v-for="item in WorkShopArr" |
| | | :key="item.code" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="所属产线" prop="linecode"> |
| | | <el-select v-model="dialogForm.linecode" :popper-append-to-body="false" :disabled="dialogForm.workshopcode===''" style="width: 200px" placeholder="请选择"> |
| | | <el-select |
| | | v-model="dialogForm.linecode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | :disabled="dialogForm.workshopcode===''" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in WorkLineArr" |
| | | :key="item.linecode" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="使用状态" prop="status"> |
| | | <el-select v-model="dialogForm.status" :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-select |
| | | v-model="dialogForm.status" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in StatusArr" |
| | | :key="item.value" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="稼动率" prop="ratio"> |
| | | <el-input v-model="dialogForm.ratio" style="width: 195px" /><span style="margin-left: 10px">%</span> |
| | | <el-input v-model="dialogForm.ratio" style="width: 195px" /> |
| | | <span style="margin-left: 10px">%</span> |
| | | </el-form-item> |
| | | |
| | | </el-form> |
| | |
| | | sortable="custom" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-select v-if="row.isVisible===1" v-model="row.eqptype_code" :popper-append-to-body="false" placeholder="请选择"> |
| | | <el-select |
| | | v-if="row.isVisible===1" |
| | | v-model="row.eqptype_code" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in DeviceTypeArr" |
| | | :key="item.code" |
| | |
| | | // 获取设备清单列表 |
| | | this.getDeviceMangerSearch() |
| | | // 获取设备类型下拉 |
| | | this.getDeviceTypeSelect() |
| | | // this.getDeviceTypeSelect() |
| | | // 获取所属车间下拉 |
| | | this.getWorkShopSelect() |
| | | // this.getWorkShopSelect() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | addDeviceGroup() { |
| | | let number = Math.random() * Math.random()// 作为删除时的标识符 |
| | | number = number === 0 ? (10 + Math.random()) : number |
| | | this.DeviceGroupArray.unshift({ code: '', name: '', eqptype_code: '', eqptype_name: '', remark: '', isVisible: 1, number: number }) |
| | | this.DeviceGroupArray.unshift({ |
| | | code: '', |
| | | name: '', |
| | | eqptype_code: '', |
| | | eqptype_name: '', |
| | | remark: '', |
| | | isVisible: 1, |
| | | number: number |
| | | }) |
| | | }, |
| | | // 排序 |
| | | sortChangeOfDeviceGroup({ column, prop, order }) { |
| | |
| | | border: none; |
| | | padding: 0 20px; |
| | | } |
| | | |
| | | ::v-deep .el-button--primary:hover { |
| | | border: none; |
| | | } |
| | | |
| | | ::v-deep .el-button--info { |
| | | //background-color: $main_color !important; |
| | | height: 30px; |
| | |
| | | width: 99%; |
| | | margin: 10px auto; |
| | | } |
| | | |
| | | .body ::v-deep .el-form-item{ |
| | | margin-bottom: 0; |
| | | } |
| | | |
| | | ::v-deep .el-input__inner:focus { |
| | | border-color: $main_color; |
| | | } |
| | |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | filterable |
| | | @change="erporderstusChange" |
| | | > |
| | | <el-option |
| | |
| | | <div class="elTableDiv"> |
| | | <el-table |
| | | :data="tableData" |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | border |
| | | stripe |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | |
| | | <el-select |
| | | v-model="dialogForm.mesorderstus" |
| | | disabled |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | |
| | | > |
| | | <el-select |
| | | v-model="dialogForm.partcode" |
| | | filterable |
| | | :disabled="operation!=='add'" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | |
| | | <el-input v-model="dialogForm.partspec" disabled style="width: 200px" /> |
| | | </el-form-item> |
| | | <div style="display: flex"> |
| | | <el-form-item label="生产车间" prop="wkshopcode"> |
| | | <el-select |
| | | v-model="dialogForm.wkshopcode" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in wkshopArr" |
| | | :key="item.code" |
| | | :label="item.name" |
| | | :value="item.code" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <div style="display: flex;flex-wrap: nowrap"> |
| | | <el-form-item label="工艺路线" prop="routecode"> |
| | | <el-select |
| | | v-model="dialogForm.routecode" |
| | | filterable |
| | | :disabled="dialogForm.partcode===''" |
| | | :popper-append-to-body="false" |
| | | style="width: 160px" |
| | | style="width: 172px" |
| | | placeholder="请选择" |
| | | @change="routecodeChange" |
| | | > |
| | | <el-option |
| | | v-for="item in routeArr" |
| | |
| | | <!-- :disabled="dialogForm.routecode===''"--> |
| | | |
| | | </div> |
| | | <el-form-item label="生产车间" prop="wkshopcode"> |
| | | <el-select |
| | | v-model="dialogForm.wkshopcode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px;" |
| | | placeholder="请选择" |
| | | :disabled="dialogForm.routecode===''" |
| | | > |
| | | <el-option |
| | | v-for="item in wkshopArr" |
| | | :key="item.org_code" |
| | | :label="item.org_name" |
| | | :value="item.org_code" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </div> |
| | | <el-form-item label="计划开始时间" prop="planstartdate"> |
| | | <el-date-picker |
| | |
| | | <el-form-item label="工单等级" prop="orderlev"> |
| | | <el-select |
| | | v-model="dialogForm.orderlev" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | |
| | | ClosedErpOrder, |
| | | ClosedMesOrder, |
| | | DeleteMesOrder, |
| | | MesOrderSearch, SearchWorkStep, |
| | | MesOrderSearch, RouteSelectWkshop, SearchWorkStep, |
| | | SelectRouteStep |
| | | } from '@/api/scgl' |
| | | import { WorkShopSelect } from '@/api/sbgl' |
| | |
| | | // 获取产品信息 |
| | | const { data: res1 } = await PartSelect() |
| | | this.partArr = res1 |
| | | |
| | | // 获取生产车间数组 |
| | | const { data: res2 } = await WorkShopSelect() |
| | | this.wkshopArr = res2 |
| | | }, |
| | | // 订单状态改变时 |
| | | erporderstusChange(val) { |
| | |
| | | const { data: res } = await PartSelectRpute({ partcode: val }) |
| | | this.routeArr = res |
| | | this.dialogForm.routecode = '' |
| | | this.dialogForm.wkshopcode = '' |
| | | }, |
| | | // 工艺路线值改变 |
| | | async routecodeChange(val) { |
| | | const data = { |
| | | partcode: this.dialogForm.partcode, |
| | | routecode: this.dialogForm.routecode |
| | | } |
| | | // 获取生产车间数组 |
| | | const { data: res2 } = await RouteSelectWkshop(data) |
| | | this.wkshopArr = res2 |
| | | this.dialogForm.wkshopcode = '' |
| | | }, |
| | | // 工序任务 |
| | | async check(row) { |
| | |
| | | this.dialogForm.mesqty = row.plan_qty |
| | | this.dialogForm.partspec = row.partspec |
| | | // this.dialogForm.routecode = row.route_code// 工艺路线代码 |
| | | this.dialogForm.wkshopcode = row.wkshp_code// 生产车间代码 |
| | | // this.dialogForm.wkshopcode = row.wkshp_code// 生产车间代码 |
| | | |
| | | this.dialogForm.planstartdate = row.plan_startdate !== null ? row.plan_startdate : handleDatetime(new Date()) |
| | | this.dialogForm.planenddate = row.plan_enddate !== null ? row.plan_enddate : handleDatetime(new Date()) |
| | |
| | | <el-form-item label="订单状态" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.erporderstus" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | |
| | | <el-input v-model="form.creatuser" style="width: 200px" placeholder="请输入" /> |
| | | </el-form-item> |
| | | <el-form-item label="创建时间" style=" display: flex;"> |
| | | <!-- <el-date-picker--> |
| | | <!-- v-model="form.createdate"--> |
| | | <!-- type="daterange"--> |
| | | <!-- :clearable="false"--> |
| | | <!-- range-separator="~"--> |
| | | <!-- start-placeholder="开始日期"--> |
| | | <!-- end-placeholder="结束日期"--> |
| | | <!-- size="mini"--> |
| | | <!-- />--> |
| | | <!-- :picker-options="expireTimeOption"--> |
| | | <el-date-picker |
| | | v-model="form.createdate" |
| | | type="date" |
| | | size="mini" |
| | | type="daterange" |
| | | :clearable="false" |
| | | style="width: 200px;" |
| | | format="yyyy-MM-dd" |
| | | placeholder="选择日期" |
| | | range-separator="~" |
| | | start-placeholder="开始日期" |
| | | style="width: 240px" |
| | | end-placeholder="结束日期" |
| | | size="mini" |
| | | /> |
| | | <!-- :picker-options="expireTimeOption"--> |
| | | <!-- <el-date-picker--> |
| | | <!-- v-model="form.createdate"--> |
| | | <!-- type="date"--> |
| | | <!-- size="mini"--> |
| | | <!-- :clearable="false"--> |
| | | <!-- style="width: 200px;"--> |
| | | <!-- format="yyyy-MM-dd"--> |
| | | <!-- placeholder="选择日期"--> |
| | | <!-- />--> |
| | | </el-form-item> |
| | | </div> |
| | | <div style="min-height: 100px"> |
| | |
| | | <div class="elTableDiv"> |
| | | <el-table |
| | | :data="tableData" |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | border |
| | | stripe |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | |
| | | tempDate2 = handleDatetime(tempDate2[0]) + '~' + handleDatetime(tempDate2[1]) |
| | | } |
| | | |
| | | // let tempDate = this.form.createdate |
| | | // if (tempDate.length > 0) { |
| | | // tempDate = handleDatetime(tempDate[0]) + '~' + handleDatetime(tempDate[1]) |
| | | // } |
| | | let tempDate = this.form.createdate |
| | | if (tempDate.length > 0) { |
| | | tempDate = handleDatetime(tempDate[0]) + '~' + handleDatetime(tempDate[1]) |
| | | } |
| | | |
| | | const data = { |
| | | erporderstus: this.form.erporderstus, // 订单状态码 |
| | |
| | | partspec: this.form.partspec, // 产品规格 |
| | | paydate: tempDate2, // 交付时间 |
| | | creatuser: this.form.creatuser, // 创建人员 |
| | | createdate: this.form.createdate.toString().length > 0 ? handleDatetime(this.form.createdate) : '', // 创建时间 |
| | | // createdate: tempDate, |
| | | // createdate: this.form.createdate.toString().length > 0 ? handleDatetime(this.form.createdate) : '', // 创建时间 |
| | | createdate: tempDate, |
| | | prop: this.form.prop, // 排序字段 |
| | | order: this.form.order, // 排序字段 |
| | | page: this.form.page, // 第几页 |
| | |
| | | <div style="display: flex;align-items: center"> |
| | | <div style="width: 70px">工序码:</div> |
| | | <el-input |
| | | v-model="produceCode" |
| | | oninput="value=value.replace(/[^0-9a-zA-Z;]/g,'')" |
| | | v-model="form.orderstepqrcode" |
| | | oninput="value=value.replace(/[^0-9a-zA-Z;_]/g,'')" |
| | | name="produceCode" |
| | | style="width: 500px" |
| | | style="width: 300px" |
| | | @keyup.enter.native="val=>enterNative(val,'produceCode')" |
| | | /> |
| | | </div> |
| | |
| | | <div class="elTableDiv"> |
| | | <el-table |
| | | :data="tableData" |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | border |
| | | stripe |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | |
| | | :cell-style="this.$cellStyle" |
| | | @sort-change="sortChange" |
| | | > |
| | | <!-- <el-table-column--> |
| | | <!-- width="50"--> |
| | | <!-- >--> |
| | | <!-- <template slot-scope="{row}">--> |
| | | <!-- <!– <el-radio–>--> |
| | | <!-- <!– v-model="radioSelected"–>--> |
| | | <!-- <!– :label="row.wo"–>--> |
| | | <!-- <!– style="color: #fff;padding-left: 10px; margin-right: -25px;"–>--> |
| | | <!-- <!– @change.native="getCurrentRow(row.wo)"–>--> |
| | | <!-- <!– />–>--> |
| | | <!-- </template>--> |
| | | <!-- </el-table-column>--> |
| | | <el-table-column |
| | | width="50" |
| | | fixed |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-radio |
| | | v-model="radioSelected" |
| | | :label="row.wo" |
| | | style="color: #fff;padding-left: 10px; margin-right: -25px;" |
| | | @change.native="getCurrentRow(row.wo)" |
| | | /> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="RowNum" |
| | | width="50" |
| | |
| | | <el-tab-pane label="外协列表"> |
| | | <div style="margin-left: 10px;margin-top:10px;display: flex;justify-content: space-between"> |
| | | <div style="display: flex;align-items: center"> |
| | | <div style="width: 70px">工序码:</div> |
| | | <div style="width: 90px;">外协类型:</div> |
| | | <el-select |
| | | v-model="WXSelected" |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | > |
| | | <el-option |
| | | v-for="item in WXSelectArr" |
| | | :key="item.code" |
| | | :label="item.name" |
| | | :value="item.code" |
| | | /> |
| | | </el-select> |
| | | <div style="width: 70px;margin-left: 20px">工序码:</div> |
| | | <el-input |
| | | v-model="WXproduceCode" |
| | | oninput="value=value.replace(/[^0-9a-zA-Z;]/g,'')" |
| | | v-model="WXform.orderstepqrcode" |
| | | oninput="value=value.replace(/[^0-9a-zA-Z;_]/g,'')" |
| | | name="WXproduceCode" |
| | | style="width: 500px" |
| | | style="width: 300px" |
| | | @keyup.enter.native="val=>enterNative(val,'WXproduceCode')" |
| | | /> |
| | | </div> |
| | |
| | | <div class="elTableDiv"> |
| | | <el-table |
| | | :data="WXtableData" |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | border |
| | | stripe |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | | highlight-current-row |
| | | :header-cell-style="this.$headerCellStyle" |
| | | :cell-style="this.$cellStyle" |
| | | @sort-change="sortChange" |
| | | @sort-change="WXsortChange" |
| | | > |
| | | <!-- <el-table-column--> |
| | | <!-- width="50"--> |
| | | <!-- >--> |
| | | <!-- <template slot-scope="{row}">--> |
| | | <!-- <!– <el-radio–>--> |
| | | <!-- <!– v-model="radioSelected"–>--> |
| | | <!-- <!– :label="row.wo"–>--> |
| | | <!-- <!– style="color: #fff;padding-left: 10px; margin-right: -25px;"–>--> |
| | | <!-- <!– @change.native="getCurrentRow(row.wo)"–>--> |
| | | <!-- <!– />–>--> |
| | | <!-- </template>--> |
| | | <!-- </el-table-column>--> |
| | | <el-table-column |
| | | width="50" |
| | | fixed |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <el-radio |
| | | v-model="radioSelected" |
| | | :label="row.wo_code" |
| | | style="color: #fff;padding-left: 10px; margin-right: -25px;" |
| | | @change.native="getWXCurrentRow(row.wo_code)" |
| | | /> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="RowNum" |
| | | width="50" |
| | |
| | | width="150" |
| | | /> |
| | | <el-table-column |
| | | prop="seq" |
| | | width="80" |
| | | prop="stepname" |
| | | width="100" |
| | | label="工序" |
| | | sortable="custom" |
| | | /> |
| | |
| | | <div style="width: 200px">{{ dialogForm.wo_code }}</div> |
| | | </el-form-item> |
| | | <el-form-item label="产品编码:"> |
| | | <div style="width: 200px">427100</div> |
| | | <div style="width: 200px">{{ dialogForm.partcode }}</div> |
| | | </el-form-item> |
| | | <el-form-item label="产品名称:"> |
| | | <div style="width: 200px">机箱板底</div> |
| | | <div style="width: 200px">{{ dialogForm.partname }}</div> |
| | | </el-form-item> |
| | | <el-form-item label="产品规格:"> |
| | | <div style="width: 200px">机箱底板&1</div> |
| | | <div style="width: 200px">{{ dialogForm.partspec }}</div> |
| | | </el-form-item> |
| | | <el-form-item label="当前工序:"> |
| | | <div style="width: 200px">激光切割</div> |
| | | <div style="width: 200px">{{ dialogForm.stepname }}</div> |
| | | </el-form-item> |
| | | <el-form-item label="工序描述:"> |
| | | <el-tooltip class="item" effect="dark" content="原材料切按材料切按材料切按时打卡数据的卡" placement="top-start"> |
| | | <!-- <el-tooltip class="item" effect="dark" content="原材料切按材料切按材料切按时打卡数据的卡" placement="top-start">--> |
| | | <div style="width: 200px;white-space: nowrap;text-overflow: ellipsis;overflow: hidden;"> |
| | | 原材料切按材料切按材料切按时打卡数据的卡 |
| | | {{ dialogForm.stepdesc }} |
| | | </div> |
| | | </el-tooltip> |
| | | <!-- </el-tooltip>--> |
| | | </el-form-item> |
| | | <el-form-item label="任务数量:"> |
| | | <div style="width: 200px">1000</div> |
| | | <div style="width: 200px">{{ dialogForm.planqty }}</div> |
| | | </el-form-item> |
| | | <el-form-item label="未报/已报:"> |
| | | <div style="width: 200px">900/100</div> |
| | | <el-form-item :label="dialogTitle==='自制开始'||dialogTitle==='自制报工'?'未报/已报:':'未发/已发:'"> |
| | | <div style="width: 200px">{{ dialogForm.noreportqty }}/{{ dialogForm.reportqty }}</div> |
| | | </el-form-item> |
| | | |
| | | <el-form-item v-if="dialogTitle==='自制开始'" label="开工数量:"> |
| | |
| | | import { |
| | | MesOrderGroupSelectUser, |
| | | MesOrderStepReportSelectUserGroup, |
| | | MesOrderStepSearch, |
| | | MesOrderStepSearch, MesOrderStepStart, |
| | | MesOrderStepStartSelectEqp, |
| | | MesOrderWxStepSearch |
| | | } from '@/api/scgl' |
| | | import { MesOrderStepSelectWX } from '@/api/sbgl' |
| | | |
| | | const SER_HZ = /^[\u4e00-\u9fa5]+$/ |
| | | export default { |
| | |
| | | tableHeight: 0, |
| | | produceCode: '', // 工序码 |
| | | WXproduceCode: '', // 外协工序码 |
| | | radioSelected: '', // 工序选中 |
| | | WXradioSelected: '', // 工序选中 |
| | | form: { |
| | | orderstepqrcode: 'PO202206280001_4;Step01', // 扫描的二维码信息 |
| | | prop: 'wo', // 排序字段 |
| | |
| | | total: 10, |
| | | tableData: [], |
| | | WXform: { // 外协表单 |
| | | // PO202206280001_4;Step01 |
| | | orderstepqrcode: 'PO202206280001_4;Step01', // 扫描的二维码信息 |
| | | prop: 'wo_code', // 排序字段 |
| | | order: 'asc', // 排序字段 |
| | |
| | | WXtotal: 10, // 外协表单总数 |
| | | WXtableData: [], // 外协表 |
| | | |
| | | WXSelectArr: [// 外协类型下拉列表 |
| | | { code: 'OUT', name: '发料' }, |
| | | { code: 'IN', name: '收料' } |
| | | ], |
| | | WXSelected: 'OUT', // 外协下拉列表选中值 |
| | | |
| | | judgeIsDialog: false, // 判断是否自动弹窗 |
| | | judgeIsDialogNumber: false, // 判断弹哪个窗 |
| | | |
| | | dialogVisible: false, |
| | | dialogTitle: '', // 自制开始、自制报工、外协发料、外协收料 |
| | | dialogForm: { |
| | |
| | | partcode: '', // 产品编码 |
| | | partname: '', // 产品名称 |
| | | partspec: '', // 产品规格 |
| | | currentstep: '', // 当前工序 |
| | | nextstep: '', // 下一道工序 |
| | | desr: '', // 工序描述 |
| | | plan_qty: '', // 任务数量 |
| | | report_qty: '', // 已报数量 |
| | | noreport_qty: '' // 未报数量 |
| | | stepname: '', // 当前工序名 |
| | | nextstepname: '', // 下一道工序名 |
| | | stepdesc: '', // 工序描述 |
| | | planqty: '', // 任务数量 |
| | | reportqty: '', // 已报数量 |
| | | noreportqty: '', // 未报数量 |
| | | startqty: '' // 发料数量 |
| | | |
| | | // eqpcode: '', // 设备编码 |
| | | // usergroupcode: '', // 班组编码 |
| | | // reportuser: '', // 报工人员 |
| | | // taskqty: '', // 任务数量 |
| | | // startqty: '', // 开工数量 |
| | | // reportqty: '', // 报工数量 |
| | | // ngqty: '' // 不良数量 |
| | | |
| | | }, |
| | | userTableData: [ |
| | |
| | | } |
| | | }, |
| | | created() { |
| | | this.getMesOrderStepSearch() |
| | | // this.getMesOrderStepSearch() |
| | | this.tabClick() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | methods: { |
| | | async getMesOrderStepSearch() { |
| | | const res = await MesOrderStepSearch(this.form) |
| | | if (res.code === '200') { |
| | | this.tableData = res.data |
| | | this.total = res.count |
| | | } |
| | | }, |
| | | async MesOrderWxStepSearch() { |
| | | async getMesOrderWxStepSearch() { |
| | | const res = await MesOrderWxStepSearch(this.WXform) |
| | | if (res.code === '200') { |
| | | this.WXtableData = res.data |
| | | this.WXtotal = res.count |
| | | } |
| | | }, |
| | | // 排序改变时 |
| | | sortChange({ column, prop, order }) { |
| | |
| | | this.form.prop = prop |
| | | this.getMesOrderStepSearch() |
| | | }, |
| | | getCurrentRow() { |
| | | // WX排序改变时 |
| | | WXsortChange({ column, prop, order }) { |
| | | if (order === 'descending') { |
| | | order = 'desc' |
| | | } else if (order === 'ascending') { |
| | | order = 'asc' |
| | | } else { |
| | | order = 'desc' |
| | | } |
| | | this.WXform.order = order |
| | | this.WXform.prop = prop |
| | | this.getMesOrderWxStepSearch() |
| | | }, |
| | | // 自制页签原点点击 |
| | | getCurrentRow(val) { |
| | | |
| | | }, |
| | | // 外协页签原点点击 |
| | | getWXCurrentRow(val) { |
| | | console.log(val) |
| | | this.WXradioSelected = val |
| | | }, |
| | | // tab按钮切换鼠标自动聚焦 |
| | | tabClick(val, d) { |
| | | console.log(val, d, 1) |
| | | if (this.$refs.elTabs.currentName === '0') { |
| | | this.getMesOrderStepSearch() |
| | | this.$nextTick(() => { |
| | | $("input[name='produceCode']")[0].focus() |
| | | }) |
| | | } |
| | | if (this.$refs.elTabs.currentName === '1') { |
| | | this.MesOrderWxStepSearch() |
| | | this.$nextTick(() => { |
| | | $("input[name='WXproduceCode']")[0].focus() |
| | | }) |
| | | } |
| | | }, |
| | | // 扫码键盘回车事件 |
| | | async enterNative(val, belong) { |
| | | console.log(val, belong) |
| | | // 开工:code="200" count=0 |
| | | // 报工:code="200" count=1 |
| | | // 发料:code="200" count=2 |
| | | // 收料:code="200" count=3 |
| | | // 走列表形式 code="200" count=4 |
| | | if (belong === 'produceCode') { |
| | | this.ZZreport() |
| | | // this.ZZreport() |
| | | // 查找设备 |
| | | // const {data:res} = await MesOrderStepStartSelectEqp({ orderstepqrcode: this.produceCode }) |
| | | // this.xxx=res |
| | |
| | | // const { data: res2 } = await MesOrderStepReportSelectUserGroup() |
| | | } |
| | | if (belong === 'WXproduceCode') { |
| | | |
| | | const data = { |
| | | OperType: 'WX', |
| | | orderstepqrcode: this.WXform.orderstepqrcode, |
| | | SelectType: this.WXSelected// OUT、IN |
| | | } |
| | | const res = await MesOrderStepStart(data) |
| | | if (res.code === '200' && res.count === 2) { |
| | | this.WXsend(res.data) |
| | | } |
| | | } |
| | | }, |
| | | // 查询 |
| | |
| | | this.getUserTableData() |
| | | }, |
| | | // 外协发料 |
| | | async WXsend() { |
| | | async WXsend(obj) { |
| | | if (this.WXradioSelected.length < 1 && obj.length < 1) { |
| | | return this.$message.info('请先选择工序!') |
| | | } |
| | | this.dialogTitle = '外协发料' |
| | | this.dialogVisibleTrue() |
| | | // this.dialogVisible = true |
| | | this.dialogVisible = true |
| | | console.log(obj, 321) |
| | | this.dialogForm.wo_code = obj.wo_code |
| | | this.dialogForm.partcode = obj.partnumber |
| | | this.dialogForm.partname = obj.partname |
| | | this.dialogForm.partspec = obj.partspec |
| | | this.dialogForm.stepname = obj.stepname |
| | | this.dialogForm.stepdesc = obj.stepdesc |
| | | this.dialogForm.planqty = obj.planqty |
| | | this.dialogForm.reportqty = obj.reportqty |
| | | this.dialogForm.noreportqty = obj.noreportqty |
| | | this.dialogForm.startqty = obj.startqty |
| | | |
| | | // const { data: res } = await MesOrderStepReportSelectUserGroup() |
| | | // this.xx = res |
| | | // const data = { |
| | | // |
| | | // } |
| | | // const res = await MesOrderStepSelectWX(data) |
| | | // console.log(res) |
| | | }, |
| | | // 外协收料 |
| | | WXback() { |
| | |
| | | // this.dialogVisible = true |
| | | }, |
| | | dialogVisibleTrue() { |
| | | this.dialogVisible = true |
| | | // this.dialogVisible = true |
| | | // this.dialogForm.wo_code= |
| | | }, |
| | | // 报工查询用户表 |
| | |
| | | border-color: $main_color; |
| | | } |
| | | |
| | | .dialogVisible{ |
| | | //.dialogVisible{ |
| | | ::v-deep .el-select .el-input .el-select__caret { |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | } |
| | | //} |
| | | .elTableDiv { |
| | | ::v-deep .el-radio__label { |
| | | display: none; |
| | | } |
| | | |
| | | } |
| | | </style> |
| | |
| | | <div class="elTableDiv"> |
| | | <el-table |
| | | :data="tableData" |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | border |
| | | stripe |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | |
| | | :data="tableData" |
| | | border |
| | | stripe |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | | highlight-current-row |
| | | :header-cell-style="this.$headerCellStyle" |
| | |
| | | <el-input v-model="form.createuser" style="width: 200px" placeholder="请输入" /> |
| | | </el-form-item> |
| | | <el-form-item label="所属仓库" style=" display: flex;"> |
| | | <el-select v-model="form.stockcode" :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-select |
| | | v-model="form.stockcode" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getWareHouseSelect" |
| | | > |
| | | <el-option |
| | | v-for="item in stockArr" |
| | | :key="item.code" |
| | |
| | | :data="tableData" |
| | | border |
| | | stripe |
| | | :height="tableHeight" |
| | | :height="tableHeight+'px'" |
| | | :style="{width: 100+'%',height:tableHeight+'px',}" |
| | | highlight-current-row |
| | | :header-cell-style="this.$headerCellStyle" |
| | |
| | | <el-form-item label="所属库位" prop="stockcode"> |
| | | <el-select |
| | | v-model="dialogForm.stockcode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getWareHouseSelect2" |
| | | > |
| | | <el-option |
| | | v-for="item in stockArr" |
| | | v-for="item in stockArr2" |
| | | :key="item.code" |
| | | :label="item.name" |
| | | :value="item.code" |
| | |
| | | }, |
| | | total: 10, |
| | | stockArr: [], // 所属仓库数组 |
| | | stockArr2: [], // 所属仓库数组对话框 |
| | | tableData: [], |
| | | dialogVisible: false, |
| | | dialogForm: { |
| | |
| | | }, |
| | | created() { |
| | | this.getStorageDefSearch() |
| | | this.getWareHouseSelect() |
| | | // this.getWareHouseSelect() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | const { data: res } = await WareHouseSelect() |
| | | this.stockArr = res |
| | | }, |
| | | // 对话框中的 |
| | | async getWareHouseSelect2() { |
| | | const { data: res } = await WareHouseSelect() |
| | | this.stockArr2 = res |
| | | }, |
| | | // 排序改变时 |
| | | sortChange({ column, prop, order }) { |
| | | if (order === 'descending') { |
| | |
| | | <el-select |
| | | v-model="dialogForm.filingdate" |
| | | style="width: 220px" |
| | | filterable |
| | | placeholder="请选择" |
| | | :popper-append-to-body="false" |
| | | > |
| | |
| | | <el-form-item label="存货类型" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.stocktypecode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @change="val=>stocktypecodeChange(val,'form')" |
| | | > |
| | | <!-- @change="val=>stocktypecodeChange(val,'form')"--> |
| | | <el-option |
| | | v-for="item in stocktypeArr" |
| | | :key="item.code" |
| | |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="物料类型" style=" display: flex;"> |
| | | <el-form-item v-if="false" label="物料类型" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.materialtypecode" |
| | | filterable |
| | | :disabled="form.stocktypecode===''" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | |
| | | <el-form-item label="所属仓库" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.storehousecode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getWareHouseSelect" |
| | | > |
| | | <el-option |
| | | v-for="item in storehouseArr" |
| | |
| | | label="存货类型" |
| | | sortable="custom" |
| | | /> |
| | | <el-table-column |
| | | prop="materialtypename" |
| | | label="物料类别" |
| | | sortable="custom" |
| | | /> |
| | | <!-- <el-table-column--> |
| | | <!-- prop="materialtypename"--> |
| | | <!-- label="物料类别"--> |
| | | <!-- sortable="custom"--> |
| | | <!-- />--> |
| | | <el-table-column |
| | | prop="stck_name" |
| | | label="仓库名称" |
| | |
| | | <el-form-item label="使用单位" prop="uomcode"> |
| | | <el-select |
| | | v-model="dialogForm.uomcode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | |
| | | <el-form-item label="所属仓库" prop="warehousecode"> |
| | | <el-select |
| | | v-model="dialogForm.warehousecode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getWareHouseSelect2" |
| | | > |
| | | <el-option |
| | | v-for="item in storehouseArr" |
| | | v-for="item in storehouseArr2" |
| | | :key="item.code" |
| | | :label="item.name" |
| | | :value="item.code" |
| | |
| | | <el-form-item label="存货类型" prop="stocktypecode"> |
| | | <el-select |
| | | v-model="dialogForm.stocktypecode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @change="val=>stocktypecodeChange(val,'dialogForm')" |
| | | > |
| | | <!-- @change="val=>stocktypecodeChange(val,'dialogForm')"--> |
| | | |
| | | <el-option |
| | | v-for="item in stocktypeArr" |
| | | :key="item.code" |
| | |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="物料类型" prop="materialtypecode"> |
| | | <el-form-item v-if="false" label="物料类型" prop="materialtypecode"> |
| | | <el-select |
| | | v-model="dialogForm.materialtypecode" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | filterable |
| | | :disabled="dialogForm.stocktypecode===''" |
| | | placeholder="请选择" |
| | | > |
| | |
| | | stocktypeArr: [], // 存货类型数组 |
| | | materialtypeArr: [], // 物料类型数组 |
| | | storehouseArr: [], // 所属仓库数组 |
| | | storehouseArr2: [], // 所属仓库数组对话框 |
| | | tableData: [], |
| | | dialogVisible: false, |
| | | dialogForm: { |
| | |
| | | created() { |
| | | this.getInventoryFileSelect() |
| | | this.getStockTypeSelect() |
| | | this.getWareHouseSelect() |
| | | // this.getWareHouseSelect() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | const { data: res } = await WareHouseSelect() |
| | | this.storehouseArr = res |
| | | }, |
| | | async getWareHouseSelect2() { |
| | | const { data: res } = await WareHouseSelect() |
| | | this.storehouseArr2 = res |
| | | }, |
| | | async getuomSelect() { |
| | | const { data: res } = await UomSelect() |
| | | this.uomArr = res |
| | |
| | | <el-input v-model="form.stepname" placeholder="请输入" style="width: 200px" /> |
| | | </el-form-item> |
| | | <el-form-item label="启用状态" style=" display: flex;"> |
| | | <el-select v-model="form.enable" :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-select v-model="form.enable" filterable :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in enableArr" |
| | | :key="item.code" |
| | |
| | | <el-form-item label="工序类型" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.steptypecode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | |
| | | <el-form-item prop="steptypecode" label="工序类型"> |
| | | <el-select |
| | | v-model="dialogForm.steptypecode" |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | :popper-append-to-body="false" |
| | |
| | | <el-form-item prop="enable" label="启用状态"> |
| | | <el-select |
| | | v-model="dialogForm.enable" |
| | | filterable |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | :popper-append-to-body="false" |
| | |
| | | <el-form-item prop="enable" label="使用状态" style="margin-right: 20px"> |
| | | <el-select |
| | | v-model="dialogForm.enable" |
| | | filterable |
| | | :disabled="operation==='edit'" |
| | | :popper-append-to-body="false" |
| | | style="width: 220px" |
| | |
| | | <el-form-item label="产品名称" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.partcode" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | | @focus="getPartSelect" |
| | | @change="partChange" |
| | | > |
| | | <el-option |
| | |
| | | <el-form-item label="工艺路线" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.routecode" |
| | | filterable |
| | | :disabled="form.partcode===''" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | |
| | | <el-form-item label="关联设备" style=" display: flex;"> |
| | | <el-select |
| | | v-model="form.eqpcode" |
| | | filterable |
| | | :disabled="form.stepcode===''" |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | |
| | | <el-select |
| | | v-show="operation==='add'" |
| | | v-model="dialogForm.partcode" |
| | | filterable |
| | | style="width: 220px" |
| | | placeholder="请选择" |
| | | :popper-append-to-body="false" |
| | | @focus="getPartSelect2" |
| | | @change="partDialogChange" |
| | | > |
| | | <el-option |
| | | v-for="item in partArr" |
| | | v-for="item in partArr2" |
| | | :key="item.partcode" |
| | | :label="item.partname" |
| | | :value="item.partcode" |
| | |
| | | v-show="operation==='add'" |
| | | v-model="dialogForm.routecode" |
| | | style="width: 220px" |
| | | filterable |
| | | :disabled="dialogForm.partcode===''" |
| | | placeholder="请选择" |
| | | :popper-append-to-body="false" |
| | |
| | | rows: 20 // 每页多少条 |
| | | }, |
| | | partArr: [], // 产品集合 |
| | | partArr2: [], // 产品集合对话框 |
| | | routeArr: [], // 产品集合 |
| | | stepArr: [], // 产品集合 |
| | | eqpArr: [], // 产品集合 |
| | |
| | | }, |
| | | created() { |
| | | this.getBeatRateSearch() |
| | | this.getPartSelect() |
| | | // this.getPartSelect() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.getHeight) |
| | |
| | | const { data: res } = await PartSelect() |
| | | this.partArr = res |
| | | }, |
| | | async getPartSelect2() { |
| | | const { data: res } = await PartSelect() |
| | | this.partArr2 = res |
| | | }, |
| | | async partChange(val) { |
| | | const { data: res } = await PartSelectRpute({ partcode: val }) |
| | | this.routeArr = res |
| | |
| | | <el-input v-model="form.materialtypename" placeholder="请输入" style="width: 200px" /> |
| | | </el-form-item> |
| | | <el-form-item label="存货类型" style=" display: flex;"> |
| | | <el-select v-model="form.stocktypecode" :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-select v-model="form.stocktypecode" filterable :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in stocktypeArr" |
| | | :key="item.code" |
| | |
| | | <el-input v-model="dialogForm.materialtypename" style="width: 200px" /> |
| | | </el-form-item> |
| | | <el-form-item label="存货类型" prop="stocktypecode"> |
| | | <el-select v-model="dialogForm.stocktypecode" :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-select v-model="dialogForm.stocktypecode" filterable :popper-append-to-body="false" style="width: 200px" placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in stocktypeArr" |
| | | :key="item.code" |