Add optional job-id to prioritized/sorted operation attributes
Some printers are really picky...
This commit is contained in:
parent
51c90e6443
commit
5f71f2dd64
1 changed files with 6 additions and 2 deletions
|
@ -319,12 +319,16 @@ Bytestream IppMsg::encode()
|
||||||
QStringList InitialAttrs = {"attributes-charset",
|
QStringList InitialAttrs = {"attributes-charset",
|
||||||
"attributes-natural-language",
|
"attributes-natural-language",
|
||||||
"printer-uri",
|
"printer-uri",
|
||||||
|
"job-id",
|
||||||
"requesting-user-name"};
|
"requesting-user-name"};
|
||||||
for(QString key : InitialAttrs)
|
for(QString key : InitialAttrs)
|
||||||
|
{
|
||||||
|
if(_opAttrs.find(key) != _opAttrs.end())
|
||||||
{
|
{
|
||||||
QJsonObject val = _opAttrs.take(key).toObject();
|
QJsonObject val = _opAttrs.take(key).toObject();
|
||||||
encode_attr(ipp, val["tag"].toInt(), key, val["value"]);
|
encode_attr(ipp, val["tag"].toInt(), key, val["value"]);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
for(QJsonObject::iterator it = _opAttrs.begin(); it != _opAttrs.end(); it++)
|
for(QJsonObject::iterator it = _opAttrs.begin(); it != _opAttrs.end(); it++)
|
||||||
{ // encode any remaining op-attrs
|
{ // encode any remaining op-attrs
|
||||||
QJsonObject val = it.value().toObject();
|
QJsonObject val = it.value().toObject();
|
||||||
|
|
Loading…
Reference in a new issue