WPF实战学习笔记24-首页编辑与完成

news/2024/4/25 8:11:26/文章来源:https://blog.csdn.net/xinzhiya001/article/details/131994043

首页编辑与完成

  • indexview添加Listbox控件的鼠标双击行为
    • 添加todo、memo的编辑命令
    • indexviewmodel添加对应的更新事件处理
  • 添加ToggleButton与后台的绑定
    • 将ToggleButton的ischeck绑定到status属性
    • 添加bool int 转换器
    • 添加完成命令
    • 添加完成功能函数

Listbox添加行为

给行为添加命令空间

文件:Mytodo.Views.IndexView.cs

    xmlns:i="http://schemas.microsoft.com/xaml/behaviors"

添加行为事件

文件:Mytodo.Views.IndexView.cs

<i:Interaction.Triggers><i:EventTrigger EventName="MouseDoubleClick"><i:InvokeCommandAction Command="{Binding EditTodoCmd}" CommandParameter="{Binding ElementName=todolbox, Path=SelectedItem}" /></i:EventTrigger>
</i:Interaction.Triggers>
<i:Interaction.Triggers><i:EventTrigger EventName="MouseDoubleClick"><i:InvokeCommandAction Command="{Binding EditTodoCmd}" CommandParameter="{Binding ElementName=todolbox, Path=SelectedItem}" /></i:EventTrigger>
</i:Interaction.Triggers>

后台添加对应的命令,并初始化

文件:Mytodo.Views.IndexViewmodel.cs

/// <summary>
/// 命令:编辑备忘
/// </summary>
public DelegateCommand<MemoDto> EditMemoCmd { get;private set; }/// <summary>
/// 命令:编辑待办
/// </summary>
public DelegateCommand<ToDoDto> EditTodoCmd { get; private set; }
//初始化命令
EditMemoCmd = new DelegateCommand<MemoDto>(Addmemo);
EditTodoCmd = new DelegateCommand<ToDoDto>(Addtodo);

添加命令方法

文件:Mytodo.Views.IndexViewmodel.cs

/// <summary>
/// 添加待办事项
/// </summary>
async void Addtodo(ToDoDto model)
{DialogParameters param = new DialogParameters();if (model != null)param.Add("Value", model);var dialogres = await dialog.ShowDialog("AddTodoView", param);var newtodo = dialogres.Parameters.GetValue<ToDoDto>("Value");if (newtodo == null || string.IsNullOrEmpty(newtodo.Title) || (string.IsNullOrEmpty(newtodo.Content)))return;if (dialogres.Result == ButtonResult.OK){try{if (newtodo.Id > 0){var updres = await toDoService.UpdateAsync(newtodo);if (updres.Status){var todo = TodoDtos.FirstOrDefault(x=>x.Id.Equals(newtodo.Id));//更新信息todo.Content = newtodo.Content;todo.Title = newtodo.Title;todo.Status = newtodo.Status;}}else{//添加内容 //更新数据库数据var addres  = await toDoService.AddAsync(newtodo);//更新UI数据if (addres.Status){TodoDtos.Add(addres.Result);}}}catch {}finally{UpdateLoding(false);}}}/// <summary>
/// 添加备忘录
/// </summary>
async void Addmemo(MemoDto model)
{DialogParameters param = new DialogParameters();if (model != null)param.Add("Value", model);var dialogres = await dialog.ShowDialog("AddMemoView", param);if (dialogres.Result == ButtonResult.OK){try{var newmemo = dialogres.Parameters.GetValue<MemoDto>("Value");if (newmemo != null && string.IsNullOrWhiteSpace(newmemo.Content) && string.IsNullOrWhiteSpace(newmemo.Title))return;if (newmemo.Id > 0){var updres = await memoService.UpdateAsync(newmemo);if (updres.Status){//var memo = MemoDtos.FindFirst(predicate: x => x.Id == newmemo.Id);var memo = MemoDtos.FirstOrDefault( x => x.Id.Equals( newmemo.Id));//更新信息memo.Content = newmemo.Content;memo.Title = newmemo.Title;}}else{//添加内容var addres = await memoService.AddAsync(newmemo);//更新UI数据if (addres.Status){MemoDtos.Add(addres.Result);}}}catch{}finally{UpdateLoding(false);}}
}

添加ToggleButton绑定与check事件

添加转换器

添加文件:Mytodo.Common.Converters.BoolInt_TConverter.cs

using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;namespace Mytodo.Common.Converters
{public  class BoolInt_TConverter : IValueConverter{/// <summary>/// int to bool/// </summary>/// <param name="value"></param>/// <param name="targetType"></param>/// <param name="parameter"></param>/// <param name="culture"></param>/// <returns></returns>public object Convert(object value, Type targetType, object parameter, CultureInfo culture){if(value!=null&&int.TryParse(value.ToString(),out int result)){if(result==0)return true;elsereturn false;}return false;}/// <summary>/// bool to int /// </summary>/// <param name="value"></param>/// <param name="targetType"></param>/// <param name="parameter"></param>/// <param name="culture"></param>/// <returns></returns>public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture){if (value != null && bool.TryParse(value.ToString(), out bool result)){if (result)return 0;elsereturn 1;}return false;}}
}

添加转换器,添加命令

修改文件:Mytodo.Views.IndexView.xaml

  1. 添加命名空间
    xmlns:cv="clr-namespace:Mytodo.Common.Converters"
  1. 添加资源

        <UserControl.Resources><ResourceDictionary><cv:BoolInt_TConverter x:Key="BoolInt_TConverter" /></ResourceDictionary></UserControl.Resources>
    
  2. 绑定命令,添加转换器

    <ToggleButtonWidth="40"Command="{Binding DataContext.ToDoCompltedCommand, RelativeSource={RelativeSource Mode=FindAncestor,AncestorType=ItemsControl}}"CommandParameter="{Binding }"DockPanel.Dock="Right"IsChecked="{Binding Status, Converter={StaticResource BoolInt_TConverter}, Mode=TwoWay}" />
    <StackPanel>
    
  3. 定义命令,并初始化

    /// <summary>
    /// Todo完成命令
    /// </summary>
    public DelegateCommand<ToDoDto> ToDoCompltedCommand { get; set; }
    public IndexViewModel(IContainerProvider provider,IDialogHostService dialog) : base(provider)
    {//实例化接口this.toDoService= provider.Resolve<ITodoService>();this.memoService = provider.Resolve<IMemoService>();//实例化对象MemoDtos = new ObservableCollection<MemoDto>();TodoDtos = new ObservableCollection<ToDoDto>();//初始化命令EditMemoCmd = new DelegateCommand<MemoDto>(Addmemo);EditTodoCmd = new DelegateCommand<ToDoDto>(Addtodo);ToDoCompltedCommand = new DelegateCommand<ToDoDto>(Compete);ExecuteCommand = new DelegateCommand<string>(Execute);this.dialog = dialog;CreatBars();
    }
    
  4. 初始化命令操作函数

    /// <summary>
    /// togglebutoon 的命令
    /// </summary>
    /// <param name="dto"></param>
    /// <exception cref="NotImplementedException"></exception>
    async private void Compete(ToDoDto dto)
    {if (dto == null || string.IsNullOrEmpty(dto.Title) || (string.IsNullOrEmpty(dto.Content)))return;var updres = await toDoService.UpdateAsync(dto);if (updres.Status){var todo = TodoDtos.FirstOrDefault(x => x.Id.Equals(dto.Id));//更新信息todo.Status = dto.Status;}
    }
    

修改相关bug

修改Mytodo.ViewModels.cs

using Mytodo.Common.Models;
using Prism.Mvvm;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Reflection.Metadata;
using System.Text;
using System.Threading.Tasks;
using MyToDo.Share.Models;
using Prism.Commands;
using Prism.Services.Dialogs;
using Mytodo.Dialog;
using Mytodo.ViewModels;
using Mytodo.Service;
using Prism.Ioc;
using System.Diagnostics;
using Microsoft.VisualBasic;
using ImTools;
using DryIoc;
using MyToDo.Share;
using System.Windows;namespace Mytodo.ViewModels
{public class IndexViewModel:NavigationViewModel{#region 定义命令/// <summary>/// Todo完成命令/// </summary>public DelegateCommand<ToDoDto> ToDoCompltedCommand { get; set; }public DelegateCommand<string> ExecuteCommand { get; set; }/// <summary>/// 命令:编辑备忘/// </summary>public DelegateCommand<MemoDto> EditMemoCmd { get;private set; }/// <summary>/// 命令:编辑待办/// </summary>public DelegateCommand<ToDoDto> EditTodoCmd { get; private set; }#endregion#region 定义属性public string Title { get; set; }public ObservableCollection<MemoDto> MemoDtos{get { return memoDtos; }set { memoDtos = value; RaisePropertyChanged(); }}public ObservableCollection<ToDoDto> TodoDtos{get { return todoDtos; }set { todoDtos = value; RaisePropertyChanged(); }}/// <summary>/// 首页任务条/// </summary>public ObservableCollection<TaskBar> TaskBars{get { return taskBars; }set { taskBars = value; RaisePropertyChanged(); }}#endregion#region 定义重要命令#endregion#region 定义重要字段private readonly IDialogHostService dialog;private readonly ITodoService toDoService;private readonly IMemoService memoService;#endregion#region 定义普通字段private ObservableCollection<TaskBar> taskBars;private ObservableCollection<ToDoDto> todoDtos;private ObservableCollection<MemoDto> memoDtos;#endregion#region 命令相关方法/// <summary>/// togglebutoon 的命令/// </summary>/// <param name="dto"></param>/// <exception cref="NotImplementedException"></exception>async private void Compete(ToDoDto dto){if (dto == null || string.IsNullOrEmpty(dto.Title) || (string.IsNullOrEmpty(dto.Content)))return;var updres = await toDoService.UpdateAsync(dto);if (updres.Status){var todo = TodoDtos.FirstOrDefault(x => x.Id.Equals(dto.Id));//更新信息todo.Status = dto.Status;}}/// <summary>/// 选择执行命令/// </summary>/// <param name="obj"></param>void Execute(string obj){switch (obj){case "新增待办": Addtodo(null); break;case "新增备忘": Addmemo(null); break;}}/// <summary>/// 添加待办事项/// </summary>async void Addtodo(ToDoDto model){DialogParameters param = new DialogParameters();if (model != null)param.Add("Value", model);var dialogres = await dialog.ShowDialog("AddTodoView", param);var newtodo = dialogres.Parameters.GetValue<ToDoDto>("Value");if (newtodo == null || string.IsNullOrEmpty(newtodo.Title) || (string.IsNullOrEmpty(newtodo.Content)))return;if (dialogres.Result == ButtonResult.OK){try{if (newtodo.Id > 0){var updres = await toDoService.UpdateAsync(newtodo);if (updres.Status){var todo = TodoDtos.FirstOrDefault(x=>x.Id.Equals(newtodo.Id));//更新信息todo.Content = newtodo.Content;todo.Title = newtodo.Title;todo.Status = newtodo.Status;}}else{//添加内容 //更新数据库数据var addres  = await toDoService.AddAsync(newtodo);//更新UI数据if (addres.Status){TodoDtos.Add(addres.Result);}}}catch {}finally{UpdateLoding(false);}}}/// <summary>/// 添加备忘录/// </summary>async void Addmemo(MemoDto model){DialogParameters param = new DialogParameters();if (model != null)param.Add("Value", model);var dialogres = await dialog.ShowDialog("AddMemoView", param);if (dialogres.Result == ButtonResult.OK){try{var newmemo = dialogres.Parameters.GetValue<MemoDto>("Value");if (newmemo != null && string.IsNullOrWhiteSpace(newmemo.Content) && string.IsNullOrWhiteSpace(newmemo.Title))return;if (newmemo.Id > 0){var updres = await memoService.UpdateAsync(newmemo);if (updres.Status){//var memo = MemoDtos.FindFirst(predicate: x => x.Id == newmemo.Id);var memo = MemoDtos.FirstOrDefault( x => x.Id.Equals( newmemo.Id));//更新信息memo.Content = newmemo.Content;memo.Title = newmemo.Title;}}else{//添加内容var addres = await memoService.AddAsync(newmemo);//更新UI数据if (addres.Status){MemoDtos.Add(addres.Result);}}}catch{}finally{UpdateLoding(false);}}}#endregion#region 其它方法#endregion#region 启动项相关void CreatBars(){Title = "您好,2022";TaskBars = new ObservableCollection<TaskBar>();TaskBars.Add(new TaskBar { Icon = "CalendarBlankOutline", Title = "汇总", Color = "#FF00FF00", Content = "27", Target = "" });TaskBars.Add(new TaskBar { Icon = "CalendarMultipleCheck", Title = "已完成", Color = "#6B238E", Content = "24", Target = "" });TaskBars.Add(new TaskBar { Icon = "ChartLine", Title = "完成比例", Color = "#32CD99", Content = "100%", Target = "" });TaskBars.Add(new TaskBar { Icon = "CheckboxMarked", Title = "备忘录", Color = "#5959AB", Content = "13", Target = "" });}#endregionpublic IndexViewModel(IContainerProvider provider,IDialogHostService dialog) : base(provider){//实例化接口this.toDoService= provider.Resolve<ITodoService>();this.memoService = provider.Resolve<IMemoService>();//实例化对象MemoDtos = new ObservableCollection<MemoDto>();TodoDtos = new ObservableCollection<ToDoDto>();//初始化命令EditMemoCmd = new DelegateCommand<MemoDto>(Addmemo);EditTodoCmd = new DelegateCommand<ToDoDto>(Addtodo);ToDoCompltedCommand = new DelegateCommand<ToDoDto>(Compete);ExecuteCommand = new DelegateCommand<string>(Execute);this.dialog = dialog;CreatBars();}}
}

修改Mytodo.AddMemoViewModel.cs

using MaterialDesignThemes.Wpf;
using Mytodo.Dialog;
using MyToDo.Share.Models;
using Prism.Commands;
using Prism.Mvvm;
using Prism.Services.Dialogs;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;namespace Mytodo.ViewModels.Dialogs
{internal class AddMemoViewModel : BindableBase, IDialogHostAware{public AddMemoViewModel(){SaveCommand = new DelegateCommand(Save);CancelCommand = new DelegateCommand(Cancel);}private MemoDto model;public MemoDto Model{get { return model; }set { model = value; RaisePropertyChanged(); }}private void Cancel(){if (DialogHost.IsDialogOpen(DialogHostName))DialogHost.Close(DialogHostName, new DialogResult(ButtonResult.No));}private void Save(){if (DialogHost.IsDialogOpen(DialogHostName)){//确定时,把编辑的实体返回并且返回OKDialogParameters param = new DialogParameters();param.Add("Value", Model);DialogHost.Close(DialogHostName, new DialogResult(ButtonResult.OK, param));}}public string DialogHostName { get; set; }public DelegateCommand SaveCommand { get; set; }public DelegateCommand CancelCommand { get; set; }public void OnDialogOpend(IDialogParameters parameters){if (parameters.ContainsKey("Value")){Model = parameters.GetValue<MemoDto>("Value");if(Model == null) {Model = new MemoDto();}c}elseModel = new MemoDto();}}
}

修改Mytodo.AddTodoViewModel.cs

using MaterialDesignThemes.Wpf;
using Mytodo.Dialog;
using MyToDo.Share.Models;
using Prism.Commands;
using Prism.Mvvm;
using Prism.Services.Dialogs;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;namespace Mytodo.ViewModels.Dialogs
{internal class AddTodoViewModel : BindableBase, IDialogHostAware{public AddTodoViewModel(){SaveCommand = new DelegateCommand(Save);CancelCommand = new DelegateCommand(Cancel);}private ToDoDto model;/// <summary>/// 新增或编辑的实体/// </summary>public ToDoDto Model{get { return model; }set { model = value; RaisePropertyChanged(); }}/// <summary>/// 取消/// </summary>private void Cancel(){if (DialogHost.IsDialogOpen(DialogHostName))DialogHost.Close(DialogHostName, new DialogResult(ButtonResult.No)); //取消返回NO告诉操作结束}/// <summary>/// 确定/// </summary>private void Save(){if (DialogHost.IsDialogOpen(DialogHostName)){//确定时,把编辑的实体返回并且返回OKDialogParameters param = new DialogParameters();param.Add("Value", Model);DialogHost.Close(DialogHostName, new DialogResult(ButtonResult.OK, param));}}public string DialogHostName { get; set; }public DelegateCommand SaveCommand { get; set; }public DelegateCommand CancelCommand { get; set; }public void OnDialogOpend(IDialogParameters parameters){if (parameters.ContainsKey("Value")){Model = parameters.GetValue<ToDoDto>("Value");if (Model == null){Model = new ToDoDto();Model.Status = 1;}}else{Model = new ToDoDto();Model.Status = 1;}}}
}

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.luyixian.cn/news_show_337283.aspx

如若内容造成侵权/违法违规/事实不符,请联系dt猫网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

JS-----数据结构与算法(2)

目录 三. 栈结构 1.认识栈结构 2. 封装栈结构 3. 应用 3-1 十进制转二进制 3-2 进制转换法 四. 队列 1.队列是什么&#xff1f; 2.队列的封装 3. 队列的应用-击鼓传花 4. 双端队列 5.判断是否为回文 三. 栈结构 1.认识栈结构 栈&#xff08;stack&#xff09;又…

7.29训练总结

CodeForces - 1609E 这种使得整个串不包含子串’abc’的题目&#xff0c;发现可以用线段树维护 #include<bits/stdc.h> using namespace std; const int maxn1e55; #define lson now<<1 #define rson now<<1|1 struct seg {int a,b,c;int ab,bc,abc; }tr[m…

2023 年还推荐报计算机专业吗?

计算机科学是一个很好的专业&#xff0c;因为它由各种课程组成&#xff0c;为学生在成熟和新兴专业就业做好准备。以下是一些通常属于计算机科学专业的课程&#xff1a; 基本编程介绍了用于构建和维护数字架构和基础设施的编程语言和标准。 微积分为制定高级计算和设计概念提供…

eclipse 最新版没有navigator视图如何解决

使用project exploere视图可以显示类似navigator视图 1.显示project exploere视图 window---->show view --->project exploere 2.project exploere视图转换为类似navigator视图 第一步&#xff1a;点击视图右上角三个点或者倒三角&#xff0c;点击fiters and custom…

蓝图节点编辑器

打印字符串 第02章 蓝图结构 03 -注释和重新路由_哔哩哔哩_bilibili 第02章 蓝图结构 04 - 变量_哔哩哔哩_bilibili 第03章 蓝图简易门 01 - 箱子碰撞_哔哩哔哩_bilibili 第03章 蓝图简易门 02 - 静态Mesh和箭头_哔哩哔哩_bilibili 第03章 蓝图简易门 03 - 设置相对旋转节点_哔…

rocketmq rsqldb 简单记录

GitHub 地址 https://github.com/alibaba/rsqldb/tree/main&#xff0c;是和目前stream sql化看齐的Rocketmq的sql&#xff0c;类似还有kafka的sqlDB 和flink sql。 目前版本0.2 &#xff0c;主要提供rest模式调用&#xff0c;controller类为public class RsqlController支持的…

6G内存运行Llama2-Chinese-7B-chat模型

6G内存运行Llama2-Chinese-7B-chat模型 Llama2-Chinese中文社区 第一步&#xff1a; 从huggingface下载 Llama2-Chinese-7b-Chat-GGML模型放到本地的某一目录。 第二步&#xff1a; 执行python程序 git clone https://github.com/Rayrtfr/llama2-webui.gitcd llama2-web…

儿童居家健身好伙伴,小莫计数摸高训练器

现在的孩子们的越来越不喜欢运动了&#xff0c;总是爱玩手机游戏&#xff0c;对他们的身体健康非常不好&#xff0c;作为家长&#xff0c;我们希望能够给孩子提供更多的运动机会&#xff0c;有必要每天准备一些能让他们活动活动手脚的小游戏&#xff0c;让他们每天有足够的运动…

Pytorch个人学习记录总结 10

目录 优化器 优化器 官方文档地址&#xff1a;torch.optimhttps://pytorch.org/docs/stable/optim.html Debug过程中查看的grad所在的位置&#xff1a; model --> Protected Atributes --> _modules --> ‘model’ --> Protected Atributes --> _modules -…

【matlab】机器人工具箱快速上手-动力学仿真(代码直接复制可用)

动力学代码&#xff0c;按需修改参数 各关节力矩-关节变量的关系曲线&#xff1a; %%%%%%%%SCARA机器人仿真模型 l[0.457 0.325]; L(1) Link(d,0,a,l(1),alpha,0,standard,qlim,[-130 130]*pi/180);%连杆1 L(2)Link(d,0,a,l(2),alpha,pi,standard,qlim,[-145 145]*pi/180);%连…

小学期笔记——天天酷跑1

文件快照&#xff08;File snapshot&#xff09;通常是指对文件系统中某个特定时间点的文件或文件夹的快照或副本。它记录了文件或文件夹在某一时刻的状态&#xff0c;包括文件的内容、属性、权限、位置等信息。 文件快照通常用于数据备份、恢复和版本控制等目的。通过捕捉文件…

关于c++中虚函数和虚函数表的创建时机问题

以这段代码为例。 #include <iostream>using namespace std;class Parent { public:Parent(){}virtual void func1() {};virtual void func2() {}; };class Child :public Parent { public:Child():n(0),Parent(){cout << "Child()" << endl;}vir…

【网络原理】 (1) (应用层 传输层 UDP协议 TCP协议 TCP协议段格式 TCP内部工作机制 确认应答 超时重传 连接管理)

文章目录 应用层传输层UDP协议TCP协议TCP协议段格式TCP内部工作机制确认应答超时重传 网络原理部分我们主要学习TCP/IP协议栈这里的关键协议(TCP 和 IP),按照四层分别介绍.(物理层,我们不涉及). 应用层 我们需要学会自定义一个应用层协议. 自定义协议的原因? 当前的软件(应用…

轮趣科技教育版ros小车键盘控制运动

我之前买的ros小车是单独买的底板&#xff0c;以为随便一个树莓派就可以&#xff0c;因为我以前有一个树莓派3B&#xff0c;后来买了单独的小车之后&#xff0c;发现只能使用树莓派4B&#xff0c;然后又单独买了一个树莓派4B&#xff0c;给装上镜像&#xff0c;安装ros-melodic…

基于因果关系知识库的因果事件图谱构建、文本预处理、因果事件抽取、事件融合等

项目设计集合&#xff08;人工智能方向&#xff09;&#xff1a;助力新人快速实战掌握技能、自主完成项目设计升级&#xff0c;提升自身的硬实力&#xff08;不仅限NLP、知识图谱、计算机视觉等领域&#xff09;&#xff1a;汇总有意义的项目设计集合&#xff0c;助力新人快速实…

IntersectionObserver实现小程序长列表优化

IntersectionObserver实现小程序长列表优化 关于 IntersectionObserver 思路 这里以一屏数据为单位【一个分页的10条数据&#xff0c;最好大于视口高度】&#xff0c; 监听每一屏数据和视口的相交比例&#xff0c;即用户能不能看到它 只将可视范围的数据渲染到页面上&#x…

基于注解的 SpringMVC

SpringMVC SpringMVC使用SpringMVC的两个配置EnableWebMVC 和 ACWACSpringMVC执行流程接收请求参数Postman 发包工具&#xff08;&#xff09;get 请求---简单类型数据&#xff08;基本数据类型和String&#xff09;get 请求---对象类型数据get 请求---数组类型get 请求 --- 集…

Codeforces Round 886 (Div. 4)F题解

文章目录 [We Were Both Children](https://codeforces.com/contest/1850/problem/F)问题建模问题分析1.分析到达的点与跳跃距离的关系2.方法1倍数法累计每个点所能达到的青蛙数代码 方法2试除法累计每个点能到达的青蛙数代码 We Were Both Children 问题建模 给定n个青蛙每次…

自动驾驶感知系统--惯性导航定位系统

惯性导航定位 惯性是所有质量体本身的基本属性&#xff0c;所以建立在牛顿定律基础上的惯性导航系统&#xff08;Inertial Navigation System,INS&#xff09;(简称惯导系统)不与外界发生任何光电联系&#xff0c;仅靠系统本身就能对车辆进行连续的三维定位和三维定向。卫星导…

前端框架学习-Vue(二)

最近在学习Vue框架&#xff0c;Vue中的内容很多。相当于把之前后端的MVC&#xff0c;V层转移到前端来编写和部署。下面是学习Vue时的大纲。 Vue生命周期是Vue应用的生命周期Vue脚手架&#xff0c;即vue-cli&#xff0c;使用node.js 来创建和启动vue项目Vue组件知识&#xff0c;…