当前位置:网站首页>[uniapp native plug-in] shangmi cashbox plug-in
[uniapp native plug-in] shangmi cashbox plug-in
2022-06-11 22:13:00 【Tellsea】
List of articles
Shangmi cashbox plug-in
- Plug-in address :https://ext.dcloud.net.cn/plugin?id=8426
Plug in requirements
Before using plug-ins , Please use the trial version first , Debug locally , See if the plug-in meets , And then buy . If the plug-in doesn't meet your needs , You can contact me , Try to modify the plug-in or add functions , To help implement your business logic .
The plugin is introduced
As long as it is a cashbox connected to shangmi equipment , You can use this plug-in to open the cashbox , The cashbox does not limit the brand
Use cases
Get plug-ins
// Shangmi cashbox plug-in
let sunmiCashboxPlugin = uni.requireNativePlugin('Tellsea-SunmiCashboxPlugin');
console.log(' Shangmi cashbox plug-in :' + JSON.stringify(sunmiCashboxPlugin));
Connection service
// Connection service
connect() {
sunmiPrinterPlugin.connect((e) => {
let res = JSON.parse(e);
console.log(res);
if (res.code == 200) {
that.$msg(res.msg);
} else {
that.$msg(res.msg);
}
});
},
Disconnect service
// Disconnect service
disconnect() {
sunmiPrinterPlugin.disconnect((e) => {
let res = JSON.parse(e);
console.log(res);
if (res.code == 200) {
that.$msg(res.msg);
} else {
that.$msg(res.msg);
}
});
},
Open the money box
// Open the money box
openDrawer() {
sunmiCashboxPlugin.openDrawer((e) => {
let res = JSON.parse(e);
console.log(res);
if (res.code == 200) {
that.$msg(res.msg);
} else {
that.$msg(res.msg);
}
});
},
边栏推荐
- [academic related] under the application review system, how difficult is it to study for a doctoral degree in a double first-class university?
- Players must read starfish NFT advanced introduction
- R language book learning 03 "in simple terms R language data analysis" - Chapter 12 support vector machine Chapter 13 neural network
- Tkinter学习笔记(三)
- Tkinter study notes (II)
- Stack栈的实现
- [Chongqing Guangdong education] college physics of Xiangtan University: mechanical and thermal reference materials
- 高考结束,人生才刚刚开始,10年职场老鸟给的建议
- Basic operation and question type summary of linked list
- 消息队列入门MQ
猜你喜欢

Simple example of logistic regression for machine learning

仅需三步学会使用低代码ThingJS与森数据DIX数据对接

leetcode 257. Binary Tree Paths 二叉树的所有路径(简单)

R语言书籍学习03 《深入浅出R语言数据分析》-第十章 关联规则 第十一章 随机森林

Leetcode - day 2

电脑强制关机 oracle登录不上

Why is the printer unable to print the test page

二叉树的基本操作与题型总结

Inner join execution plan changed

Collection of articles and literatures related to R language (continuously updated)
随机推荐
Unity3D getLaunchIntentForPackage 获取包返回null问题
常用分页方法总结
如果重来一次高考,我要好好学数学!
还在直接用 localStorage 么?该提升下逼格了
Use the securecrtportable script function to read data from network devices
电脑强制关机 oracle登录不上
Why microservices are needed
Prefabricated dishes in the trillion market have also begun to roll inside. How can brands stand out in the fierce competition?
R语言相关文章、文献整理合集(持续更新)
使用VBScript读取网络的日志数据进行处理
玩家必读|Starfish NFT进阶攻略
Take off efficiently! Can it be developed like this?
超标量处理器设计 姚永斌 第2章 Cache --2.4 小节摘录
R7-1 列表或元组的数字元素求和
R语言书籍学习03 《深入浅出R语言数据分析》-第八章 逻辑回归模型 第九章 聚类模型
Go IO module
leetcode 257. Binary tree paths all paths to a binary tree (simple)
Go encoding package
Introduction to MySQL transactions
Basic operation and question type summary of binary tree