---
title: "RotateProductCommand | Customer's Canvas On-Premises"
canonical: "https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/RotateProductCommand/"
---

# RotateProductCommand

> - [`BaseProductCommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#abstract-baseproductcommand)\<[`IRotateProductCmdArgs`](#irotateproductcmdargs), `number`\>

## Classes

### RotateProductCommand

#### Extends

#### Constructors

##### Constructor

```ts
new RotateProductCommand(
   productHandler, 
   historyArgs, 
   product, 
   args): RotateProductCommand;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `productHandler` | [`ProductHandler`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/ProductHandler.md#producthandler) |
| `historyArgs` | [`IHistoryArgs`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/ModelUpdateCommand.md#ihistoryargs) |
| `product` | `Product` |
| `args` | [`IRotateProductCmdArgs`](#irotateproductcmdargs) |

###### Returns

[`RotateProductCommand`](#rotateproductcommand)

###### Overrides

[`BaseProductCommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#abstract-baseproductcommand).[`constructor`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#constructor)

#### Methods

##### execute()

```ts
execute(): Promise<number>;
```

###### Returns

[`Promise`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/finally.md#promise)\<`number`\>

###### Inherited from

[`BaseProductCommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#abstract-baseproductcommand).[`execute`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#execute)

##### executeCommandBody()

```ts
executeCommandBody(): Promise<number>;
```

###### Returns

[`Promise`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/finally.md#promise)\<`number`\>

###### Overrides

```ts
BaseProductCommand._executeCommandBody
```

##### redo()

```ts
redo(): Promise<void>;
```

###### Returns

[`Promise`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/finally.md#promise)\<`void`\>

###### Overrides

[`BaseProductCommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#abstract-baseproductcommand).[`redo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#redo)

##### rotateProduct()

```ts
rotateProduct(type): number;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `type` | `RotationType` |

###### Returns

`number`

##### undo()

```ts
undo(): Promise<void>;
```

###### Returns

[`Promise`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/finally.md#promise)\<`void`\>

###### Overrides

[`BaseProductCommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#abstract-baseproductcommand).[`undo`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms/BaseProductCommand.md#undo)

## Interfaces

### IRotateProductCmdArgs

#### Properties

##### rotationType

```ts
rotationType: RotationType;
```
