Compare commits
	
		
			3 Commits
		
	
	
		
			b240d7a9d1
			...
			2ba590a0a0
		
	
	| Author | SHA1 | Date | 
|---|---|---|
|  | 2ba590a0a0 | |
|  | a62eeb60d2 | |
|  | 31a13546bb | 
|  | @ -203,9 +203,9 @@ func (w Warehouse) UpdateStatusWarehousePendingInactive(p model.UpdateStatusWare | |||
| 	return nil | ||||
| } | ||||
| 
 | ||||
| // MigrationSellyMall ...
 | ||||
| func (w Warehouse) MigrationSellyMall() error { | ||||
| 	_, err := natsio.GetServer().Request(subject.Warehouse.MigrationIsSellyMall, toBytes("")) | ||||
| // UpdateIsSellyMall ...
 | ||||
| func (w Warehouse) UpdateIsSellyMall(p model.UpdateIsSellyMallRequest) error { | ||||
| 	msg, err := natsio.GetServer().Request(subject.Warehouse.UpdateIsSellyMall, toBytes(p)) | ||||
| 	if err != nil { | ||||
| 		return err | ||||
| 	} | ||||
|  | @ -214,9 +214,11 @@ func (w Warehouse) MigrationSellyMall() error { | |||
| 		Error string `json:"error"` | ||||
| 	} | ||||
| 
 | ||||
| 	if err = json.Unmarshal(msg.Data, &r); err != nil { | ||||
| 		return fmt.Errorf("nats: update_is_selly_mall %v", err) | ||||
| 	} | ||||
| 	if r.Error != "" { | ||||
| 		return errors.New(r.Error) | ||||
| 	} | ||||
| 
 | ||||
| 	return nil | ||||
| } | ||||
|  |  | |||
|  | @ -120,6 +120,11 @@ type UpdateStatusWarehousePendingInactiveRequest struct { | |||
| 	Warehouses []UpdateStatusWarehousePendingInactive `json:"warehouses"` | ||||
| } | ||||
| 
 | ||||
| // UpdateIsSellyMallRequest ...
 | ||||
| type UpdateIsSellyMallRequest struct { | ||||
| 	SupplierID string `json:"supplier"` | ||||
| } | ||||
| 
 | ||||
| // UpdateStatusWarehousePendingInactive ...
 | ||||
| type UpdateStatusWarehousePendingInactive struct { | ||||
| 	WarehouseID     string `json:"warehouse"` | ||||
|  |  | |||
|  | @ -29,7 +29,7 @@ var Warehouse = struct { | |||
| 	GetWarehouses                        string | ||||
| 	UpdateORDeliveryStatus               string | ||||
| 	UpdateStatusWarehousePendingInactive string | ||||
| 	MigrationIsSellyMall                 string | ||||
| 	UpdateIsSellyMall                    string | ||||
| }{ | ||||
| 	CreateWarehouseIntoServiceSupplier:   getWarehouseValue("create_warehouse_into_service_supplier"), | ||||
| 	UpdateWarehouseIntoServiceSupplier:   getWarehouseValue("update_warehouse_into_service_supplier"), | ||||
|  | @ -51,5 +51,5 @@ var Warehouse = struct { | |||
| 	GetWarehouses:                        getWarehouseValue("get_warehouses"), | ||||
| 	UpdateORDeliveryStatus:               getWarehouseValue("update_or_delivery_status"), | ||||
| 	UpdateStatusWarehousePendingInactive: getWarehouseValue("update_status_warehouse_pending_inactive"), | ||||
| 	MigrationIsSellyMall:                 getWarehouseValue("migration_is_selly_mall"), | ||||
| 	UpdateIsSellyMall:                    getWarehouseValue("update_is_selly_mall"), | ||||
| } | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue