Add business profile links
This commit is contained in:
@@ -179,8 +179,26 @@ class MzansiProfileProvider extends ChangeNotifier {
|
||||
personalLinks[personalIndex] = updatedLink;
|
||||
}
|
||||
if (businessIndex != -1) {
|
||||
businessLinks[personalIndex] = updatedLink;
|
||||
businessLinks[businessIndex] = updatedLink;
|
||||
}
|
||||
notifyListeners();
|
||||
}
|
||||
|
||||
void reorderPersonalLinks({required int oldIndex, required int newIndex}) {
|
||||
if (oldIndex < newIndex) {
|
||||
newIndex -= 1;
|
||||
}
|
||||
final ProfileLink link = personalLinks.removeAt(oldIndex);
|
||||
personalLinks.insert(newIndex, link);
|
||||
notifyListeners();
|
||||
}
|
||||
|
||||
void reorderBusinessLinks({required int oldIndex, required int newIndex}) {
|
||||
if (oldIndex < newIndex) {
|
||||
newIndex -= 1;
|
||||
}
|
||||
final ProfileLink link = businessLinks.removeAt(oldIndex);
|
||||
businessLinks.insert(newIndex, link);
|
||||
notifyListeners();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user