1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- <template>
- <!-- 修改人员信息 -->
- <div id="contractDetails">
- <page-title>编辑</page-title>
- <div class="main">
- <span class="text">人员信息</span>
- </div>
- <div class="contractTitle">
- <div class="form-box">
- <div class="form-one">
- <dil-form :formId="324" v-model="form1"></dil-form>
- </div>
- </div>
- </div>
- <div class="button-box">
- <el-button type="primary" @click="onClickConfirm">确认</el-button>
- <el-button @click="onClickCancel">返回</el-button>
- </div>
- </div>
- </template>
- <script>
- import PageTitle from "@/components/Page/Title";
- //import { sjTime } from "@/js/sharedJsFile";
- export default {
- components: { PageTitle },
- data() {
- return {
- form1: {},
- };
- },
- mounted() {
- this.information();
- },
- methods: {
- information() {
- //编辑
- console.log(this.$route.params)
- this.$axios
- .post(
- "/api/v1/rms/getPersonnelById/" +
- this.$route.params.personnelId
- )
-
- .then((res) => {
- console.log(res.data.data)
- res.data.data.forEach((e) => {
- this.form1 = e;
- });
- });
- },
- // 返回
- onClickCancel() {
- this.$router.go(-1);
- },
- // 确认
- onClickConfirm() {
- console.log(this.form1)
- let RmsPersonnel={
- personnelId:this.form1.personnelId,
- personnelJobNumber: this.form1.personnelJobNumber,
- personnelName: this.form1.personnelName,
- personnelPost: this.form1.personnelPost,
- personnelWorkshopid: this.form1.personnelWorkshopid,
- personnelShifts: this.form1.personnelShifts,
- shipperId: this.form1.shipperId,
- }
- this.$axios
- .post(
- "/api/v1/rms/updatePersonnel",
- RmsPersonnel
- )
- .then((res) => {
- if (res.data.code == "200") {
- this.$router.go(-1);
-
- }
- });
- },
- },
- };
- </script>
- <style lang="scss" scoped>
- </style>
|