addtocash using sendcoins Circuit
This commit is contained in:
@@ -60,11 +60,14 @@ function getRecordProductEmpty(): IProduct {
|
||||
|
||||
stockQty: 0,
|
||||
stockBloccatiQty: 0,
|
||||
bookedQtyOrdered: 0,
|
||||
bookedQtyConfirmed: 0,
|
||||
|
||||
qtyToReachForGas: 0,
|
||||
|
||||
maxbookableGASQty: 0,
|
||||
bookedGASQtyOrdered: 0,
|
||||
bookedGASQtyConfirmed: 0,
|
||||
bookableGASBloccatiQty: 0,
|
||||
|
||||
canBeShipped: false,
|
||||
@@ -621,6 +624,10 @@ export const useProducts = defineStore('Products', {
|
||||
return ris
|
||||
},
|
||||
|
||||
getOptions() {
|
||||
return {}
|
||||
},
|
||||
|
||||
async CreateOrdersCart({ cart_id, status, note }: { cart_id: string, status: number, note: string }) {
|
||||
|
||||
const userStore = useUserStore()
|
||||
@@ -631,7 +638,7 @@ export const useProducts = defineStore('Products', {
|
||||
|
||||
let ris = null
|
||||
|
||||
ris = await Api.SendReq('/cart/' + userStore.my._id + '/createorderscart', 'POST', { cart_id, status, note })
|
||||
ris = await Api.SendReq('/cart/' + userStore.my._id + '/createorderscart', 'POST', { cart_id, status, note, options: this.getOptions() })
|
||||
.then((res) => {
|
||||
|
||||
if (res.data.status === shared_consts.OrderStatus.CHECKOUT_SENT) {
|
||||
@@ -662,7 +669,7 @@ export const useProducts = defineStore('Products', {
|
||||
|
||||
let ris = null
|
||||
|
||||
ris = await Api.SendReq('/cart/updatestatuscart', 'POST', { ordercart_id, status })
|
||||
ris = await Api.SendReq('/cart/updatestatuscart', 'POST', { ordercart_id, status, options: this.getOptions() })
|
||||
.then((res) => {
|
||||
|
||||
if (res.data.status === shared_consts.OrderStatus.CHECKOUT_SENT) {
|
||||
@@ -681,6 +688,8 @@ export const useProducts = defineStore('Products', {
|
||||
return ris
|
||||
},
|
||||
|
||||
|
||||
|
||||
async UpdateOrderCartStatus({ order_id, status }: { order_id: string, status: number }) {
|
||||
|
||||
const userStore = useUserStore()
|
||||
@@ -691,7 +700,7 @@ export const useProducts = defineStore('Products', {
|
||||
|
||||
let ris = null
|
||||
|
||||
ris = await Api.SendReq('/cart/' + userStore.my._id + '/ordercartstatus', 'POST', { order_id, status, options })
|
||||
ris = await Api.SendReq('/cart/' + userStore.my._id + '/ordercartstatus', 'POST', { order_id, status, options: this.getOptions() })
|
||||
.then((res) => {
|
||||
|
||||
this.updateDataProduct(res)
|
||||
|
||||
Reference in New Issue
Block a user