mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-01-14 12:06:24 +00:00
Enable multi-line text editing for API forms
- User can edit part notes - User can edit stock item notes
This commit is contained in:
parent
b8379e05db
commit
d6a2a41ab2
10 changed files with 129 additions and 82 deletions
|
|
@ -47,7 +47,6 @@ class _StockItemDisplayState extends RefreshableState<StockDetailWidget> {
|
|||
final _removeStockKey = GlobalKey<FormState>();
|
||||
final _countStockKey = GlobalKey<FormState>();
|
||||
final _moveStockKey = GlobalKey<FormState>();
|
||||
final _editStockKey = GlobalKey<FormState>();
|
||||
|
||||
_StockItemDisplayState(this.item);
|
||||
|
||||
|
|
@ -291,9 +290,6 @@ class _StockItemDisplayState extends RefreshableState<StockDetailWidget> {
|
|||
|
||||
void _transferStockDialog(BuildContext context) async {
|
||||
|
||||
var locations = await InvenTreeStockLocation().list();
|
||||
final _selectedController = TextEditingController();
|
||||
|
||||
int? location_pk;
|
||||
|
||||
_quantityController.text = "${item.quantityString}";
|
||||
|
|
@ -563,22 +559,21 @@ class _StockItemDisplayState extends RefreshableState<StockDetailWidget> {
|
|||
);
|
||||
}
|
||||
|
||||
if (item.notes.isNotEmpty) {
|
||||
tiles.add(
|
||||
ListTile(
|
||||
title: Text(L10().notes),
|
||||
leading: FaIcon(FontAwesomeIcons.stickyNote, color: COLOR_CLICK),
|
||||
onTap: () {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(builder: (context) => StockNotesWidget(item))
|
||||
);
|
||||
// TODO: Load notes in markdown viewer widget
|
||||
// TODO: Make this widget editable?
|
||||
}
|
||||
)
|
||||
);
|
||||
}
|
||||
// Notes field
|
||||
tiles.add(
|
||||
ListTile(
|
||||
title: Text(L10().notes),
|
||||
leading: FaIcon(FontAwesomeIcons.stickyNote, color: COLOR_CLICK),
|
||||
onTap: () {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(builder: (context) => StockNotesWidget(item))
|
||||
);
|
||||
// TODO: Load notes in markdown viewer widget
|
||||
// TODO: Make this widget editable?
|
||||
}
|
||||
)
|
||||
);
|
||||
|
||||
return tiles;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue