|
@@ -221,24 +221,6 @@ export default {
|
|
|
this.form.customId = info.id;
|
|
this.form.customId = info.id;
|
|
|
this.form.customName = info.name;
|
|
this.form.customName = info.name;
|
|
|
},
|
|
},
|
|
|
- confirmFn (options) {
|
|
|
|
|
- let that = this
|
|
|
|
|
- if (options.sendType == 2) {
|
|
|
|
|
- options.sendCost = "";
|
|
|
|
|
- }
|
|
|
|
|
- let Fn = createOrder
|
|
|
|
|
- let params = {...options,modifyPrice: this.modifyPrice,newVersion:1};
|
|
|
|
|
- if(this.option.orderId && this.option.orderId > 0){
|
|
|
|
|
- Fn = updateOrder
|
|
|
|
|
- params = {...params,id:this.option.orderId}
|
|
|
|
|
- }
|
|
|
|
|
- Fn(params).then((res) => {
|
|
|
|
|
- //删除记忆
|
|
|
|
|
- this.removeMemory()
|
|
|
|
|
- const {data: { id, orderSn },} = res;
|
|
|
|
|
- this.$util.pageTo({ url: '/admin/breakage/result',type:2})
|
|
|
|
|
- });
|
|
|
|
|
- },
|
|
|
|
|
affirmFormSubmit () {
|
|
affirmFormSubmit () {
|
|
|
let self = this;
|
|
let self = this;
|
|
|
if(this.isBilling){
|
|
if(this.isBilling){
|
|
@@ -291,7 +273,7 @@ export default {
|
|
|
content: "确认报损?",
|
|
content: "确认报损?",
|
|
|
success: function (res) {
|
|
success: function (res) {
|
|
|
if (res.confirm) {
|
|
if (res.confirm) {
|
|
|
- wastage({product:JSON.stringify(product)}).then((res) => {
|
|
|
|
|
|
|
+ wastage({product:JSON.stringify(product),remark:that.form.remark}).then((res) => {
|
|
|
//删除记忆
|
|
//删除记忆
|
|
|
that.removeMemory()
|
|
that.removeMemory()
|
|
|
const {data: { id, orderSn },} = res;
|
|
const {data: { id, orderSn },} = res;
|
|
@@ -330,7 +312,7 @@ export default {
|
|
|
let checkRes = formUtil.validation(formData, []);
|
|
let checkRes = formUtil.validation(formData, []);
|
|
|
// 验证通过!
|
|
// 验证通过!
|
|
|
if (!checkRes) {
|
|
if (!checkRes) {
|
|
|
- this.confirmFn(formData);
|
|
|
|
|
|
|
+
|
|
|
} else {
|
|
} else {
|
|
|
this.$msg(checkRes);
|
|
this.$msg(checkRes);
|
|
|
}
|
|
}
|