diff --git a/demos/_demo-data/create-db.php b/demos/_demo-data/create-db.php index 931ef89ff8..201fe4aaaa 100644 --- a/demos/_demo-data/create-db.php +++ b/demos/_demo-data/create-db.php @@ -358,7 +358,7 @@ public function import(array $rowsMulti) $model->addField('name', ['type' => 'string']); $model->addField('type', ['type' => 'string']); $model->addField('is_folder', ['type' => 'boolean']); -$model->addField('parent_folder_id', ['type' => 'integer']); +$model->addField('parent_folder_id', ['type' => 'bigint']); (new Migrator($model))->create(); (new Migrator($model))->createForeignKey([$model->getField('atk_fp_file__parent_folder_id'), $model->getField('atk_fp_file__id')]); $model->import([ @@ -1125,7 +1125,7 @@ public function import(array $rowsMulti) $model = new ImportModelWithPrefixedFields($db, ['table' => 'product_sub_category']); $model->addField('name', ['type' => 'string']); -$model->addField('product_category_id', ['type' => 'integer']); +$model->addField('product_category_id', ['type' => 'bigint']); $productSubcategoryIdField = $model->getField('atk_fp_6f3c91cf51e02fd5__id'); (new Migrator($model))->create(); (new Migrator($model))->createForeignKey([$model->getField('atk_fp_6f3c91cf51e02fd5__product_category_id'), $productCategoryIdField]); @@ -1144,8 +1144,8 @@ public function import(array $rowsMulti) $model = new ImportModelWithPrefixedFields($db, ['table' => 'product']); $model->addField('name', ['type' => 'string']); $model->addField('brand', ['type' => 'string']); -$model->addField('product_category_id', ['type' => 'integer']); -$model->addField('product_sub_category_id', ['type' => 'integer']); +$model->addField('product_category_id', ['type' => 'bigint']); +$model->addField('product_sub_category_id', ['type' => 'bigint']); (new Migrator($model))->create(); (new Migrator($model))->createForeignKey([$model->getField('atk_fp_product__product_category_id'), $productCategoryIdField]); (new Migrator($model))->createForeignKey([$model->getField('atk_fp_product__6f3c91cf51e02fd5_id'), $productSubcategoryIdField]); @@ -1163,7 +1163,7 @@ public function import(array $rowsMulti) $model->addField('item', ['type' => 'string']); $model->addField('inv_date', ['type' => 'date']); $model->addField('inv_time', ['type' => 'time']); -$model->addField('country_id', ['type' => 'integer']); +$model->addField('country_id', ['type' => 'bigint']); $model->addField('qty', ['type' => 'integer']); $model->addField('box', ['type' => 'integer']); (new Migrator($model))->create(); diff --git a/demos/init-app.php b/demos/init-app.php index 2f161a12cc..97c96b0666 100644 --- a/demos/init-app.php +++ b/demos/init-app.php @@ -47,7 +47,7 @@ public function typecastAttributeSaveField(Field $field, $value): ?string if ($field->type === WrappedIdType::NAME) { return $value === null ? null - : $this->typecastAttributeSaveField(new Field(['type' => 'integer']), $value->getId() + 218_000_000); + : $this->typecastAttributeSaveField(new Field(['type' => 'bigint']), $value->getId() + 218_000_000); } return parent::typecastAttributeSaveField($field, $value); @@ -57,7 +57,7 @@ public function typecastAttributeSaveField(Field $field, $value): ?string public function typecastAttributeLoadField(Field $field, ?string $value) { if ($field->type === WrappedIdType::NAME) { - $value = $this->typecastAttributeLoadField(new Field(['type' => 'integer']), $value); + $value = $this->typecastAttributeLoadField(new Field(['type' => 'bigint']), $value); return $value === null ? null diff --git a/demos/init-db.php b/demos/init-db.php index 22c5e75ef0..bc8516bfe3 100644 --- a/demos/init-db.php +++ b/demos/init-db.php @@ -65,7 +65,7 @@ public function getName(): string #[\Override] public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform): string { - return DbalType::getType('integer')->getSQLDeclaration($fieldDeclaration, $platform); + return DbalType::getType('bigint')->getSQLDeclaration($fieldDeclaration, $platform); } #[\Override] @@ -75,7 +75,7 @@ public function convertToDatabaseValue($value, AbstractPlatform $platform): ?int return null; } - return DbalType::getType('integer')->convertToDatabaseValue($value->getId(), $platform); + return DbalType::getType('bigint')->convertToDatabaseValue($value->getId(), $platform); } #[\Override] @@ -85,7 +85,7 @@ public function convertToPHPValue($value, AbstractPlatform $platform): ?object return null; } - return new WrappedId(DbalType::getType('integer')->convertToPHPValue($value, $platform)); + return new WrappedId((int) DbalType::getType('bigint')->convertToPHPValue($value, $platform)); // once DBAL 3.x support is dropped, the explicit cast should no longer be needed } #[\Override] @@ -675,13 +675,13 @@ protected function init(): void 'expr' => function (Model /* TODO self is not working because of clone in Multiline */ $row) { return $row->expr('{' . $this->fieldName()->qty . '} * {' . $this->fieldName()->box . '}'); // @phpstan-ignore method.notFound }, - 'type' => 'integer', + 'type' => 'bigint', ]); $this->addCalculatedField($this->fieldName()->total_php, [ 'expr' => static function (self $row) { return $row->qty * $row->box; }, - 'type' => 'integer', + 'type' => 'bigint', ]); } } diff --git a/docs/multiline.md b/docs/multiline.md index ea539b4133..58f47d2f66 100644 --- a/docs/multiline.md +++ b/docs/multiline.md @@ -159,7 +159,7 @@ class InventoryItem extends \Atk4\Data\Model $this->addField('box', ['type' => 'integer', 'caption' => '# of Boxes', 'required' => true, 'ui' => ['multiline' => [Form\Control\Multiline::TABLE_CELL => ['width' => 2]]]]); $this->addExpression('total', ['expr' => function (Model $row) { return $row->get('qty') * $row->get('box'); - }, 'type' => 'integer']); + }, 'type' => 'bigint']); } } ``` @@ -242,7 +242,7 @@ $this->addExpression('total', [ 'expr' => function (Model $row) { return $row->get('qty') * $row->get('box'); }, - 'type' => 'integer', + 'type' => 'bigint', 'ui' => ['multiline' => [Multiline::TABLE_CELL => ['width' => 1, 'class' => 'blue']]], ]); ``` diff --git a/js/src/vue-components/multiline/multiline-header.component.js b/js/src/vue-components/multiline/multiline-header.component.js index 55f9690d44..5e337dc9d4 100644 --- a/js/src/vue-components/multiline/multiline-header.component.js +++ b/js/src/vue-components/multiline/multiline-header.component.js @@ -51,7 +51,9 @@ export default { let align = 'left'; if (!column.isEditable) { switch (column.type) { + case 'smallint': case 'integer': + case 'bigint': case 'float': case 'atk4_money': { align = 'right'; diff --git a/public/js/atk-vue-multiline.js b/public/js/atk-vue-multiline.js index 228eea0807..aed6e67d3d 100644 --- a/public/js/atk-vue-multiline.js +++ b/public/js/atk-vue-multiline.js @@ -205,7 +205,9 @@ __webpack_require__.r(__webpack_exports__); let align = 'left'; if (!column.isEditable) { switch (column.type) { + case 'smallint': case 'integer': + case 'bigint': case 'float': case 'atk4_money': { diff --git a/public/js/atk-vue-multiline.js.map b/public/js/atk-vue-multiline.js.map index c5dfa22b03..96c656422d 100644 --- a/public/js/atk-vue-multiline.js.map +++ b/public/js/atk-vue-multiline.js.map @@ -1 +1 @@ -{"version":3,"file":"js/atk-vue-multiline.js","mappings":";;;;;;;;;;;;;;AAAqD;AAErD,iEAAe;EACXC,IAAI,EAAE,kBAAkB;EACxBC,QAAQ,EAAG;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwB;EACpBC,KAAK,EAAE,CAAC,WAAW,EAAE,SAAS,EAAE,YAAY,EAAE,QAAQ,CAAC;EACvDC,IAAI,EAAE,SAAAA,CAAA,EAAY;IACd,OAAO;MAAEC,MAAM,EAAE,IAAI,CAACC;IAAU,CAAC;EACrC,CAAC;EACDC,OAAO,EAAE,SAAAA,CAAA,EAAY,CAAC,CAAC;EACvBC,UAAU,EAAE;IACRC,eAAe,EAAET,gEAAYA;EACjC,CAAC;EACDU,QAAQ,EAAE;IACNC,IAAI,EAAE,SAAAA,CAAA,EAAY;MACd,OAAO,IAAI,CAACC,OAAO;IACvB;EACJ,CAAC;EACDC,KAAK,EAAE,CAAC,cAAc,CAAC;EACvBC,OAAO,EAAE;IACLC,eAAe,EAAE,SAAAA,CAAUC,QAAQ,EAAE;MACjC,IAAIA,QAAQ,GAAG,CAAC,KAAK,IAAI,CAACJ,OAAO,CAACK,MAAM,EAAE;QACtC,IAAI,CAACC,KAAK,CAAC,cAAc,CAAC;MAC9B;IACJ,CAAC;IACDC,cAAc,EAAE,SAAAA,CAAUC,GAAG,EAAE;MAC3B,OAAO,IAAI,CAACC,UAAU,CAACC,QAAQ,CAACF,GAAG,CAACG,OAAO,CAAC;IAChD,CAAC;IACDC,YAAY,EAAE,SAAAA,CAAUC,KAAK,EAAE;MAC3B,OAAO,IAAI,CAACC,MAAM,CAACD,KAAK,CAAC,IAAI,EAAE;IACnC;EACJ;AACJ,CAAC;;;;;;;;;;;;;;;;;;AC3C8D;AACA;AACV;AACT;AAE5C,iEAAe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E;MACvB,IAAI,CAAC9B,KAAK,CAAC,mBAAmB,EAAE8B,KAAK,CAACA,KAAK,CAAC;IAChD;EACJ;AACJ,CAAC;;;;;;;;;;ACjDY;AACb,QAAQ,mBAAO,CAAC,uEAAqB;AACrC,YAAY,uIAAqD;;AAEjE;AACA;AACA,IAAI,kDAAkD;AACtD;AACA;AACA;AACA,CAAC;;;;;;;;;;;ACVY;AACb,QAAQ,mBAAO,CAAC,uEAAqB;AACrC,cAAc,mBAAO,CAAC,yEAAsB;AAC5C,gBAAgB,mBAAO,CAAC,+EAAyB;AACjD,eAAe,mBAAO,CAAC,6EAAwB;AAC/C,wBAAwB,mBAAO,CAAC,iGAAkC;;AAElE;AACA;AACA,IAAI,6CAA6C;AACjD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK,IAAI,oCAAoC;AAC7C;AACA,CAAC","sources":["webpack://atk/./src/vue-components/multiline/multiline-body.component.js","webpack://atk/./src/vue-components/multiline/multiline-cell.component.js","webpack://atk/./src/vue-components/multiline/multiline-header.component.js","webpack://atk/./src/vue-components/multiline/multiline-readonly.component.js","webpack://atk/./src/vue-components/multiline/multiline-row.component.js","webpack://atk/./src/vue-components/multiline/multiline-textarea.component.js","webpack://atk/./src/vue-components/multiline/multiline.component.js","webpack://atk/./src/vue-components/share/atk-date-picker.js","webpack://atk/./src/vue-components/share/atk-lookup.js","webpack://atk/./node_modules/core-js/modules/esnext.async-iterator.some.js","webpack://atk/./node_modules/core-js/modules/esnext.iterator.some.js"],"sourcesContent":["import multilineRow from './multiline-row.component';\n\nexport default {\n name: 'AtkMultilineBody',\n template: `\n \n \n `,\n props: ['fieldDefs', 'rowData', 'deletables', 'errors'],\n data: function () {\n return { fields: this.fieldDefs };\n },\n created: function () {},\n components: {\n AtkMultilineRow: multilineRow,\n },\n computed: {\n rows: function () {\n return this.rowData;\n },\n },\n emits: ['onTabLastRow'],\n methods: {\n onTabLastColumn: function (rowIndex) {\n if (rowIndex + 1 === this.rowData.length) {\n this.$emit('onTabLastRow');\n }\n },\n isDeletableRow: function (row) {\n return this.deletables.includes(row.__atkml);\n },\n getRowErrors: function (rowId) {\n return this.errors[rowId] ?? [];\n },\n },\n};\n","import multilineReadonly from './multiline-readonly.component';\nimport multilineTextarea from './multiline-textarea.component';\nimport atkDatePicker from '../share/atk-date-picker';\nimport atkLookup from '../share/atk-lookup';\n\nexport default {\n name: 'AtkMultilineCell',\n template: `\n `,\n components: {\n AtkMultilineReadonly: multilineReadonly,\n AtkMultilineTextarea: multilineTextarea,\n AtkDatePicker: atkDatePicker,\n AtkLookup: atkLookup,\n },\n props: ['cellData', 'fieldValue'],\n data: function () {\n return {\n fieldName: this.cellData.name,\n type: this.cellData.type,\n inputName: '-' + this.cellData.name,\n inputValue: this.fieldValue,\n };\n },\n emits: ['updateValue'],\n methods: {\n getComponent: function () {\n return this.cellData.definition.component;\n },\n getComponentProps: function () {\n if (this.getComponent() === 'AtkMultilineReadonly') {\n return { readOnlyValue: this.fieldValue };\n }\n\n return this.cellData.definition.componentProps;\n },\n onInput: function (value) {\n this.inputValue = value;\n this.$emit('updateValue', this.fieldName, this.inputValue);\n },\n },\n};\n","import atk from 'atk';\n\nexport default {\n name: 'AtkMultilineHeader',\n template: `\n \n \n \n \n \n {{getErrorMsg(column)}}\n \n \n \n {{caption}}\n \n \n \n \n \n \n
{{column.caption}}
\n
\n {{getErrorMsg(column)}}\n
\n \n
\n
`,\n props: ['fields', 'selectionState', 'errors', 'caption'],\n data: function () {\n return { columns: this.fields, isDeleteAll: false };\n },\n methods: {\n filterVisibleColumns: function (columns) {\n return columns.filter((v) => v.isVisible);\n },\n onToggleDeleteAll: function () {\n this.$nextTick(() => {\n atk.eventBus.emit(this.$root.$el.parentElement.id + '-toggle-delete-all', { isOn: this.$refs.check.checked });\n });\n },\n getTextAlign: function (column) {\n let align = 'left';\n if (!column.isEditable) {\n switch (column.type) {\n case 'integer':\n case 'float':\n case 'atk4_money': {\n align = 'right';\n\n break;\n }\n }\n }\n\n return align;\n },\n getVisibleColumns: function () {\n let count = 1; // add deletable column;\n for (const field of this.columns) {\n count = field.isVisible ? count + 1 : count;\n }\n\n return count;\n },\n hasError: function () {\n return Object.keys(this.errors).length > 0;\n },\n hasCaption: function () {\n return this.caption;\n },\n getErrorMsg: function (column) {\n if (this.hasError()) {\n const rows = Object.keys(this.errors);\n for (const row of rows) {\n const error = this.errors[row].filter((col) => col.name === column.name);\n if (error.length > 0) {\n return error[0].msg;\n }\n }\n }\n\n return null;\n },\n },\n computed: {\n isIndeterminate: function () {\n return this.selectionState === 'indeterminate';\n },\n isChecked: function () {\n return this.selectionState === 'on';\n },\n },\n};\n","/**\n * Simply display a readonly value.\n */\nexport default {\n name: 'AtkMultilineReadonly',\n template: '
{{readOnlyValue}}
',\n props: ['readOnlyValue'],\n};\n","import atk from 'atk';\nimport multilineCell from './multiline-cell.component';\n\n/**\n * This will create a table td element using SuiTableCell.\n * The td element is created only if column as set isVisible = true;\n * The td element will add a multiline cell element.\n * the multiline cell will set it's own template component depending on the fieldType.\n * getValue\n */\nexport default {\n name: 'AtkMultilineRow',\n template: `\n \n \n \n \n \n \n \n `,\n props: ['fields', 'rowId', 'isDeletable', 'rowValues', 'errors'],\n data: function () {\n return { columns: this.fields };\n },\n components: {\n AtkMultilineCell: multilineCell,\n },\n computed: {\n /**\n * toDelete is bind by v-model, thus we need a setter for\n * computed property to work.\n * When isDeletable is pass, will set checkbox according to it's value.\n */\n toDelete: {\n get: function () {\n return this.isDeletable;\n },\n set: function (v) {\n return v;\n },\n },\n },\n emits: ['onTabLastColumn'],\n methods: {\n filterVisibleColumns: function (columns) {\n return columns.filter((v) => v.isVisible);\n },\n onTab: function (columnIndex) {\n if (columnIndex === this.columns.filter((column) => column.isEditable).length - 1) {\n this.$emit('onTabLastColumn');\n }\n },\n hasColumnError: function (column) {\n return this.errors.some((v) => column.name === v.name);\n },\n onToggleDelete: function (e) {\n atk.eventBus.emit(this.$root.$el.parentElement.id + '-toggle-delete', { rowId: this.rowId });\n },\n onUpdateValue: function (fieldName, value) {\n atk.eventBus.emit(this.$root.$el.parentElement.id + '-update-row', { rowId: this.rowId, fieldName: fieldName, value: value });\n },\n getValue: function (column) {\n return this.rowValues[column.name] || column.default;\n },\n },\n};\n","export default {\n name: 'AtkMultilineTextarea',\n template: '