Commit 239d6ee4 authored by zhanglw's avatar zhanglw

生产计划

parent f18a453e
<template> <template>
<div class="login" :style="'background-image:url('+ Background +');'"> <div class="login" :style="'background-image:url('+ Background +');'">
<div class="logo-place"> <div class="logo-place">
<div class="logo-title">卡车调度系统</div> <div class="logo-title">恒源矿业二道庄矿区智慧矿山</div>
<div class="ctn-place"> <div class="ctn-place">
<div class="inbox-range"> <div class="inbox-range">
<div class="ctn-fix"> <div class="ctn-fix">
......
...@@ -4,8 +4,13 @@ ...@@ -4,8 +4,13 @@
<div><input type="button" id="title-btn-left" value="<" class="title-btn-hover" @click="lastMonthCalender()"/> <div><input type="button" id="title-btn-left" value="<" class="title-btn-hover" @click="lastMonthCalender()"/>
</div> </div>
<div class="show_year_month"> <div class="show_year_month">
<div><label id="showMonth">{{ showMonth }}<span style="font-size:22px"></span></label></div> <div>
<div><label id="showYear">{{ showYear }}{{ showMonth }}月份生产计划表</label></div> <label id="showMonth">{{ showMonth }}<span style="font-size:22px"></span></label>
<el-button id="planSlotBtn" size="mini" type="success" icon="el-icon-date" plain circle @click="showPlanDateSlot()">创建计划</el-button>
</div>
<div>
<label id="showYear">{{ showYear }}{{ showMonth }}月份生产计划表</label>
</div>
</div> </div>
<div><input type="button" id="title-btn-right" value=">" class="title-btn-hover" @click="nextMonthCalender()"/> <div><input type="button" id="title-btn-right" value=">" class="title-btn-hover" @click="nextMonthCalender()"/>
</div> </div>
...@@ -74,10 +79,34 @@ ...@@ -74,10 +79,34 @@
<span id="plusMonth" class="cal" @click="nextMonthCalender()">+</span> <span id="plusMonth" class="cal" @click="nextMonthCalender()">+</span>
</div> </div>
</div> </div>
<el-dialog title="生产计划明细" :visible.sync="dialogPlanVisible" width="60%"> <el-dialog title="当日生产计划明细" :visible.sync="dialogPlanVisible" width="60%">
<!-- <div class="toolbar" style="margin-bottom:15px;display:flex">-->
<!-- <el-button size="mini" type="primary" icon="el-icon-plus" @click="showPlanDateSlot()">批量选取日期</el-button>-->
<!-- <div v-show="showDateSlot">-->
<!-- <label class="el-form-item-label" style="margin-left:150px;">选择起止日期:</label>-->
<!-- <el-date-picker v-model="planSDate" type="date" placeholder="选择开始日期"></el-date-picker>-->
<!-- ~-->
<!-- <el-date-picker v-model="planEDate" type="date" placeholder="选择结束日期"></el-date-picker>-->
<!-- </div>-->
<!-- </div>-->
<el-table :data="planData" border show-summary>
<el-table-column property="minePoint" label="采区名称" align="center"></el-table-column>
<el-table-column property="plan" label="计划量(T)" align="center">
<template slot-scope="scope">
<el-input placeholder="请输入计划量(T)" v-model="scope.row.plan" clearable :disabled="planValIsReadonly"></el-input>
</template>
</el-table-column>
<el-table-column property="actualProduction" label="实际产出(T)" align="center"></el-table-column>
</el-table>
<div slot="footer" class="dialog-footer">
<el-button @click="cancelPlanView()">取消</el-button>
<el-button v-show="!planValIsReadonly" type="primary" @click="submitPlanView()">提交</el-button>
</div>
</el-dialog>
<el-dialog title="创建生产计划" :visible.sync="showDateSlot" width="60%">
<div class="toolbar" style="margin-bottom:15px;display:flex"> <div class="toolbar" style="margin-bottom:15px;display:flex">
<el-button size="mini" type="primary" icon="el-icon-plus" @click="showPlanDateSlot()">批量选取日期</el-button> <div>
<div v-show="showDateSlot">
<label class="el-form-item-label" style="margin-left:150px;">选择起止日期:</label> <label class="el-form-item-label" style="margin-left:150px;">选择起止日期:</label>
<el-date-picker v-model="planSDate" type="date" placeholder="选择开始日期"></el-date-picker> <el-date-picker v-model="planSDate" type="date" placeholder="选择开始日期"></el-date-picker>
~ ~
...@@ -88,14 +117,13 @@ ...@@ -88,14 +117,13 @@
<el-table-column property="minePoint" label="采区名称" align="center"></el-table-column> <el-table-column property="minePoint" label="采区名称" align="center"></el-table-column>
<el-table-column property="plan" label="计划量(T)" align="center"> <el-table-column property="plan" label="计划量(T)" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input placeholder="请输入计划量(T)" v-model="scope.row.plan" clearable :disabled="planValIsReadonly"></el-input> <el-input placeholder="请输入计划量(T)" v-model="scope.row.plan" clearable></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column property="actualProduction" label="实际产出(T)" align="center"></el-table-column>
</el-table> </el-table>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="cancelPlanView()">取消</el-button> <el-button @click="cancelPlanView()">取消</el-button>
<el-button v-show="!planValIsReadonly" type="primary" @click="submitPlanView()">提交</el-button> <el-button type="primary" @click="submitPlanView()">提交</el-button>
</div> </div>
</el-dialog> </el-dialog>
...@@ -196,9 +224,19 @@ export default { ...@@ -196,9 +224,19 @@ export default {
}, },
showPlanDateSlot() { showPlanDateSlot() {
this.showDateSlot = !this.showDateSlot; this.showDateSlot = !this.showDateSlot;
document.getElementById("planSlotBtn").blur();
this.planSDate = this.showYear + '-' + this.showMonth + '-01';
this.planEDate = this.showYear + '-' + this.showMonth + '-'+this.monthDays(this.showYear, this.showMonth);
this.planData = [];
HttpReq.truckDispatching.tPlanGetOneDayPlanByTime({}).then((res) => {
if (res.code == 200) {
this.planData = res.data || [];
}
})
}, },
cancelPlanView() { cancelPlanView() {
this.dialogPlanVisible = false; this.dialogPlanVisible = false;
this.showDateSlot = false;
}, },
//计算日期对应周几 //计算日期对应周几
dateMapWeekDay(year, month, date) { dateMapWeekDay(year, month, date) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment