DD-306 : WIP : Add Check Listing to menu to audit listings individually
parent
8cb399e3e5
commit
96172ddfe6
|
|
@ -698,6 +698,9 @@ void LLFloaterAssociateListing::cancel()
|
|||
// LLFloaterMarketplaceValidation
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
// Note: The key is the UUID of the folder to validate.
|
||||
// Validates the whole marketplace listings content if UUID is null.
|
||||
|
||||
LLFloaterMarketplaceValidation::LLFloaterMarketplaceValidation(const LLSD& key)
|
||||
: LLFloater(key),
|
||||
mEditor(NULL)
|
||||
|
|
@ -732,12 +735,18 @@ void LLFloaterMarketplaceValidation::onOpen(const LLSD& key)
|
|||
{
|
||||
// Clear the text panel
|
||||
mEditor->setValue(LLSD());
|
||||
|
||||
// Validates the marketplace
|
||||
LLUUID marketplacelistings_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_MARKETPLACE_LISTINGS, false);
|
||||
if (marketplacelistings_id.notNull())
|
||||
|
||||
// Get the folder UUID to validate. Use the whole marketplace listing if none provided.
|
||||
LLUUID cat_id(key.asUUID());
|
||||
if (cat_id.isNull())
|
||||
{
|
||||
LLViewerInventoryCategory* cat = gInventory.getCategory(marketplacelistings_id);
|
||||
cat_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_MARKETPLACE_LISTINGS, false);
|
||||
}
|
||||
|
||||
// Validates the folder
|
||||
if (cat_id.notNull())
|
||||
{
|
||||
LLViewerInventoryCategory* cat = gInventory.getCategory(cat_id);
|
||||
validate_marketplacelistings(cat, boost::bind(&LLFloaterMarketplaceValidation::appendMessage, this, _1, _2), false);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -163,6 +163,8 @@ private:
|
|||
//-----------------------------------------------------------------------------
|
||||
// LLFloaterMarketplaceValidation
|
||||
//-----------------------------------------------------------------------------
|
||||
// Note: The key is the UUID of the folder to validate. Validates the whole
|
||||
// marketplace listings content if UUID is null.
|
||||
// Note: For the moment, we just display the validation text. Eventually, we should
|
||||
// get the validation triggered on the server and display the html report.
|
||||
// *TODO : morph into an html/text window using the pattern in llfloatertos
|
||||
|
|
|
|||
|
|
@ -895,6 +895,7 @@ void LLInvFVBridge::addMarketplaceContextMenuOptions(U32 flags,
|
|||
// Options available at the Listing Folder level
|
||||
items.push_back(std::string("Marketplace Create Listing"));
|
||||
items.push_back(std::string("Marketplace Associate Listing"));
|
||||
items.push_back(std::string("Marketplace Check Listing"));
|
||||
items.push_back(std::string("Marketplace List"));
|
||||
items.push_back(std::string("Marketplace Unlist"));
|
||||
if (LLMarketplaceData::instance().isUpdating(mUUID))
|
||||
|
|
@ -3110,6 +3111,12 @@ void LLFolderBridge::performAction(LLInventoryModel* model, std::string action)
|
|||
LLFloaterAssociateListing::show(mUUID);
|
||||
return;
|
||||
}
|
||||
else if ("marketplace_check_listing" == action)
|
||||
{
|
||||
LLSD data(mUUID);
|
||||
LLFloaterReg::showInstance("marketplace_validation", data);
|
||||
return;
|
||||
}
|
||||
else if ("marketplace_edit_listing" == action)
|
||||
{
|
||||
std::string url = LLMarketplaceData::instance().getListingURL(mUUID);
|
||||
|
|
|
|||
|
|
@ -29,6 +29,14 @@
|
|||
parameter="marketplace_get_listing" />
|
||||
</menu_item_call>
|
||||
<menu_item_call
|
||||
label="Check listing"
|
||||
layout="topleft"
|
||||
name="Marketplace Check Listing">
|
||||
<menu_item_call.on_click
|
||||
function="Inventory.DoToSelected"
|
||||
parameter="marketplace_check_listing" />
|
||||
</menu_item_call>
|
||||
<menu_item_call
|
||||
label="Edit listing"
|
||||
layout="topleft"
|
||||
name="Marketplace Edit Listing">
|
||||
|
|
|
|||
Loading…
Reference in New Issue