2023-01-16 13:52:08 +00:00
|
|
|
import { Sequelize } from 'sequelize';
|
|
|
|
|
2023-05-30 09:46:46 +00:00
|
|
|
const volumePrice = {
|
2023-05-15 12:19:43 +00:00
|
|
|
supplyLineId: {
|
|
|
|
type: Sequelize.STRING,
|
|
|
|
primaryKey: true,
|
|
|
|
},
|
|
|
|
unit: {
|
|
|
|
type: Sequelize.STRING,
|
|
|
|
primaryKey: true,
|
|
|
|
},
|
|
|
|
pricePerPiece: {
|
|
|
|
type: Sequelize.DECIMAL(10,2),
|
|
|
|
primaryKey: true,
|
|
|
|
},
|
2023-01-16 13:52:08 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
export default (sequelize) => {
|
2023-05-30 09:46:46 +00:00
|
|
|
return sequelize.define(
|
|
|
|
'supplyLineVolumePrice',
|
|
|
|
volumePrice, {
|
2023-05-15 12:19:43 +00:00
|
|
|
timestamps: false,
|
|
|
|
freezeTableName: true,
|
|
|
|
}
|
|
|
|
);
|
2023-01-16 13:52:08 +00:00
|
|
|
};
|